Get Speed of moving object Rigidbody in unity3d
Channel:
Subscribers:
1,110
Published on ● Video Link: https://www.youtube.com/watch?v=9CYZg1vb8Vc
Code :
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Speedcalculator : MonoBehaviour
{
public Rigidbody rigidbody;
public float speed;
// Start is called before the first frame update
void Start()
{
}
// Update is called once per frame
void Update()
{
speed = rigidbody.velocity.magnitude;
}
}
Other Videos By Muhammad Shahzaib
Tags:
unity
unity3d
learn unity
unity tutorials
get speed in unity
speed finder in unity 3d
Other Statistics
Unreal Statistics For Muhammad Shahzaib
At present, Muhammad Shahzaib has 379 views spread across 3 videos for Unreal, and less than an hour worth of Unreal videos were uploaded to his channel. This is 1.16% of the total watchable video on Muhammad Shahzaib's YouTube channel.