I can't insert scripts!

Can someone please tell me how to insert scripts into objects? I have looked at tons of videos but they say nothing whatsoever. I try to insert a script from MonoScript and I drag it over an object but it STILL won’t work! Can someone help me?!?!?!

Try creating a new c# script by doing the following;

Create a new scene.
Go to the GameObject menu (on the top menu).
Click ‘Create Empty GameObject’.

Select this object in the ‘Hierarchy’ window.

In the ‘Inspector’ panel, click on Add Component. Then select new script. Give it the name test and make sure it is C#. The name is very important, as Unity will not recognise the script if it doesn’t have the same name as the class in the code.

You should now see the script as a component attached to the empty gameobject. Right click on the name and select edit. This will open Mono Develop.

Copy and paste the following into this script you just created;

using UnityEngine;
using System.Collections;

public class test : MonoBehaviour {

    void Start() {
         Debug.Log ("Your Attached Script Is Working!!");

If you start the game and then open the console, you should see the text as an information message.

This means the script is working.

There are a few ways to do this, one method

  1. in the Editor hierarchy, click a gameobject

  2. in the Editor project view // Assets // scripts folder (assuming you have one), find your script

  3. click on the script, drag it onto the Inspector/GameObject view and release

  4. the script is now attached to the GameOject

Take a look at this site

You can, as Peter suggested also use the Addcomponent button.