I was wondering if someone can help me make a weapon that works similar to the void ray. It would get stronger as it hit the target but once the target is changed or dies it resets counter and has to build up again. Not sure if there is a validator to check if the target changed or not.
Well, the void ray uses tons of effects and especially actors. You can try to copy that, but its a little tough for starters, I think.
You could go for a weapon similar to the Sentry as a base. It uses a channeling persistent effect instead of the actual weapon cooldown (just like the void ray btw). So you can make your persistent stack damage behaviors on the hero, and whenever the persistent stops, remove all behavior stacks again.
Drawback would be, that plain attackspeed bonuses would have no effect anymore, because they work for the weapon, but not on the persistent effect.
Void ray works by applying a persistent to the target which after so many seconds expires and applies a buff to the void ray. When initialting an attack it uses a switch to determine what damage stage is used. If not actively attacking the buff duration expires and so it resets back to the start.
How I would do it is get the weapon to use a set that adds a buff to the caster that gives the bonus damage on each attack with a remove validator that the caster is not attacking and applies a buff to the target. The buff applied to the target has a damage response that on death it removes all charges of that buff from the attacker.
@Kueken531: Go
Yea the void weapon is little overboard but that has mostly to do with special effects of having extra beams(visual) added as the dmg goes up. The way effect is done is actually pretty nice. thanks for letting know about the attack speed thing didn't know that and could prove to be problem for some of my other weapons.
@DrSuperEvil: Go
cool might be worth a shot though here your assuming their is only one weapon. If you have another unit with it and both attacking the target. What will happen with the dmg response? will it remove charges just from one or both. If the not attacking is activated between switching targets or death then this problem will be solved.
As the damage response is fatal and you can set it to trigger only on a specific effect (look at massive void ray vulnerability of motherships) that should not be an issue. Also if you have several weapons I presume you would use different stacking buffs for each and could just use a damage effect on attacker to add a damage effect on attack to the target. Between the Unit Compare Order Count and the Unit Order Queue validators, I am sure you wont have a problem. In the worst case you could just throw the not attacking validator on another buff that when removed it has a timer using a create persistent that then removes the others but the remove behaviour has a requirement of it's own that the unit lacks the buff that causes it.
Rollback Post to RevisionRollBack
Contribute to the wiki (Wiki button at top of page) Considered easy altering of the unit textures?
I was wondering if someone can help me make a weapon that works similar to the void ray. It would get stronger as it hit the target but once the target is changed or dies it resets counter and has to build up again. Not sure if there is a validator to check if the target changed or not.
Well, the void ray uses tons of effects and especially actors. You can try to copy that, but its a little tough for starters, I think.
You could go for a weapon similar to the Sentry as a base. It uses a channeling persistent effect instead of the actual weapon cooldown (just like the void ray btw). So you can make your persistent stack damage behaviors on the hero, and whenever the persistent stops, remove all behavior stacks again.
Drawback would be, that plain attackspeed bonuses would have no effect anymore, because they work for the weapon, but not on the persistent effect.
Void ray works by applying a persistent to the target which after so many seconds expires and applies a buff to the void ray. When initialting an attack it uses a switch to determine what damage stage is used. If not actively attacking the buff duration expires and so it resets back to the start.
How I would do it is get the weapon to use a set that adds a buff to the caster that gives the bonus damage on each attack with a remove validator that the caster is not attacking and applies a buff to the target. The buff applied to the target has a damage response that on death it removes all charges of that buff from the attacker.
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
@Kueken531: Go Yea the void weapon is little overboard but that has mostly to do with special effects of having extra beams(visual) added as the dmg goes up. The way effect is done is actually pretty nice. thanks for letting know about the attack speed thing didn't know that and could prove to be problem for some of my other weapons.
@DrSuperEvil: Go cool might be worth a shot though here your assuming their is only one weapon. If you have another unit with it and both attacking the target. What will happen with the dmg response? will it remove charges just from one or both. If the not attacking is activated between switching targets or death then this problem will be solved.
As the damage response is fatal and you can set it to trigger only on a specific effect (look at massive void ray vulnerability of motherships) that should not be an issue. Also if you have several weapons I presume you would use different stacking buffs for each and could just use a damage effect on attacker to add a damage effect on attack to the target. Between the Unit Compare Order Count and the Unit Order Queue validators, I am sure you wont have a problem. In the worst case you could just throw the not attacking validator on another buff that when removed it has a timer using a create persistent that then removes the others but the remove behaviour has a requirement of it's own that the unit lacks the buff that causes it.
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 @Kueken531: Go I forgot to thank you guys. I got this to work. If someone wants to know how, just let me know.