Dreamsavior

Villager
Member
Joined
Mar 31, 2016
Messages
12
Reaction score
71
First Language
Not English
Primarily Uses
RMMV
Hi everyone,

Sorry if this question has been asked before. I've been looking for an answer to this question and every solution to this question leads to a script that only detects the keyboard button in the map, not in the menu.

What I need is to detect the keyboard while the menu is open.

Please enlighten me on this.
 

Andar

Regular
Regular
Joined
Mar 5, 2013
Messages
39,908
Reaction score
11,860
First Language
German
Primarily Uses
RMMV
what do you want to happen when the key is pressed?

and just to make sure we are on the same page, because you posted in the wrong forum in all cases:
scripting is not the same as eventing. Those two words have ver specific meanings in all RPG Makers.

On the map, keyboard presses can be detected by both eventing and scripting (scripting as in programm code, not as in sequences of event commands).
On the menu, events can't be processed at all.

Second problem: The scripting language is different depending on the maker, and it can't be used in the wrong maker. You posted in the forum for Ace, which would be for an evented solution in Ace. Ace uses RGSS3 as a script language however, and any change to the menu requires you to insert a full script with the script editor. And those question would belong under RGSS3 script requests, not here.

However your profile says that you're using MV, and MV uses javascript as a language. Any change to the menu in MV will require a plugin to be added, and that would go into the plugin request forum for MV.

So what exactly do you want? please report that to a moderator so that your topic can be moved after you added the missing info.
 

Dreamsavior

Villager
Member
Joined
Mar 31, 2016
Messages
12
Reaction score
71
First Language
Not English
Primarily Uses
RMMV
Hi Andar, Thank you for your quick response.
First of all, The thing I asked is for RPG Maker VX Ace. and by VX Ace, it is indeed RGSS3.

Why you might asked. Well I'm translator and a modder. I need a script that will trigger a ruby script (or common events) when you pressing certain key while you're on the menu. And yes, because my field of expertise is JavaScript and not Ruby... I really need a help here.

And lastly, Apologize if I'm in the wrong forum.
 

Andar

Regular
Regular
Joined
Mar 5, 2013
Messages
39,908
Reaction score
11,860
First Language
German
Primarily Uses
RMMV
Doesn't work exactly that way.

The script you want to trigger needs to be rewritten in a way that it implements that key trigger for itself into the update method of the menu.

There is no game interpreter in the menu screen, that is why all item-based common events close the menu and return to the map to have their common event processed.
Because of that there is no way to check for any key from outside the menu, the check needs to be implemented into the menu code itself - and that can only be done by a full script.

And instead of murking up the code by having a script that adds a key check just to call another script, it's better to modify the script that is supposed to be called to provide its own key trigger on the screens.
The only exception to this is if you don't want to call a script but a default script function, in that case you would need an independent script.

If you only want to process a common event while in the menu itself, there are already scripts for that - either tsukihime's menu interpreter on himeworks or yanfly's common event menu.
 

Latest Threads

Latest Profile Posts

"Do this task for me, and you will be allowed to eat your weight in gold as a reward".
Hmm. Like. I do art things. But, every time I try to make a logo I keep thinking about how awesome it would be if I was not doing it. That may go into the outsource pile. :kaothx:
I put lights up in my living room! And, a stego with hats ^-^
20231130_131859.jpg
Yo, anybody seen this yet?
At what stage are you?

87shj5.jpg

Forum statistics

Threads
136,627
Messages
1,268,124
Members
180,305
Latest member
Tony_Waters
Top