- Notifications
You must be signed in to change notification settings - Fork163
Game examples implemented as .NET console applications primarily for providing education and inspiration. :)
License
dotnet/dotnet-console-games
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
Game examples implemented as .NET console applications primarily for providing education and inspiration. :)
Recommendation
Play the games, pick a game you like, and try to code the game yourself from scratch.
| Game | *Weight | Notes |
|---|---|---|
| Guess A Number | 0 | |
| Rock Paper Scissors | 0 | |
| Dice Game | 0 | *Community Contribution |
| Flash Cards | 0 | |
| Quick Draw | 1 | |
| Tug Of War | 1 | |
| Whack A Mole | 1 | |
| Tic Tac Toe | 1 | |
| Simon | 1 | |
| Roll And Move | 1 | |
| Beep Pad | 1 | |
| Draw | 1 | |
| Tower Of Hanoi | 1 | |
| Clicker | 1 | |
| Hangman | 2 | |
| Lights Out | 2 | |
| Wordle | 2 | |
| Memory | 2 | |
| Connect 4 | 2 | |
| Minesweeper | 2 | |
| Wumpus World | 2 | |
| Rythm | 2 | |
| Type | 2 | |
| Drive | 2 | |
| Sliding Puzzle | 2 | |
| Snake | 3 | |
| Word Search | 3 | |
| Hurdles | 3 | |
| Pong | 3 | |
| Flappy Bird | 3 | |
| Oligopoly | 3 | *Community Contribution |
| Reversi | 3 | |
| Darts | 3 | |
| Yahtzee | 4 | |
| Tanks | 4 | |
| Helicopter | 4 | |
| 2048 | 4 | |
| Sudoku | 4 | |
| Mancala | 4 | |
| Bound | 4 | |
| Tents | 4 | |
| Battleship | 4 | |
| Checkers | 4 | *Community Contribution |
| Duck Hunt | 5 | *Community Contribution |
| Blackjack | 5 | |
| Fighter | 5 | |
| Maze | 5 | |
| PacMan | 5 | |
| Gravity | 5 | |
| Tetris | 5 | *Community Contribution |
| Shmup | 5 | |
| Role Playing Game | 6 | |
| Console Monsters | 7 | *Community Collaboration |
| First Person Shooter | 8 |
*Weight: A relative rating for how advanced the source code is.
*Community Contribution: Special thanks to everyone who contributed games!
*Community Collaboration: Games where multiple members of the community participated in the development!
You can play the games in your browser:
Hosted On GitHub Pages
Clone the repository ordownload the repository and unzip the contents.dotnet-console-games should build with any .NET build process, such as one of the following:
Visual Studio[Expand]
InstallVisual Studio if not already installed.
Run the games with the
Debug->Start Debugging(default hotkeyF5) option in the menu strip. You can switch games by right clicking the projects in the solution explorer and using theSet as Startup Projectoption.Note This is optional, buthere are some settings you can change in Visual Studio.
Visual Studio Code[Expand]
Install the.NET SDK if not already installed.
InstallVisual Studio Code if not already installed.
Open the
root folderof the repository in Visual Studio Code.Run the games using the
Start Debugginggreen triangle button (default hotkeyF5) in theRun and Debugtab. You can switch games in the drop down next to theStart Debuggingbutton.Note The following files are included in the repository:
.vscode/extensions.jsonrecommends Vistual Studio Code extension dependencies.vscode/launch.jsonincludes the configurations for debugging the examples.vscode/settings.jsonautomatically applies settings to the workspace.vscode/tasks.jsonincludes the commands to build the projectsNote You will be prompted to install the necessary Visual Studio Code extensions when you open the folder:
- ms-dotnettools.csharpC# support
Command Line[Expand]
Install the.NET SDK if not already installed.
Run the games using the
dotnet run --project <PROJECT>command where<PROJECT>is the file path to one of the.csprojfiles. For example, running thedotnet run --project Projects/Drive/Drive.csprojcommand from the root of the repository will run theDrivegame.
Beginner's Guide To Console Input In C#August 1, 2020
dotnet Console Games Tips And TricksApril 7, 2022
Want to show support? You can star the github repository.
Have any questions?Start a new discussion.
Find a bug or have a suggestion?Open an issue.
Want to chat with the developer(s)?Join the discord server.
Want to contribute?Look for open issues you can help with.
About
Game examples implemented as .NET console applications primarily for providing education and inspiration. :)
Topics
Resources
License
Code of conduct
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Uh oh!
There was an error while loading.Please reload this page.
