FPS Mobile game Issue

I am currently working on a Virtual Exhibtion Experience with a FPS script, and for the mobile version I am experience a wobbly kind of movement at times. I am not really sure what is cursing this issue.

Any ideas of what could be done?

Editor:
https://launch.playcanvas.com/951821?debug=true
Published:

Thanks

Hi @Anders_Juul_Jorgense and welcome,

Touch controls seem to be working fine, if you are referring to the up and down movement of the camera while walking, you can fix that by changing some properties in your Character Controller rigid body component.

Right now you have it configured like this:

image

Try updating its values to:

image

Taken from this tutorial, the main fix is the Angular Factor being 0,0,0:

https://playcanvas.com/editor/scene/440123

Thanks for help. Is it possible to change the character height too? whenever I tried the character height from 2 to more it wont move no more.

Sure, to do that do two things:

  • Change the Height of the collision box component
  • Change the scale of the model entity
  • Find the camera entity which is a child in your Character Controller and move it up a bit to match the new height of the model/body

Whenever I change the height in the collision component and adjust the camera, the player wont move.
Is there a way where I dont have to scale the whole scene?

What @Leonidas suggested is the way, that allows you to change the size, without scaling the scene. Make sure your collision capsule does not intersect ground after you changed the scale. You can even place the player a little bit above the ground - it will fall to the ground when game starts.

1 Like

I have tried that, and made sure it did not intersect with the ground. I just wont move when I change the height of capsule. I dont really understand why :frowning: But thanks for the help.

Hi @Anders_Juul_Jorgense,

Try posting a sample project url to take a look at how you set up your scene, it will help resolve your issue.

Thanks a lot. The height should be around 8.

https://playcanvas.com/editor/scene/968206

Hi @Anders_Juul_Jorgense,

It seems some of your static colliders can’t fit a 8 units tall cylinder. But you can keep it the same, don’t touch it, just change the position of your camera, something like this will work:

1 Like

Perfect! Thanks a lot :slight_smile:

1 Like