| 09-27-2009, 08:00 AM | #1 |
The compiler is doing something very weird. My code that i typed in looks like this: JASS:function Stop takes nothing returns nothing call PauseUnit(GetEnumUnit(), true) endfunction function Trig_MazeInit_Actions takes nothing returns nothing local integer i local group g loop exitwhen i == bj_MAX_PLAYERS set g = GetUnitsOfPlayerAll(ConvertedPlayer(i)) call ForGroup(g, Stop) set i = i+1 endloop endfunction //=========================================================================== function InitTrig_MazeInit takes nothing returns nothing set gg_trg_MazeInit = CreateTrigger( ) call TriggerRegisterVariableEvent(gg_trg_MazeInit, "levelCount", EQUAL, 25) call TriggerAddAction( gg_trg_MazeInit, function Trig_MazeInit_Actions ) endfunction But on the window that comes up it looks like this: JASS:function Stop takes nothing returns nothing call PauseUnit(GetEnumUnit() , true) endfunction function Trig_MazeInit_Actions takes nothing returns nothing local integer i local group g loop exitwhen i == bj_MAX_PLAYERS set g = GetUnitsOfPlayerAll(ConvertedPlayer(i)) call ForGroup(g , (1)) set i = i + 1 endloop endfunction //=========================================================================== function InitTrig_MazeInit takes nothing returns nothing set gg_trg_MazeInit = CreateTrigger() call TriggerRegisterVariableEvent(gg_trg_MazeInit , "levelCount" , EQUAL , 25) call TriggerAddAction(gg_trg_MazeInit , function Trig_MazeInit_Actions) endfunction |
| 09-27-2009, 08:12 AM | #2 |
call ForGroup(g, Stop)
-> call ForGroup(g, function Stop) |
| 09-27-2009, 09:15 AM | #3 |
this is crush prevention mechanism. |
| 09-27-2009, 06:31 PM | #4 |
I assume you mean crash? |
