View Full Version : 3D Snake
12-11-2008, 05:07 PM
Dear Guys ,
i have a project to make a 3D snake game using OPENGL.. i was just wondering if anyone can help me and tell me how to start ..
help me draw the snake and move it and detect collision between snake and object etc .. and how manage the length of the snake if it hits a wall or something .. thnks in advance .
12-12-2008, 01:50 AM
stop flooding the forums and do your homework [edited by moderator]. just to help you out somewhat, think logically what you need for your task and how you could possibly implement it and then start doing it!
A bit more patience would be appropriate...
12-12-2008, 05:38 AM
Another post like this and you will be banned
12-12-2008, 06:09 AM
dude shut the [censored] up. you posted your question multiple times. read the forum rules punk and do your homework.
previous post says everything: http://www.opengl.org/discussion_boards/...9002#Post249002 (http://www.opengl.org/discussion_boards/ubbthreads.php?ubb=showflat&Main=48501&Number=249002#Post249002)
so afraid of your warning
12-12-2008, 06:41 AM
_NK47 - don't you think that insulting other people (whenever they deserve it or not) is againt the rules, too? It's really sad to read such comments on forum like this.
30baz - it's really not a good idea to ask people how to write entire application - no one is going to do your work for you. If you end up with some specific OpenGL problem, then let us know.
Right now it looks like you need to learn programming in general. Buy yourself a book and start learning. Otherwise you're not getting anywhere.
12-12-2008, 06:52 AM
k_szczech, personally i agree yes. just the fact that this happend i learned from your comment. didnt mean to insult anybody but i apologize. its usually things like this where people advance the best (myself) and get a bit better.
12-14-2008, 01:18 PM
Well, to help the original poster out with some broad ideas:
Think about storing an array that will act as a grid for your snake game. Most snake games run on a grid. Think of storing the type of thing in each location in this array, e.g. wall, snake, or empty. Detect collisions by checking whether the next block you will move to is empty. Keep track of the current direction of the snake; this determines the next block you will move to. You could make collision detection into a hard problem, but it's almost trivial if you use a grid and should be sufficient for making a snake game.
You also need to think about whether your snake will move in 3D, or whether your snake will move in 2D but the camera can move in 3D. Think about controls - how will the player control the movement?
Seriously, I think the OP asked a completely legitimate question. The format of their question was: Here's what I want to do; how do I do it? Isn't that the format of every question asked on these forums? We're not going to write their code for them; that's one thing for certain. But, we respond to provide help and ideas. Why can't people ask for ideas?
Powered by vBulletin® Version 4.2.3 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.