how do Digging game like Dig Dug

Get help using Construct 2

Post » Wed Aug 21, 2013 2:55 pm

this link explain all
http://www.youtube.com/watch?v=7no4Kilk5BY

so how do i digged paths?delgado2013-08-21 14:55:35
B
113
S
29
G
48
Posts: 1,883
Reputation: 36,580

Post » Wed Aug 21, 2013 5:03 pm

on press button - is facing & touching block - Destroy block?

B
12
S
3
G
1
Posts: 347
Reputation: 2,866

Post » Wed Aug 21, 2013 5:07 pm

Hi Ghost yeah but this need lot of small sprites
B
113
S
29
G
48
Posts: 1,883
Reputation: 36,580

Post » Thu Aug 22, 2013 8:59 am

make a sprite, not destroy it
B
38
S
13
G
4
Posts: 152
Reputation: 5,147

Post » Thu Aug 22, 2013 4:18 pm

DigDugExperiment.capx

This is just the inkling of an idea, but I'm thinking Canvas can help. I've just got solids here, but you can paste in textures. That's the digging taken care of. For enemy AI, I'm thinking a combination of more hidden canvas layers & node deposits on direction changes. You can use flood fill to see if the enemy can reach the player or not, and then with help of maybe flood again and/or the nodes as helpers for finding routes to the player, you can do your own path finding.
ImageImageImage
B
71
S
22
G
259
Posts: 3,793
Reputation: 143,702

Post » Thu Aug 22, 2013 4:37 pm

@blackhornet hi, i see this is experiment i try add some platform behavior sprite but i need solids, hmm im wonder how do it because when whole canvas is a solid Playersprite dont want to walk ;pdelgado2013-08-22 16:44:18
B
113
S
29
G
48
Posts: 1,883
Reputation: 36,580

Post » Thu Aug 22, 2013 5:42 pm

I don't see any of C2's behaviours working for this. That's why I was suggesting old-school flood-fill & custom path-finding. Otherwise, lots of little blocks, or compromise with a grid-based system.
ImageImageImage
B
71
S
22
G
259
Posts: 3,793
Reputation: 143,702

Post » Thu Aug 22, 2013 5:59 pm

@blackhornet   OK thanks for your support
B
113
S
29
G
48
Posts: 1,883
Reputation: 36,580

Post » Thu Aug 22, 2013 7:58 pm

Rather than removing the blocks, I think dig-dug actually drew the tunnels over the dirt textures.

Would save you from drawing thousands of tiles, Just make your dirt in one layer, and have your player and ready made tunnels in another layer so it draws on top of the dirt.

When the player moves off a tunnel tile have it draw another tunnel tile in the direction the player is facing.Then you will have a digging effect, and you wont need as many collision sensors. Just have the collision sensor on the player and monsters to make sure they are on the tunnel tiles. When the monsters are over the diet tiles either have them draw more tunnels in front of them (dig), or turn into the "ghost eyes" as they are floating under the dirt like the arcade game.

TL;DR, paint tunnels OVER the dirt, do not remove the dirt...

Hope that makes sense :D
B
29
S
8
G
4
Posts: 767
Reputation: 5,985

Post » Fri Aug 23, 2013 6:55 pm

@delgado there's a lemmings example capx in the forums, could help as a start
B
12
S
3
G
1
Posts: 347
Reputation: 2,866

Next

Return to How do I....?

Who is online

Users browsing this forum: EuropaMin3r, maddy467, work3 and 6 guests