Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Font help
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Llama




PostPosted: Sat Jun 07, 2003 2:02 pm   Post subject: Font help

I am making a program for my computer class. It is a slot machine. I dont know how to display the money without having that stupid long white line. The variable is called money and it is an integer. I need to know how to display it without having to use the put statement.

Please help ASAP
Sponsor
Sponsor
Sponsor
sponsor
Andy




PostPosted: Sat Jun 07, 2003 2:06 pm   Post subject: (No subject)

if you have .. after your the variable you out put, it erases the long line
code:

put money..

the only problem is the next time you output something it'll be outputed after the previous output.
the locate command locates a row and a column so you can output stuff on anyline/column you want
code:

put money..
locate(whatrow+1,1)
%have your next output here

you should read the tutorial on put statements
Llama




PostPosted: Sat Jun 07, 2003 2:11 pm   Post subject: font

can i use Font.Draw or something like that??
Andy




PostPosted: Sat Jun 07, 2003 2:16 pm   Post subject: (No subject)

ya you can
code:

var font := Font.New ("Arial:24:bold,italic")
Font.Draw ("SCORE", 50, 30, font, red)

there is just one thing, the text you put in to Font.Draw has to be a string, and your score is probably an integer, so you'll have to do this

code:

var font := Font.New ("Arial:24:bold,italic")
var score:int:=1
Font.Draw (intstr(score), 50, 30, font, red)


the intstr command changes an integer to a string format
Llama




PostPosted: Sat Jun 07, 2003 2:23 pm   Post subject: a

WOW THANKS MAN!!! Laughing Laughing Laughing
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 5 Posts ]
Jump to:   


Style:  
Search: