Was the CharacterController touching the ground during the last move?
#pragma strict public class Example extends MonoBehaviour { var controller: CharacterController; function Start() { controller = GetComponent.<CharacterController>(); } function Update() { if (controller.isGrounded) { print("CharacterController is grounded"); } } }
using UnityEngine;
public class Example : MonoBehaviour { CharacterController controller;
void Start() { controller = GetComponent<CharacterController>(); }
void Update() { if (controller.isGrounded) { print("CharacterController is grounded"); } } }
Did you find this page useful? Please give it a rating: