Update the project name and description

This commit is contained in:
Amine B. Hassouna
2018-11-20 17:51:16 +01:00
parent 3b227aeee9
commit 9a9d4df97a
3 changed files with 14 additions and 13 deletions

View File

@@ -44,7 +44,7 @@ sudo apt install codeblocks
```sh
# Create a folder for the Code::Blocks project
cd basic-c-sdl-project
cd basic-c-sdl-game
mkdir -p build/codeblocks
cd build/codeblocks
@@ -53,7 +53,7 @@ cmake ../.. -G "CodeBlocks - Unix Makefiles"
```
*Open the project:*<br>
Run Code::Blocks, and open the project in `basic-c-sdl-project/build/codeblocks`.<br>
Run Code::Blocks, and open the project in `basic-c-sdl-game/build/codeblocks`.<br>
Finally, build and run the project.
@@ -72,15 +72,15 @@ Offline package: https://www.eclipse.org/downloads/packages
```sh
# Create a folder for the Eclipse project outside this project
cd basic-c-sdl-project
mkdir ../eclipse-basic-c-sdl-project
cd ../eclipse-basic-c-sdl-project
cd basic-c-sdl-game
mkdir ../eclipse-basic-c-sdl-game
cd ../eclipse-basic-c-sdl-game
# Generate an Eclipse project
cmake ../basic-c-sdl-project -G "Eclipse CDT4 - Unix Makefiles"
cmake ../basic-c-sdl-game -G "Eclipse CDT4 - Unix Makefiles"
```
*Open the project:*<br>
Run Eclipse, and open the project in `eclipse-basic-c-sdl-project`.<br>
Run Eclipse, and open the project in `eclipse-basic-c-sdl-game`.<br>
Create a new run configuration: Go to `Run` &gt; `Run configurations` &gt;
`C\C++ Application` and specify the C/C++ Application using `Search Project...`<br>
Finally, build and run the project.

View File

@@ -1,6 +1,7 @@
# Basic C SDL project
# Basic C SDL game
This project is a basic C [SDL][] project that uses [CMake][] as a build system.
This project is a basic C [SDL][] game that uses [CMake][] as a build system.<br>
It shows how we can develop a basic grid-based game.
## Dependencies
@@ -29,8 +30,8 @@ sudo apt install libsdl2-image-dev libsdl2-ttf-dev libsdl2-gfx-dev
```sh
# Clone this repo
git clone https://gitlab.com/aminosbh/basic-c-sdl-project.git
cd basic-c-sdl-project
git clone https://gitlab.com/aminosbh/basic-c-sdl-game.git
cd basic-c-sdl-game
# Create a build folder
mkdir build
@@ -41,7 +42,7 @@ cmake ..
make
# Run
./basic-c-sdl-project
./basic-c-sdl-game
```
***Note:*** To use SDL2_image, SDL2_ttf or SDL2_gfx, you should uncomment

View File

@@ -52,7 +52,7 @@ int main(int argc, char* argv[])
}
// Create window
SDL_Window *window = SDL_CreateWindow("Basic C SDL project",
SDL_Window *window = SDL_CreateWindow("Basic C SDL game",
SDL_WINDOWPOS_UNDEFINED,
SDL_WINDOWPOS_UNDEFINED,
SCREEN_WIDTH, SCREEN_HEIGHT,