I am working through the tutorial Project #00: Roll-a-Ball in Learn/Tutorial/Projects.
In part two Moving the player I get an error at 09:38 of the video. Can anyone tell me what I am doing wrong here?
using UnityEngine;
using System.Collections;
public class PlayerController : MonoBehaviour
{
void FixedUpdate ()
{
float moveHorizontal = Input.GetAxis("Horizontal");
float moveVertical = Input.GetAxis("Vertical");
Vector3 movement = new Vector3(moveHorizontal, 0.0f, moveVertical);
rigidbody.Addforce(movement);
}
}
and the error message is
Assets/Scripts/PlayerController.cs(13,27): error CS1061: Type UnityEngine.Rigidbody' does not contain a definition for Addforce’ and no extension method Addforce' of type UnityEngine.Rigidbody’ could be found (are you missing a using directive or an assembly reference?)