 |
shaun.murray Magician

Joined: 23 Jul 2005 Posts: 334 Location: Chicago
|
Posted: Sun Jul 24, 2005 2:53 am
%format(2, %eval( %float... what!??!?! |
Me again... ^^ Trying to get a percentage left of my script. Easy understand below...
#VARIABLE scriptpercent %format( 2, %eval( %float( @line / @line_max) * 100))
But its coming up with 0.00%... Wierd... =[ Any help would be much appreciated! TY much! |
|
|
 |
nexela Wizard

Joined: 15 Jan 2002 Posts: 1644 Location: USA
|
Posted: Sun Jul 24, 2005 3:42 am |
Sure its floating 0 %float(@line/@line) you only need to float one value *fixed below*
%format( 2, %eval( %float( @line)/@line_max*100)) |
|
|
 |
shaun.murray Magician

Joined: 23 Jul 2005 Posts: 334 Location: Chicago
|
Posted: Sun Jul 24, 2005 4:03 am |
Huh... Aiight. So do I even need to use the float? It seems to me that might be overkill....
|
|
|
 |
nexela Wizard

Joined: 15 Jan 2002 Posts: 1644 Location: USA
|
Posted: Sun Jul 24, 2005 4:58 am |
yes it has to be floated to return a floating point value otherwise it just returns everthing before the decimal
|
|
|
 |
shaun.murray Magician

Joined: 23 Jul 2005 Posts: 334 Location: Chicago
|
Posted: Sun Jul 24, 2005 1:18 pm |
Alright. I'll give it a shot! Thankx Nexla! Your the man! (Or woman, whichever it may be... ^^)
|
|
|
 |
shaun.murray Magician

Joined: 23 Jul 2005 Posts: 334 Location: Chicago
|
Posted: Sun Jul 24, 2005 4:48 pm |
Worked like a champ! =D
|
|
|
 |
|
|