Well it's for a TD map. (I should have specified!)
You get 1 mineral for 10 unit kills. When the player gains that mineral, I want a unit to be created at a region and set the minerals back to zero.
(Just thinking, maybe instead just make a trigger: player x kills 10 units belonging to Player x - create unit...) Would that be easier? If so, how can I make that trigger?
I had a trigger in the old editor that looked like this:
Player accumulates 1 Mineral
-Subtract 1 mineral
-Create Unit at region
How can i do this in the new editor? I can't seem to get it. Thanks!!!
So you want every mineral you mine to create a unit at a point? also reset minerals to 0? @copperfront: Go
@cstorm15: Go
Well it's for a TD map. (I should have specified!)
You get 1 mineral for 10 unit kills. When the player gains that mineral, I want a unit to be created at a region and set the minerals back to zero.
(Just thinking, maybe instead just make a trigger: player x kills 10 units belonging to Player x - create unit...) Would that be easier? If so, how can I make that trigger?
Or if just "Player x gains 10 minerals - -> Create unit at region + Modify P prop (minerals) to 0"
how can i do that?
bump
I don't understand why you would need to do that, as you are essentially using the minerals as a variable.
Have an integer variable to keep track of how many units you kill for that player and increment it whenever the player kills a unit.
Whenever you increase that variable, you can run a If statement to see if it's >10, if so, give a unit.
It also frees up the minerals to be used for other things