Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Control[] dogArray = Game.Game.Instance.ctrlNodes.selectState.
- Select(x => x as Dog).
- Where(x => x != null).
- Select(x => x.dogObject.gameObject.GetComponent<Control>()).
- Where(x => x != null).ToArray();
- Control[] catArray = Game.Game.Instance.ctrlNodes.selectState.
- Select(x => x as Cat).
- Where(x => x != null).
- Select(x => x.catObject.gameObject.GetComponent<Control>()).
- Where(x => x != null).ToArray();
- Control[] combArray = dogArray.Concat(catArray).ToArray();
- foreach (Control n in combArray)
- {
- //n.Roar();
- }
Add Comment
Please, Sign In to add comment