Status
Not open for further replies.

Isabella Ava

Veteran
Veteran
Joined
Sep 13, 2016
Messages
635
Reaction score
756
First Language
English
Hi, is Console window that open when we press F8 is a built-in system of MV?
It's just so very convenient to have this Window, because beside of displaying Errors,
it even allow Users to check objects' properties/ functions/ ....
Now that when i using some other Game Engines those also written with Javascript,
it's so awkward to not have a Console Window like RMV's one.
Even when i tried to print out a random message like this:
console.log("hello");
the game crashed and display message "console is not defined"
@.@ (what? isn't console.log is default command of javascript?)

Is there anyway to have a Console window like MV for another Javascript Game Engine?
Thank you = )
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,179
Reaction score
14,659
First Language
English
Primarily Uses
RMMV
No, it's not. It's a browser tool. If your other game engine runs its games in a web browser, you should be able to open the developer tools and go to the Console window. It just may not have F8 as a shortcut key.
 

Poryg

Dark Lord of the Castle of Javascreeps
Veteran
Joined
Mar 23, 2017
Messages
4,125
Reaction score
10,657
First Language
Czech
Primarily Uses
RMMV
As mentioned, it's a browser tool. A lot of browsers have a default shortcut f12 (nw.js as well btw., some plugins just overwrite this key to do their bidding).
Also, Javascript is an interpreted language, not a compiled one. As such it only depends on the interpreter which functions are included and which not (and it also explains why in some browsers some functions aren't supported or do slightly different stuff than other browsers). Since some apps have custom JS interpreters, they often omit the console.
 

Isabella Ava

Veteran
Veteran
Joined
Sep 13, 2016
Messages
635
Reaction score
756
First Language
English
Thanks Shaz ,@Poryg, so in MV case, whose browser's tool was it?
Does that mean MV just take advantage of some available Tool and implement it into MV?
 

Poryg

Dark Lord of the Castle of Javascreeps
Veteran
Joined
Mar 23, 2017
Messages
4,125
Reaction score
10,657
First Language
Czech
Primarily Uses
RMMV

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
42,179
Reaction score
14,659
First Language
English
Primarily Uses
RMMV

So it is related to javascript? I tried a few different web pages to see if they all brought up the dev tools and console, but all the ones I tested were js so I still couldn't be sure on that.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
32,535
Reaction score
8,152
First Language
German
Primarily Uses
RMMV
@Isabella Ava you missed the main part - RMMV did nothing but provide a shortcut, it is always part of the browser.
If you playtest in firefox, it will be firefox that provides the console. If you playtest in chrome, it will be chrome that provides the console.

The editor has a variant of a browser (chromium-based if I remember correctly) integrated, but that is only for convenience - the console still comes from the browser and not the editor.
 

Isabella Ava

Veteran
Veteran
Joined
Sep 13, 2016
Messages
635
Reaction score
756
First Language
English
@Andar wait, you mean when i press F8, MV just open the Browser's Dev Tool through a shortcut?
But then how could that Dev Tool able to display error/ objects/ properties those are within my project?
... = | hmm it's kinda confuse. Unless those Dev Tool was implemented inside MV somehow, how could it access MV project like that?
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
32,535
Reaction score
8,152
First Language
German
Primarily Uses
RMMV
the MV games are HTML5-games, they always run inside a browser. The console accesses the browser data, nothing more. The editor writes and stores everything as HTML5.
 

Poryg

Dark Lord of the Castle of Javascreeps
Veteran
Joined
Mar 23, 2017
Messages
4,125
Reaction score
10,657
First Language
Czech
Primarily Uses
RMMV
@Shaz Not sure what concretely is related to Javascript.

@Isabella Ava Dev tools are implemented inside nw.js, which is a web browser. MV only provided the shortcut so it can open your project remotely. It's not implemented into MV, it's just opened by MV editor upon hitting Playtest.
 

Poryg

Dark Lord of the Castle of Javascreeps
Veteran
Joined
Mar 23, 2017
Messages
4,125
Reaction score
10,657
First Language
Czech
Primarily Uses
RMMV
@Isabella Ava Nowadays we don't need to create it, since even a basic console application made in C++ can be debugged using the cout << stuff.
If you want to create 100% your own, you need to have a firm grasp of a programming language.
It's a subprocess, so accessing the app's variables won't be a problem. But you need something to handle graphical output and you'd need the console class to be a friend of every class in the program in order for their methods to be accessible by the console. So overall it's not that difficult, you just need to know what you're doing.

In the worst case you could also do it via memory scanning using C++, but that's rather complicated.
 

Isabella Ava

Veteran
Veteran
Joined
Sep 13, 2016
Messages
635
Reaction score
756
First Language
English
@Poryg mm so in the case i am trying to access to data of a Game Engine based on Javascript, how should i access its data? (for example. to access a single objects & its properties)
In the case i am trying to access its data from a 3rd party software made by myself?
Is there some simple way like.. reading a text file or st?? = ))
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,305
Reaction score
11,734
First Language
English
Primarily Uses
RMVXA
We do not support queries about other game engines.
[mod]Closing this.[/mod]
 
Status
Not open for further replies.

Latest Threads

Latest Posts

Latest Profile Posts

We're playing Omori by OMOCAT starting at 2pm est :D
Hi there! Do you actively use your Itch.io account? How do you use it?
When you have your friend over and you try to have a good time and let him try your game but he legit finds 10+ bugs that you now have to add to your already big workload for the day lol.

Forum statistics

Threads
111,337
Messages
1,060,258
Members
144,655
Latest member
Lyorna
Top