public override void OnEnable() { base.OnEnable(); foreach (CanTelePortTo tele in telePorts) { if (!tele.Know) { string desc = $"Unlock teleport to\nWorld: {tele.World}\nMap: {tele.Map}"; void Action() { tele.Unlock(); OnEnable(); } BuySerciveInfo buySercive = new BuySerciveInfo("Teleport location", desc, 1000f, Action); wares.BuyServices(buySercive); } } }
public void BuyServices(BuySerciveInfo serciveInfo) => Instantiate(service, container).Setup(serciveInfo);
public void Setup(BuySerciveInfo serciveInfo) => Setup(serciveInfo.Title, serciveInfo.Desc, serciveInfo.Price, serciveInfo.Action);