} //End HUD int getter #endregion //Get the game objects and scripts for managing the HUD private void Start() { if (conversationHUDGameObject == null) { conversationHUDGameObject = GameObject.FindGameObjectWithTag("Conversation HUD"); }//End if if (explorationHUDGameObject == null) { explorationHUDGameObject = GameObject.FindGameObjectWithTag("Exploration HUD"); }//End if conversationHUDScript = gameObject.GetComponent <ConversationHUD>(); explorationHUDScript = gameObject.GetComponent <ExplorationHUD>(); activeHUD = (int)HUDOptions.exploration; }//End Start
}//End Is Interacting Setter #endregion //Initialise variables on player start private void Start() { //Set the player to whatever is currently set as the player player = GameObject.FindGameObjectWithTag("Player"); //Find camera playerCam = FindObjectOfType <Camera>(); //Set the interaction range to a test value of ten interactRange = 1.5f; //Set the interaction layer to... the interaction layer interactLayer = LayerMask.GetMask("Interactible"); //Set the HUD Handler to the correct object HUDHandler = GameObject.FindGameObjectWithTag("HUD").GetComponent <ExplorationHUD>(); //Set player voice GameObject.FindGameObjectWithTag("MainCamera").GetComponentInChildren <AudioSource>().clip = JSONHolder.getSpeaker("Player").voice; }//End Start