Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

unity run all interfaces

 using System.Linq;   
 ...    
              var ss = FindObjectsOfType<MonoBehaviour>().OfType<IStats>();
              foreach (IStats s in ss) {
                  enemies.Add (s);
              }
 
PREVIOUS NEXT
Tagged: #unity #run #interfaces
ADD COMMENT
Topic
Name
7+2 =