public override void InitButton(int index) { SetHealth(teamMate.MaxHP); teamMateClass = (TeamMateClass)index; SetButtonImageFromMood(TeamMateMood.NEUTRAL); teamMate.OnHealthChanged += SetHealth; teamMate.OnMoodChanged += SetMoodIconFromMoodValue; extaticMoodThreshold = (int)(teamMate.BiggestMood); happyMoodThreshold = (int)(teamMate.BiggestMood * 0.70f); neutralMoodThreshold = (int)(teamMate.BiggestMood * 0.50f); angryMoodThreshold = (int)(teamMate.BiggestMood * 0.30f); SetMoodIconFromMoodValue(teamMate.BiggestMood); border.color = TeamMate.GetTeamMateColor(teamMateClass); border.gameObject.SetActive(true); }
public void SetChatColor() { TextColor = TeamMate.GetTeamMateColor(SenderClass); }