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
Eul
Wanderer


Joined: 30 Jun 2007
Posts: 53

PostPosted: Wed Nov 02, 2011 7:10 pm   

Trigger help please.
 
I was wondering if someone could help me please.

I am making a trigger to produce five diferent outcomes depending on some variables.

basicly, if @bury=1 it knows there is something to bury. @align then breaks it off into two diffident sets of triggers that basically do the same thing as each other, then at the end if bury did not =1, move.

Oh and please ignore my silly #echo's. I have been trying to test it and figure out where the problem is =)

Code:

#if @bury=1 {
  #if @align=1 {
    #if @loot=0 {
      #echo out of align, but got bag space.
      #additem bury 0
      #delitem bury 1
      #alarm "loot" +%random( 1, 2) {lootsac}
      } {
      #echo out of align, but got no bag space.
      #additem bury 0
      #delitem bury 1
      #alarm "loot" +%random( 1, 2) {sac}
      }
    } {
    #if @loot=0 {
      #echo not out of align, but got bag space.
      #additem bury 0
      #delitem bury 1
      #alarm "loot" +%random( 1, 2) {loot}
      } {
      #echo not out of align, but got no bag space.
      #additem bury 0
      #delitem bury 1
      #alarm "loot" +%random( 1, 2) {b}
      }
    }
   {
  #additem bury 0
  #delitem bury 1
  #echo nothing bury, are there npc's?
  #ALARM "walk" +1.5 {
    #STEP
    #PAUSE
    }
  }}


Any help would be greatly appreciated. I sort of had it working at one point, but broke it and have not been able to get it anywhere near since.

Thanks.
Reply with quote
Eul
Wanderer


Joined: 30 Jun 2007
Posts: 53

PostPosted: Wed Nov 02, 2011 8:11 pm   
 
Never mind, I had some brackets in the wrong place and a variable set to the wrong name!

Thanks anyway =)
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