This thread was automatically marked as Locked.
I have locked this becuase it is solved and it works great. read on if you want to see the outcome. :D
This thread was automatically marked as Locked.
I have locked this becuase it is solved and it works great. read on if you want to see the outcome. :D
I am tring to make an ability that requires you to have energy to move. i use to have it but i can not remember what i did before (LOL). currently i have an ability/behavior/affect for this, and all i need to do is figure out where the "cost" energy goes. suggestions. i have behavior set as Buff, Effect as Apply Buff, Ability as Effect Instant. maybe these need to change as well, idk. Thanks or any feed back.
So, what you want is an ability that allows a unit to move but causes a gradual energy loss, like a ghost's cloak? If so all you need is a Behavior ability that activates a behavior that enables a Move ability and adds an energy loss.
@Spoolofwhool: Go
Thanks i will try that out. :D
@tdhsst: Go
Field Ghost - Cloak Unit: Vital Regeneration Bonus + (0|0|-1.4765)
going to apply this to my behavior to see if it works, lol.
Edit: i did apply this and it does work ,but the problem is how do i only get it to fire when the unit is moving only. i added a behavior to the unit but it runs constantly not when only moving.. suggestions?
Okay, I thought you wanted it to be a togglable ability like cloak but I'm guessing its more like a thing where all the time, if the unit doesn't have energy it can't move and while it is moving, it's energy lowers.
Take copy the ghost cloak behaviour and remove the cloak part, if you haven't done something similar already. Then make a Unit Compare Order Queue or Unit Compare Order validator (I'm not sure what the differences between them is, but I know one of them works.) and set the Validator - Ability field to move and the Validator - Value field to 1 and the Validator - Unit - Value to caster. Finally add your validator to the Validator - Disable field of your behaviour and it should work. If it doesn't, or it works oppositely, then try messing with the values.
@Spoolofwhool: Go
Thanks! btw nice name, lol. going to try that out. :D
you can just make an behavior that lower your energy regen and set a valdiator to the behavior so that the behavior would just work when the unit use move ability
You will also need a Combine validator to check for patrol (move index 2) and the attack ability.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
@Darkillusion95: Go
@DrSuperEvil: Go
Thanks guys it works perfectly to drain energy while moving and such... now the only issue is that i need the unit to STOP when it has 0 energy.
ideas?
Have another Buff that disables the Move ability which is disabled if the unit has energy.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
@DrSuperEvil: Go
Ability: Abilities Disabled + (Attack|Move)
Behavior: Validators (Disable) - (Caster Has Energy)
i have this set and its constantly on... which is confusing because it says "If one of these Validators returns false, the behvior will be disabled"
You want the bahavior which disables the abilities to be ON when unit has energy returns false
You are using a validator that returns true if the caster has energy. As you are using an equivalent double negation you want it to return true when the caster has 0 no energy.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg
@DrSuperEvil: Go
Thank you very much for your help, i have it worked out now, just going to adjust numbers to suit how i want it..
The end results are: Apply Behavior to drain energy while attacking/moving/pathing. Then i had to make an Instant Ability Autocast to self/Effect:apply Buff, Buff/Disable Move&Attack abilities when energy is 0. The reason i had to put it in an ability is because using it in a straight Behavior attached to the unit it would only work when the unit is stationary, meaning the energy would drain to 0 but it would not stop the unit till the attack/patrol/move was done, then it would apply. With the Ability on autocast as soon as the unit hits 0 energy it casts and applies the brakes, removing the attack/move ablity. Keep an eye out in the future on the 'new map' forum for the map i am putting together. Thanks again. :D.
Reminds me of this this thread.
http://www.sc2mapster.com/forums/development/data/31698-solved-modifying-an-attribute-behavior-stat-while-moving/#p8
You just need two buffs. The first drains energy via nega regen or a periodic Modify Unit effect and is disabled when the unit is not using move/attack. The second buff disables move and requires =0 energy to be enabled.
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
https://www.sc2mapster.com/forums/resources/tutorials/179654-data-actor-events-message-texture-select-by-id
https://media.forgecdn.net/attachments/187/40/Screenshot2011-04-17_09_16_21.jpg