Pacoman
-
Don't know if this is the right place to ask really, I can start a new topic in General if you want, but at a high level, how do you restrict the sprites to moving within the paths of the maze? If you were to just increment / decrement X/Y values then obviously they'd be free to roam all over the screen which isn't what you want. Been pondering this for a while!
-
i basically have a maze grid, and then allow the sprites to move freely in one direction until the next optional corner (there are no dead ends, so every intersection counts)
so my maze grid is each 8x8 char, and the the sprites can move freely betwen them (1 pixel at a time) and only when they are exactly on a grid square can they change direction
another way is to use a hardness map but we cant read pixels in fuze so that's not an option
not sure if my explanation has helped or made it more confusing (currently replying from my phone in nando's!)
-
Yep, that made sense :) You basically only check for a change of direction when you know you are in the middle of a "decision tile" for want of a better phrase. So all you need to do is know in which tiles it is possible to change and since everything is based on 8x8 tiles that's easy enough to multiply up from the x/y position.
-
absolutely bang on.
when you know your 3 possible outcomes at any intersection and know you can't 180 (unless your player is pacman) it makes decisions easy since that ghost always has a target square (be that the one pacman is on, or their home square or maybe the ghost pen as eyes), so when it comes to making your ghosts"smart", you end up only needing to make a simple choice at intersections!
taking this approach i had a game that played itself before i even had chance to wire up the control system 😊
-
We're a bit further along now. The results are very nice
What's weird (or not so weird, I dunno) is that it actually feels like real pacman.
The ghost AI is all done
The variable speeds are all done
chase / scatter / frightened modes are done
Bonus fruit now appears at the right time
Inky now speeds up when he should (he can now catch you at 10 dots left)Player cant die yet, and I seem to have inherited the arcade bug where you can walk through a ghost when both sprites swap squares during one frame.
Very cool though. Can't wait to finish it!
-
@MartinW In some strange turn of events I stumbled upon your pacman Amiga code, weirdly i had the page open best part of the whole of yesterday evening without even realising as i searched for pacmanemulation.pdf whilst looking up some info on the namco wsg3. it wasn't until i opened my mac tab on my phone this morning that i noticed the domain name!
-
Hah! I forgot that I’d even made the repo public!! Don’t laugh too hard :)
I’m in the process of trying a few different approaches to see if I can get my head round a couple of problems.
-
I don't think there's any shame in what you are trying to achieve there (it is no mean feat for sure)
-
So, many hours have gone into this now and we are reaching the end.
We have sounds!
We have a CRT effect
We even have a nice intro music piece created by @Dave !
-
-
Really interested in seeing the code for this after release!!! We need to be swapping friend codes :)
-
Hey folks - Martin, this really is an outrageous example of Mike's abilities. It is absolutely perfect, even down to the overlapping pixel collision tricks. When Mike says it feels like Pacman he's not exaggerating. It's quite odd. Also very impressive is that all the sounds are programmed using the in built synth. There are no samples.
-
That looks really cool.
-
It's coding with Basic ?
-
-
@Myddrak a future update will have it! (I'll code it myself if necessary) :laughing:
-
Currently live streaming the development of this at https://youtube.com/MikeDX2
-
I can't wait for this game. I think Pacman was my first video type game. No, wait, that was Breakout, a console game back the 70s. Can you believe they made single game consoles? Pacman was one of the early ones so this will be great to experiment with.
v/r
Jeff