Search Unity

Question how do I increase mouse camera movement speed in 3D games?

Discussion in 'Getting Started' started by zoldos, Aug 5, 2021.

  1. zoldos

    zoldos

    Joined:
    Jul 31, 2021
    Posts:
    10
    On second thought, this might be a good feature to have in a game's settings. Is it possible? Thanks!
     
    Last edited: Aug 5, 2021
  2. zoldos

    zoldos

    Joined:
    Jul 31, 2021
    Posts:
    10
    *bunp :)
     
  3. UnityMaru

    UnityMaru

    Community Engagement Manager PSM

    Joined:
    Mar 16, 2016
    Posts:
    1,227
    Please don't bump threads.
     
    zoldos likes this.
  4. zoldos

    zoldos

    Joined:
    Jul 31, 2021
    Posts:
    10
    Okay no prob. Sorry about that.
     
  5. Vryken

    Vryken

    Joined:
    Jan 23, 2018
    Posts:
    2,106
    Multiply your movement logic by an additional variable to change its speed.

    Example:
    Code (CSharp):
    1. public class Example : MonoBehaviour {
    2.   public Vector3 targetPosition;
    3.   public float moveSpeed = 1f;
    4.  
    5.   void MoveToTarget() {
    6.     transform.position = Vector3.MoveTowards(transform.positiom, targetPosition, Time.deltaTime * moveSpeed);
    7.   }
    8. }
     
    zoldos likes this.
  6. zoldos

    zoldos

    Joined:
    Jul 31, 2021
    Posts:
    10
    Cool, thanks! I'm totally new to Unity. How do I implement this in say the 3D Game Kit?