Advertisement
Guest User

Untitled

a guest
Sep 23rd, 2019
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.61 KB | None | 0 0
  1. using System;
  2.  
  3. namespace ConsoleApp1
  4. {
  5. class Program
  6. {
  7. static void Main(string[] args)
  8. {
  9. /* LOOP
  10. * draw some stuff
  11. * get some input
  12. * do some simulation
  13. * decide if we should quit
  14. * loop again
  15. * */
  16.  
  17. bool shouldQuit = false;
  18. int turnNumber = 0;
  19. // < <= > >= == !=
  20.  
  21. // Boolean operators
  22. // && AND
  23. // || OR
  24. // ! NOT
  25. // Operate on a boolean value
  26. // ! negates the boolean value, so true becomes false, false becomes true
  27.  
  28. int arrowCount = 0;
  29. int arrowIncrease = 1;
  30. // Press a key to spend all your arrows.
  31. // Now every turn you make more arrows based on the number of arrows you just spent.
  32.  
  33. // Come up with a game, using this basic format, or keeping track of the turn number (maybe some other stuff)
  34. // printing out based on the state of the game
  35. // responding to inputs
  36.  
  37. // Scope and variable declarations
  38.  
  39. while (!shouldQuit)
  40. {
  41. Console.Clear();
  42. Console.WriteLine("Hey gamer.");
  43. Console.WriteLine("Turn number is " + turnNumber);
  44.  
  45.  
  46. ConsoleKey k = Console.ReadKey(true).Key;
  47.  
  48.  
  49.  
  50. if (k == ConsoleKey.Escape)
  51. {
  52. shouldQuit = true;
  53. }
  54.  
  55. turnNumber = turnNumber + 1;
  56. }
  57.  
  58. Console.WriteLine("Goodbye World!");
  59. }
  60. }
  61. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement