Warcraft III resources & community, 2003–2006 · archived

Ammuntion Count Help!!!

4 posts
#1

Ammuntion Count Help!!!

Can someone post the correct format or way to add Ammunition to a unit??? Example can be found in All Dawn of the Dead Games. Thanks for helping guys.
#2
you have to use gold or wood for ammunition (in following i use wood) . for a simple ammo system use triggers like that:

TRIGGER 1:  ----Ammo decrease

EVENT:      unit-a unit is attacked

CONDITION:  <<< here conditions that only those players decrease ammo, which use ammo >>>
           ---for example---
           OR   
           - (owner of attacking unit) equal to player X
           - (owner of attacking unit) equal to player Y

ACTIONS:   add -1 lumber to (owner of attacking unit)


TRIGGER 2: ---If Ammo 0---

EVENT:    (player X) lumber less than or equal to 0
          (player Y) lumber less than or equal to 0
          ...

COND:     

ACTIONS: set (triggering player) alliance to player(enemy) to neutral


TRIGGER 3: ---Has ammo again---

EVENT:    (player X) lumber becomes greater than 0
          (player Y) lumber becomes greater than 0
          ...

COND:     

ACTIONS: set (triggering player) alliance to player(enemy) to enemy



hope that helps you. i created this system for my resevil map and it work all fine. :wink:
#3

Worked Rather Nicely!

Thanks man, It really did work well. I'll be sure to give you credit where needed :D
#4
no problems at all :D