Comments (12)
Ran into this additional effect of the bug:
With square tiles, the sprite goes straight through, but with sloped tiles this happens.
from phaser-arcade-slopes.
Thanks, this is probably to do with the heuristics that try to avoid objects catching on the corners of sloped tiles that are placed next to each other.
I'll try flinging some tiny projectiles at such tiles myself to see if I can reproduce the problem.
Out of interest, are you using collide
or overlap
to check for these collisions? Or are you checking the overlap properties set on the body?
from phaser-arcade-slopes.
Using the Arcade collide
function, not doing any manual checking. Is it possible to disable that heuristic as a temp workaround?
from phaser-arcade-slopes.
It should be yes, I'll check for you.
from phaser-arcade-slopes.
game.slopes.solvers.sat.options.restrain = false;
:)
from phaser-arcade-slopes.
👍 seems to be working! Thanks.
from phaser-arcade-slopes.
Awesome, no worries.
from phaser-arcade-slopes.
When 0.2.0 is released you will be able to achieve the same thing with a shorter syntax (d530f30).
game.slopes.heuristics = false;
from phaser-arcade-slopes.
@grayleonard Just to confirm, regarding this issue, were you destroying bullets in a collision callback?
I have a feeling the plugin simply isn't running the callback properly because of the heuristic restraints, and they aren't destroyed on those slope because they're no longer colliding with them; they're actually moving perfectly in parallel with them because there's no gravity.
from phaser-arcade-slopes.
Yes, I was destroying the bullets within the collision callback, and I have gravity set to 0.
It might be necessary for the project I'm working on to use the heuristics for other sprites, so I might do a bit of debugging on my own and let you know what I figure out.
from phaser-arcade-slopes.
(Feel free to close this issue for now though, as d530f30 resolves it)
from phaser-arcade-slopes.
Cool. Right now I don't think heuristics can be enabled per-sprite but I will add a flag that allows this.
I was leaving this open because I think I can make improvements for 0.2.0, and have features planned for 0.3.0 relating to this too. I might just make new issues for these things though. :)
Thanks for your input here.
from phaser-arcade-slopes.
Related Issues (20)
- Automatically update sprite body polygons
- Remove the snap feature HOT 1
- Fix the wasTouching flags HOT 1
- Ninja physics mapping for 64px+ HOT 1
- Fix skipped collisions between tiles HOT 3
- Prevent internal edge collisions without heuristics HOT 4
- AMD/UMD HOT 2
- Object pooling for calculations HOT 1
- Bodies not colliding HOT 2
- Automatically set colliding tiles for Tilemaps
- Drop Bower HOT 1
- Update npm package HOT 10
- Full-block tile in arcadeslopes not registering for collision HOT 4
- Using Slopes in Typescript HOT 20
- Question: How to prevent slipping or sliding on slopes HOT 1
- Curved slopes HOT 4
- Phaser 3 HOT 14
- Errors: "Unresolved slope type 'r' / Slope type r not defined", "tilemapLayer.getTileOffsetX is not a function" HOT 4
- Sprite jitters/bounces at some tile junctions HOT 14
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from phaser-arcade-slopes.