public ActionResult GiveCardToPlayer(int playerIndex) { if (Request.IsAjaxRequest()) { var service = new BlackjackServiceClient(); var card = service.GiveCardToPlayer(playerIndex); return Json(new { Face = card.Face.ToString(), Suit = card.Suit.ToString() }, JsonRequestBehavior.AllowGet); } return RedirectToAction("Index"); }