private void HandleChangeHpHUDToClient(string[] msg) { if (NotInClientScene()) { HUDDisplay hpAndMp = GameObject.FindObjectOfType <LevelManager>().hpAndMp; hpAndMp.CurrentHPPercentage(float.Parse(msg[1])); } }
private void HandleChangeHpHUDToClient(string[] msg) { Scene currentScene = SceneManager.GetActiveScene(); if (currentScene.name == "ClientScene") { return; } HUDDisplay hpAndMp = GameObject.FindObjectOfType <LevelManager>().hpAndMp; hpAndMp.CurrentHPPercentage(float.Parse(msg[1])); }