1234567891011121314151617181920 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- public class RollingSphere : MonoBehaviour
- {
- private Rigidbody sphere;
- // Start is called before the first frame update
- void Start()
- {
- sphere = GetComponent<Rigidbody>();
- }
- // Update is called once per frame
- void Update()
- {
- sphere.AddTorque(0,0,1);
-
- }
- }
|