Access the particle system lights module.
no example available in JavaScript
using UnityEngine; using System.Collections;
public class ExampleClass : MonoBehaviour {
public Light lightPrefab;
void Start() { ParticleSystem ps = GetComponent<ParticleSystem>(); var lights = ps.lights; lights.enabled = true; lights.ratio = 0.5f; lights.light = lightPrefab; } }
Did you find this page useful? Please give it a rating: