[Home] [Downloads] [Search] [Help/forum]

Gammon Software Solutions forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  MUSHclient
. -> [Folder]  General
. . -> [Subject]  World Events

Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?

World Events

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page


Posted by Seriley   (42 posts)  [Biography] bio
Date Sun 13 Mar 2011 03:44 AM (UTC)  quote  ]
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
[Go to top] top

Posted by Nick Gammon   Australia  (18,770 posts)  [Biography] bio   Forum Administrator
Date Reply #1 on Sun 13 Mar 2011 04:32 AM (UTC)  quote  ]
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
[Go to top] top

Posted by Seriley   (42 posts)  [Biography] bio
Date Reply #2 on Sun 13 Mar 2011 04:44 AM (UTC)  quote  ]
Message
Thank you, Nick
[Go to top] 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.


749 views.

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

[Home]

Written by Nick Gammon - 5K

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( http://www.gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Internet Contents Rating Association (ICRA) - 2K]    [Web site powered by FutureQuest.Net]