Is there a command in ICE to display the value of a ICE variable in the graphics mode?
PrintInt() and PrintUInt().
What is the syntax for that? I tried using that but it came out corrupted
The REAL LAX18 wrote:
What is the syntax for that? I tried using that but it came out corrupted

The syntax is detailed in the documentation I believe. What are you having trouble with?
The REAL LAX18 wrote:
What is the syntax for that?

det(15,n,digits_to_display -- printint
det(16,n,digits -- printUnsignedint
det(19,textX,textY -- sets the current print screen position
MateoConLechuga: I am writing a program that keeps track of a score. I am attempting to write that score to the canvas every time it updates. However it keeps showing corrupted text.
The REAL LAX18 wrote:
I am writing a program that keeps track of a score. I am attempting to write that score to the canvas every time it updates. However it keeps showing corrupted text.

Is the number negative? Then use printInt.
If the number isn't, then use printUint.
But DONT FORGET TO SET THE TEXTS X,Y POSITION
So it would look like:
det(16,S)

PS. S is the score variable
The REAL LAX18 wrote:
So it would look like:
det(16,S)

PS. S is the score variable

Also you need to set a number of digits to display
How would i do that? That is probably my problem.
The REAL LAX18 wrote:
How would i do that? That is probably my problem.

Just do det(16,number,NUMBER_OF_DIGITS_OF_THE_NUMBER_TO_DISPLAY
This is the code:
det(18,"SCORE:",105,50
det(19,105,60
---enter score display line here -----
det(74,1,1
I think it worked!!!!
The REAL LAX18 wrote:
This is the code:
det(18,"SCORE:",105,50
det(19,105,60
---enter score display line here -----
det(74,1,1


det(16,N,10
10 is the number of digits of the number to display, so...
9999999999 you could display as the max.
EXEPT: ICE only has numbers up to 16777215
Thanks! Very Happy
The REAL LAX18 wrote:
Thanks! Very Happy

You're very welcome! Smile
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement