Video texture problem?

Hello!

I use this script to make the video texture start, but it gives me these errors:

Assets/Scripts/Js_TV.js(12,51): BCE0019: ‘isPlaying’ is not a member of ‘UnityEngine.Texture’.
Assets/Scripts/Js_TV.js(13,55): BCE0019: ‘Pause’ is not a member of ‘UnityEngine.Texture’.
Assets/Scripts/Js_TV.js(16,55): BCE0019: ‘Play’ is not a member of ‘UnityEngine.Texture’.


function OnTriggerStay (other : Collider) {
if(other.gameObject.tag == "Player")
{
	if (Input.GetKeyDown(KeyCode.Space))
	{
		if (renderer.material.mainTexture.isPlaying) {
			renderer.material.mainTexture.Pause();
		}
		else {
			renderer.material.mainTexture.Play();
		}
	}
}
}

this code will work perfectly for you.

var movTexture : MovieTexture;

function Update ()
{
if (Input.GetButtonDown (“Jump”))
{
if (movTexture.isPlaying)
{
movTexture.Pause();
}
else
{
movTexture.Play();
}
}

}

Searching for C# and find =)

MovieTexture mov;

void Update () {
mov=(MovieTexture)renderer.material.mainTexture;
mov.Play(); }