public static HabilitesHandler Instance() { if (!habiliteH) { habiliteH = FindObjectOfType(typeof(HabilitesHandler)) as HabilitesHandler; if (!habiliteH) // Make sure that Modalpanel existes. { Debug.Log("There needs to be one active HabilitesHandler Script on a GameObject in your scene"); } } return(habiliteH); }
void Awake() { eventTrigger = GetComponent <EventTrigger> (); GameObject go = GameObject.FindGameObjectWithTag("Player"); playerControl = go.GetComponent <PlayerControl> (); gameSetupL = GameSetupLanguages.Instance(); tutorialComplete = transform.FindChild("Tutorial Complete"); tutorialInstructions = transform.FindChild("Tutorial Instructions"); HandAnim = tutorialInstructions.FindChild("HandAnim"); instructionText = tutorialInstructions.FindChild("InstructionText").GetComponent <Text>(); HandAnimAnimator = HandAnim.gameObject.GetComponent <Animator> (); habilitesHandler = HabilitesHandler.Instance(); }
void Awake() { habiliteHandler = HabilitesHandler.Instance(); }