// Author: Trenton Plager /// <summary> /// A helper method that cooks food depending on the current burner it is on /// </summary> /// <param name="currentFood">The food that needs to be cooked</param> /// <param name="burner">The burner that the food is on</param> public void CookFoodHelper(CookableObject currentFood, StoveLocation burner) { int burnerTemp = stoveTemps.GetBurnerTemp(burner); switch (burnerTemp) { case 1: currentFood.Cook(timeToSkip * currentFood.LowHeatMultiplier); break; case 2: currentFood.Cook(timeToSkip * currentFood.MediumHeatMultiplier); break; case 3: currentFood.Cook(timeToSkip * currentFood.HighHeatMultiplier); break; } }
// Author: Trenton Plager /// <summary> /// Returns the temp of the passed-in burner /// </summary> /// <param name="burner">The burner to return the temp of</param> /// <returns></returns> public int GetBurnerTemp(StoveLocation burner) { switch (burner) { case StoveLocation.BottomLeftBurner: return(burnerBL); case StoveLocation.BottomRightBurner: return(burnerBR); case StoveLocation.TopLeftBurner: return(burnerTL); case StoveLocation.TopRightBurner: return(burnerTR); default: return(0); } }