On trigger stay

Hello to everyone
I want to make my FPS when is on trigger stay (any box collider) to play a movie texture that I put in a plane.
P.S the idea is I have a lot of videos and I want when the player is front of every video, the video plays and on trigger exit the video stops.

I start with this script and with some changes but it did work

Any ideas?

Do you have the pro version?

yeap!!

Just checking since I new it was a pro only feature. Sorry I can’t help I don’t have the pro version so no experience.

No prob my friend!

I think I would use OnTriggerEnter() instead of OnTriggerStay()

Something like this:

private var moviePlay : boolean = false;

function Update()
{
if (moviePlay)
{
movTexture.Play();
}

function OnTriggerEnter()
{
moviePlay = true;
{

function OnTriggerExit()
{
moviePlay = false;
}

Thanks my friend it works fine!