Hi Everyone...!!
Last Week, I Was Assigned A Project Of Building A Mine Sweeper Game In Console.!! I Start Working On It But I Don't Have Any Idea From Where Should I Get Started..!! I Want To Add Some Simple Graphics In My Game, But First I Want To Make Simple Game...!! For That Purpose, I Figure Out Some Task For The Project..!!
1) Make A Board On The Console (2x2, 4x4, 8x8, 16x16)
For That Purpose I Used The Following Code:
#include <iostream>
using namespace std;
int main()
{
for (int i = 0; i < 4; i++)
{
for (int j = 0; j < 4; j++)
{
i % 2 == 0 ? cout << " |" : cout << "---";
}
cout << endl;
}
return 0;
}
It Simply Prints The 4x4 Board On The Screen...!! Although, I Am Not Satisfied With The Pattren...!!
2) Now, After That I Wanted To Get Input From The Keyboard And Move The Cursor And I Did So By Using gotoxy()
Function..!!
But The Real Problem Is Get Started Now..!!
How Can I Restricted The Movement Of The Cursor And Determined At Which Point/Pixel User Hit Any Key..!! And That Area In Within The Range Also...!!
3) I Want To Add Some Graphics Also In The Game But As Far As I Know, Graphics In C++ Are Much More Difficult As Compared With Python, Java, C#...!! Is There Any Way To Learn About C++ Graphics Within 3-4 Weeks That Are Enough For This Game..!!
4) I Know The Following Topics Of C++
- Functions!
- Arrays!
- Vectors!
- Pointers!
- File Handling!
- Structure Programming!
- OOP (A Little Bit)
Thanks In Advance For Answering...!!