[request] collision enable for the tilemap object

0 favourites
  • 7 posts
From the Asset Store
Welcome! I-Spy (Hidden objects) is an educational puzzle that is more than just seek-and-find activities.
  • Is there a reason you can't disable and enable collisons for the tilemap object?

    This would be useful for my case where I have a large generated world, each chunk is a separate tilemap object. I want to disable collision checks for far away chunks.

  • Tilemaps handle collisions diffrently and it's probably best to "disable" chunks altogether when you don't need them. A more viable aproach in this case would be storing the world data in an array and use only handfull of chunks around the player when they move. For example you can use 9 chunks around the player and when he exits the central chunk, the furthest ones change position to the front of player's movement, while getting world data from the array and setting tiles accordingly. Alternatively you can update one single tilemap object and shift all objects to create an illusion of seamless movement. I tried this aproach with an infinite world and performance is pretty solid even with bitwise autotiling slapped on top of the whole process. If you're interested you can check the "infinite runner" example

  • RadioMars

    Thanks for your insight, your suggestions definitly sound like solid workarounds!

    still I wish disabling collisions for tilemaps would be available.

    I get that collisions work differently, as there are probably separate collision checks per tile or optimized tile-cluster.

    But from my naive point of view I would imagine this should still be fairly simple to add to construct 3.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • if you have events to disable the collisions, just switch them out for collision-less tiles.

  • sure, but then I would still need to store the correct tiles in an array, or add double the amoun of tiles to have a collision-less version for each tile.

    So RadioMars suggestion would probably be better than.

    Thank you nontheless!

  • so just do that, You'll get better experience and become better as a programmer, and you won't completely depend on built in code made by someone else who might not do exactly what you want

  • yea no real problem there, just felt counter intuitive to have this action missing for tilemaps. As it is available for all(?) other object types that have collisions.

    But there probably is a good reason it's not possible.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)