public override void Refresh() { table.Refresh(); var sb = new StringBuilder(); string scienceModifier; var spModifier = Country.modSciencePoints.getModifier(Game.Player, out scienceModifier); sb.Append("Science points: ").Append(Game.Player.sciencePoints).Append(" + "); sb.Append(Game.Player.getSciencePointsBase().multiplyOutside(spModifier)).Append(" Modifiers: ").Append(scienceModifier); if (selectedInvention == null) { inventButton.interactable = false; inventButton.GetComponentInChildren <Text>().text = "Select from left"; sb.Append("\n\nSelect invention from left panel"); } else { sb.Append("\n\n").Append(selectedInvention).Append(" : ").Append(selectedInvention.getDescription()); // invention available if (!Game.Player.isInvented(selectedInvention) && Game.Player.sciencePoints.get() >= selectedInvention.getCost().get()) { inventButton.GetComponentInChildren <Text>().text = "Invent " + selectedInvention.ToString(); inventButton.interactable = true; } else { inventButton.interactable = false; if (Game.Player.isInvented(selectedInvention)) { inventButton.GetComponentInChildren <Text>().text = "Already invented " + selectedInvention.ToString(); } else { inventButton.GetComponentInChildren <Text>().text = "Not enough Science points to invent " + selectedInvention.ToString(); } } } descriptionText.text = sb.ToString(); }