World Events

Posted by Seriley on Sun 13 Mar 2011 03:44 AM — 3 posts, 14,388 views.

#0

World Events

You can put the names for subroutines (functions) that you want called for the various events below. The name must match the name of a function in your world file. For example, if you specify "OnWorldOpen" for the "open" event below, then your script should look like this (in Lua):

function OnWorldOpen ()
  Note ("World has been opened")
end -- function OnWorldOpen 


When it specifies that the function called must match the name of a function in your world file, is it talking about the script file that is loaded each time the world is loaded, or actually putting the file in the .mcl?

Thanks
Australia Forum Administrator #1
The script file associated with this world. In other words, the script file you have chosen further up in the dialog for this world.
#2
Thank you, Nick