First person movement script camera strafing problem

Hello

Another question I have here that I am confused about

I am studying the default first person movement script: First Person Movement | Learn PlayCanvas

When you face the camera down in that script and look at the players feet and strafe using W+A or W+D the player does not strafe forward-left/right as it should. I am wondering why it behaves like this when the camera is facing too far down or up.

Here is what I mean:

What should happen:
12121

What actually happens:
121212

Just curious to know why this behaviour happens in certain camera angels closer to 90 and -90.

Thanks

Hi @nasjarta,

The first person movement script is pretty basic as it even allows you to rotate camera at 180 degrees, I will look at it a bit later and would suggest you to use Will’s extended first person movement script which handles this case as well as the case you mentioned above:

https://playcanvas.com/project/626211/overview/first-person-shooter-starter-kit

3 Likes

hi

I clamped the camera so it could not rotate to 180.

I want to know why this behaviour happens when you are looking down. The W when pressing W+A is ignored suddenly.

@Saad_Haider

Is it possible for us to talk through the playcanvas editor regarding this issue?

If you are available and willing I would like to ask you some questions based on this topic.

Hi @nasjarta ,

It works for me,

What did you do to achieve this?

Also is it possible for me to add you to a project to show you some stuff inside the editor and talk about this?