Closing the Menu Scene with an event

Songsmith

Veteran
Veteran
Joined
Jun 17, 2016
Messages
66
Reaction score
4
First Language
English
Primarily Uses
N/A
I have an item called "glowing box" that gives the player a random legendary item on opening. Because of this, it needs to open up a message window when it is used, telling the player which item they got. However, when using this item from the item menu I get a crash saying, "cannot read property "refresh" of undefined". I'm pretty sure that the problem is the item's common event trying to open a message box while the menu is still open.

I am using MOGHunter's menu plugins, including his item_scene plugin. When I turn it off, this works fine, so this is almost certainly an issue with that plugin. That being said, is there a way around this? If I could just force close the menu with an event, I'm pretty sure that would fix this problem. Is that possible?
 
Last edited:

Trihan

Speedy Scripter
Veteran
Joined
Apr 12, 2012
Messages
2,604
Reaction score
1,960
First Language
English
Primarily Uses
RMMV
You could do

SceneManager.push(Scene_Map)

as a script call, maybe.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,370
Reaction score
7,678
First Language
German
Primarily Uses
RMMV
I'm pretty sure that the problem is the item's common event trying to open a message box while the menu is still open.
Nope - that is impossible unless you've installed some extreme plugins, which would mean the problem isn't at this point anyway.

The menu automatically closes because the entire common event called by item use needs to be processed on the map. It cannot be processed on the menu at all unless you installed one of the scene-interpreter plugins. And even if you do that, all of those plugins support the show text command, so it wouldn't cause this problem anyway.

Please give a screenshot of the common event and of the console output (F8) when the crash happens, that will allow us to identify what really is the cause.
 

Songsmith

Veteran
Veteran
Joined
Jun 17, 2016
Messages
66
Reaction score
4
First Language
English
Primarily Uses
N/A
I have no idea why, but it has suddenly started working on its own. (I changed many seemingly unrelated things in the meantime.) Thank you for everyone who attempted to help. If it breaks again, I'll let you know, haha.
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,370
Reaction score
7,678
First Language
German
Primarily Uses
RMMV
(I changed many seemingly unrelated things in the meantime.)
Nothing is completely unrelated in a computer, because everything goes down to numbers and the computer doesn't understand what the numbers represent. One of the more strange (but reproducable) effects I ever encountered was that a wrong but working mouse driver under Windows98 created a black line (display error) under DOS.

That said, if you don't know why an unrelated changed affected this (or did changes at random to solve this), then there is a high chance you created other bugs with those changes.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

Are we allowed to post about non-RPG Maker games? And, if so, would any of you be interested in a short, proof of concept type non-euclidian puzzle game?
I should realize that error was produced by a outdated version of MZ so that's why it pop up like that
Ami
i can't wait to drink some ice after struggling with my illness in 9 days. 9 days is really bad for me,i can't focus with my shop and even can't do something with my project
How many hours have you got in mz so far?

A bit of a "sparkle" update to the lower portion of the world map. :LZSexcite:

Forum statistics

Threads
105,883
Messages
1,017,234
Members
137,608
Latest member
Arm9
Top