Temp Trigger

User avatar
Vadi
Posts: 5042
Joined: Sat Mar 14, 2009 3:13 pm

Re: Temp Trigger

Post by Vadi »

Seems to me personally you're doing it in a rather complicated and convulted way... even if you get this working now, you'll have a hard time getting how it works a month from now.

Since you're calling some rewear function anyway, and tracking what's removed - why not just make a normal trigger for balance recovery that checks if you're missing something and wears it for you.

Wennef
Posts: 43
Joined: Sun Apr 11, 2010 3:48 am

Re: Temp Trigger

Post by Wennef »

Okay, will think of how to do that, Vadi.

The rewear thing came from here.

Rewear Antitheft

But it doesn't work well for armour yet.

Wennef
Posts: 43
Joined: Sun Apr 11, 2010 3:48 am

Re: Temp Trigger

Post by Wennef »

I've worked around that without using temp triggers. I still don't get why I have temp trigger left overs from this.

Code: Select all

remove_armour_trigger_id = tempTrigger("You have recovered balance on all limbs.", [[ send("wear " .. _G["myarmour"]) ]])
wear_armour_trigger_id = tempTrigger("You are now wearing a suit of scale mail.", [[killTrigger(]] .. remove_armour_trigger_id .. [[);killTrigger(]] .. wear_armour_trigger_id ..[[)]])

User avatar
Heiko
Site Admin
Posts: 1548
Joined: Wed Mar 11, 2009 6:26 pm

Re: Temp Trigger

Post by Heiko »

At the time you pass the id of your second tempTrigger to the second killtrigger function, the id is not defined because it will only be defined after the function call to tempTimer().

Wennef
Posts: 43
Joined: Sun Apr 11, 2010 3:48 am

Re: Temp Trigger

Post by Wennef »

can you explain that in normal speak? D: All I understood from that is I didn't let the temptrigger finish.

Wyd
Posts: 54
Joined: Wed Mar 24, 2010 11:56 pm

Re: Temp Trigger

Post by Wyd »

That bit of code was my fault

edit: Rest of my post was wrong, opps

Post Reply