How do I make tiles in tileset not collide

0 favourites
  • 6 posts
From the Asset Store
2D fighting template based in the game that defined the fighting games genre.
  • I have a tileset with tiles with full collision (block) and partial (slope),but I need some not to collide at all. I want that so I can make the tilemap solid and act as the level platform. If that is not possible, I'd like to know whether there is a way to make only certain tiles be solid following the collision polygon. Is this doable, or do I need two tilemap objects, one for colliding solids and one for non-colliding scenery?

    Thanks in advance!

  • I have a simple solution, if anyone has a different one, please post! I have the main tilemap, non-solid, the solid one and a "solids" variable that looks like this: "0,1,2,5,6,128,234,456" and contains the ids of solid tiles. At start, it loops through all tiles on the non-solid tilemap and compares them to the variable. If a tile matches, it is set in the same position on the solid tilemap and removed from the old one.

  • From manual:

    [quote:2a29kagd]

    Collisions

    When testing for collisions with a Tilemap object, empty (erased) tiles count as not colliding, and all other tiles count as colliding. A custom collision polygon can be set for individual tiles by clicking the Edit tile collision polygon button in the Tilemap bar, or just double-clicking the tile in the Tilemap bar. Note however the collision polygon cannot be entirely removed from a tile: only an erased tile counts as not colliding at all.

    If you wish to have tiles that are visible but do not register a collision, use two Tilemap objects layered on top of each other. Test for collisions with just the top object, and erase any tiles that should not register a collision. These tiles can then be placed on the tilemap object beneath, so they appear in the same place but are not tested for collisions.

  • From manual:

    [quote:1k69b4qv]

    Collisions

    When testing for collisions with a Tilemap object, empty (erased) tiles count as not colliding, and all other tiles count as colliding. A custom collision polygon can be set for individual tiles by clicking the Edit tile collision polygon button in the Tilemap bar, or just double-clicking the tile in the Tilemap bar. Note however the collision polygon cannot be entirely removed from a tile: only an erased tile counts as not colliding at all.

    If you wish to have tiles that are visible but do not register a collision, use two Tilemap objects layered on top of each other. Test for collisions with just the top object, and erase any tiles that should not register a collision. These tiles can then be placed on the tilemap object beneath, so they appear in the same place but are not tested for collisions.

    Must've missed that.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • RecGames nothing to be ashamed about in my opinion... not many of the features of Tiled are supported in C2 currently, and I'm sure someone will inevitably come along with this same question and probably find the answer here. Looking forward to seeing what you're working on, looks interesting.

  • RecGames nothing to be ashamed about in my opinion... not many of the features of Tiled are supported in C2 currently, and I'm sure someone will inevitably come along with this same question and probably find the answer here. Looking forward to seeing what you're working on, looks interesting.

    Take a look at this (made in Game Maker, source and resources up for download):

    http://remar.se/daniel/iji.php

    One of my favorite games. The graphics are from there.

    EDIT: When asking questions, always read the manual!

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