Below I have the code that uses AnimatedValue(), and I also have a text that displays the health:
Code: Select all
screen tryme:
bar:
value AnimatedValue(health, 100, 2) # Animate the health from 20 -> 100 in 2 seconds (doesn't work)
range(100) # Maximum value is 100
xysize(300,5)
xpos 300
ypos 200
text ""+str(health) xpos 350 ypos 250 size 20
label start:
default health = 20
show screen tryme
$ renpy.pause(10000)
1. The healthbar is still sitting at value 20, it is not animating at all to 100 over 2 seconds.
2. The health integer value is still at 20. I would like to see this value increase as the healthbar increases.
What am I doing wrong?