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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » CMUD General Discussion
rmorock8869@yahoo.com
Beginner


Joined: 15 May 2018
Posts: 17

PostPosted: Wed Nov 21, 2018 5:24 pm   

Thief Script
 
I am very very new to cmud. I have dabbling around with triggers and #wait but I am trying to execute a script so that my thief will look @target, Steal coin @target. IF he sees coins he will continue to try and steal until he receives a trigger of "Nothing" or "You can't seem to find it" and then he will Kill @target. Seems fairly simple but I have to keep hitting the button and occasionally the logs build up and then spam it all at once causing the mud to shut down. I have been using the wait command because he takes a few seconds before he can perform another action (You cannot do that while recovering from physical exertion!), Any help?
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 4691
Location: Pensacola, FL, USA

PostPosted: Thu Nov 22, 2018 2:19 am   
 
Well first you need to set your target somehow:

target=Marky Mark

In thieving lingo, that is called your mark
Code:
#ALIAS setMark {
  mark=%1
  look @mark
  #WAITFOR {The line that indicates they have coins} 3000 {steal @mark} {#PRINT @mark is broke!}
  }


Then to loop it:

Code:
#TRIGGER {You stole * coins from @mark!} {
  #WAIT 3000
  steal @mark
  }
_________________
Discord: Shalimarwildcat
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » CMUD General Discussion 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