public void OpenMessagePanel(InteractableItemBase item) { MessagePanel.SetActive(true); Text mpText = MessagePanel.transform.Find("Text").GetComponent <Text>(); mpText.text = item.InteractText + " " + RichText.Paint(item.Name, item.itemNameColor, true, false); mIsMessagePanelOpened = true; }
void RPC_ChangeMap(int map) { settings.map = (Map)map; mapNameText.text = mapNameText.text = RichText.Paint("Map: ", Color.yellow, true, false) + RichText.Paint(settings.map.ToString(), Color.white, false, true); foreach (Sprite sprite in images) { if (sprite.name == settings.map.ToString()) { mapImage.sprite = sprite; } } }
void Start() { PV = GetComponent <PhotonView>(); //Saving data in scripts when scene is changing OnGameSceneChanged += Inventory.instance.SaveData; OnGameSceneChanged += GMSetting.setting.SaveData; OnGameSceneChanged += SaveData; readyToCount = false; readyToStart = false; lessThanMaxPlayers = startingTime; atMaxPlayers = 6; timeToStart = startingTime; gameModeText.text = RichText.Paint("Game mode: ", Color.red, true, false) + RichText.Paint("None", Color.white, false, true); mapNameText.text = RichText.Paint("Map: ", Color.yellow, true, false) + RichText.Paint("None", Color.white, false, true); }
public void UpdateMoneyUI() { moneyText.text = "Team money: " + RichText.Paint(money.ToString(), Color.yellow, false, false); }
void RPC_ChangeGameMode(int mode) { settings.mode = (GameMode)mode; gameModeText.text = RichText.Paint("Game mode: ", Color.red, true, false) + RichText.Paint(settings.mode.ToString(), Color.white, false, true); }