Computer Science Canada Guitar Hero theme problem |
Author: | LostUser [ Wed Jun 03, 2009 12:00 pm ] | ||
Post subject: | Guitar Hero theme problem | ||
What is it you are trying to achieve? I'm trying to achieve a guitar hero game What is the problem you are having? I got the bars to move but I don't know how to get it so if you click this button then the bar will dissapear and I want to have multiply bars going at the same time Describe what you have tried to solve this problem I don't know enough... Post any relevant code (You may choose to attach the file instead of posting the code if it is too long) This is what I got so far I want to put like lots of for commands.... but like one box goes at a time, I don' t want that, is it possible to get multiple multiple boxes to go, I made it like that but it looks awkward and is flickering
Please specify what version of Turing you are using 4.1.1 |
Author: | Diablo117 [ Wed Jun 03, 2009 3:36 pm ] |
Post subject: | Re: Guitar Hero theme problem |
For loops will only run the code that is inside of them then exit. You need to update their locations in a different way, without for loops, but counters. A computer can only do 1 task at a time, so it would run your for loops in order, moving 1 box at a time. |
Author: | DtY [ Wed Jun 03, 2009 4:57 pm ] |
Post subject: | Re: Guitar Hero theme problem |
Diablo117 @ Wed Jun 03, 2009 3:36 pm wrote: For loops will only run the code that is inside of them then exit. You need to update their locations in a different way, without for loops, but counters. A computer can only do 1 task at a time, so it would run your for loops in order, moving 1 box at a time.
Just to put it out there, turing can do more than one task at the same time using the fork command, however since forked processes are run independently of main program, you will have to do some advanced timing to make everything move properly using that. |