PacMan with pathfinding

Get help using Construct 2

Post » Thu Feb 14, 2013 4:37 pm

Hi guys,

Im trying to make a pacman game with touch controls using the pathfinding behavior.

Is there a way to make pacman move (like in the pacman game) without touching the walls, (not doing diagonals).

I would like to restrict the movement to 4 directions.

Is this possible?
B
13
S
4
G
2
Posts: 20
Reputation: 2,517

Post » Thu Feb 14, 2013 4:48 pm

A possible implementation is to use the 8 direction behavior and set its property "Directions" to "4 directions".
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,998
Reputation: 57,791

Post » Thu Feb 14, 2013 5:11 pm

Thanks Kyatric

I tried that but it is not working very well. The player gets stuck on solids a lot of the time.

The movement would need to be some sort of tile/grid movement. But I dont really know if that can be implemented using the pathfinding

If anyone has any ideas please shoot.

Cheersknudle2013-02-14 17:11:50
B
13
S
4
G
2
Posts: 20
Reputation: 2,517

Post » Thu Feb 14, 2013 5:38 pm

Do you mean the actual pathfinder moves your pacman character ?
If so, diagonal movement in open space is set by default, an option to make paths with or without such diagonals is missing in the behavior at the moment but might be added in some newer release.Kyatric2013-02-14 17:39:29
New to Construct ? Where to start

Image Image
Image Image

Please attach a capx to any help request or bug report !
Moderator
B
247
S
85
G
40
Posts: 6,998
Reputation: 57,791

Post » Thu Feb 14, 2013 5:43 pm

Yes!
PacMan touch waaaaaay

yeah thought so. It will be nice to be able to control how many directions the pathfinder can have.
B
13
S
4
G
2
Posts: 20
Reputation: 2,517

Post » Thu Jun 06, 2013 1:48 am

Oh man im waiting for that.. want to make the pathfinding use only four directions and based on a grid of the size I want
B
30
S
6
G
5
Posts: 433
Reputation: 6,061


Return to How do I....?

Who is online

Users browsing this forum: Colorfish, Waltuo and 4 guests