Can I have an overall about game main loop, it seems to be complicated :-/
Thanks
Ayaat Monem
-4
Newbie Poster
Recommended Answers
Jump to PostCan you provide an example of what you are looking for? Are you asking about wrapping up your game code in main in a while or do/while loop so you allow the user to repeat playing?
Jump to PostAn approach, perhaps not the most effective and fanciest, would be to implement a "turn" based system. Make a class for your snake and make a "game" class that contains a snake object. One turn will pass once you've placed all the food, moved all the enemies one or more …
All 5 Replies
jonsca
1,059
Quantitative Phrenologist
Team Colleague
Featured Poster
Ayaat Monem
-4
Newbie Poster
jonsca
1,059
Quantitative Phrenologist
Team Colleague
Featured Poster
Fbody
682
Posting Maven
Featured Poster
Ayaat Monem
-4
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.