FragMate CommunityLog in

FragMate - Software and Game Developer Community, including Resources, Forums, Marketplace & More.

Share

descriptionSimple light flicker

more_horiz
Hi guys Very Happy I made this very simple script of light flicker Very Happy I hope it's useful for someone

Script (Js):

Code:

#pragma strict

var interval : float = 1.0f;
function Start ()
{
 ¬†InvokeRepeating("Toggle", interval, interval);
}

function Update ()
{
light.intensity = Random.Range (0.3f, 5f);
}
function Toggle()
{
 ¬† ¬†gameObject.active = !gameObject.active;
}

Image:

Last edited by developer23 on Tue Jan 27, 2015 12:49 pm; edited 2 times in total

_________________
Game Developer
YouTube Channel: [You must be registered and logged in to see this link.]
Website: [You must be registered and logged in to see this link.]

descriptionRe: Simple light flicker

more_horiz
Hey developer23, thanks for the share. I'm sure it is going to be useful to someone.

--New Developer

_________________
Serious, Focused but FUN.

descriptionRe: Simple light flicker

more_horiz
[You must be registered and logged in to see this link.] wrote:
Hey developer23, thanks for the share. I'm sure it is going to be useful to someone.

--New Developer

Thank you Very Happy I also added in description the image Very Happy

_________________
Game Developer
YouTube Channel: [You must be registered and logged in to see this link.]
Website: [You must be registered and logged in to see this link.]

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