- Joined
- Nov 9, 2006
- Messages
- 2,561
So i have these two triggers, i'm curious if theres something here that causes a desync.
It always occurs when the supply drops spawn in.
I've not yet had problems with this trigger until recently when i made a few adjustments.
The jist of it is that the game's a battle royale and a box spawns randomly inside the circle containing items, units or such.
It always occurs when the supply drops spawn in.
I've not yet had problems with this trigger until recently when i made a few adjustments.
The jist of it is that the game's a battle royale and a box spawns randomly inside the circle containing items, units or such.
-
Cache Spawn
-
Events
-
Time - CacheTimer expires
-
-
Conditions
-
GameOver Equal to False
-
-
Actions
-
Set Cache_TempPoint[1] = (Position of CircleUnit)
-
For each (Integer Cache_Integer1) from 1 to 100, do (Actions)
-
Loop - Actions
-
Set Cache_TempPoint[2] = (Cache_TempPoint[1] offset by ((Random real number between 0.00 and CircleRadius) + 0.00) towards (Random angle) degrees)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Terrain pathing at Cache_TempPoint[2] of type Walkability is off) Equal to False
-
((Playable map area) contains Cache_TempPoint[2]) Equal to True
-
-
Then - Actions
-
-------- Spacebar Point --------
-
Player Group - Pick every player in (All players) and do (Actions)
-
Loop - Actions
-
Camera - Set a spacebar-point for (Picked player) at Cache_TempPoint[2]
-
-
-
-------- Run Trigger --------
-
Sound - Play Hint <gen>
-
Cinematic - Ping minimap for (All players) at Cache_TempPoint[2] for 30.00 seconds, using a Warning ping of color (25.00%, 100.00%, 25.00%)
-
-------- Clear Nearby Crops --------
-
Set Integer1 = (Random integer number between 1 and 3)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Integer1 Equal to 3
-
-
Then - Actions
-
-------- Item Cache --------
-
Unit - Create 1 Item Cache for Neutral Hostile at Cache_TempPoint[2] facing (Random angle) degrees
-
Game - Display to (All players) for 5.00 seconds the text: |cffffcc00Note:|r A...
-
-
Else - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Integer1 Equal to 2
-
-
Then - Actions
-
-------- Supply Cache --------
-
Unit - Create 1 Supply Cache for Neutral Hostile at Cache_TempPoint[2] facing (Random angle) degrees
-
Game - Display to (All players) for 5.00 seconds the text: |cffffcc00Note:|r A...
-
-
Else - Actions
-
-------- Prison Cage --------
-
Unit - Create 1 Prison Cage for Neutral Hostile at Cache_TempPoint[2] facing (Random angle) degrees
-
Game - Display to (All players) for 5.00 seconds the text: |cffffcc00Note:|r A...
-
-
-
-
-
-------- Loop Stuff --------
-
Unit - Set the custom value of (Last created unit) to 100
-
Unit Group - Add (Last created unit) to CacheUnitGroup
-
Unit - Make (Last created unit) Invulnerable
-
Animation - Change (Last created unit)'s vertex coloring to (25.00%, 100.00%, 25.00%) with 100.00% transparency
-
-------- Set New Timer --------
-
Set Real1 = (Random real number between SupplyDropMinCooldown and SupplyDropMaxCooldown)
-
Set Real2 = (20.00 x (Real(CircleNumber)))
-
Countdown Timer - Start CacheTimer as a One-shot timer that will expire in (Real1 + Real2) seconds
-
Set CacheTimer = (Last started timer)
-
-------- Cleaning --------
-
Custom script: call RemoveLocation(udg_Cache_TempPoint[1])
-
Custom script: call RemoveLocation(udg_Cache_TempPoint[2])
-
-------- Cache Loop --------
-
Trigger - Turn on Cache Loop <gen>
-
-------- Skip --------
-
Skip remaining actions
-
-
Else - Actions
-
Custom script: call RemoveLocation(udg_Cache_TempPoint[2])
-
-
-
-
-
Custom script: call RemoveLocation(udg_Cache_TempPoint[1])
-
-------- No Spawn --------
-
Game - Display to (All players) the text: Debug: Couldn't fin...
-
-------- Set New Timer --------
-
Set Real1 = (Random real number between SupplyDropMinCooldown and SupplyDropMaxCooldown)
-
Set Real2 = (20.00 x (Real(CircleNumber)))
-
Countdown Timer - Start CacheTimer as a One-shot timer that will expire in (Real1 + Real2) seconds
-
Set CacheTimer = (Last started timer)
-
-
-
Cache Loop
-
Events
-
Time - Every 0.30 seconds of game time
-
-
Conditions
-
GameOver Equal to False
-
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Number of units in CacheUnitGroup) Greater than 0
-
-
Then - Actions
-
Unit Group - Pick every unit in CacheUnitGroup and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Custom value of (Picked unit)) Greater than or equal to 0
-
-
Then - Actions
-
Set Cache_TempPoint[3] = (Position of (Picked unit))
-
Unit - Set the custom value of (Picked unit) to ((Custom value of (Picked unit)) - 1)
-
Animation - Change (Picked unit)'s vertex coloring to (25.00%, 100.00%, 25.00%) with (Real((Custom value of (Picked unit))))% transparency
-
Set Real1 = ((Real((Custom value of (Picked unit)))) - 100.00)
-
Set Real2 = (Abs(Real1))
-
Set Real3 = (Real2 x 4.50)
-
Destructible - Pick every destructible within Real3 of Cache_TempPoint[3] and do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
((Picked destructible) is invulnerable) Equal to False
-
-
Then - Actions
-
Destructible - Set life of (Picked destructible) to ((Current life of (Picked destructible)) - 10.00)
-
-
Else - Actions
-
-
-
-
Custom script: call RemoveLocation(udg_Cache_TempPoint[3])
-
-
Else - Actions
-
Set Cache_TempPoint[4] = (Position of (Picked unit))
-
Special Effect - Create a special effect at Cache_TempPoint[4] using Objects\Spawnmodels\Undead\UDeathMedium\UDeath.mdl
-
Special Effect - Destroy (Last created special effect)
-
Animation - Change (Picked unit)'s vertex coloring to (100.00%, 100.00%, 100.00%) with 0.00% transparency
-
Unit Group - Remove (Picked unit) from CacheUnitGroup
-
Unit - Make (Picked unit) Vulnerable
-
Custom script: call RemoveLocation(udg_Cache_TempPoint[4])
-
-
-
-
-
-
Else - Actions
-
Trigger - Turn off (This trigger)
-
-
-
-