Snap to the Correct Position with Tilemaps

Get help using Construct 2

Post » Sun Nov 02, 2014 4:02 pm

Hi Everyone!

What I'm trying to achieve is to make a tangram-like game, where you drop the objects and you have to "complete" the whole area.

The problem I'm facing at the momment is to make the draggable objects, snap to the correct position when they are dropped nearby.

At the momment I have the box as a tilemap and each draggable object as a tilemap as well (some have 1 tile, others 2 tiles or more).

What's the best way to achieve this?

Image
Image

PS: In the game logic I'm using a family to group all the draggable objects. In the game, I painted the graphics so the game can't be identified later on.

Thanks in advance!
B
3
Posts: 7
Reputation: 189

Post » Sun Nov 02, 2014 7:22 pm

Don't lose your work. Backup your game with Dropbox.
B
44
S
10
G
10
Posts: 1,106
Reputation: 9,202

Post » Sun Nov 02, 2014 9:19 pm

Thanks a lot Tim, but I didn't find it very useful because I don't have any anchors ... the users must be able to place the objects wherever they want inside the white box. I'm starting to believe I can't do this with Construct 2.
B
3
Posts: 7
Reputation: 189

Post » Mon Nov 03, 2014 7:52 pm

Anything can be done with Construct 2 !
You do not have the required permissions to view the files attached to this post.
B
76
S
31
G
27
Posts: 1,015
Reputation: 20,790

Post » Mon Nov 03, 2014 11:10 pm

Magistross wrote:Anything can be done with Construct 2 !


Amazing, Amazing, Amazing! Thank you so much! :D
B
3
Posts: 7
Reputation: 189

Post » Tue Nov 04, 2014 4:13 pm

Magitross, I'm changing the tile sizes, is there anything I should worry about? I have changed the conditions on the event sheet and the tilemaps. However when I drop the objects they always return to the startposition. Does this have anything to with the tilemaps?

Image
B
3
Posts: 7
Reputation: 189

Post » Tue Nov 04, 2014 5:30 pm

Figured it out! Thanks!
B
3
Posts: 7
Reputation: 189

Post » Tue Nov 04, 2014 6:13 pm

I forgot to mention that I was using the tile id 9 as an empty space, my bad !
B
76
S
31
G
27
Posts: 1,015
Reputation: 20,790

Post » Wed Nov 05, 2014 4:19 pm

No problem, I figured it out :D
B
3
Posts: 7
Reputation: 189

Post » Thu Nov 13, 2014 4:49 pm

Hi again!

How hard would it to be to dynamically resize the tilemaps? My idea is to have the original objects in a smaller size and expand to the real size them once they are picked up.

I have tried to reduce the width and height however that messes up with the tilemaps.

Thanks in advance! :)
B
3
Posts: 7
Reputation: 189

Next

Return to How do I....?

Who is online

Users browsing this forum: No registered users and 6 guests