Missing animation option
vinilneves opened this issue ยท 5 comments
Describe the bug
Expected 'custom function' to be an option at Animations > Main > Type
, as described at the Wiki: https://github.com/WeakAuras/WeakAuras2/wiki/Custom-Animation-Functions
To Reproduce
What I did:
1 - Create a bar aura for a buff using a template, fingers of frost in this case.
2 - Go to the animations tab
3 - Click the Type
dropdown under the Main
section
Did you try having WeakAuras as the only enabled addon and everything else (especially something like ElvUI) disabled?
Happened with or without any other AddOns
Which version of WeakAuras are you using?
2.17.5
Are you on World of Warcraft Classic or Retail?
- Classic
- Retail
Was it working in a previous version? If yes, which was the last good one?
Did not try
Additional Info
The Custom Functions are defined in the individual animated properties, like Alpha or Colour.
This is not a bug. In a custom animation, you can set multiple different aspects of the aura to be animated, which are the fade, color, scale, etc options. Those are where custom code is accepted.
What I did to solve this:
(function code at the end)
- Add two
Conditions
, one forRemaining Duration
<= my threshold and the other one if > - Set them to
Run Custom Code
- Set a custom variable to
true
orfalse
according to the condition (I usedaura_env.brain_freeeze_ending
)
- Go to
Animations
and selectCustom
for theType
underMain
- Check for example
Fade
and change it'sType
toCustom Function
- Change the function so it returns values based on the custom variable set by your
Actions
The code:
function(progress, start, delta)
if aura_env.brain_freeeze_ending then
return start + (progress * delta)
end
return start
end
Also thanks @emptyrivers, @asaka-wa for the quick reply!