RigitBodyController doesn't move my object

Hi!

I’m new to Unity, and by now I watching several how-to videos. In one of them, that is published on officcila MS webiste is tought how to write scripts in Unity.

I’m using Unity 5, and come up with such issue. My object doesn’t respond to Move buttons. This method was taken from videoguide, I’m looking through.

using UnityEngine;
using System.Collections;

public class NewScriprt : MonoBehaviour {

    public float move;
    public float maxSpeed = 10f;
    private Rigidbody2D rb;


    // Use this for initialization
    void Start () {

    }

    void FixedUpdate()
    {
        move = Input.GetAxis("Horizontal");
    }

    // Update is called once per frame
  void Update () {

        rb.velocity = new Vector2 (move * maxSpeed, rb.velocity.y);
  
  }
}

Hey man try too use the getComponent reference.
Rigidbody2D rb2;

using UnityEngine;
 using System.Collections;
 
 public class NewScriprt : MonoBehaviour {
 
     public float move;
     public float maxSpeed = 10f;
     private Rigidbody2D rb2;
 
 
     // Use this for initialization
     void Start () {
       rb2 = GetComponent<Rigidbody2D>();

     }
 
     void FixedUpdate()
     {
         move = Input.GetAxis("Horizontal");
     }
 
     // Update is called once per frame
   void Update () {
 
         rb.velocity = new Vector2 (move * maxSpeed, rb.velocity.y);
   
   }
 }

This maybe helpes