Computer Science Canada

Make Background go forever (please help :S)

Author:  vagyb [ Fri May 21, 2004 8:46 pm ]
Post subject:  Make Background go forever (please help :S)

can someone plz tell me how i can make the background go forever in this small game i am making for a computer project. once u run the game u'll know what i mean. anyways thx alot whoever can find the answer.

Author:  guruguru [ Fri May 21, 2004 9:43 pm ]
Post subject: 

Since you have a fairly simple background, I would suggesting using colorback() to set the background to black and then load in the star picture overtop of the background. Then you move the x and y values of the stars instead of the whole background. When a star goes off the screen, its x values is restarted back to x (just and idea). This should work if you keep the background simple, and a uniform color. It's looking good, eager to see final program!

Author:  vagyb [ Sat May 22, 2004 6:24 am ]
Post subject: 

oh i c, thx alot i think i understand what u mean even i'm a complete nooby lol. let me go try that rite now.

Author:  vagyb [ Sat May 22, 2004 7:06 am ]
Post subject: 

damn once i took background off and i ran into some problems. could soemoen plz read the new code again and tell me how i can fix it, and also if you can post where i am supposed to add the stars/planet/

Author:  guruguru [ Sat May 22, 2004 11:18 am ]
Post subject: 

I fixed some of your code and implemented my idea with comments. I didnt really get what you did in the second attachment so i edited the first one. If you dont understand anything please let me know and ill explain it. And if you dont like the idea w/e, its all good.

Author:  vagyb [ Sun May 23, 2004 12:27 pm ]
Post subject: 

wow thx alot man, i'll try to work from here lol.

Author:  vagyb [ Sun May 23, 2004 12:35 pm ]
Post subject: 

omg wow its actually working pretty good. i'll try to finish this up over the weekend and post the final results. man again thx alot i couldn't have done this without u

Author:  vagyb [ Mon May 24, 2004 12:49 pm ]
Post subject: 

hey okay well i think i figured this things out, but problem is the rocks that come every time are in the exact same place :S cuz the x and y values are the same, so i decided to put a random number from a specific range for each of the values, but the problem is that they come in random places only once i start the game. if you can plz check the code again and tell me how i can fix this i would apreciate it greatly

Author:  Dan [ Tue May 25, 2004 2:21 pm ]
Post subject: 

just add the radmoizing code in the ifs where u check if the rock whent off the screen.

Ex.

code:

if boulder1X + boulderWidth <= 0 then
         boulder1X := maxx
         randint (boulder1Y, 250, 350)
else
...........

Author:  vagyb [ Tue May 25, 2004 7:29 pm ]
Post subject: 

i'm so happy i'm almost done my game, and i somehow by some miracle made the whatdotcolor work during my computer class. the only problem is now that the detection is not very great, and sometimes it doesn't stop. i think the problem is that i can't match the red color in turing with the red color in paint. but this is just a guess. could someone plz try my game out and tell me how i can make the whatdotcolor better.


ps. guruguru i couldn't take the space thing out :S it was just too hard lol and i'm scared to make the program shorter cuz it mite not work normally anymore lol. i know i know it sounds very noobish Sad

Author:  guruguru [ Tue May 25, 2004 9:06 pm ]
Post subject: 

yagyb: PM me the code and I'll see what I can do. When I was fiddling with your prog I took the space out but I deleted the file... I'll take it out for you.

everyone else: No I am not doing his project for him so dont start flaming me. I'm merely helping him out.


: