• 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.

How to make multiple units to spawn from point and move to another point?

Status
Not open for further replies.
Level 1
Joined
Apr 2, 2011
Messages
5
It's been a while since I have made any kinds of triggers and now I have forgotten al of the basics. Could any one please tell me how to make some units to spawn and then to move to another location?
Like:
  • Sheeps
    • Events
      • Time - Every 0.50 seconds of game time
    • Conditions
    • Actions
      • Set Sheepspawn[1] = ((Center of Region 000 <gen>) offset by (500.00, 0.00))
      • Unit - Create 1 Sheep for Neutral Passive at Sheepspawn[1] facing 270.00 degrees
      • Custom script: call RemoveLocation (udg_Sheepspawn[1])
      • Set Smoveint[Smoveint2] = Smoveint[(Smoveint2 + 1)]
      • Set Sheep[Smoveint[Smoveint2]] = (Last created unit)
      • Set Sheepposition[Smoveint[Smoveint2]] = (Position of Sheep[Smoveint[Smoveint2]])
      • Set Sheepmove[Smoveint[Smoveint2]] = (Sheepposition[Smoveint[Smoveint2]] offset by 20.00 towards -90.00 degrees)
      • Unit - Move Sheep[Smoveint[Smoveint2]] instantly to Sheepmove[Smoveint[Smoveint2]]
I know, this version doesn't work at all but the idea of this thing is that sheep (or anything else) spawns from point and then moves to another location with instant move to position which is close to unit and then creates some kind of wave of sheeps. Please help me!
 
Level 1
Joined
Apr 2, 2011
Messages
5
well I try tochange it to 270 then... I was a little bit lazy
Nope. It still doesnt work. sheeps get spawned but they are not moving.
trigger looks like this atm
  • Sheeps
    • Events
      • Time - Every 0.50 seconds of game time
    • Conditions
    • Actions
      • Set Sheepspawn[1] = ((Center of Region 000 <gen>) offset by (500.00, 0.00))
      • Set Smoveint[Smoveint2] = Smoveint[(Smoveint2 + 1)]
      • Unit - Create 1 Sheep for Neutral Passive at Sheepspawn[1] facing 270.00 degrees
      • Set Sheep[Smoveint[Smoveint2]] = (Last created unit)
      • Set Sheepposition[Smoveint[Smoveint2]] = (Position of Sheep[Smoveint[Smoveint2]])
      • Set Sheepmove[Smoveint[Smoveint2]] = (Sheepposition[Smoveint[Smoveint2]] offset by 20.00 towards 270.00 degrees)
      • Unit - Move Sheep[Smoveint[Smoveint2]] instantly to Sheepmove[Smoveint[Smoveint2]]
 
Last edited:
Level 9
Joined
Dec 26, 2010
Messages
475
well I try tochange it to 270 then... I was a little bit lazy
Nope. It still doesnt work. sheeps get spawned but they are not moving.
trigger looks like this atm
  • Sheeps
    • Events
      • Time - Every 0.50 seconds of game time
    • Conditions
    • Actions
      • Set Sheepspawn[1] = ((Center of Region 000 <gen>) offset by (500.00, 0.00))
      • Set Smoveint[Smoveint2] = Smoveint[(Smoveint2 + 1)]
      • Unit - Create 1 Sheep for Neutral Passive at Sheepspawn[1] facing 270.00 degrees
      • Set Sheep[Smoveint[Smoveint2]] = (Last created unit)
      • Set Sheepposition[Smoveint[Smoveint2]] = (Position of Sheep[Smoveint[Smoveint2]])
      • Set Sheepmove[Smoveint[Smoveint2]] = (Sheepposition[Smoveint[Smoveint2]] offset by 20.00 towards 270.00 degrees)
      • Unit - Move Sheep[Smoveint[Smoveint2]] instantly to Sheepmove[Smoveint[Smoveint2]]

POST the map. and i'll try to fix it.
 
Status
Not open for further replies.
Top