Hey there,
Can't find anything that would be helping me. I have following trigger:
It's converted from GUI, but I then edited it to fit my needs. Still, the problem is that the progress is never set to my specified percent. I tried GetConstructingStructure, GetTriggerUnit and GetEventTargetUnit. I believe it could be due to the PLAYER_UNIT_EVENT, that he needs a player input and can't just pick the unit itself.
Help anyone?
Can't find anything that would be helping me. I have following trigger:
JASS:
function Trig_Fast_Construction_Actions takes nothing returns nothing
call UnitSetConstructionProgress(GetConstructingStructure(), 99)
endfunction
function InitTrig_Fast_Construction takes nothing returns nothing
local trigger trig = CreateTrigger()
local integer i = 0
loop
exitwhen i > 11
call TriggerRegisterPlayerUnitEvent(trig, Player(i), EVENT_PLAYER_UNIT_CONSTRUCT_START, null)
set i = i + 1
endloop
call TriggerAddAction(trig, function Trig_Fast_Construction_Actions)
set trig = null
endfunction
It's converted from GUI, but I then edited it to fit my needs. Still, the problem is that the progress is never set to my specified percent. I tried GetConstructingStructure, GetTriggerUnit and GetEventTargetUnit. I believe it could be due to the PLAYER_UNIT_EVENT, that he needs a player input and can't just pick the unit itself.
Help anyone?