31 posts in this topic

I remember I tried this plugin a few days ago. Does it works now if I use a tilemap with 16px x 16px little tiles? I remember it used to only work with the 32px phaser sample.

Share this post


Link to post
Share on other sites
On 1/18/2017 at 10:03 PM, icetimux said:

I remember I tried this plugin a few days ago. Does it works now if I use a tilemap with 16px x 16px little tiles? I remember it used to only work with the 32px phaser sample.

The plugin shouldn't be constrained to tiles of any specific size, it will use whatever width and height each tile has set, which will come from your map data.

Share this post


Link to post
Share on other sites

Hello everyone!

I've recently released v0.2.0-beta for you all to check out.

It comes with several new features:

  • Premade tilesets
  • Built in tileset slope mappings for Ninja Physics and Arcade Slopes tilesets
  • Debug rendering for tile polygons (tilemapLayer.debug = true)
  • Offset tilemap layer support (though this has always been janky in Phaser)
  • Circular physics body support
  • Tile collision flag support

Grab a copy here.

Check out the demo!

The demo has been updated with Phaser CE 2.7.3 and Arcade Slopes v0.2.0-beta. It lets you change the player's shape & size and witness the debug rendering.

askariwa and jpdev like this

Share this post


Link to post
Share on other sites

Thought I might as well update this thread with the changes between v0.2.0-beta and v0.2.0.

v0.3.0 is now in the works!

Quote

v0.2.0-beta2 - 7th June 2017

  • Implemented unintrusive support for an experimental Phaser CE fork.
  • Added sprite scale support for AABB physics bodies.
  • Included a reference to the plugin with the facade. This makes it easier to
    remove the plugin at runtime
    (this.game.plugins.remove(this.game.slopes.plugin)).
  • Fixed multiple calls to slopes.body.enable(sprite) causing an error.
  • Ensured that tilemap debug rendering only wraps if the layer has its wrap
    property set to true.
  • Fixed wasTouching flags (#35).
  • Added the last collided tile to body.slopes.tile.
  • Fixed a heuristics mistake that's been around since May 2016 (4ee0d23)! There
    are probably more...
  • Fixed a wrapping issue with tilemap layer debug rendering.
  • Added dynamic heuristics and preferY properties to the Facade, making it
    simpler to toggle these features globally (game.slopes.heuristics,
    game.slopes.preferY).
  • Fixed SatSolver.collide() setting collision response properties on physics
    bodies before knowing whether the separation was successful.
  • Fixed SatSolver.collideOnAxis() not setting collision response properties on
    physics bodies.
  • Improved memory consumption by reusing SAT response objects for each body.

v0.2.0 - 18th June 2017

  • Added heuristics for square tiles to improve skipped collisions (#38) at the
    expense of some inconsistencies when bodies exit tiles from inside.
  • Allowed physics bodies to disable and enable heuristics for themselves using
    body.slopes.heuristics. null uses default, false disables and true
    enables.
askariwa likes this

Share this post


Link to post
Share on other sites
On 29/5/2017 at 2:52 AM, hexus said:

Thought I might as well update this thread with the changes between v0.2.0-beta and v0.2.0.

v0.3.0 is now in the works!

Great work Hexus, i really like the sprite scale support, btw i think you meant May (not June 2017).

Any thought about what you're thinking to add to the v0.3.0 ?

Share this post


Link to post
Share on other sites

Thanks!

Yeah, actually, quite a good idea so far.

  • I'll be removing the heuristics in place of smarter use of the SAT algorithm (this has already been done)
  • Memory consumption improvements (mostly already done)
  • There will be solutions implemented to help avoid tunnelling (such as swept intersection tests)
  • There may be a built in raycaster for line intersection tests against tilemaps
  • Auto-rotation for sprites based on collision vectors, optionally restricted to a range of angles

For more, you can check out the roadmap. Whenever I get an idea for something that I'm pretty confident I want to implement, I put it there.

For v1.0.0 I plan to build large polygons from the the tiles, as well as support actual polygons from Tiled maps as collision shapes/objects. There's a plugin that already does this by @michaelcalkins, called Arcade Polygons, which is in fact based on some of my code for the plugin and initial SAT proof of concept, but I've planned to do something like that from the beginning.

jpdev likes this

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.