- Joined
- Jun 17, 2010
- Messages
- 2,275
I made the game display checks to see where the trigger was at a given interval and everything leads to the correct spot but the other actions dont seem to be working and i cant quite find the error since this is my first time using hashtables.
-
Decieve Break
-
Events
- Unit - A unit Is attacked
-
Conditions
- ((Attacking unit) has buff Decieve ) Equal to True
-
Actions
- Set Guise_Controller_Point = (Position of (Triggering unit))
- Set Decieve_Target = (Triggering unit)
- Set Decieve_Boolean = True
- Unit - Create 1 Unit Controller for (Owner of (Attacking unit)) at Guise_Controller_Point facing Default building facing degrees
- Unit - Remove (Attacking unit) from the game
- Selection - Add (Last created unit) to selection
- Set Decieve_Dummy = (Last created unit)
- Custom script: set udg_Decieve_Key = GetHandleId(udg_Decieve_Target)
- Hashtable - Save Handle OfDecieve_Dummy as 0 of Decieve_Key in Decieve_HashTable
- Hashtable - Save Decieve_Boolean as 1 of Decieve_Key in Decieve_HashTable
- Unit Group - Add Decieve_Dummy to Decieve_DummyGroup
- Trigger - Turn on Dummy Movement <gen>
- Custom script: call RemoveLocation(udg_Guise_Controller_Point)
-
Events
-
Dummy Movement
-
Events
- Time - Every 0.03 seconds of game time
- Conditions
-
Actions
- Game - Display to (All players) the text: Test: Check 5
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Decieve_DummyGroup is empty) Equal to True
-
Then - Actions
- Game - Display to (All players) the text: Test: Check 4
- Trigger - Turn off (This trigger)
-
Else - Actions
- Game - Display to (All players) the text: Test: Check 1
-
Unit Group - Pick every unit in Decieve_DummyGroup and do (Actions)
-
Loop - Actions
- Set Decieve_Dummy = (Picked unit)
- Hashtable - Save Handle OfGuise_Controller_Point as 2 of Decieve_Key in Decieve_HashTable
- Set Decieve_Boolean = (Load 1 of Decieve_Key from Decieve_HashTable)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Decieve_Boolean Equal to False
-
Then - Actions
- Game - Display to (All players) the text: Test: Check 3
- Unit Group - Remove Decieve_Dummy from Decieve_DummyGroup
- Hashtable - Clear all child hashtables of child Decieve_Key in Decieve_HashTable
-
Else - Actions
- Game - Display to (All players) the text: Test: Check 2
- Set Guise_Controller_Point = (Load 2 of Decieve_Key in Decieve_HashTable)
- Unit - Move Decieve_Dummy instantly to Guise_Controller_Point
-
If - Conditions
-
Loop - Actions
-
If - Conditions
- Custom script: call RemoveLocation(udg_Guise_Controller_Point)
-
Events
Last edited: