alexandernst 1 Report post Posted March 11, 2018 Is there a way to create a text object with physics on it, the same way I'm able to create an image object, like this: Phaser.Physics.Arcade.Image.call(this, scene, 0, 0, "my_image"); If there isn't a direct way of creating such thing, what would be a good alternative of having a dynamically generated text that acts like a game object with physics? Share this post Link to post Share on other sites
samme 701 Report post Posted March 11, 2018 You can try this.physics.world.enable(text) or whatnot. Share this post Link to post Share on other sites
alexandernst 1 Report post Posted March 11, 2018 Okey, I got it working with `Phaser.GameObjects.Text` and `physics.world.enable` as you said. But now I have another problem. I'm trying to rotate the text and the physics body that is attached to it, but only the text itself is rotating. Demo: http://plnkr.co/edit/G7obzt6xtwKJtYcv5oay?p=preview Share this post Link to post Share on other sites
alexandernst 1 Report post Posted March 11, 2018 Answering to my own question: rotation physics bodies is not possible with arcade physics. For this to be possible I'd need to switch to matter.js physics. Share this post Link to post Share on other sites
PixelPicoSean 70 Report post Posted March 12, 2018 Arcade physics of Phaser 3 does support rotation of body (using SAT algorithm), but the debug graphics simply draws a rectangle which I think is not finished yet. Share this post Link to post Share on other sites
PixelPicoSean 70 Report post Posted March 13, 2018 Sorry I just read the source code of arcade physics, it does not use SAT for collision detection and does not support rotation either. Share this post Link to post Share on other sites
rich 2,575 Report post Posted March 13, 2018 Arcade Physics 2 uses SAT but isn't in v3 yet. We basically ran out of time but will revisit it one day! Share this post Link to post Share on other sites