Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / displaying an integer using the text command

Author
Message
castek
17
Years of Service
User Offline
Joined: 15th Aug 2007
Location: Right behind you!
Posted: 11th Sep 2009 19:58 Edited at: 11th Sep 2009 20:00
Hey guys, Just a quick question, how would i go about displaying an integer using the text command. I have an integer name level and i want to display it but not using the print command, and i cant get it to work with the text command. thanks for your help guys!

EDIT:
Duh nvm im stupid,

here is what i did.

text 10,70,"Level - "+ str$(level)

this is where my signature is supposed to be.
castek
17
Years of Service
User Offline
Joined: 15th Aug 2007
Location: Right behind you!
Posted: 11th Sep 2009 20:11 Edited at: 11th Sep 2009 20:11
BUt, as long as i have this thread open ill ask another question.

Im using the text command to display an object x and y angles



but, when there displayed they dont just show like 91. 2 they show 91.1231434444 with like a ton of extra numerals (see pic), so i was wondering if it was possible to make it display only the first 3 digits or so. thanks!

this is where my signature is supposed to be.

Attachments

Login to view attachments
spooky
22
Years of Service
User Offline
Joined: 30th Aug 2002
Location: United Kingdom
Posted: 12th Sep 2009 00:11
If you look at help file for str$ you will see it supports another parameter which is number of decimal places, so for 2dp;



Boo!
castek
17
Years of Service
User Offline
Joined: 15th Aug 2007
Location: Right behind you!
Posted: 12th Sep 2009 01:44
awesome man, thanks!

this is where my signature is supposed to be.

Login to post a reply

Server time is: 2024-11-24 01:59:51
Your offset time is: 2024-11-24 01:59:51