Match 3

Get help using Construct 2

Post » Wed Feb 15, 2012 10:11 pm

Good evening everybody,

has anybody a good idea to check for 3 matching sprites of the same type that have collisions with each other?

It is no problem to check for 2, but for example if you have already placed two sprites of the same that have no collision and next place a sprite in the middle with connection to both... how can I check that there is a connection of 3?

Sorry for my bad english, I hope someone can help me. The goal is a connect 3 game, like there are many in the web, but non in Construct 2.

Please help^^

StefanKuschelbauch2012-02-15 22:13:27
B
5
S
1
G
3
Posts: 46
Reputation: 1,581

Post » Wed Feb 15, 2012 10:38 pm

Instead of collisions, you could check the coordinates of the sprites.
B
17
S
4
G
4
Posts: 137
Reputation: 3,767

Post » Wed Feb 15, 2012 11:15 pm

or overlapping.
ImageImageImageImageImageImage
Image
B
98
S
22
G
16
Posts: 1,338
Reputation: 21,202

Post » Wed Feb 15, 2012 11:59 pm

hello again,

this is understood... but these two things only check if there is a collision or not. they dont tell me if 3 sprites are connected/matching...

this was my question!

stefan
B
5
S
1
G
3
Posts: 46
Reputation: 1,581

Post » Thu Feb 16, 2012 1:56 am

Have you looked at PixelRebirth's tutorial? It's for CC but it might give you some ideas.

A basic Puzzle example (Now it even swaps back!)
B
50
S
11
G
8
Posts: 479
Reputation: 9,921

Post » Thu Feb 16, 2012 2:26 am

[QUOTE=TELLES0808] or overlapping.[/QUOTE]
Actually overlapping should work well in C2.
The way its set up now, sprites that are directly next to each other, with collisions set to bounding box, are overlapping.
Image ImageImage
B
164
S
49
G
138
Posts: 7,950
Reputation: 91,866

Post » Thu Feb 16, 2012 9:43 am

Thx to Wink,

good Idea to look into CC... Is there also a one for C2? I didnt found it...

Stefan
B
5
S
1
G
3
Posts: 46
Reputation: 1,581

Post » Thu Feb 16, 2012 10:52 am

@PixelRebirth started it on the blog We Construct.
Harass him to get the other parts written. ^^Kyatric2012-02-16 10:53:07
New to Construct ? Where to start

Image Image

Image Image

Please attach a capx to any help request or bug report !
Moderator
B
267
S
95
G
66
Posts: 7,215
Reputation: 73,096


Return to How do I....?

Who is online

Users browsing this forum: Artpunk, jhjconstruct, jpstudio, manujorgo, Romalex360, tunepunk, VnM2016 and 10 guests