Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » Finished MUD Scripts
Falcnor
Beginner


Joined: 04 Sep 2003
Posts: 14
Location: USA

PostPosted: Mon Sep 08, 2003 8:53 pm   

Falcnor's Autokill Script
 
Hey gang. Well I finished my Autokill script. Taken pieces of code from Islydur's kill script and modified it heavely. Here are the steps you need to take to ensure it will work for you.

Copy the code at the bottom into notepad and edit the following areas.

'sk @mobEnemy' : This is the kill command. Add things like 'kill @mobEnemy;pet kill @mobEnemy' and that sorta stuff

'#wait 2000' : this is just a simple pause for 2 seconds to make sure the enemy variable is populated. If you have a fast mud you can shorten this but I'd advise against it.

'#VAR mobEnemyList {rabbit|dwarf|elf}' : This is the list of monsters you want to attack. They are the simple forms of the names. Say like "A wood elf" would trigger the "elf" enemy in this list.

#TRIGGER {is DEAD} {hunt}
#TRIGGER {No *({@mobEnemyList})* here!} {hunt}
#TRIGGER {Target is not present.} {hunt}

^^ : These 3 lines are as follows
1. The "you killed the monster" tag line.
2. A line that tells you the target is not preset.
3. A line that tells you the target is not preset.

Ok, now create a path for the area you want to kill in and change the #BUTTON command at the end of the code to show your path name (#slow dwarfs was mine)

Move to the begining of you path and hit the button. It will run through the area and kill for you granted your setup works.

I will be adding little improvements for myself and putting the extra code up for everyone to see and use.

Please post comments, suggestions or gripes. And if you need some hlep setting it up for your specific mud please post a snip of your mud output for short look (ll, bl) or look (look, l).

Good luck!

#CLASS {Autokill}

#ALIAS Hunt {
#t+ MatchEnemy
#VAR mobEnemy {} {_nodef} {Autokill}
#pause
ll
#wait 2000
#if (@mobEnemy) {
sk @mobEnemy
} {
ChangeRoom
}
}

#ALIAS ChangeRoom {
#step
#wait 2000
hunt
}

#VAR mobEnemyList {rabbit|dwarf|elf}
#VAR mobEnemy {} {_nodef} {Autokill}

#TRIGGER {is DEAD} {hunt}

#TRIGGER {No *({@mobEnemyList})* here!} {hunt}

#TRIGGER {Target is not present.} {hunt}
#CLASS 0


#CLASS {Autokill|MatchEnemy}

#TRIGGER {*({@mobEnemyList})*} {#var mobEnemy %lower( {%1}) {_nodef} {Autokill};#t- MatchEnemy}
#CLASS 0

#BUTTON 14 {Start-H} {#class Autokill 1;#slow dwarfs;hunt} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} "" {} {} {}
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » Finished MUD Scripts All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net