Hey, not sure if this is the right place to post this, but I am currently working on a map and I've hit some snags.
Main snag:
All ranged units have a limited amount of ammo (charges on the weapon), and I got that part no prob, but now the part I'm having issues with is I'm wanting to either have something in the command card showing the amount of ammo left (maybe like a passive ability or something) or to have it so when the ammo count drops below a certain point, to add a behavior to the unit stating that it has low ammo.
I have racked my brain with the triggers and I the closest I have come is:
Events
Unit - Any Unit starts attacking
Local Variables
Conditions
Actions
General - If (Conditions) then do (Actions) else do (Actions)
If
(Charge Remaining Count for ability Attack on unit (Triggering unit)) < 45.0
Then
Unit - Kill (Triggering unit)
Else
The kill triggering unit was just a quick forsure way to show me that it was working. but with that trigger, whenever a unit attacks (whether it has attack counts or not) it will kill the unit. The thing that is making me think that happens is that "(Charge Remaining Count for ability Attack on unit (Triggering unit)) < 45.0" part is talking about the counts remaining on the "attack" ability, where the counts are on the weapon itself that they are using.
So please any insight would be greatly apreciated! Thanks!
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
Hey, not sure if this is the right place to post this, but I am currently working on a map and I've hit some snags.
Main snag: All ranged units have a limited amount of ammo (charges on the weapon), and I got that part no prob, but now the part I'm having issues with is I'm wanting to either have something in the command card showing the amount of ammo left (maybe like a passive ability or something) or to have it so when the ammo count drops below a certain point, to add a behavior to the unit stating that it has low ammo.
I have racked my brain with the triggers and I the closest I have come is:
Events Unit - Any Unit starts attacking Local Variables Conditions Actions General - If (Conditions) then do (Actions) else do (Actions) If (Charge Remaining Count for ability Attack on unit (Triggering unit)) < 45.0 Then Unit - Kill (Triggering unit) Else
The kill triggering unit was just a quick forsure way to show me that it was working. but with that trigger, whenever a unit attacks (whether it has attack counts or not) it will kill the unit. The thing that is making me think that happens is that "(Charge Remaining Count for ability Attack on unit (Triggering unit)) < 45.0" part is talking about the counts remaining on the "attack" ability, where the counts are on the weapon itself that they are using.
So please any insight would be greatly apreciated! Thanks!