// Use this for initialization void Start() { commands = gameObject.GetComponent <ButtonCommands>(); if (commands != null) { commands.AddCommand(resetClipPlaneAction()); } }
public virtual void Start() { ButtonCommands bc = gameObject.GetComponent <ButtonCommands>(); if (bc == null) { Debug.Log("no button commands on " + gameObject.name); } else { bc.AddCommand(Command()); } }