i have this error in my code and i dont know what to do about it please help:
Assets\scripts\controller\Movement.cs(17,10): error CS0111: Type ‘Movement’ already defines a member called ‘Start’ with the same parameter types
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Movement : MonoBehaviour
{
float Speed;
public Rigidbody rb;
public bool PlayerOnGround = true;
private void Start()
{
rb = GetComponent<Rigidbody>();
}
// Start is called before the first frame update
void Start()
{
Speed = 5;
}
// Update is called once per frame
void Update()
{
transform.Translate(Input.GetAxis("Horizontal") * Time.deltaTime * Speed, 0, Input.GetAxis("Vertical") * Time.deltaTime * Speed);
if(Input.GetKey(KeyCode.UpArrow)) {
transform.Translate(5, 0, 10 * Time.deltaTime);
}
if(Input.GetKey(KeyCode.DownArrow)) {
transform.Translate(5, 0, -10 * Time.deltaTime);
}
if(Input.GetKey(KeyCode.LeftArrow)) {
transform.Translate(-10 * Time.deltaTime, 0, 0);
}
if(Input.GetKey(KeyCode.RightArrow)) {
transform.Translate(10 * Time.deltaTime, 0, 0);
}
if(Input.GetButtonDown("w")) {
if(Input.GetButtonDown("left shift")){
transform.Translate(10 * Time.deltaTime * 3f, 0, 0);
}
}
if(Input.GetButtonDown("jump") && PlayerOnGround)
{
rb.AddForce(new Vector3(0, 5, 0), ForceMode.Impulse);
PlayerOnGround = false;
}
}
private void OnCollisionEnter(Collision collision)
{
if(collisionn.gameObject.tag == "ground")
{
PlayerOnGround = true;
}
}
}
[code]