• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Possible to make creaturescripts work for all creatures??

Mazen

Developer
Joined
Aug 20, 2007
Messages
612
Reaction score
38
Location
Sweden
Hey everyone.

I just want to ask a question, as the title say, is it possible to make a creature script work for all creatures, for both monsters and players?

What I know is that you need to register a creature event for a creature to make it work. (With the function registerCreatureEvent(cid, creatureEvent) that you put in login.lua, but monsters doesn't login )

Is it possible to make a creatureevent registered to all creatures automatically? Or do I have to use the registerCreatureEvent function every time I want to make a creature event work?
 
Oh, I didn't know that feature. Nice!

Thank you. :)

But the only problem is that I might want a creature script to work on all creatures. It will be too hard to write that on every creature xml file. :/

Open all creatures with notepad++, go to "change on all files"

change:
PHP:
</monster>

to:
PHP:
  <script>
    <event name="CreatureScript"/>
  </script>
</monster>

I use this method, try! =)
 
Back
Top