I’m using the script “RigidbodyFirstPersonController” located in the prefab in standard assent.
I have to turn off the Movement setting but not the mouse look, how do I?
because if i disable the script in the inspector
it disables all the script, while I have to turn off only the movement setting, the mouse look no
Either you split the script into two scripts where one handles the movement and the other the mouse look, so that you can toggle the movement script alone. Alternatively you place your movement input-checks inside an if-statement which you can then toggle like so:
public bool enableMovement;
void Update()
{
if(enableMovement)
{
if(Input.GetKeyDown("w")){//Move}
if(Input.GetKeyDown("s")){//Move etc.}
}
if(Input.GetKeyDown("space"))
{
enableMovement = !enableMovement //Toggle movement}
}
}