• 🏆 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!

[Trigger] Hatchery Type (Zergish code)

Status
Not open for further replies.
Level 4
Joined
May 27, 2009
Messages
44
I need a code wherein the Hatchery can spawn only 3 eggs. All Hatcheries/Queen's Lain/Metamorphic Hive are limited to only 3 eggs.

Where as the unit Eggsack can produce 1 egg.

I did try in coding it but the code doesnot impose the limit and production properly.

I also experience a bug when I start a game.

Any solutions?
 

Attachments

  • The Creepspawn.w3x
    96.6 KB · Views: 81
Level 4
Joined
May 27, 2009
Messages
44
Thanks again.

When I played the game I encounter these:

  • The Hatchery Spawns to many Eggs
  • The Code does not include 'New Hatcheries'
  • It does not spawn eggs on the New Hatcheries:zip:
  • Also, the Air unit that are upgraded from the Egg does not have a proper hegiht :eek:
  • It also continues to spawn even if the Hatchery/Lair/Hive has died

Btw, do you know how to extract files?
 

Attachments

  • The Creepspawn.w3x
    104.5 KB · Views: 57
Level 37
Joined
Mar 6, 2006
Messages
9,240
One reason is that you enabled the trigger that I disabled. Just delete it. Another reason is that you fuxored the trigger that adds hatcheries that are built. And you changed the event of "Add hacheries" to periodic, when it should be one time only.

Why did you do that?

Change "Add hatcheries 1" and "Add hatcheries 2" to what they were and remove "Egg copy" altogether.

In the map I posted, you should change "picked unit" to "triggering unit" in "Add hatcheries 2". That way new hatcheries will start spawning eggs.
 
Level 4
Joined
May 27, 2009
Messages
44
I changed the variables as you advised but I don't know why is stops spawning after a while. I also does not seem to include the Lair/Hive. I tried to add the Lair/Hive on the Temp_Group_1 but the eggs stopped spawning. :psmile:
 

Attachments

  • Creepspawn.w3x
    103.3 KB · Views: 150
Status
Not open for further replies.
Top