protected internal override void OnEnable() { if (!ActiveLights.Contains(this)) { ActiveLights.Add(this); } }
protected internal override void OnDelete() { ActiveLights.Remove(this); Lights.Remove(this); }
protected internal override void OnDisable() { ActiveLights.Remove(this); }
protected internal override void OnEnable() { ActiveLights.Add(this); }
protected internal override void Creation() { Lights.Add(this); ActiveLights.Add(this); }
public bool CheckInLight(Vector2 position) { return(ActiveLights.Count(p => p.Collider.bounds.Contains(position)) > 0); }