Commit graph

79 commits

Author SHA1 Message Date
Richard Davey
1d827c911f 0.2 is just too dim 2020-01-10 14:53:39 +00:00
Richard Davey
4d0618232b Only render compound bounds 2020-01-09 00:43:38 +00:00
Richard Davey
99df00244b Reduced default anchor size 2020-01-07 17:31:29 +00:00
Richard Davey
2b1ce933af The internal Matter Composite.setModified function will now emit a compositeModified event, which the Matter World listens for, if debug draw is enabled, so it can update the composite children render styles. 2020-01-07 17:20:31 +00:00
Richard Davey
a2c1377131 You can now set gravity: false in your Matter Config and it will reset gravity from the defaults to zero. 2020-01-07 16:38:13 +00:00
Richard Davey
8527e10d64 Added renderCollisions and renderSeparations 2020-01-07 14:02:28 +00:00
Richard Davey
c0e61cf2be Added renderBodyVelocity 2020-01-07 12:56:30 +00:00
Richard Davey
ad1891cd8d Added renderBodyBounds and renderBodyAxes methods 2020-01-07 12:39:27 +00:00
Richard Davey
0a801cbac4 Added World.renderGrid method.
Renamed showBodyPosition to showPositions
2020-01-07 11:56:39 +00:00
Richard Davey
76d2c971f7 Added showSensor debug option 2020-01-07 00:28:37 +00:00
Richard Davey
64c12a9c60 Added showBodyPosition config option 2020-01-06 22:30:38 +00:00
Richard Davey
7fdcfd540c Remove render.opacity as it's not valid for constraints 2020-01-01 20:02:15 +00:00
Richard Davey
ac124b8e20 Better handling of the runner config 2019-12-17 13:52:57 +00:00
Richard Davey
a158b14228 Matter.World.has is a new method that will take a Matter Body, or Game Object, and search the world for it. If found, it will return true. 2019-12-17 13:15:15 +00:00
Richard Davey
87a8af35c5 Added in Matter Runner 2019-12-13 19:41:27 +00:00
Richard Davey
7ba6e9fe6b Added setCompositeRenderStyle method 2019-12-12 13:31:47 +00:00
Richard Davey
c267662259 Update World.js 2019-12-11 15:00:41 +00:00
Richard Davey
444bdf116f Debug tweaks 2019-12-10 17:50:04 +00:00
Richard Davey
4f3a524114 Update World.js 2019-12-10 14:02:50 +00:00
Richard Davey
7bdcb5a892 Temp bounds debug 2019-12-10 02:42:16 +00:00
Richard Davey
e7cac4ebe9 Removed old config values and now handles opacity properly 2019-12-04 03:14:06 +00:00
Richard Davey
76c81e19c3 Moved the render style methods to World and use them as part of the event proxy 2019-12-03 14:48:04 +00:00
Richard Davey
9a0218b3da Fixed line style and updated parameter names. 2019-12-03 14:06:10 +00:00
Richard Davey
ca293d710f Proxy the add and remove events and better handle debug draw injection. 2019-12-02 19:20:54 +00:00
Richard Davey
b71d4059a7 100% JSDoc'd! 2019-12-02 15:07:44 +00:00
Richard Davey
4f8dd24df2 Handle legacy configs for now. 2019-11-28 16:19:03 +00:00
Richard Davey
f126f28121 Split out the debug rendering process into single methods, so they can be called externally if required 2019-11-28 10:43:26 +00:00
Richard Davey
3d46304b6a Final new debug config added 2019-11-27 17:49:21 +00:00
Richard Davey
7b280e4fb2 Redoing debug config 2019-11-26 16:39:34 +00:00
Richard Davey
c91ed91ce3 License link update 2019-05-10 16:15:04 +01:00
Richard Davey
2008438919 Added new Matter World config def 2019-05-09 15:31:59 +01:00
Richard Davey
09487bbfc6 Added new resetCollisionIDs method re: #4334 2019-04-08 10:34:52 +01:00
Richard Davey
0ab61ac6de When the Matter World creates its wall bounds, the left and right walls now extend further up and down than before, so that in a 4-wall setting there are no gaps in the corners, which previously allowed for fast moving objects that hit a corner intersection point to sometimes travel through it. 2019-02-09 16:27:20 +00:00
Richard Davey
5f03d2cd5e Testing Composite.remove, instead of removeBody. 2019-02-08 19:46:13 +00:00
Richard Davey
8b35743943 Matter Events added 2019-01-17 15:47:27 +00:00
Richard Davey
aa341854c7 Happy New Year 2019-01-15 16:20:22 +00:00
Richard Davey
49c2868746 All default width/height values are now taken from the Scale Manager, not the Game Config 2019-01-11 15:57:57 +00:00
Richard Davey
30dda882eb Matter.TileBody.setFromTileCollision no longer checks if the shape is concave or convex before modifying the vertices, as the update to the Matter.js lib in 3.12 stopped this from working with Tiled collision shapes. 2019-01-08 11:50:21 +00:00
Richard Davey
2780babe10 Final Doc Jam merge 2018-12-03 15:16:23 +00:00
Richard Davey
4c4421c47f Docjam merge 2018-10-19 12:32:43 +01:00
Richard Davey
4b1c762296 Updated @memberOf to @memberof 2018-10-10 10:49:13 +01:00
Richard Davey
c237209bb8 Added new jsdocs 2018-09-28 12:19:21 +01:00
Richard Davey
df7245e3c5 Added all of the new Matter debug rendering options 2018-09-26 14:12:20 +01:00
Richard Davey
5fe6dbbe0c Added more jsdocs 2018-09-13 08:09:44 +01:00
jf908
4f5b43e0ed
Allow matter js bodies to render their debug graphics individually 2018-09-04 18:45:54 +01:00
Richard Davey
3490b29082 Tidying up 2018-04-13 17:43:56 +01:00
Richard Davey
6b2307594a Scene plugin flow overhaul
Every Plugin has been updated to correctly follow the same flow through the Scene lifecycle. Instead of listening for the Scene 'boot' event, which is only dispatched once (when the Scene is first created), they will now listen for the Scene 'start' event, which occurs every time the Scene is started. All plugins now consistently follow the same Shutdown and Destroy patterns too, meaning they tidy-up after themselves on a shutdown, not just a destroy. Overall, this change means that there should be less issues when returning to previously closed Scenes, as the plugins will restart themselves properly.
2018-04-13 17:12:17 +01:00
Richard Davey
8afa6c9c7f MatterEvents.off() would cause a TypeError if you destroyed the Matter world. Fix #3562 2018-04-13 12:07:27 +01:00
Richard Davey
70c7732a1e When shutting down a Matter World it will now call MatterEvents.off, clearing all events, and also removeAllListeners for any local events. 2018-04-11 14:00:58 +01:00
Richard Davey
d93e8ab919 Make sure debug layer remains on the top 2018-04-03 15:30:46 +01:00