- Home /
Force iOS first person to move slightly when player is not moving it?
I'm at a road-block here. I want to have my first person character to move ever so slightly when the player is not even moving the character so that the Unity physics won't kick in like it would when the character is standing still. I know that I have to add something like 0.001 into the script but I don't know where or how. I am using the Standard Assets (Mobile) script "FirstPersonControl". If anyone can direct me to where I might read up on movement or help me out with this, I would be very grateful. Thank you in advance. Tom
Answer by LordZephyr · Jan 14, 2012 at 04:23 PM
Here is the answer that was given on another question by user @aldonaletto. This forces the first person character to move so slightly that it is almost unnoticeable.
... movement += velocity; movement += Physics.gravity; movement *= Time.deltaTime;
// Actually move the character
character.Move( movement ); ...
Just modify the first line by adding the small movement value below:
movement += velocity + Vector3(0, 0, 0.0001);
This moves the player to the right slightly. If you want to have the player move in reverse slightly (which is what I did) make the first line like this:
movement += velocity + Vector3(0.0001, 0, 0);
This worked great for me.
Your answer
![](https://koobas.hobune.stream/wayback/20220613062752im_/https://answers.unity.com/themes/thub/images/avi.jpg)