Game Development Community

World editor switching problem. What am I doing wrong here?

by Petter Holmberg · in Torque Game Engine · 10/18/2005 (5:55 am) · 0 replies

I have a strange problem with the game I'm working on.

In the scripts there are many references to objects I have in the MissionGroup. For instance there are lines that switch between different cameras in the current mission. I am referencing to these objects by their (semi)-full string pathway, like this:

"MissionGroup/MySimGroup/MyObject".someFunction(someArgument);

This works fine. No problem at all using the objects. But when I go into the world editor (F11) and then switch back again to my game (immediately or after doing some editing, doesn't matter), the next time some script command like the one above gets executed, it can't find the object! Even the same calls that worked previously to the toggling of the world editor stops working. But if I type in that same command in the console on the other hand, it does work and it does find the object, both before and after. I haven't noticed any changes to my objects after having visited the world editor, but something in the running of the scripts has gone broken. Any idea what's causing this?