So after a while I started creating maps again and I've encountered a silly problem... Basically I have a trigger that is activated by pressing a CTRL button. When it's activated the unit owned by the Triggering player gains additional movement speed. When it's pressed again the movement speed resets. Now that's all working like a charm, but the problem is that while the trigger is active aka while the unit has bonus movement speed it's supposed to decrement a variable.
My idea was to make a trigger which runs every x seconds decrementing y value from the global variable.
The problem is that I can't transfer the Triggering player variable to the trigger which decrements the value from the global variable. Both variables are arrays so I need to know which player pressed the button in order to decrement the right value from the variable.
Any help or just an idea is greatly appreciated :D
Oooooh, that is brilliant! :D
I thought about using functions, but forgot that you can call them inside of themselves -_-
Hard to think i'm a programmer, but hey, everyone has their silly moments :P xD
Hello everyone.
So after a while I started creating maps again and I've encountered a silly problem... Basically I have a trigger that is activated by pressing a CTRL button. When it's activated the unit owned by the Triggering player gains additional movement speed. When it's pressed again the movement speed resets. Now that's all working like a charm, but the problem is that while the trigger is active aka while the unit has bonus movement speed it's supposed to decrement a variable.
My idea was to make a trigger which runs every x seconds decrementing y value from the global variable.
The problem is that I can't transfer the Triggering player variable to the trigger which decrements the value from the global variable. Both variables are arrays so I need to know which player pressed the button in order to decrement the right value from the variable.
Any help or just an idea is greatly appreciated :D
try an action definition
@hobbidude: Go
Oooooh, that is brilliant! :D I thought about using functions, but forgot that you can call them inside of themselves -_- Hard to think i'm a programmer, but hey, everyone has their silly moments :P xD