Raised This Month: $ Target: $400
 0% 

WHY doesn't this simple float work


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Backstabnoob
BANNED
Join Date: Feb 2009
Location: Iwotadai Dorm
Old 08-13-2011 , 10:59   WHY doesn't this simple float work
Reply With Quote #1

x = start time (60 sec for example)
y = count down from x

after 10 seconds: x = 60; y = 50 (THIS WORKS, I was printing it on the server and both the numbers are ok just this fucking float doesn't do what it should)

new Float:percent = float((x - y) / x) * 100.0

Just WHY is this 0.0% no matter when, it's 0.0 after 10 seconds, 0.0 after 30 seconds, 0.0 after 23957325 seconds it simply DOESN'T CHANGE

Last edited by Backstabnoob; 08-13-2011 at 11:01.
Backstabnoob is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:31.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode