Common Events / Events / Interpreter Stuff Does Not Work on Scenes

I noticed that you can't directly execute a command in a scene. On my custom scene, I added a command that does this:

$gameTemp.reserveCommonEvent(1);But what happens is that I need to get out of the scene before the common event is executed. Same goes when I add a game message instead of a common event. 

Is there a way to override the scene so I can make the common event while in the scene?
They don't run until you return to the map, because those things are associated with Scene_Map.


Hime wrote a script in Ace that would allow you to execute common events in other scenes. I don't know if it's been ported to MV yet, but if I were looking for one, that's where I'd start my search 🙂
You could store an instance of the scene_map into a container of some kind and then in your scene call it so lets assume you stored the instance in a container called "MySceneMap" then you could do: MySceneMap.getSceneMap().callSceneMapFunctionHere()

I talk about this in one of my blog posts where I state you can use containers to pass around instances of classes or other forms of data.
Please don't store references to the scene. You run the risk to keep it around, so it doesn't get garbage collected properly. If needed, you can use this snippet to get the current scene:

Code:
SceneManager._scene;
Please don't store references to the scene. You run the risk to keep it around, so it doesn't get garbage collected properly. If needed, you can use this snippet to get the current scene:

SceneManager._scene;
Yes I use this when I need to check the instance of that scene if its somewhere else. It seems executing common events directly on scenes is harder than I expected it to be. Gotta try lots of ways, I guess. If any ideas are open, please do help.
Please don't store references to the scene. You run the risk to keep it around, so it doesn't get garbage collected properly. If needed, you can use this snippet to get the current scene:

SceneManager._scene;
Not if you clean up after your self, when you pop the old scene off or refresh the current scene you empty the container holding the reference. My laws for Map and Currencies script does this to pass information and scene states and scene instances around. The trick is:

  1. Empty Always
  2. Re Store
  3. Use
  4. Empty on scene pop/refresh, re store if needed.

The issue you run into is when you don't empty the container holding the instance.
Does anyone have an alternative way to overhaul the event in the scene then? 🙁
you could pm tsukihime to convert her scene interpreter plugin...

or if you know how to code... you could add new interpreter inside Scene_Base. and update it.

edit: even if you add interpreter to scene base... not all event command can work... mainly moveroute and show animation... you need to add more code to make it work.
Yeah, it seems it needs a little bit of adjusting. I'll ask someone who knows this as much as I do.

Original thread: https://forums.rpgmakerweb.com/threads/common-events-events-interpreter-stuff-does-not-work-on-scenes.52795/