ShikaShadow
Cool Member
- Reaction score
- 0
Hello, I am familiar with making a unit variable local within a trigger, but how can I make a destructible variable local? The formula "local unit = udg_name" doesn't work for destructible variables. And "local destructible = udg_name" doesn't work and gives an error when map is saved. I have to make the trigger local because the skill can be casted multiple times by multiple people at any given moment. The wait has to be there so that I can bring the tree's animation speed back to what it was before the right-click event. Without making the trigger local, it will be constantly interrupted causing trees to be stuck at the faster animation speed.
Here is the trigger:
Tree Jump Effect
Events
Unit - A unit Is issued an order targeting an object
Conditions
And - All (Conditions) are true
Conditions
(Issued order) Equal to Right-Click
(Mana of (Ordered unit)) Greater than or equal to 50.00
Or - Any (Conditions) are true
Conditions
(Destructible-type of (Target destructible of issued order)) Equal to Summer Tree Wall
(Destructible-type of (Target destructible of issued order)) Equal to Felwood Canopy Tree
(Destructible-type of (Target destructible of issued order)) Equal to Cityscape Summer Tree Wall
Actions
Set TreeTarget = (Target destructible of issued order)
Animation - Change TreeTarget's animation speed to 70.00% of its original speed
Wait 1.00 seconds
Animation - Change TreeTarget's animation speed to 5.00% of its original speed
Here is the trigger:
Tree Jump Effect
Events
Unit - A unit Is issued an order targeting an object
Conditions
And - All (Conditions) are true
Conditions
(Issued order) Equal to Right-Click
(Mana of (Ordered unit)) Greater than or equal to 50.00
Or - Any (Conditions) are true
Conditions
(Destructible-type of (Target destructible of issued order)) Equal to Summer Tree Wall
(Destructible-type of (Target destructible of issued order)) Equal to Felwood Canopy Tree
(Destructible-type of (Target destructible of issued order)) Equal to Cityscape Summer Tree Wall
Actions
Set TreeTarget = (Target destructible of issued order)
Animation - Change TreeTarget's animation speed to 70.00% of its original speed
Wait 1.00 seconds
Animation - Change TreeTarget's animation speed to 5.00% of its original speed