• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

terran triggers

Status
Not open for further replies.
Level 1
Joined
Jun 13, 2006
Messages
4
BlazeLancer said:
is there a action for triggers for when a unit enter a certain terran like grass or snow?
Yes, i would make it like this; 8)

First make a Variable named "tempPoint" Note; its a Point
Event;
Time - Every 0.10 seconds of game time
Conditions;
None
Actions;
Unit Group - Pick every unit in(Units in(Entire map))
Loop Actions;
Set tempPoint = (Position of (Picked unit))
If (All Conditions are True)then do (Then Actions)Else do (Else Actions)
- If Conditions
(Terrain type at tempPoint)Equal to Cityscape - *Grass Trim "Change this to the terrain type you want*
- Then Actions
Unit - *Kill (Picked unit)"Change this to the action you want*
- Else Actions
Custom script: call RemoveLocation(udg_tempPoint)

I would personaly make it like this 8)
 
Level 24
Joined
Jun 26, 2006
Messages
3,406
it might recreate the variable. or it might not actually get rid of it, but stop it from being used. i don't know that much about scripting =/
 
Level 24
Joined
Jun 26, 2006
Messages
3,406
BlazeLancer said:
si isnt there no real need to remove the var and just end in "do nothing"?
pretty much but this saves just a smidgeon of space on ur map. actually u wouldn't use "do nothing" u would stop the trigger there.
 
Status
Not open for further replies.
Top