HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

help with guard position plz

03-11-2007, 11:48 PM#1
botanic
ok I have this script (thanks to pyrogasm) however the units are still under the effects of there guard position how can i fix it?

PS: I cant change the gameplay constants unless someone can tell me how to create a guard position for some units

Trigger:
Spawn
Collapse Events
Time - Every 25.00 seconds of game time
Conditions
Collapse Actions
-------- Red --------
Collapse For each (Integer A) from 1 to 4, do (Actions)
Collapse Loop - Actions
Collapse For each (Integer B) from 1 to 2, do (Actions)
Collapse Loop - Actions
If ((Integer B) Equal to 1) then do (Set temppoint = (Center of Spawn_Regions[(Integer A)])) else do (Set temppoint = (Center of Spawn_Regions[((Integer A) + 8)]))
Unit - Create creepNum Unit_Spawns[(Integer B)] for Neutral Victim at temppoint facing Default building facing degrees
Custom script: call RemoveLocation( udg_temppoint )
Set temppoint = (Position of Path_Makers[(Integer A)])
If ((Integer B) Equal to 1) then do (Set tempunitgroup = (Units in Spawn_Regions[(Integer A)] owned by Neutral Victim)) else do (Set tempunitgroup = (Units in Spawn_Regions[((Integer A) + 8)] owned by Neutral Victim))
Unit Group - Pick every unit in tempunitgroup and do (AI - Ignore (Picked unit)'s guard position)
Unit Group - Pick every unit in tempunitgroup and do (Unit - Order (Picked unit) to Attack-Move To temppoint)
Custom script: call RemoveLocation( udg_temppoint )
Custom script: call DestroyGroup( udg_tempunitgroup )
Collapse For each (Integer A) from 5 to 8, do (Actions)
Collapse Loop - Actions
Collapse For each (Integer B) from 1 to 2, do (Actions)
Collapse Loop - Actions
If ((Integer B) Equal to 1) then do (Set temppoint = (Center of Spawn_Regions[(Integer A)])) else do (Set temppoint = (Center of Spawn_Regions[((Integer A) + 8)]))
Unit - Create creepNum Unit_Spawns[((Integer B) + 2)] for Neutral Extra at temppoint facing Default building facing degrees
Custom script: call RemoveLocation( udg_temppoint )
Set temppoint = (Position of Path_Makers[(Integer A)])
If ((Integer B) Equal to 1) then do (Set tempunitgroup = (Units in Spawn_Regions[(Integer A)] owned by Neutral Extra)) else do (Set tempunitgroup = (Units in Spawn_Regions[((Integer A) + 8)] owned by Neutral Extra))
Unit Group - Pick every unit in tempunitgroup and do (AI - Ignore (Picked unit)'s guard position)
Unit Group - Pick every unit in tempunitgroup and do (Unit - Order (Picked unit) to Attack-Move To temppoint)
Custom script: call RemoveLocation( udg_temppoint )
Custom script: call DestroyGroup( udg_tempunitgroup )
03-12-2007, 12:57 AM#2
Pyrogasm
Did you try doing:
Trigger:
AI - Ignore the guard positions of all Neutral Victim units
AI - Ignore the guard positions of all Neutral Extra units
Periodically?
03-12-2007, 02:47 AM#3
botanic
yes i did try that I don't know why it does not work. I attached the map if anyone has any ideas.
Attached Files
File type: w3xPOH V.5.w3x (288.5 KB)