Thursday, 2020-12-03, 8:15 PM
[ New messages · Members · Forum rules · Search · RSS ]
  • Page 1 of 1
  • 1
Forum » Forum » Ideas » Wendigo's Size doesn't increase with his HP
Wendigo's Size doesn't increase with his HP
wosfreakFecha: Thursday, 2015-09-03, 1:49 PM | Mensaje # 1
Lieutenant
Group: Partner
Message: 41
Reputation: 0
Status: Offline
Why is this?
Back in the day I was really excited to see how big I could get, but then I noticed only my hit points increased, with no effect on my actual size.
I found this profoundly upsetting
afisFecha: Sunday, 2017-05-07, 7:00 PM | Mensaje # 2
Private
Group: User
Message: 6
Reputation: 1
Status: Offline
I really like this idea, been playing around with it and is fun to have.
To increase chance it will show up in next version I wrote a viable trigger for it

Code
function Trig_enterwendigo_Actions takes nothing returns nothing
local integer i= GetUnitTypeId(GetTriggerUnit())
if (i=='H05D')or(i=='H05C')or(i=='H05E')or(i=='H05F') then
set udg_wendigo=GetTriggerUnit()
call ConditionalTriggerExecute(gg_trg_wendscale)
endif
endfunction

function InitTrig_enterwendigo takes nothing returns nothing
set gg_trg_enterwendigo=CreateTrigger()
call TriggerRegisterEnterRectSimple(gg_trg_enterwendigo,GetPlayableMapRect())
call TriggerAddAction(gg_trg_enterwendigo,function Trig_enterwendigo_Actions)
endfunction

Code
function Trig_wendscale_Actions takes nothing returns nothing
local real wscale
if udg_wendigo!=null then
set wscale=Pow(GetUnitState(udg_wendigo,UNIT_STATE_MAX_LIFE) /4500.0, 0.32)
call SetUnitScale(udg_wendigo, wscale, wscale, wscale)
endif
endfunction

function InitTrig_wendscale takes nothing returns nothing
set gg_trg_wendscale = CreateTrigger()  
call TriggerRegisterTimerEventPeriodic(gg_trg_wendscale,5.)
call TriggerAddAction(gg_trg_wendscale,function Trig_wendscale_Actions)
endfunction

This needs a unit variable named wendgio
Then, just create the triggers wendscale and enterwendigo, convert both to custom text and replace contents with what I posted.


Message edited by afis - Monday, 2017-05-08, 3:13 AM
Forum » Forum » Ideas » Wendigo's Size doesn't increase with his HP
  • Page 1 of 1
  • 1
Search: