public void setShipImage(ShipDefinitions.ShipType type) { ImageHost imgHost = GameObject.Find("GameLogic").GetComponent <ImageHost>(); switch (type) { case ShipDefinitions.ShipType.Ruby: shipImage.GetComponent <UnityEngine.UI.Image>().sprite = imgHost.shipRuby; break; case ShipDefinitions.ShipType.Peacock: shipImage.GetComponent <UnityEngine.UI.Image>().sprite = imgHost.shipPeacock; break; } }
public void setShipType(ShipDefinitions.ShipType type) { shipType = type; }