private void ShowHoveringInfo() { //GameObject.Find("InfoUI").transform.position = new Vector3(9f, 2, 3.5f); GameObject.Find("InfoUI").GetComponent <UI>().AskMovement(InfoUIShownPosition, UITransitionDelay); GameObject.Find("HoveringInfoSprite").GetComponent <SpriteRenderer>().sprite = HoveringLifie.GetComponent <SpriteRenderer>().sprite; GameObject.Find("HoveringLifieName").GetComponent <Text>().text = HoveringLifie.Name; GameObject.Find("HoveringLifieElement").GetComponent <Text>().text = HoveringLifie.ElementToString(); GameObject.Find("HoveringLifieLevel").GetComponent <Text>().text = HoveringLifie.LevelToString(); GameObject.Find("HoveringLifieLP").GetComponent <Text>().text = HoveringLifie.LPToString() + " / " + HoveringLifie.TotalLPToString(); GameObject.Find("HoveringLifieAP").GetComponent <Text>().text = HoveringLifie.APToString() + " / " + HoveringLifie.TotalAPToString(); GameObject.Find("HoveringLifieStatus").GetComponent <Text>().text = HoveringLifie.StatusConditionToString(); GameObject.Find("HoveringLifieMovementCapacity").GetComponent <Text>().text = HoveringLifie.MovementCapacityToString(); GameObject.Find("HoveringLifieStrength").GetComponent <Text>().text = HoveringLifie.StrengthToString(); GameObject.Find("HoveringLifieDefense").GetComponent <Text>().text = HoveringLifie.DefenseToString(); GameObject.Find("HoveringLifieMagic").GetComponent <Text>().text = HoveringLifie.MagicToString(); GameObject.Find("HoveringLifieMagicDefense").GetComponent <Text>().text = HoveringLifie.MagicDefenseToString(); Color tempcolor = new Color32(50, 50, 50, 255); GameObject.Find("HoveringLifieTileBuffArrow").GetComponent <Text>().enabled = false; GameObject.Find("HoveringLifieStrength").GetComponent <Text>().color = tempcolor; GameObject.Find("HoveringLifieDefense").GetComponent <Text>().color = tempcolor; GameObject.Find("HoveringLifieMagic").GetComponent <Text>().color = tempcolor; GameObject.Find("HoveringLifieMagicDefense").GetComponent <Text>().color = tempcolor; string tempstring = ""; string el1, el2; switch (HoveringTile.type) { case 1: el1 = "Strength"; el2 = "Magic"; break; case 2: el1 = "Defense"; el2 = "Magic Defense"; break; case 3: el1 = "Strength"; el2 = "Defense"; break; case 4: el1 = "Strength"; el2 = "Magic Defense"; break; case 5: el1 = "Magic"; el2 = "Magic Defense"; break; default: el1 = el2 = ""; break; } if (el1 != "" && el2 != "") { tempstring = "+50% " + el1 + " and " + el2; el1 = Regex.Replace(el1, " ", ""); el2 = Regex.Replace(el2, " ", ""); GameObject.Find("HoveringLifieTileBuffArrow").GetComponent <Text>().enabled = true; GameObject.Find("HoveringLifie" + el1).GetComponent <Text>().color = new Color32(0, 183, 0, 255); Debug.Log("element 2: " + el2); GameObject.Find("HoveringLifie" + el2).GetComponent <Text>().color = new Color32(0, 183, 0, 255); } GameObject.Find("HoveringLifieTileBuff").GetComponent <Text>().text = tempstring; }