Beispiel #1
0
 public void DeregisterMember(LightgroupMember member)
 {
     if (members == null)
     {
         return;
     }
     if (members.Contains(member))
     {
         members.Remove(member);
     }
 }
Beispiel #2
0
 public void RegisterMember(LightgroupMember member)
 {
     if (members == null)//initialize if needed.
     {
         members = new List <LightgroupMember>();
     }
     if (!members.Contains(member))
     {
         members.Add(member);
     }
     else
     {
         // This actually happens a lot because scriptableObjects dont reset on exiting play mode.
         // Debug.LogWarning("Light already member of group: "+this.name,member);
     }
 }