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
Dryeck
Beginner


Joined: 19 Feb 2010
Posts: 13

PostPosted: Sat Apr 16, 2011 7:14 pm   

Trigger not working
 
My hunting trigger is not working and for the life of me I can't figure out why:

F2 executes: 'cast firelash at @FCS_Target' which works fine
While off equilibrium from firelash, I press F3 a few times, which executes:
'#IF (@FCS_AutoAttack2 = 4) {FCS_AutoAttack2 = 5}
#IF (@FCS_AutoAttack2 = 3) {FCS_AutoAttack2 = 4}
#IF (@FCS_AutoAttack2 = 2) {FCS_AutoAttack2 = 3}
#IF (@FCS_AutoAttack2 = 1) {FCS_AutoAttack2 = 2}
#IF (@FCS_AutoAttack2 = 0) {FCS_AutoAttack2 = 1}'

Which basically increase my autoattack variable by 1 every time I press it, up to 5. Now, on my trigger that executes off of "You have recovered equilibrium." (happens a few seconds after firelashing), it goes:
'#IF (@./FCS_AutoAttack2 = 1) {
cast firelash at @FCS_Target; ./FCS_AutoAttack2 = 0}
#IF (@./FCS_AutoAttack2 = 2) {
cast firelash at @FCS_Target; ./FCS_AutoAttack2 = 1}
#IF (@./FCS_AutoAttack2 = 3) {
cast firelash at @FCS_Target; ./FCS_AutoAttack2 = 2}
#IF (@./FCS_AutoAttack2 = 4) {
cast firelash at @FCS_Target; ./FCS_AutoAttack2 = 3}
#IF (@./FCS_AutoAttack2 = 5) {
cast firelash at @FCS_Target; ./FCS_AutoAttack2 = 4}'

Which basically means that when I recover equilibrium, I firelash, and my auto attack variable decreases by 1. However, the problem is that it doesn't work. I recover equilibrium and nothing happens. I know the string that triggers is correct, as I use it for other things in the same trigger that function correctly. I've even tried making the variable 1, and simplifying the trigger to:
'#IF (@./FCS_AutoAttack2 = 1) {cast firelash at @FCS_Target}' and it still refuses to work. I CANNOT figure out what's wrong. Could anyone help? I can clarify anything if needed.
Reply with quote
Rahab
Wizard


Joined: 22 Mar 2007
Posts: 2320

PostPosted: Sun Apr 17, 2011 12:13 am   
 
Why do you have "@./FCS_AutoAttack2" in the second trigger? What is that supposed to mean? It seems likely that this is supposed to be @FCS_AutoAttack2 as in the first trigger.

As an aside, your trigger is needlessly complex. You don't need that complicated series of #IF statements. You could, instead, simply do:
Code:
FCS_Autottack2 = (@FCS_Autoattack + 1)

in the first trigger, and:
Code:
cast firelash at @FCS_Target; FCS_Autoattack2 = (@FCS_Autoattack2 - 1)

in the second.
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