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 / Help with Starting Pacman

Author
Message
GuruSY
20
Years of Service
User Offline
Joined: 23rd Jan 2004
Location:
Posted: 27th Jan 2004 08:14
Hey guys, I'm just starting to learn game programming, I am using DBPro demo until the version I ordered gets in...

Anyways, I just completed my first game, a version of nibbles (or snake as some call it). I wanted to make a pacman game (in 2D). I don't want code or anything. Just some theory hints.

Here is my thinking so far, please tell me if i'm on the right track:

1. I have pacman as a sprite
2. I render the level in one big image?
3. What is the best way to have pacman move around the level?

Again, I don't need code or anything, just some quick hints to get started.

Thanks in advance!
Chris K
20
Years of Service
User Offline
Joined: 7th Oct 2003
Location: Lake Hylia
Posted: 27th Jan 2004 11:34
Do it in 3D.

Pacman should be a sphere, move with the arrow keys. Walls as static objects, check for collision on arrow key press. Code like this:



waffle
22
Years of Service
User Offline
Joined: 9th Sep 2002
Location: Western USA
Posted: 27th Jan 2004 12:44
actually, any method you can think of will work. Its really up to you. If you stick with the 2D idea,

Set backdrop to black
Use a giant sprite with black as transparent and the walls on that sprite. Collisions can be handled by checking for pixel collision against that sprite.

next, use another bunch of sprites as the dots....

that should get you going...
Not sure if DBPro demo supports pixcel collision or not. The tool I use does (for 2D). Just checked, DBPro does NOT support pixcel collisions..... On that note, you'll need to do this:

1 - backdrop is black
2 - each wall must be a sprite (make it solid, no transparent areas)
3 - each dot a sprite
4 - make packman an animated sprite
.....
Make all sprites transparent black
Should run pretty smooth just remeber to check collision....

Save current position....
Perform keyboard check...
Do test move.............
If collision with wall... restore old position
if collision with dot.... give points, remove dot
make current position perminante
repeate

internet gaming group
current project http://home.comcast.net/~norman.perry/Archon.html
GuruSY
20
Years of Service
User Offline
Joined: 23rd Jan 2004
Location:
Posted: 28th Jan 2004 03:14
Thanks waffle! That is alot of help!

Login to post a reply

Server time is: 2024-09-21 18:47:22
Your offset time is: 2024-09-21 18:47:22