- Joined
- Mar 10, 2009
- Messages
- 5,016
SOLVED!
I was wondering about something...What's the use of ForGroup if there is GroupEnumUnitsInRange?...
Which do you preffer and faster?...
I was wondering about something...What's the use of ForGroup if there is GroupEnumUnitsInRange?...
Which do you preffer and faster?...
JASS:
function MR_FILTER takes nothing returns boolean
if IsUnitType(GetFilterUnit(), UNIT_TYPE_HERO)==false then
call KillUnit(GetFilterUnit())
endif
return false
endfunction
function TEST takes nothing returns nothing
call GroupEnumUnitsInRange(bj_lastCreatedGroup, GetUnitX(u), GetUnitY(u), 500, Filter(function MR_FILTER))
endfunction
JASS:
function MR_FILTER takes nothing returns nothing
if IsUnitType(GetEnumUnit(), UNIT_TYPE_HERO)==false then
call KillUnit(GetEnumUnit())
endif
endfunction
function TEST takes nothing returns nothing
call GroupEnumUnitsInRange(bj_lastCreatedGroup, GetUnitX(u), GetUnitY(u), 500, null)
call ForGroup(bj_lastCreatedGroup, function MR_FILTER)
endfunction
Last edited: