How to load a movie at the beginning of my game

I'M A BEGINNER and I just want do know how to play a movie at the beginning of my game plz answer

You can use a Movie Texture.

Edit: Alright, this is as detailed as I'm going to get. If you still don't understand me, I don't know what else to tell you, other than to learn some Unity basics before attempting this.

  • Import your movie file into the Assets section of Unity.
  • Create an empty Game Object.
  • Place something like this script inside of it:
MovieTexture myMovie;

void Start()
{
     myMovie.Play();
}

void OnGUI()
{
     GUI.DrawTexture(new Rect(0, 0, Screen.width, Screen.height), myMovie);
}

I think that code will work, though I don't have Unity Pro so there's no way for me to test it out. Someone correct me if I'm wrong.

Anyway.

  • Attach that script (add your own class header to it) to your empty Game Object.
  • Drag your movie file from the Assets pane onto the Inspector for the script (on the empty game object), which should have a slot for "My Movie".
  • Play the scene. Your movie should play, full-screen.

doesnt make sense. doesnt work!

using UnityEngine;
using System.Collections;

public class NewBehaviourScript : MonoBehaviour {
public MovieTexture myMovie;

void Start()
{
	myMovie.Play();
}

void OnGUI()
{
	GUI.DrawTexture(new Rect(0, 0, Screen.width, Screen.height), myMovie);
}

}