-
Are you planning to upload your awesome spell or system to Hive? Please review the rules here.Dismiss Notice
-
Find your way through the deepest dungeon in the 18th Mini Mapping Contest Poll.Dismiss Notice
-
A brave new world lies beyond the seven seas. Join the 34th Modeling Contest today!Dismiss Notice
-
Check out the Staff job openings thread.Dismiss Notice
Dismiss Notice
Hive 3 Remoosed BETA - NOW LIVE. Go check it out at BETA Hive Workshop! Post your feedback in this new forum BETA Feedback.
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.
Delayed Action 1.5a
Submitted by
Tasyen
- Tags:
- System, GUI / Triggers
- Filesize:
- 64.18 KB
- Rating:
-
(1 vote)
- Downloads:
- 903
- Uploaded:
- Oct 29, 2016
- Updated:
- Feb 11, 2017
- Resources:
- 1
- Author(s):
- Tasyen
- State:
- Approved

This bundle is marked as approved. It works and satisfies the submission rules.
A System which allows you to execute a Trigger after a Delay or/and Frequently, like a timer but this System allows you to save and use the saved data on the later executed Action-Trigger.
Features:
Features:
- Execute a Trigger after a delay
- Execute a Trigger Perodic
- Setup an Delayed Action to start another Delayed Action
- Save & use Data into a DA. Allowing full Mui effects.
- Attach any Arraybased-Variable.
- Terminate a running DA
- Unpause/Pause a running DA
- Show an Grafical effect.
- Delayed Action makes creating custom Delayed Spells/Triggers more simple.
- This System differs between the first delay and further ones.
- Actions created by DA are not unique, allows to spamm and stack pretty easy.
- Delayed Action needs no custom script to be used by the User, except for custom variable cleaning if you use that feature.
- You get alot of control over the Delayed Spells/Triggers using this.
The Basic Delayed Action needs two Triggers:
1. A Trigger Creating an Delayed Action.
Here you setup all DelayA_P Variables you need and run the DelayA_CONS_CREATE Trigger.2. The: DelayA_Action Trigger, This one is called by the System as soon a DelayA_Delay Expired and each time it Reloads.
Inside the DelayA-Action Trigger you are able to read any DelayA__Action variable, which are your previously saved Values (DelayA___P)
Basic
This is one of the in the Map contained Demos.
Stormhammer:
On Attack: After 3 seconds an Lightning form the sky will hit the Target and deal 50 Spelldamage.
Creation-Trigger
Setup all P-Variables you need.
-
Stormhammer attack
-
Events
-
Unit - A unit is Attacked
-
-
Conditions
-
(Level of Stormhammer for (Attacking unit)) != 0
-
-
Actions
-
-------- Delay in Seconds --------
-
Set DelayA___P_Delay = 3.00
-
-------- Units --------
-
Set DelayA___P_Source = (Attacking unit)
-
Set DelayA___P_Target = (Attacked unit)
-
-------- Effect beeing Called --------
-
Set DelayA___P_Trigger = stormhammer <gen>
-
-------- Grafical Indikator --------
-
Spezialeffekt - Create a special effect attached to the chest of P_Target using Abilities\Weapons\FarseerMissile\FarseerMissile.mdl
-
Set DelayA___P_Grafic = (Last created special effect)
-
-------- Create/Start DelayA --------
-
Trigger - Run DelayA_CONS_CREATE (ignoring conditions)
-
-
DelayA-Action Trigger: Runs after the Delay Expired.
The DelayA__Action.. Variable are used here.
-
stormhammer
-
Events
-
Conditions
-
(DelayA__Action_Target is alive)
-
-
-
Actions
-
Spezialeffekt - Create a special effect attached to the origin of DelayA__Action_Target using Abilities\Spells\Other\Monsoon\MonsoonBoltTarget.mdl
-
Spezialeffekt - Destroy (Last created special effect)
-
Unit - Cause DelayA__Action_Source to damage DelayA__Action_Target, dealing 50.00 damage of attack type Spell and damage type Magic
-
Reteleport:
Enchants a target after 6 seconds it is teleported to the position it was Enchanted.
-
Reteleport cast
-
Events
-
Unit - A unit casts a spell
-
-
Conditions
-
(Ability being cast) = Reteleport
-
-
Actions
-
Set DelayA___P_Delay = 6.00
-
Set DelayA___P_Source = (Triggering unit)
-
Set DelayA___P_Target = (Target unit of ability being cast)
-
Set DelayA___P_Loc = (Position of P_Target)
-
Spezialeffekt - Create a special effect at DelayA___P_Loc using Abilities\Spells\Human\MassTeleport\MassTeleportTo.mdl
-
Set DelayA___P_Grafic = (Last created special effect)
-
Set DelayA___P_Trigger = Reteleport <gen>
-
Trigger - Run DelayA_CONS_CREATE (ignoring conditions)
-
-
-
Reteleport
-
Events
-
Conditions
-
(DelayA__Action_Target is alive)
-
-
Actions
-
-------- Eye Candy --------
-
Set loc = (Position of DelayA__Action_Target)
-
Spezialeffekt - Create a special effect at loc using Abilities\Spells\NightElf\Blink\BlinkCaster.mdl
-
Spezialeffekt - Destroy (Last created special effect)
-
Custom script: call RemoveLocation(udg_loc)
-
-------- Teleport Back --------
-
Unit - Move DelayA__Action_Target instantly to DelayA__Action_Loc
-
-
Freq Feature
The Freq Feature allows you to preset a Delayed Action to Create another.
Trap
This Creates Periodic Traps which will have a delay and then will deal dps for a short time.
-
Demo Create Traps
-
Events
-
Time - Elapsed game time is 1.00 seconds
-
-
Conditions
-
Actions
-
-------- ------------ --------
-
-------- Trap Fire --------
-
-------- Every 8 seconds will a Fire spawn which will deal 50 DpS for 4 seconds to Units in an 180 AoE. --------
-
-------- Trap Intervall --------
-
Set DelayA___P_Reload_Dur = 8.00
-
Set DelayA___P_Reloads = DelayA_CONSTANT_UNLIMITED_RELOADS
-
Set DelayA___P_Loc = (Center of Trap <gen>)
-
-------- Trap First Delay --------
-
Set DelayA___P_Freq_Delay = 0.20
-
-------- Trap Action --------
-
Set DelayA___P_Freq_Trigger = Trap DPS <gen>
-
-------- Trap 's Free Info; Here: AoE & DPA --------
-
Set DelayA___P_Freq_Data = 180
-
Set DelayA___P_Freq_Real = 10.00
-
-------- Intervall of Action --------
-
Set DelayA___P_Freq_Reload_Dur = 0.20
-
Set DelayA___P_Freq_Reloads = 19
-
-------- -> Results in 20 (19 Reloads + 1 instantly) Executions of the Action. In this Case 10 * 20 Dmg --------
-
-------- Grafic Stuff --------
-
Set DelayA___P_Freq_Grafic_TargetType = DelayA_CONSTANT_GRAFIC_Point
-
Set DelayA___P_Freq_Grafic_Path = Abilities\Spells\Other\ImmolationRed\ImmolationRedTarget.mdl
-
Trigger - Run DelayA_CONS_CREATE (ignoring conditions)
-
-------- ------------ --------
-
-------- ------------ --------
-
-------- Trap Lightning --------
-
-------- Every 5 seconds will a Lightning Strike the Loc dealing 140 Dmg over 0.9 seconds. --------
-
-------- Trap Intervall --------
-
Set DelayA___P_Loc = (Center of Trap 2 <gen>)
-
Set DelayA___P_Reload_Dur = 5.00
-
Set DelayA___P_Reloads = DelayA_CONSTANT_UNLIMITED_RELOADS
-
-------- Trap Effect --------
-
Set DelayA___P_Freq_Trigger = Trap DPS <gen>
-
Set DelayA___P_Freq_Real = 20.00
-
Set DelayA___P_Freq_Data = 100
-
Set DelayA___P_Freq_Reload_Dur = 0.15
-
Set DelayA___P_Freq_Reloads = 6
-
Set DelayA___P_Freq_Grafic_TargetType = DelayA_CONSTANT_GRAFIC_Point
-
Set DelayA___P_Freq_Grafic_Path = Abilities\Spells\Other\Monsoon\MonsoonBoltTarget.mdl
-
Trigger - Run DelayA_CONS_CREATE (ignoring conditions)
-
-
-
Trap DPS
-
Events
-
Conditions
-
Actions
-
Custom script: set bj_wantDestroyGroup=true
-
Einheitengruppe - Pick every unit in (Units within (Real(DelayA__Action_Data)) of DelayA__Event_Loc matching (((Matching unit) is alive) equal True)) and do (Actions)
-
Schleifen - Aktionen
-
Unit - Set life of (Picked unit) to ((Leben of (Picked unit)) - DelayA__Action_Real)
-
-
-
-
Custom Variable Usage
You can attach any Array Based Variable to a started Delayed Action.
This is done by using DelayedA_Index_Entered.
Inside a Delayed Action Trigger you use DelayedA_Index to Access the Custom Variable.
Here a simple Demo, Granting a Hero which has not a full inventory a Ring of Regeneration for 5 seconds.
This is not included in the Demo Map.
-
Custom Variable start
-
Events
-
Unit - A unit is Attacked
-
-
Bedingungen
-
((Triggering unit) is a Hero)
-
(Number of items carried by (Triggering unit)) Smaller as (Size of inventory for (Triggering unit))
-
-
Aktionen
-
Hero - Create Ring of Regeneration and give it to (Triggering unit)
-
Set DelayA___P_Delay = 5.00
-
Set DelayA___P_Trigger = Custom Variable Action <gen>
-
Set DelayA___P_OnTerminate = Custom Variable Clear <gen>
-
Trigger - Run DelayA_CONS_CREATE (ignoring conditions)
-
-------- Attaching the Item to the Delayed Action --------
-
Set Item[DelayA_Index_Entered] = (Last created item)
-
-
The Action in which we destroy The Ring again.
-
Custom Variable Action
-
Events
-
Conditions
-
Actions
-
Item - Remove Item[DelayA_Index]
-
-
The OnTerminate Trigger: Here you Remove/Destroy Objects created by your Custom Variabales.
-
Custom Variable Clear
-
Events
-
Conditions
-
Actions
-
Set Item[DelayA_Index] = No Item
-
-
-
-
Delayed Action loop
-
Events
-
Conditions
-
Actions
-
-------- For Easy Copy; You can Remove this comment and the next Line if you want. --------
-
Set DelayA_Loop = 0
-
Set DelayA_Index = 0
-
For each (Integer DelayA_Loop) from 1 to DelayA_Count, do (Actions)
-
Schleifen - Aktionen
-
Set DelayA_Index = DelayA_Link_Next[DelayA_Index]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
Or - Any (Conditions) are true
-
Bedingungen
-
DelayA_Paused[DelayA_Index] Equal False
-
DelayA_Terminate[DelayA_Index] Equal True
-
-
-
-
Then - Actions
-
Set DelayA_Remainig_Dur[DelayA_Index] = (DelayA_Remainig_Dur[DelayA_Index] - DelayA_CONS_Intervall)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
Or - Any (Conditions) are true
-
Bedingungen
-
DelayA_Remainig_Dur[DelayA_Index] smaller Equal 0.00
-
DelayA_Terminate[DelayA_Index] Equal True
-
-
-
-
Then - Actions
-
-------- Skip Actions ; If Termiation is set. --------
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Terminate[DelayA_Index] Equal False
-
-
Then - Actions
-
-------- Creates another Delayed Action if enabled; Based on the Freq Variables. --------
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Freq_Has[DelayA_Index] Equal True
-
-
Then - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Freq_Intervall[DelayA_Index] smaller Equal 0
-
-
Then - Actions
-
Set DelayA_Freq_Intervall[DelayA_Index] = DelayA_Freq_Intervall_Reload[DelayA_Index]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Has_Loc[DelayA_Index] Equal True
-
DelayA_Freq_Grafic_Targetype[DelayA_Index] Equal DelayA_CONS_GRAFIC_POINT
-
-
Then - Actions
-
Set DelayA___P_Loc = (Point(DelayA_X[DelayA_Index], DelayA_Y[DelayA_Index]))
-
Spezialeffekt - Create a special effect at DelayA___P_Loc using DelayA_Freq_Grafic_Path[DelayA_Index]
-
Set DelayA___P_Grafic = (Last created special effect)
-
-
Else - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Freq_Grafic_Targetype[DelayA_Index] Equal DelayA_CONS_GRAFIC_TARGET
-
-
Then - Actions
-
Spezialeffekt - Create a special effect attached to the DelayA_Freq_Attachment[DelayA_Index] of DelayA_Targets[DelayA_Index] using DelayA_Freq_Grafic_Path[DelayA_Index]
-
Set DelayA___P_Grafic = (Last created special effect)
-
-
Else - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Freq_Grafic_Targetype[DelayA_Index] Equal DelayA_CONS_GRAFIC_SOURCE
-
-
Then - Actions
-
Spezialeffekt - Create a special effect attached to the DelayA_Freq_Attachment[DelayA_Index] of DelayA_Sources[DelayA_Index] using DelayA_Freq_Grafic_Path[DelayA_Index]
-
Set DelayA___P_Grafic = (Last created special effect)
-
-
Else - Actions
-
-
-
-
-
-
Set DelayA___P_Data = DelayA_Freq_Data[DelayA_Index]
-
Set DelayA___P_Real = DelayA_Freq_Data_Real[DelayA_Index]
-
Set DelayA___P_Reload_Dur = DelayA_Freq_Reload_Dur[DelayA_Index]
-
Set DelayA___P_Reloads = DelayA_Freq_Reloads[DelayA_Index]
-
Set DelayA___P_Source = DelayA_Sources[DelayA_Index]
-
Set DelayA___P_Target = DelayA_Targets[DelayA_Index]
-
Set DelayA___P_Trigger = DelayA_Freq_Trigger[DelayA_Index]
-
Set DelayA___P_Delay = DelayA_Freq_Duration[DelayA_Index]
-
Set DelayA___P_OnTerminate = DelayA_Freq_OnTerminate[DelayA_Index]
-
Trigger - Run DelayA_CONS_CREATE (ignoring conditions)
-
Trigger - Run DelayA_Freq_OnStart[DelayA_Index] (ignoring conditions)
-
-
Else - Actions
-
Set DelayA_Freq_Intervall[DelayA_Index] = (DelayA_Freq_Intervall[DelayA_Index] - 1)
-
-
-
-
Else - Actions
-
-
-------- Skip Event-Actions; if No Trigger is set --------
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Trigger[DelayA_Index] UnEqual NO_TRIGGER
-
-
Then - Actions
-
-------- Filll the DE-Action Vari --------
-
-------- Start the Action Trigger --------
-
Set DelayA__Action_Data = DelayA_Data[DelayA_Index]
-
Set DelayA__Action_Real = DelayA_Data2[DelayA_Index]
-
Set DelayA__Action_Terminate_This = False
-
Set DelayA__Action_Source = DelayA_Sources[DelayA_Index]
-
Set DelayA__Action_Target = DelayA_Targets[DelayA_Index]
-
Set DelayA__Action_Grafic = DelayA_Grafic[DelayA_Index]
-
Set DelayA__Action_Left_Reloads = DelayA_ReLoads[DelayA_Index]
-
Custom script: set udg_DelayA__Action_Has_Reloads = not ( udg_DelayA_ReLoads[udg_DelayA_Index] == 0)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Has_Loc[DelayA_Index] Equal True
-
-
Then - Actions
-
-------- Handle Event Loc --------
-
Set DelayA__Action_Loc = (Point(DelayA_X[DelayA_Index], DelayA_Y[DelayA_Index]))
-
Trigger - Run DelayA_Trigger[DelayA_Index] (checking conditions)
-
Custom script: call RemoveLocation(udg_DelayA__Action_Loc)
-
Custom script: set udg_DelayA__Action_Loc=null
-
-
Else - Actions
-
Trigger - Run DelayA_Trigger[DelayA_Index] (checking conditions)
-
-
-
Custom script: if udg_DelayA__Action_Loc_New != null then
-
Set DelayA_X[DelayA_Index] = (X of DelayA__Action_Loc_New)
-
Set DelayA_Y[DelayA_Index] = (Y of DelayA__Action_Loc_New)
-
Set DelayA_Has_Loc[DelayA_Index] = True
-
Custom script: call RemoveLocation(udg_DelayA__Action_Loc_New)
-
Custom script: set udg_DelayA__Action_Loc_New=null
-
Custom script: endif
-
-
Else - Actions
-
Set DelayA__Action_Terminate_This = False
-
-
-
-
Else - Actions
-
-
-------- Termination? --------
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
Or - Any (Conditions) are true
-
Bedingungen
-
DelayA_ReLoads[DelayA_Index] Equal 0
-
DelayA__Action_Terminate_This Equal True
-
DelayA_Terminate[DelayA_Index] Equal True
-
-
-
-
Then - Actions
-
-------- Clearing and Custom Variable Termination --------
-
Spezialeffekt - Destroy DelayA_Grafic[DelayA_Index]
-
Trigger - Run DelayA_OnTerminate[DelayA_Index] (ignoring conditions)
-
Set DelayA_Freq_Has[DelayA_Index] = False
-
-------- Change Pointers & Reading Array --------
-
Set DelayA_Link_Next[DelayA_Link_Previous[DelayA_Index]] = DelayA_Link_Next[DelayA_Index]
-
Set DelayA_Link_Previous[DelayA_Link_Next[DelayA_Index]] = DelayA_Link_Previous[DelayA_Index]
-
Set DelayA_Pointer_Unused[DelayA_Pointer_Unused_Last] = DelayA_Index
-
Set DelayA_Pointer_Unused_Last = (DelayA_Pointer_Unused_Last + 1)
-
Set DelayA_Count = (DelayA_Count - 1)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Count Equal 0
-
-
Then - Actions
-
Trigger - Turn off (This trigger)
-
-
Else - Actions
-
-
-
Else - Actions
-
Set DelayA_Remainig_Dur[DelayA_Index] = DelayA_ReLoad_Dur[DelayA_Index]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_ReLoads[DelayA_Index] Greater as 0
-
-
Then - Actions
-
Set DelayA_ReLoads[DelayA_Index] = (DelayA_ReLoads[DelayA_Index] - 1)
-
-
Else - Actions
-
-
-
-
-
Else - Actions
-
-
-
Else - Actions
-
-
-
-
-
-
Delayed Action add
-
Events
-
Conditions
-
Actions
-
Set DelayA_Count = (DelayA_Count + 1)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_Pointer_Unused_Last UnEqual 0
-
-
Then - Actions
-
Set DelayA_Pointer_Unused_Last = (DelayA_Pointer_Unused_Last - 1)
-
Set DelayA_Index_Entered = DelayA_Pointer_Unused[DelayA_Pointer_Unused_Last]
-
-
Else - Actions
-
Set DelayA_Pointer_Last_Row = (DelayA_Pointer_Last_Row + 1)
-
Set DelayA_Index_Entered = DelayA_Pointer_Last_Row
-
-
-
Set DelayA_Link_Next[DelayA_Index_Entered] = 0
-
Set DelayA_Link_Next[DelayA_Link_Previous[0]] = DelayA_Index_Entered
-
Set DelayA_Link_Previous[DelayA_Index_Entered] = DelayA_Link_Previous[0]
-
Set DelayA_Link_Previous[0] = DelayA_Index_Entered
-
-------- Save P_Data into DA_System Array --------
-
Set DelayA_Terminate[DelayA_Index_Entered] = False
-
Set DelayA_Paused[DelayA_Index_Entered] = False
-
Set DelayA_Remainig_Dur[DelayA_Index_Entered] = DelayA___P_Delay
-
Set DelayA_Sources[DelayA_Index_Entered] = DelayA___P_Source
-
Set DelayA_Targets[DelayA_Index_Entered] = DelayA___P_Target
-
Set DelayA_Trigger[DelayA_Index_Entered] = DelayA___P_Trigger
-
Set DelayA_OnTerminate[DelayA_Index_Entered] = DelayA___P_OnTerminate
-
Set DelayA_Data[DelayA_Index_Entered] = DelayA___P_Data
-
Set DelayA_Data2[DelayA_Index_Entered] = DelayA___P_Real
-
Set DelayA_ReLoad_Dur[DelayA_Index_Entered] = DelayA___P_Reload_Dur
-
Set DelayA_ReLoads[DelayA_Index_Entered] = DelayA___P_Reloads
-
Set DelayA_Grafic[DelayA_Index_Entered] = DelayA___P_Grafic
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
Or - Any (Conditions) are true
-
Bedingungen
-
DelayA___P_Freq_Trigger UnEqual NO_TRIGGER
-
DelayA___P_Freq_Grafic_Path UnEqual <Leerer String>
-
-
-
-
Then - Actions
-
Set DelayA_Freq_Has[DelayA_Index_Entered] = True
-
Set DelayA_Freq_Attachment[DelayA_Index_Entered] = DelayA___P_Freq_Grafic_Attach
-
Set DelayA_Freq_Data[DelayA_Index_Entered] = DelayA___P_Freq_Data
-
Set DelayA_Freq_Data_Real[DelayA_Index_Entered] = DelayA___P_Freq_Real
-
Set DelayA_Freq_Duration[DelayA_Index_Entered] = DelayA___P_Freq_Delay
-
Set DelayA_Freq_Grafic_Targetype[DelayA_Index_Entered] = DelayA___P_Freq_Grafic_Target
-
Set DelayA_Freq_Grafic_Path[DelayA_Index_Entered] = DelayA___P_Freq_Grafic_Path
-
Set DelayA_Freq_Intervall[DelayA_Index_Entered] = DelayA___P_Freq_Intervall
-
Set DelayA_Freq_Intervall_Reload[DelayA_Index_Entered] = DelayA___P_Freq_Intervall
-
Set DelayA_Freq_OnStart[DelayA_Index_Entered] = DelayA___P_Freq_OnStart
-
Set DelayA_Freq_Reload_Dur[DelayA_Index_Entered] = DelayA___P_Freq_Reload_Dur
-
Set DelayA_Freq_Reloads[DelayA_Index_Entered] = DelayA___P_Freq_Reloads
-
Set DelayA_Freq_OnTerminate[DelayA_Index_Entered] = DelayA___P_Freq_OnTerminate
-
Set DelayA_Freq_Trigger[DelayA_Index_Entered] = DelayA___P_Freq_Trigger
-
-
Else - Actions
-
Set DelayA_Freq_Has[DelayA_Index_Entered] = False
-
-
-
-------- Save Loc if used --------
-
Custom script: if udg_DelayA___P_Loc != null then
-
Set DelayA_X[DelayA_Index_Entered] = (X of DelayA___P_Loc)
-
Set DelayA_Y[DelayA_Index_Entered] = (Y of DelayA___P_Loc)
-
Set DelayA_Has_Loc[DelayA_Index_Entered] = True
-
Custom script: else
-
Set DelayA_Has_Loc[DelayA_Index_Entered] = False
-
Custom script: endif
-
-------- -------------------- --------
-
Trigger - Turn on Delayed Action loop <gen>
-
-------- Clean Parameters --------
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditios
-
DelayA_CONS_CLEAR_PARAMETER Equal True
-
-
Then - Actions
-
Custom script: call RemoveLocation(udg_DelayA___P_Loc)
-
Custom script: set udg_DelayA___P_Loc=null
-
Set DelayA___P_Data = 0
-
Custom script: set udg_DelayA___P_Grafic = null
-
Set DelayA___P_Delay = 0.00
-
Set DelayA___P_Real = 0.00
-
Set DelayA___P_Reload_Dur = 0.00
-
Set DelayA___P_Reloads = 0
-
Set DelayA___P_Source = Keine Einheit
-
Set DelayA___P_Target = Keine Einheit
-
Set DelayA___P_Trigger = NO_TRIGGER
-
Set DelayA___P_OnTerminate = NO_TRIGGER
-
Set DelayA___P_Freq_Delay = 0.00
-
Set DelayA___P_Freq_Grafic_Target = 0
-
Set DelayA___P_Freq_Grafic_Attach = <Leerer String>
-
Set DelayA___P_Freq_Grafic_Path = <Leerer String>
-
Set DelayA___P_Freq_Data = 0
-
Set DelayA___P_Freq_Delay = 0.00
-
Set DelayA___P_Freq_OnStart = NO_TRIGGER
-
Set DelayA___P_Freq_Real = 0.00
-
Set DelayA___P_Freq_Intervall = 0
-
Set DelayA___P_Freq_Reload_Dur = 0.00
-
Set DelayA___P_Freq_Reloads = 0
-
Set DelayA___P_Freq_OnTerminate = NO_TRIGGER
-
Set DelayA___P_Freq_Trigger = NO_TRIGGER
-
-
Else - Actions
-
-
-
-
Delayed Action init
-
Events
-
Map initialization
-
-
Conditions
-
Actions
-
-------- Constant Intervall should not be Changed anywhere Else. --------
-
-------- Depending on usage you can Increase this value or decrease --------
-
-------- Higher Values make it more Incorrect but leighter on CPU --------
-
Set DelayA_CONS_Intervall = 0.05
-
Trigger - Add to Delayed Action loop <gen> the event (Time - Every DelayA_CONS_Intervall seconds of game time)
-
-------- This says if you want that the parameter values are nulled after usage --------
-
-------- can be changed before you call the "Delayed Effect add" Trigger --------
-
Set DelayA_CONS_CLEAR_PARAMETER = True
-
-------- Constants --------
-
Set DelayA_CONS_UNLIMITED_RELOADS = -1
-
Set DelayA_CONS_GRAFIC_POINT = 1
-
Set DelayA_CONS_GRAFIC_SOURCE = 2
-
Set DelayA_CONS_GRAFIC_TARGET = 3
-
Set DelayA_CONS_CREATE = Delayed Action add <gen>
-
-------- Some Copy Paste values --------
-
Set DelayA__Action_Has_Reloads = False
-
-
-
This is a helper function contained in the System which shows access from outside of the Delayed Action infrastructure.
In this Trigger we terminate all Delayed Actions created by the unit DelayA___P_Source.
-
DA Terminate PSource
-
Events
-
Conditions
-
Actions
-
Set DelayA_Index = 0
-
For each (Integer A) from 1 to DelayA_Count, do (Actions)
-
Schleifen - Aktionen
-
Set DelayA_Index = DelayA_Link_Next[DelayA_Index]
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
DelayA_Sources[DelayA_Index] Equal DelayA___P_Source
-
-
Then - Actions
-
Set DelayA_Terminate[DelayA_Index] = True
-
-
Else - Actions
-
-
-
-
-
-
Order of executions in the Delayed Action Loop:
- Freq Creation
- Freq - OnStart
- DelayA Trigger
- DelayA OnTermination/ or only Reload
List of Variables API
-----------
Creation
-----------
DelayA___P_Delay The First Delay
DelayA___P_Trigger which Aciton shall be done
DelayA___P_Reload_Dur The Intervall
DelayA___P_Reloads How often you Repeat execution of the Trigger
DelayA___P_Source The unit triggering all that
DelayA___P_Target The Unit suffering/benefiting, if there is one
DelayA___P_Data A Free simple Number
DelayA___P_Real A Free Real Number
DelayA___P_Loc If you want to save a Location
DelayA___P_Grafic A Spezialeffect you might want to save; It is destroyed on overall Expire
DelayA___P_OnTerminate This Trigger is called as soon your DelayA Ends. Cleaning
Freq Variables to let an DelayA start another DelayA.
----------
DelayA___P_Freq_Data A Free to use Integer for Frequenlly Effects:
DelayA___P_Freq_Real A Free to use Real
DelayA___P_Freq_Delay First Delay of your secondary DelayA
DelayA___P_Freq_Intervall If set above 0 the Freq Effect will only trigger every x reloads of the primary DelayA; 1 Means every second Reload of the primary DelayA.
DelayA___P_Freq_Grafic_TargetType Says who gets the Grafical effect if Spawned. Use the Constants to choose the right
DelayA___P_Freq_Grafic_Attachment If TargetType = Target/Source; On which Attachment Point for example overhead.
DelayA___P_Freq_Grafic_Path Which Modell has the Grafic Effect.
DelayA___P_Freq_Reload_Dur Intervall of secondary DelayA
DelayA___P_Freq_Reloads How often does your secondary DelayA repeats
For Custom Variables:
DelayA___P_Freq_OnStart An trigger running directly after the Creation of the Freq DelayA. Here you can create/setup your custom Variables. [use udg_DelayA_Index_Entered]
DelayA___P_Freq_OnTerminate This will Run if the Freq Trigger does expire. Should be used to clean custom variables.
Action This Variables are used in your DelayA-Action Trigger
-----------
Read-only
--------
DelayA__Action_Source Saved Source
DelayA__Action_Target Saved Target
DelayA__Action_Data Free Integer
DelayA__Action_Real Free Real
DelayA__Action_Loc, If set earlier; It is cleaned by the System automataclly
DelayA__Action_Has_Reloads
DelayA__Action_Left_Reloads
DelayA__Action_Grafic
Write-able
---------
DelayA__Action_Loc_new, to change the Loc saved
DelayA__Action_Terminate_This Terminates the DelayA triggering the Action.
/
Custom Variables
---------------
To use Custom Variables it has to be an Array-based Varible.
Connection your Variable with an DelayA is done over three Steps.
1.Set them with the index [udg_DelayA_Index_Entered] which the System offers after you called the "Delayed Action add"-Trigger.
udg_Your_Vari [udg_DelayA_Index_Entered] = your Value
2.Termination-Trigger
Destroy/null used custom Variables
call DestroyGroup( udg_Your_Group[udg_DelayA_Index] )
A Demo showing this is Static Volt, Greater Heal.
/
List of System Variables
-----------------
Constants
-----------
DelayA_CONS_CLEAR_PARAMETER If true it will clear and null DelayA_Parameters
DelayA_CONS_GRAFIC_POINT Value of TargetType
DelayA_CONS_GRAFIC_SOURCE ""
DelayA_CONS_GRAFIC_TARGET ""
DelayA_CONS_Intervall Should only be changed at Delayed Action Init;
DelayA_CONS_UNLIMITED_RELOADS -1; Negative Reloads mean unlimited Repeats
DelayA_CONS_ADD_DelayA A easy Reference to Delayed Action add Trigger. Simplifies Copy and creating new ones, if you got alot of Triggers starting with D.
Index-Values
-----------
DelayA_First The Lowest Index of Running DelayA
DelayA_Last The Highest Index
DelayA_Index The Index of the current DelayA DataPack
Use THis inside a DelayA_Action/Terminate Trigger to access the DelayA Datapack
DelayA_Link_Next Linked List Reference, use this to Acces values from outside of the DelayA System, Checkout Delayed Action Helper
DelayA_LInk_Previous Linked List Reference
DelayA_Index_Entered Index of a new created/started DelayA.
DelayA_Loop Current Index in the Loop do not Use that
DelayA_Pointer_Last_Row Size of Data-Tabell
DelayA_Pointer_Unused_Last Amount of unused DelayA-Pointers (-1 at start)
DelayA_Pointer_Unused Array of Unused Pointers/Free to use Data Rows
Arraybased-System
-----------
DelayA_Freq_Attachment
DelayA_Freq_Data
DelayA_Freq_Data_Real
DelayA_Freq_Duration
DelayA_Freq_Grafic_Path
DelayA_Freq_Grafic_TargetTyp
DelayA_Freq_Has
DelayA_Freq_Intervall
DelayA_Freq_Intervall_Reload
DelayA_Freq_OnStart
DelayA_Freq_OnTerminate
DelayA_Freq_Reload_Dur
DelayA_Freq_Trigger
DelayA_Data The Free Integers
DelayA_Data2 The Free Real
DelayA_Grafic
DelayA_Has_Loc
DelayA_Paused
DelayA_ReLoad_Dur
DelayA_ReLoads
DelayA_Remainig_Dur
DelayA_Sources
DelayA_Targets
DelayA_Terminate
DelayA_Trigger
DelayA_OnTerminate
DelayA_X
DelayA_Y
Version 1.1
First ReleaseVersion 1.2
Un/Pause, Permanent Delayed ActionVersion 1.3
Preset Delayed Action to start another Delayed Action, This is called FreqVersion 1.3a
Terminate DA from outside
Documentation UpdateVersion 1.3c
Renamed from Delayed Effect -> Delayed Action
Optimizing of Version Row 1.3Version 1.4
Pointers were implemented which Point to the Data-Row beeing used.Version 1.4a
Removed the Need of Reindex Triggers of Version 1.3 Row.
Consider OnTermination still is needed to Remove/Destroy used Objects.
Fixed a critical Bug Implemented in V1.4.V1.4b
Sternenregen -> Star circle
Sternregen is now in English
Added a new Constant: DelayA_CONS_ADD_DelayA.
The new constant makes copying more easy and sets the Creating trigger at the top of the Trigger List.
Changed the Prefix of System Variable: DA -> DelayA
This ones were shortend to accept the new Prefix.
DA___P_Freq_Grafic_Attachment -> DelayA___P_Freq_Grafic_Attach
DA___P_Freq_Grafic_TargetType -> DelayA___P_Freq_Grafic_Target
DA__Action_Has_Reloads_Left -> DelayA__Action_Has_Reloads
DA__Action_Remaining_Reloads -> DelayA__Action_Left_Reloads
DA__Action_Terminate_This_DA -> DelayA__Action_Terminate_This
DA_Pointer_Unused_Last_Index -> DelayA_Pointer_Unused_Last
Term Changes:
DA_Constant -> DelayA_CONS
DA_Frequently -> DelayA_Freq
Version 1.5
Changed Access type: Dynamic Pointer -> Linked ListVerson 1.5a
Optimized the Linked List
Credits |
Maker zv27 |
Contents
Page 1 of 2