Destroy a tile for tilemap

Get help using Construct 2

Post » Mon May 05, 2014 2:14 am

How do I to destroy a tile for tilemap?
https://www.dropbox.com/s/3oepa0e22p2zspd/timeMapTest.capx
B
43
S
6
Posts: 79
Reputation: 4,235

Post » Mon May 05, 2014 2:32 am

Here you go.... :)

I added a delete tile with a function to convert layout position info to a tile position. I also moved the origin of the bullet so that it would overlap the tilemap tile when the collision polygon made contact with the tile (the conversion takes the coordinate of the bullet and if the origin is not overlapping the tile even though the bullet and tile are in collision, no tile deletion would take place). Not perfect but an easy work-around.
You do not have the required permissions to view the files attached to this post.
I only occasionally visit - I'm learning C# for Unity, but c2 is still a respectable game engine imo....
B
73
S
19
G
66
Posts: 2,198
Reputation: 42,193

Post » Mon May 05, 2014 3:04 am

Tks Colludium,

So what would be the right way to do? I am looking for a right way to make tile style games . Before, I duplicated several sprites around the layout and I think it made the game lag. I hope it can decrease the use of processing. It is a good way for solve this?
B
43
S
6
Posts: 79
Reputation: 4,235

Post » Mon May 05, 2014 3:33 am

I'm not a fan of tilemaps, but that's just my style of game creation (and you should also note that I'm a full-up amateur here - this is a bit of fun/hobby for me rather than a means of making a living). I prefer to use sprites and tiled backgrounds because they scale better than the tilemap object. However, from what I've read on the forum, the tilemap is a very efficient way of drawing lots of images (the problem for me is it produces visible seams unless you do not use pixel rounding and you do use integer scaling). If you are happy to work around those limitations then I think it's your best option - and from the sounds of your description of using lots of sprites - it might just well be. It's also worth considering that C2 optimizes its collision checking so that (not so effective on mobile) lots of objects shouldn't impact on your game's performance too much. If any of your sprites are large, however, you also run the risk of running out of memory. Hope this helps?
I only occasionally visit - I'm learning C# for Unity, but c2 is still a respectable game engine imo....
B
73
S
19
G
66
Posts: 2,198
Reputation: 42,193

Post » Mon May 05, 2014 11:16 am

Yes, thank y o u alot, colludium. This explanation helps me so much.
B
43
S
6
Posts: 79
Reputation: 4,235


Return to How do I....?

Who is online

Users browsing this forum: SputnikCZ and 3 guests