Search the Community
Showing results for tags 'matter-attractors'.
-
I'm not understanding how to incorporate plugins... especially for matter-attractors. my config file looks like this, I'm bringing in another plugin that worked well, and had good instructions. type: Phaser.AUTO, parent: "my game", canvas: document.getElementById("game"), width: 1500, // window.innerWidth height: 1500, // window.innerHeight pixelArt: true, roundPixels: true, physics: { default: "matter", matter: { gravity: { scale: 0 }, debug: true, }, }, plugins: { scene: [ { plugin: PhaserMatterCollisionPlugin, // The plugin class key: "matterCollision", // Where to store in Scene.Systems, e.g. scene.sys.matterCollision mapping: "matterCollision", // Where to store in the Scene, e.g. scene.matterCollision }, { plugin: MatterAttractors, key: "matterAttractors", mapping: "matterAttractors", }, ], }, }; You can see I'm trying to use it there at the bottom... I'm not having any luck. I'm expecting to see them in the console when they get in by using this: this.plugins.scenePlugins I'm hoping someone call show me what needs to change. here is matter-atractor's github link