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

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
cawzor987
Newbie


Joined: 16 Feb 2012
Posts: 3
Location: United States

PostPosted: Thu Feb 16, 2012 11:22 pm   

Help. I dont understand why this doesnt work
 
Code:

#class acme
#var incombat 0
#var killcount 0
#slow 5w3s9e3n5w
#trigger {A student is here} {#math mob @killcount + 1;#if (@incombat  = 0) {kill student;#math battle @incombat+1}{say fires}}
#trigger {An Acme student leaves} { #math mob @killcount-1}
#trigger{An Acme student arrives from the} {#math mob @killcount+1}
#trigger {Alas, an Acme student is dead!  R.I.P} {#math battle @incombat-1;#math mob @killcount-1;#if (@mob < 1) {#ok;#step;#pause}{kill student}}


Dont understand why this doesn't work any help would be appreciated
Reply with quote
charneus
Wizard


Joined: 19 Jun 2005
Posts: 1876
Location: California

PostPosted: Thu Feb 16, 2012 11:30 pm   
 
You're missing a space on #trigger 3.

Code:
#trigger{An Acme student arrives from the}


You need it to be:
Code:
#trigger {An Acme student arrives from the}


Other than that, if it's not your issue, you need to be clear on what isn't working, what you expect it to do, etc. We're not mind readers.
Reply with quote
cawzor987
Newbie


Joined: 16 Feb 2012
Posts: 3
Location: United States

PostPosted: Thu Feb 16, 2012 11:34 pm   
 
Ok im sorry well that script loaded in the first trigger fires but outputs this to the the mud
{kill student;#math battle 0+1}{say fires}

on the alas trigger i get this sent to the mud
{#ok;#step;#pause}{kill student}
also the variables are not adding like they should when the trigger fires. and b there making there own class's some how

what im trying to do is when i enter the room a trigger fires adding to a count how many students are in the room. then if im not in combat kill one of them
the other triggers are for in case one walks into the room during combat or leaves. Then the last trigger i wanted it to check the total of students in the room if there are none left move to the next step in the path if there is more left then stay and kill
Reply with quote
Daern
Sorcerer


Joined: 15 Apr 2011
Posts: 809

PostPosted: Fri Feb 17, 2012 2:18 am   
 
You're missing spaces in both of those triggers too, between the } and {.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD 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