Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / for next loops

Author
Message
Ultimate Newbie
19
Years of Service
User Offline
Joined: 21st Sep 2005
Location:
Posted: 22nd Nov 2005 21:02
This is probably a stupid question (thank god for the new book), but, can I have two conditions to be met in a for/Next loop?
What I mean is this: in order for my game to go to the next level, the player has to have either scored five points, without using up his ten tries, in which case it will return to the beginning. Or is there another loop which will be better, like Repeat/until?
thanks
Scraggle
Moderator
21
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 22nd Nov 2005 21:05
Repeat/until would probably work better.
Something like this:



Great Britain would be Amazing Britain if it wasn't for idiots like you bringing down the average!
Ultimate Newbie
19
Years of Service
User Offline
Joined: 21st Sep 2005
Location:
Posted: 22nd Nov 2005 21:46
Thanks. I'll give it a go.
Lost in Thought
20
Years of Service
User Offline
Joined: 4th Feb 2004
Location: U.S.A. : Douglas, Georgia
Posted: 23rd Nov 2005 01:44


if moveon = 1 then load next level else replay level

?

Ultimate Newbie
19
Years of Service
User Offline
Joined: 21st Sep 2005
Location:
Posted: 23rd Nov 2005 12:32
If someone with more brains than me(which shouldn't be too hard) could explain how I can upload the media with my code, then maybe that person can also tell me what's wrong with my code. It's driving me nuts.
Me!
19
Years of Service
User Offline
Joined: 26th Jul 2005
Location:
Posted: 23rd Nov 2005 13:24 Edited at: 23rd Nov 2005 13:26
zip up the folder and media without any compiled exe in it and then just upload the whole lot, I prefer people who post source and media anyway since with any code you can see before you compile you can be sure it doesn`t have a virus lurking in it as for the question, something like

repeat

game code

until (points>5) and (tries<10)

would do it.



Do parachute manufacturers have a refunds policy?
Ultimate Newbie
19
Years of Service
User Offline
Joined: 21st Sep 2005
Location:
Posted: 23rd Nov 2005 21:33
let's see if this works

Attachments

Login to view attachments
Ultimate Newbie
19
Years of Service
User Offline
Joined: 21st Sep 2005
Location:
Posted: 23rd Nov 2005 21:35
Sorry, I forgot the message. If anyone can tell me what's wrong with this code I won't be forced to blow myself up out of frustration.

Login to post a reply

Server time is: 2024-11-27 12:28:42
Your offset time is: 2024-11-27 12:28:42