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

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




PostPosted: Wed Dec 20, 2006 11:48 pm   Post subject: Block Game

Hi. I am trying to create a game that iwll test a students ability to put 5 blocks in order from smallest to largest. 5 blocks in random order are displayed horizontally across the top of the screen, and there will be 5 empty spaces below them. Using the mouse, the user will select each block and drag it to the space below... any ideas on what global variables to use???
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Wed Dec 20, 2006 11:53 pm   Post subject: Re: Block Game

jakey140 wrote:
any ideas on what global variables to use???

Don't, it's bad practice
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
jakey140




PostPosted: Wed Dec 20, 2006 11:54 pm   Post subject: (No subject)

well, it helps me out... im still quite a newb.. any ideas?
Tony




PostPosted: Thu Dec 21, 2006 12:06 am   Post subject: (No subject)

well in such a case just add new ones as you need them

5 blocks? Make an array.
Using mouse? x_position, y_position, button_state
something else? well we'll see about that later... maybe time and score.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
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: