So I recently discovered how to keep track of Hp and Exp in flash. Is there a way I can convert the variables to bars instead of numbers?
Printable View
So I recently discovered how to keep track of Hp and Exp in flash. Is there a way I can convert the variables to bars instead of numbers?
You can just set the width of a shape to equal the HP/EXP.
Code:hpBar.width = hp;
expBar.width = exp;
can you elaborate please? I understand I have to make a dynamic text box and insert the variable name into the text box for numbers, but I don't know how to do that with bars....
Ok, just draw a rectangular bar and convert it to MovieClip, give it the instance name "hpBar". Then where you set the "hp" value to dynamic text box, just add the above code.
AS2 version would be hpBar._width = hp;
im sorry, i tried to follow your instructions, but it didnt work.....
when i tested my movie the hp didnt change....
sorry :/
You can post your source code / snippet or just upload your FLA, so members can take a look.
aw, its fine....
I'll figure it out one way or another :)