Register forum user name Search FAQ

Gammon Forum

Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the password reset link.

Due to spam on this forum, all posts now need moderator approval.

 Entire forum ➜ MUSHclient ➜ General ➜ World Events

World Events

It is now over 60 days since the last post. This thread is closed.     Refresh page


Posted by Seriley   (42 posts)  Bio
Date Sun 13 Mar 2011 03:44 AM (UTC)
Message

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
Top

Posted by Nick Gammon   Australia  (23,133 posts)  Bio   Forum Administrator
Date Reply #1 on Sun 13 Mar 2011 04:32 AM (UTC)
Message
The script file associated with this world. In other words, the script file you have chosen further up in the dialog for this world.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
Top

Posted by Seriley   (42 posts)  Bio
Date Reply #2 on Sun 13 Mar 2011 04:44 AM (UTC)
Message
Thank you, Nick
Top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


11,015 views.

It is now over 60 days since the last post. This thread is closed.     Refresh page

Go to topic:           Search the forum


[Go to top] top

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.