Exemple #1
0
        public ActionResult AlienTravelResult(AlienTransportEnterModel model)
        {
            AlienTransportViewModel resultModel = new AlienTransportViewModel();

            resultModel.ModeOfTransport = model.ModeOfTransport;
            resultModel.Planet          = model.Planet;
            resultModel.TravelTime      = Planets.CalculateTravelTime(model.Planet, model.ModeOfTransport);
            resultModel.DestinationAge  = Planets.CalculateArrivalAge(model.EarthAge, resultModel.TravelTime);

            return(View("AlienTravelResult", resultModel));
        }