public TwentyFiveBanksUpgrade(BankBuilding cursorBuilding, string name, double price, bool isShownIcon, bool isBought) : base(name, price, isShownIcon, isBought) { this.bankBuilding = cursorBuilding; Description = "Banks are twice as efficient."; PrepareImage(); }
public ActionResult Create(BankBuilding bankBuilding) { if (ModelState.IsValid) { var index = db.BankBuildings.Max(x => x.id); var bank = db.BankBuildings.Find(index); bankBuilding.CurrentPrices += bank.CurrentPrices; db.BankBuildings.Add(bankBuilding); db.SaveChanges(); return(RedirectToAction("Index")); } return(View(bankBuilding)); }
public BankUpgrades(BankBuilding bankBuilding, bool isContinueClicker) { this.isContinueClicker = isContinueClicker; this.bankBuilding = bankBuilding; InitializeUpgrades(); allUpgrades = new List <Upgrade>(); allUpgrades.Add(fiveFarmsUpgrade); allUpgrades.Add(fifteenFarmsUpgrade); allUpgrades.Add(twentyFiveFarmsUpgrade); allUpgrades.Add(fiftyFarmsUpgrade); allUpgrades.Add(seventyFiveFarmsUpgrade); allUpgrades.Add(oneHundredFarmsUpgrade); allUpgrades.Add(oneHundredFiftyFarmsUpgrade); }