Nothing happens when the game is launched. Black screen. The console throw pc.Mat4#invertTo3x3: Matrix not invertible error; This is the link to the script file https://playcanvas.com/editor/code/515637?tabs=9862158. Can you tell me what I’m doing wrong? I was trying to create a script so I can move the object on the X axis.
I’m not sure what’s causing the Matrix not invertible warning, but the scene isn’t rendering because the X-coordinate of the camera’s viewport is set to 1. Setting it to 0 will render the scene as expected.
Hm… I am also trying to make the camera view from top so it look like a 2d ? Is there a better way to do that?
although that rendered the game
Set the camera to orthographic if you are making a ‘2D’ game.
Flappy Bird demo from Will is a good example: https://playcanvas.com/project/375389/overview/flappy-bird