• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Spawn Problems

Status
Not open for further replies.
Level 7
Joined
Mar 22, 2010
Messages
214
I made a simple spawing system.

Oooh.
  • Spawn
    • Events
      • Time - Every 30.00 seconds of game time
    • Conditions
    • Actions
      • -------- Spawn --------
      • Unit - Create 4 Brigand for Neutral Hostile at (Center of 1 <gen>) facing Default building facing degrees
      • Unit - Create 4 Rogue for Neutral Hostile at (Center of 2 <gen>) facing Default building facing degrees
      • Unit - Create 4 Brigand for Neutral Hostile at (Center of 3 <gen>) facing Default building facing degrees
      • Unit - Create 4 Rogue for Neutral Hostile at (Center of 4 <gen>) facing Default building facing degrees
      • Unit - Create 4 Brigand for Neutral Hostile at (Center of 5 <gen>) facing Default building facing degrees
      • Unit - Create 4 Rogue for Neutral Hostile at (Center of 6 <gen>) facing Default building facing degrees
      • Unit - Create 4 Brigand for Neutral Hostile at (Center of 7 <gen>) facing Default building facing degrees
      • Unit - Create 4 Rogue for Neutral Hostile at (Center of 8 <gen>) facing Default building facing degrees

the problem is, it only spawn at a region, and then after 30 seconds, it will spawn into a different region, I mean not all the regions are spawned.

----

Don't worry about leaks,
I've created Variable called "Loc"
And then after they are spawned
I just putted "RemoveLoc custom script" :smile:
Well, I didn't include it here, I removed it cause it didn't work, too.

Tried everything I've got :sad:
 
Level 7
Joined
Mar 22, 2010
Messages
214
:) well, i tried that before I've done the trigger posted here.

Can someone take my request?
> First, A countdown timer, 30 seconds.
> when the countdown timer finishes,
> Spawn Level 1 creeps at the 8 regions :smile:
> then after about 45 seconds,
> Spawn Level 2 creeps at the 8 regions :wink:
> then so on and so forth.
 
Level 29
Joined
Mar 10, 2009
Messages
5,016
Im doing a test and it works fine...
  • Test
    • Events
      • Time - Every 5.00 seconds of game time
    • Conditions
    • Actions
      • Unit - Create 4 Brigand for Neutral Hostile at (Center of Region 000 <gen>) facing Default building facing degrees
      • Unit - Create 4 Rogue for Neutral Hostile at (Center of Region 001 <gen>) facing Default building facing degrees
      • Unit - Create 4 Brigand for Neutral Hostile at (Center of Region 002 <gen>) facing Default building facing degrees
      • Unit - Create 4 Rogue for Neutral Hostile at (Center of Region 003 <gen>) facing Default building facing degrees

BUT, the units have a 'hide' ability during night so do this for testing...

Melee Game - Use melee time of day (for all players)
 
Level 7
Joined
Mar 22, 2010
Messages
214
Thanks for pointing me out, I've created my own, can you please check it if it is leak-less.

  • Spawn Initialization
    • Events
      • Map initialization
    • Conditions
    • Actions
      • -------- Types --------
      • Set Unit_Type[1] = Brigand
      • Set Unit_Type[2] = Rogue
      • Set Unit_Type[3] = Bandit
      • Set Unit_Type[4] = Murloc Huntsman
      • Set Unit_Type[5] = Giant Wolf
      • Set Unit_Type[6] = Timber Wolf
      • Set Unit_Type[7] = Furbolg
  • Spawn Creeps
    • Events
      • Time - Every 45.00 seconds of game time
    • Conditions
    • Actions
      • -------- Locs --------
      • Set Loc[1] = (Center of 1 <gen>)
      • Set Loc[2] = (Center of 2 <gen>)
      • Set Loc[3] = (Center of 3 <gen>)
      • Set Loc[4] = (Center of 4 <gen>)
      • Set Loc[5] = (Center of 5 <gen>)
      • Set Loc[6] = (Center of 6 <gen>)
      • Set Loc[7] = (Center of 7 <gen>)
      • Set Loc[8] = (Center of 8 <gen>)
      • For each (Integer A) from 1 to 1, do (Actions)
        • Loop - Actions
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[1] facing Default building facing degrees
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[2] facing Default building facing degrees
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[3] facing Default building facing degrees
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[4] facing Default building facing degrees
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[5] facing Default building facing degrees
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[6] facing Default building facing degrees
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[7] facing Default building facing degrees
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[8] facing Default building facing degrees
      • -------- Remove Leak --------
      • Custom script: call RemoveLocation( udg_Loc[1] )
      • Custom script: call RemoveLocation( udg_Loc[2] )
      • Custom script: call RemoveLocation( udg_Loc[3] )
      • Custom script: call RemoveLocation( udg_Loc[4] )
      • Custom script: call RemoveLocation( udg_Loc[5] )
      • Custom script: call RemoveLocation( udg_Loc[6] )
      • Custom script: call RemoveLocation( udg_Loc[7] )
      • Custom script: call RemoveLocation( udg_Loc[8] )
 
Level 29
Joined
Mar 10, 2009
Messages
5,016
that's a long trigger, shorter is...
  • Untitled Trigger 001
    • Events
      • Time - Every 45.00 seconds of game time
    • Conditions
    • Actions
      • For each (Integer A) from 1 to 8, do (Actions)
        • Loop - Actions
          • Unit - Create 4 Unit_Type[(Random integer number between 1 and 7)] for Neutral Hostile at Loc[(Integer A)] facing Default building facing degrees
if your using your Loc variable many times to the same CENTER POINT, you
dont need to remove it 'always'...just set it at the initialization part...
 
Status
Not open for further replies.
Top