Project Planning - ljackl/BubbleTrouble GitHub Wiki
Coding Standard
C++ Programming Style Guidelines
C++ Coding Standards Part 0: Automated Code Analysis
Braces {}
For this project we'll be using the following braces style
if (condition) {
...
}
This is based on the traditional Unix policy.
Naming Conventions
Overall aim to be descriptive and consistent
General Naming Conventions
For general variables camelCase preferred.
int savingsBalance;
bool isAlive;
Types start with capitals: MyClass
Functions and variables start with lower case: myMethod
Constants are all capital: const int PI=3.14159265358979323;
Comments
Single line comment blocks should use //
, not /* *
.
// this function does something
int myFunc()
{
...
}
To comment out blocks of code use /* *
.
/*
// this function does something
int myFunc()
{
...
}
*/
Formatting
- spaces preferred over tabs for indentation (use tab but save as spaces)
- 4 space characters per indent
Tutorials
Project Setup
Creating an SFML project on Mac OS using CLion and CMake
Environement Setup
SFML and Linux
SFML and Visual studio
Games Programming
SFML C++ Tutorial Series
Building your first SFML game project
Coding a simple Pong game with SFML