public ActionResult CreateAttention(int id) { Tama tamagotchi = Tama.Find(id); tamagotchi.Play(); return(View("Details", tamagotchi)); }
public ActionResult CreateAttention(int id) { Tama tamagotchi = Tama.Find(id); List <Tama> allTama = Tama.GetAll(); tamagotchi.Play(); Tama.CheckForDead(); return(tamagotchi.IsDead() ? RedirectToAction("Index", allTama) : RedirectToAction("Details", tamagotchi)); }