Quote (H_A_PK)
Это делается дополнительными триггерами
Само собой. Я так и делал.
Quote (H_A_PK)
откуда мы знаем, код покажи, все телепаты уехали по лагерям
Это сделано на ГУИ, потому что во всей этой системе присутствуют 9 триггеров и в абилки.Добавлено (22.07.11, 16:26)
---------------------------------------------
Вот триггер в котором абилка добавляет событие в дополнительный триггер:
Code
Suffer
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Suffer Butcher
Actions
Set Suffer_Unleash_Counter = (Suffer_Unleash_Counter + 1.00)
Set Suffer_Unleash = 0.00
Set SufferCaster = (Casting unit)
Set SufferLevel = (Level of Suffer Butcher for SufferCaster)
Set Suffer_Active = True
Player - Disable Suffer Butcher for (Owner of SufferCaster)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(SufferCaster is in SufferCheckGroup) Equal to False
Then - Actions
Trigger - Add to Suffer Take <gen> the event (Unit - SufferCaster Takes damage)
Unit Group - Add SufferCaster to SufferCheckGroup
Else - Actions
Wait 60.00 seconds
Player - Enable Suffer Butcher for (Owner of SufferCaster)
Unit Group - Remove all units from SufferCheckGroup
Custom script: call DestroyGroup(udg_SufferCheckGroup)
Set SufferCaster = No unit
Custom script: call RemoveUnit(udg_SufferCaster)
Set Suffer_Unleash = 0.00
Special Effect - Destroy Suffer_Max
Trigger - Turn off Unleash Ready <gen>
Floating Text - Destroy Unleash_Ready_Text
Set Suffer_Active = False
Добавлено (22.07.11, 16:26)
---------------------------------------------
А вот сам дополнительный триггер куда добавляется событие:
Code
Suffer Take
Events
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
And - All (Conditions) are true
Conditions
Suffer_Unleash Greater than or equal to Suffer_Damage
(Damage taken) Greater than 0.00
Suffer_Active Equal to True
Then - Actions
Set Suffer_Unleash = Suffer_Damage
Sound - Play AbominationYesAttack1 <gen> at 100.00% volume, attached to SufferCaster
Trigger - Turn on Unleash Ready <gen>
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
And - All (Conditions) are true
Conditions
(Damage taken) Greater than 0.00
Suffer_Active Equal to True
Then - Actions
Set Suffer_Unleash = (Suffer_Unleash + ((Damage taken) / Suffer_Unleash_Counter))
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
And - All (Conditions) are true
Conditions
(Damage taken) Greater than 0.00
Suffer_Active Equal to True
Then - Actions
Special Effect - Create a special effect attached to the chest of SufferCaster using Abilities\Spells\Other\Stampede\StampedeMissileDeath.mdl
Wait 0.10 seconds
Special Effect - Destroy (Last created special effect)
Else - Actions