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

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




PostPosted: Sat Jan 18, 2003 1:15 pm   Post subject: moving to next column

hi everyone i have another question for my program now...ese i have word serach adn the user types in the word that they found, and it crossesi t out. The program runs okay, bu ti have a problem.

There are 20 words that needs to be found, along with 10 extra guesses..sot he user can type in 30 words in total. After about teh 18th word, the screen scrolls down..i need it so it goes like this:

word word
word word
word word
word word
word word

u know, so after the 10tho word or whatever it just moves to the other 'side' instaed of scrolling down.

any suggestions?

O.o*cutecotton*o.O

p.s i need some ideas for some games for my tping tutor...basic typign games, nay ideas? btw how do you make a timer? so i can say the user has liek 10 seconds to type this word and if they dotn' get it within that 10 secson it's game over
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Sat Jan 18, 2003 3:25 pm   Post subject: (No subject)

you can use

locate(r,c) to locate the output/input, where R is the row and C is the column.

So basically before inputing/outputing each word, you do something like

locate(wordcounter mod 10, Column)

though you need to set up a counter for the column that will increase after 10 words by the length of column.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
DarkHelmet




PostPosted: Sat Jan 18, 2003 3:58 pm   Post subject: (No subject)

you could use the statement :

for i : 1..30
locate(i mod 10, ((i div 10) + 1) * 15)
get strword(i) : *
end for

the second value would make it so that after 10 numbers, it would go to the next column, and after 20 words, it would go to the third column. You can change the 15 based on how wide you want the columns.
cutecotton




PostPosted: Sat Jan 18, 2003 4:22 pm   Post subject: (No subject)

tks a bunch Smile i'll keep those in mind when i need it make it work again ^^

any one have any other ideas or examples to typing tutor games? so far i only got a word serach...

i'm also tryign to link my program all together, its' really really hard for me to make sense of all...><
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  [ 4 Posts ]
Jump to:   


Style:  
Search: