View Single Post
07/04/15, 06:46 AM   #6
Capadillo
Join Date: Feb 2014
Posts: 12
Originally Posted by Sasky View Post
I'd try to stick to the Animation system if at all possible. Unless you're careful, you can easily do too much in an OnUpdate and cause an FPS drop. For example, that code runs every frame whether it needs to or not.
I'm still trying to figure out how to make it work the way I want it to. So I'm sure you can imagine that there is going to be bugs in my code that I have to get through...

Originally Posted by Sasky View Post
Also, you're not guaranteed to actually hit your end value but could end up oscillating above/below. That part could actually be what's causing the shadow.
Agreed, is there a solution that you could suggest? I'm coming up short of a decent solution.

Originally Posted by Sasky View Post
Furthermore, that's rather brittle and doesn't allow you to change a set duration; it will change at the same speed whether you need to go a small part of the bar or the whole thing.
The idea is to have the same speed. I do realize the drawbacks for this.

Originally Posted by Sasky View Post
The animation system will handle register/deregister of the update handler for you. It's also more keyed to how long the animation is, which is more critical. The player should be able to look at the bar after .3s, .5s, probably 1s at the most and see the correct value. And if it's a small change, you can still take that time and have a smoother animation.
You don't really see the correct value for the default attribute bars until their animation is completed anyway. I expect the same will happen no matter how you animate your bars. Unless you're happy with the bar jumping back and forth without anything smoothing. As a side note; my function looks similar to the default attribute bars. Obviously I want it to be more smoother then that though.

Again, thanks for the feedback!

Last edited by Capadillo : 07/04/15 at 07:00 AM.
  Reply With Quote