About Us
Products
Purchase
Downloads
Support
Forums
Contact Us
Site
 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
Dyron
Apprentice


Joined: 08 Apr 2004
Posts: 103
Location: USA

PostPosted: Fri Sep 26, 2008 4:17 am   

Trigger question.
 
Alright, here is the problem. I am playing on a mud called Aetolia where there are things called Illusions, these illusions are
nonexistent inflictions used to confuse your system. I am giving three examples of what they can look like. There are about
50 different possibilities for the two "fake" afflictions, so I can not use those as a dependable value. The goal is to be able to
read that it's an illusion and discard the two fake afflictions. Any ideas would be great, thank you.

Example 1:

H:100% M:97% E:99% W:99% B:68% XP:41% [csdb eb]
** Illusion **
Fake affliction.
Fake affliction.
H:100% M:97% E:99% W:99% B:68% XP:41% [csdb eb]

Example 2:

H:100% M:97% E:99% W:99% B:68% XP:41% [csdb eb]
** Illusion **
Fake affliction.
Fake affliction.
** Illusion **
H:100% M:97% E:99% W:99% B:68% XP:41% [csdb eb]

Example 3:


H:100% M:97% E:99% W:99% B:68% XP:41% [csdb eb]
Fake affliction.
Fake affliction.
** Illusion **
H:100% M:97% E:99% W:99% B:68% XP:41% [csdb eb]
Reply with quote
Vijilante
SubAdmin


Joined: 18 Nov 2001
Posts: 5182

PostPosted: Fri Sep 26, 2008 9:41 am   
 
Change your triggers that capture illusions to put them into a pending variable instead of the variable you use to determine curing. Don't take immediate curing actions during those triggers.

Next is a simple trigger.
#TRIGGER {^~*~* Illusion ~*~*$} {Illusion=1}

Finally in your prompt trigger check the illusion state to determine if you should commit the pending afflictions to your curing system. Something like this:
Code:
#IF (@Illusion) {
 PendingAfflictions=""
 Illusion=0
} {
 Afflictions=%concat(@Afflictions,"|",@PendingAfflictions)
 Cure
}
_________________
The only good questions are the ones we have never answered before.
Search the Forums
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