How can I go multiple decimal places with variables? I am making a game that uses the variable to display money, but I need it to go down to the hundredths place to show ALL of your money. Is ther eany way to do this (and I tried when green flag clicked set Money to 3.00)
Offline
Please, it's bugging me
Offline
I don't think u can actually put it down to the hundreds unless ur really accurate
Offline
deatheater wrote:
I don't think u can actually put it down to the hundreds unless ur really accurate
What do you mean? I'm just trying to have it start at 3.00 dollars and make it easier to change you values
Offline
well, if u upload it the decimal places go to the billions, but if ur exact u can make it so it only goes to the hundreds
Offline
deatheater wrote:
well, if u upload it the decimal places go to the billions, but if ur exact u can make it so it only goes to the hundreds
You mean I need an equation? Well, I guess I won't do this game than because of that lack of function
Offline
Zelda123 wrote:
I tried multiple ways of achieving a hundredth's place but couldn't found a way. It doesn't seem like it shows it as it always rounds to the closest tenth.
If anyone can find a way, I'll continue the game. I know one time I tried to get it to equal Pi and I got it the like ……… Hundred Thousandths or something
Offline
ha ha (lol) u see these blocks <move( 20000000000 )steps> <say[ vote who you think will win ]for( 99999999999999999999999999999999999999999 )secs>
Offline
Bluestribute wrote:
Zelda123 wrote:
I tried multiple ways of achieving a hundredth's place but couldn't found a way. It doesn't seem like it shows it as it always rounds to the closest tenth.
If anyone can find a way, I'll continue the game. I know one time I tried to get it to equal Pi and I got it the like ……… Hundred Thousandths or something
It seems that variables will only display to the nearest tenth. But the Say function will show lots of decimal places. And, you can use one of Kevin_karplus routines, like this one,
http://scratch.mit.edu/projects/kevin_karplus/2951
that use the Stamp function to print out decimal numbers.
Offline
You could have something to say the amount of money when clicked, using "
When (?) clicked, say "money" for (X) seconds. It will display the decimals, even if you cant see it on the actual variable. (You insert the oval variable block into the say block)
Last edited by Rurigok (2008-07-15 18:14:22)
Offline
We really need single and double precision floating-point variables.
Offline
Cyclone103 wrote:
We really need single and double precision floating-point variables.
I think we already have sufficiently accurate variables...what we don't have is any easy way to format them for output to the screen!
Offline
Paddle2See wrote:
Cyclone103 wrote:
We really need single and double precision floating-point variables.
I think we already have sufficiently accurate variables...what we don't have is any easy way to format them for output to the screen!
That is true!
Offline