What happened to my game?

PlayCanvas 3D HTML5 Game Engine This is my game, but the code is messed up. I tried to put it in first person but it did not work, can someone tell me what I did wrong?

Hi @Adrian_Eu and welcome!

It looks like lines 61 to 68 of your PlayerCameraMovement.js script, is a function inside another function. This is not correct. You should place these lines for example after the current line 106. Current line 59 should be removed.

Ok so I changed the things you said (I am new to this sorry) and it still doesn’t work. The camera is all the way to the south east of the entity and the movement is broken, how do I change this?

As you’ve changed the script name to ‘firstPersonMovement’ in the file PlayCameraMovement.js PlayCanvas | HTML5 Game Engine, you need to parse the file and add it the entity you want it on.

Select the script asset and press this button (may take a few button presses)

And then add the script to the Entity you need it on.

I’m not entirely sure what your intention is but this is what’s currently causing an issue with the project.

I was trying to make the entity first person I think it was my code that was the problem, but I am on mobile so its kinda hard to find stuff