static void Main() { if (SimplePlatform.runningPlatform() != SimplePlatform.Platform.Windows) { return; } Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(new frmMain()); }
public int GetPrice(SimplePlatform platform) { var price = -1; switch (tapState.State) { case TapState.TypeOfTap.Wall: price = PriceForWall(platform); break; case TapState.TypeOfTap.Spike: price = PriceForSpikes(platform); break; case TapState.TypeOfTap.Return: price = PriceForReturn(platform); break; } return(price); }
private int PriceForWall(SimplePlatform platform) => (4 - platform.indexOfLayer) * turn / 5 + platform.WallAmount;
private int PriceForReturn(SimplePlatform platform) => (4 - platform.indexOfLayer) * turn / 2;
private int PriceForSpikes(SimplePlatform platform) => (4 - platform.indexOfLayer) + platform.SpikesAmount * 3 / 2;