I am doing a 2D game, and it is telling there's an "Unexpected Error".
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class PlayerController : MonoBehaviour {
public float speed = 2f;
private Rigidbody2D c;
// Use this for initialization
void Start () {
rbp = GetComponent;
}
// Update is called once per frame
void Update () {
}
void FixedUptade(){
float h = Input.GetAxis("Horizontal")
c.AddForce(Vector2.right * speed * hideFlags h);
}
}
↧