|
||||||||||||||||
|
||||||||||||||||
Camera.velocity
var velocity : Vector3DescriptionGet the world-space speed of the camera (Read Only). This camera's motion in units per second as it was during the last frame.
JavaScripts
function Update () {
print ("Camera moving at " + camera.velocity.magnitude + " m/s"); }
using UnityEngine;
using System.Collections; public class example : MonoBehaviour { void Update() { print("Camera moving at " + camera.velocity.magnitude + " m/s"); } }
import UnityEngine
import System.Collections class example(MonoBehaviour): def Update(): print((('Camera moving at ' + camera.velocity.magnitude) + ' m/s')) |
|
|||||||||||||||