- Joined
- Feb 27, 2019
- Messages
- 401
Hello,
I have a map I am editing with editor 1.31.1. It has many GUI triggers, and I am trying to use the local globals trick (having a local with the name of a global so you can use GUI functions).
However the trigger below displays "TODO Security1" then "55".
What do I do wrong ? How do you do "if" conditions with local globals ? Custom script ? It seems to be that because when I convert the trigger to JASS, the integer comparison is in a subfunction, so the local is not defined there...
Or did they remove this local global cheat in Warcraft 1.31 ?
I have a map I am editing with editor 1.31.1. It has many GUI triggers, and I am trying to use the local globals trick (having a local with the name of a global so you can use GUI functions).
However the trigger below displays "TODO Security1" then "55".
What do I do wrong ? How do you do "if" conditions with local globals ? Custom script ? It seems to be that because when I convert the trigger to JASS, the integer comparison is in a subfunction, so the local is not defined there...
Or did they remove this local global cheat in Warcraft 1.31 ?
-
Actions
-
Custom script: local boolean udg_TempBoolean
-
Custom script: local integer udg_TempInteger
-
Set TempInteger = (Count structures controlled by Player 9 (Gray) (Exclude incomplete structures))
-
Set TempInteger = (TempInteger + (Count structures controlled by Player 10 (Light Blue) (Exclude incomplete structures)))
-
Set TempInteger = (TempInteger + (Count structures controlled by Player 11 (Dark Green) (Exclude incomplete structures)))
-
Set TempInteger = (TempInteger + (Count structures controlled by Player 12 (Brown) (Exclude incomplete structures)))
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
TempInteger Equal to 55
-
-
Then - Actions
-
Do nothing
-
-
Else - Actions
-
Game - Display to (All players) the text: TOTO Security1
-
Game - Display to (All players) the text: (String(TempInteger))
-
Custom script: call DestroyTrigger(gg_trg_AttackStart)
-
-
-
Last edited: