Народ подскажыте скрином или картой как в Переменую засунуть ГРупу юнитов Уменя сделано что Рядом скаждым юнитом поивляеца юнит как мне этих юнитов которые поивляюца рядом с другими юнитами засунуть в переменую
Болие кратно Я хочю их всех удалить
`
ОЖИДАНИЕ РЕКЛАМЫ...
13
  1. ПЕРЕМЕННЫЕ. Создать переменную юнит "дамми" и в цикле "отряд" после создания вбей в переменную с "последний созданный юнит" затем установи юниту таймер ( он находится в действии "добавить таймер юниту" у юнитов ). Так не придётся удалять.
  2. Очищяй группу
  3. Неиспользуй действие "ждать". Пользуйся таймером ( это триггер таймер )
15
Для болие точного понимание можеш прикрепити скрин
5
Вот тебе моя системка на JASS для пользования нужен JNGP. Не нравится - ищи, иначе - пользуйся.
Stun System - JASS
// Stun System v2.0

globals
constant integer StunSystem_DummyID='u000'		//боевая единица пустышка
constant integer StunSystem_DummyAbility='A000'	//способность на основе Громовой поступи
constant integer StunSystem_Buff='BSTN'		//смотрим какой бафф добавили способности и суда вписываем
constant integer StunSystem_OrderID=852127	//OrderId("stomp")
constant real StunSystem_X=-3035.0		//координата Х безопасной точки для использования Громовой поступи
constant real StunSystem_Y=2762.		//координата Y безопасной точки для использования Громовой поступи
unit StunSystem_Dummy=null

real StunSystem_TIME=.0
unit StunSystem_TARGET=null
endglobals

function StunSystem takes nothing returns boolean
local real x=GetUnitX(StunSystem_TARGET)
local real y=GetUnitY(StunSystem_TARGET)
if GetUnitAbilityLevel(StunSystem_TARGET, StunSystem_Buff)==0 then
    if GetUnitX(StunSystem_Dummy)!=StunSystem_X and GetUnitY(StunSystem_Dummy)!=StunSystem_Y then
        call SetUnitPosition(StunSystem_Dummy,StunSystem_X,StunSystem_Y)
    endif
    call SetUnitX(StunSystem_TARGET,StunSystem_X)
    call SetUnitY(StunSystem_TARGET,StunSystem_Y)
    call IssueImmediateOrderById(StunSystem_Dummy, StunSystem_OrderID)
    call SetUnitX(StunSystem_TARGET,x)
    call SetUnitY(StunSystem_TARGET,y)
endif
set BuffSystem_TARGET=StunSystem_TARGET
set BuffSystem_ID_Buff=StunSystem_Buff
set BuffSystem_TIME=StunSystem_TIME
call TriggerEvaluate(gg_trg_BuffSystem)		//вызов бафф системы
set StunSystem_TIME=.0
set StunSystem_TARGET=null
return true
endfunction

function StunSystem_Func_Init takes nothing returns nothing
set gg_trg_StunSystem=CreateTrigger()
set StunSystem_Dummy=CreateUnit(Player(15),StunSystem_DummyID,StunSystem_X,StunSystem_Y,0)
call UnitAddAbility(StunSystem_Dummy,StunSystem_DummyAbility)
call UnitAddAbility(StunSystem_Dummy,'Aloc')
call ShowUnit(StunSystem_Dummy,false)
call TriggerAddCondition(gg_trg_StunSystem, Condition(function StunSystem))
endfunction
BuffSystem - JASS
// Bufff System v1.1

globals
constant real BuffSystem_Interval=.03125

timer BuffSystem_Timer=CreateTimer()
integer BuffSystem_MAX=0
unit array BuffSystem_Unit
integer array BuffSystem_AbilId
integer array BuffSystem_BuffId
real array BuffSystem_Time

unit BuffSystem_TARGET=null
real BuffSystem_TIME=.0
integer BuffSystem_ID_Ability=0
integer BuffSystem_ID_Buff=0
endglobals

function BuffSystem_Periodic takes nothing returns nothing
local integer i = 0
    loop
        exitwhen i == BuffSystem_MAX
        if BuffSystem_Time[i]>0.0 and BuffSystem_Unit[i]!=null and (not IsUnitType(BuffSystem_Unit[i],UNIT_TYPE_DEAD)) then
            set BuffSystem_Time[i]=BuffSystem_Time[i]-BuffSystem_Interval
        else
            if BuffSystem_AbilId[i]!=0 then
                call UnitMakeAbilityPermanent(BuffSystem_Unit[i],false,BuffSystem_AbilId[i])
                call UnitRemoveAbility(BuffSystem_Unit[i],BuffSystem_AbilId[i])
            endif
            call UnitRemoveAbility(BuffSystem_Unit[i],BuffSystem_BuffId[i])
            
            set BuffSystem_MAX=BuffSystem_MAX-1
            set BuffSystem_Unit[i]=BuffSystem_Unit[BuffSystem_MAX]
            set BuffSystem_Time[i]=BuffSystem_Time[BuffSystem_MAX]
            set BuffSystem_AbilId[i]=BuffSystem_AbilId[BuffSystem_MAX]
            set BuffSystem_BuffId[i]=BuffSystem_BuffId[BuffSystem_MAX]
            
            set BuffSystem_Unit[BuffSystem_MAX]=null
            set BuffSystem_Time[BuffSystem_MAX]=0.
            set BuffSystem_AbilId[BuffSystem_MAX]=0
            set BuffSystem_BuffId[BuffSystem_MAX]=0
            
            set i = i - 1
            if (0 == BuffSystem_MAX) then
                call PauseTimer(BuffSystem_Timer)
            endif
        endif
        set i = i + 1
    endloop
endfunction

function BuffSystem_Checker takes nothing returns boolean
local integer i=0
loop
    exitwhen i==BuffSystem_MAX
    if BuffSystem_TARGET==BuffSystem_Unit[i] and BuffSystem_ID_Ability==BuffSystem_AbilId[i] and BuffSystem_ID_Buff==BuffSystem_BuffId[i] then
        if BuffSystem_TIME>BuffSystem_Time[i] then
            set BuffSystem_Time[i]=BuffSystem_TIME
        endif
        return false
    endif
    set i=i+1
endloop
return true
endfunction

function BuffSystem takes nothing returns boolean
if BuffSystem_Checker() then
    if BuffSystem_MAX==0 then
        call TimerStart(BuffSystem_Timer,BuffSystem_Interval, true, function BuffSystem_Periodic)
    endif
    if BuffSystem_ID_Ability!=0 then
        call UnitAddAbility(BuffSystem_TARGET, BuffSystem_ID_Ability)
        call UnitMakeAbilityPermanent(BuffSystem_TARGET,true,BuffSystem_ID_Ability)
    endif
    set BuffSystem_Unit[BuffSystem_MAX]=BuffSystem_TARGET
    set BuffSystem_Time[BuffSystem_MAX]=BuffSystem_TIME
    set BuffSystem_AbilId[BuffSystem_MAX]=BuffSystem_ID_Ability
    set BuffSystem_BuffId[BuffSystem_MAX]=BuffSystem_ID_Buff
    set BuffSystem_MAX=BuffSystem_MAX+1
endif

set BuffSystem_TARGET=null
set BuffSystem_TIME=.0
set BuffSystem_ID_Ability=0
set BuffSystem_ID_Buff=0
return false
endfunction

function BuffSystem_Func_Init takes nothing returns nothing
set gg_trg_BuffSystem=CreateTrigger()
call TriggerAddCondition(gg_trg_BuffSystem, Condition(function BuffSystem))
endfunction
Чтобы оставить комментарий, пожалуйста, войдите на сайт.