I don't know why you need to do this. Technically, when charges are at 0, you're not supposed to be able to use that weapon anyway.
Use a validator of type "CValidatorUnitCompareChargeUsed" which checks :
- When it's equal to 0
- When it's greater than 0 (optional).
Pay attention :
> If you set an ability, the value for the field is the link in "Cost" field of your ability WITHOUT the prefix "Abil/".
> If you don't set an ability neither a behavior, the value is the link WITH the prefix "Abil/".
In addition to this, you need to create a new behavior that controls your weapon.
Set modifications which deactivate the weapon. It should be temporary.
And finally, set validator (deactivate) with "CValidatorUnitCompareChargeUsed" when EQ 0. If the validator is false, the behavior is deactivated. That means we deactivate the weapon when the behavior is active, when the validator is true and thus when charges EQ 0.