Error CS1001

Can Someone Help It’s Showing Error CS1001 Again Checked The Script But Can’t Find Any Error Some One Help Pls.

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class FlyLittleBird : MonoBehaviour {

     public float velocity = 1;
     private Rigidbody2D rb;
    public float speed = 2;
   // Use this for initialization
   void Start () {
       rb = GetComponent<Rigidbody2D.();
   }
   
    // Update is called once per frame 
    void Update () {
        if(Input.GetKeyDown(KeyCode.Space))
        {
            //Jump
            rb.velocity = Vector2.up * velocity;
        }
    }
}

Post the full error message, including the line the error occurs at. Nobody is remembering these errors by their ID, and nobody is gonna google it and then guess where it may occur in your code.

Edit: Well in line 12 there is certainly a dot instead of a closing >.

2 Likes

Looks like just a typo on line 12.