JASS Help

GetEnumUnit

native GetEnumUnit takes nothing returns [[[unit|unit.html]]]

Функция, служащая для получения текущего юнита при переборе группы с помощью функции ForGroup.

globals group g = [[[CreateGroup|creategroup.html]]]() endglobals function forGroupIterator takes [[[nothing|nothing.html]]] returns [[[nothing|nothing.html]]] call ConsolePrint(GetUnitName(GetEnumUnit())) endfunction function gameStart takes [[[nothing|nothing.html]]] returns [[[nothing|nothing.html]]] call GroupAddUnit(g, CreateUnit(Player(0), '[[[uloc|aloc.html]]]', 0, 0, 0)) call GroupAddUnit(g, CreateUnit(Player(0), 'hfoo', 0, 0, 0)) call [[[ForGroup|forgroup.html]]](g, function forGroupIterator) endfunction function [[[main|main.html]]] takes [[[nothing|nothing.html]]] returns [[[nothing|nothing.html]]] call TimerStart(CreateTimer(), 0, false, function gameStart) endfunction
Last modified: 22 October 2024