Unity Ninja Unity 3D Forum
To have exclusive access to all downloads, recourses and links within this forum, a free registered account is required. Just a heads up Wink

You are not connected. Please login or register

Unity Ninja Unity 3D Forum » FREE Project Downloads & Recources » Scripts » Shootout Light Script

Shootout Light Script

View previous topic View next topic Go down  Message [Page 1 of 1]

1 Shootout Light Script on Sun Apr 06, 2014 5:54 pm

BryceCain25


SUPER MODERATOR
SUPER MODERATOR
Hello Everyone! Today I have a shootout light script, today its pretty simple
just attach this to the light of your script, make sure it has a collider, assign the light variable and if you have a tagged object named "bullet" it will turn off the light
Smile
have fun!
(this script was made all by me)

Code:
#pragma strict

var lighttoturnoff : Light;
function OnTriggerEnter () {
if(GameObject.FindWithTag("Bullet")) {
lighttoturnoff = GetComponent(Light);
lighttoturnoff.enabled = false;
}
}

View user profile

View previous topic View next topic Back to top  Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum