Skip to content

Code style and formatting

kiwipuppeh edited this page Oct 22, 2015 · 1 revision

Code style and formatting

For consistency reasons, everyone should follow this code format.

  • No brackets on the same line (unless it's a 1-liner, but then most of the time you can omit the braces in C#/C++)
  • Every variable declared must have a scope identifier, and be in upper camel case.

s_ - Current Scope, normally this means "within the current function"

m_ - Class Member

l_ - Looped variable

p_ - Function Parameter

All code should be commented, but if you write things clear enough there shouldn't be any need for comments, but still document your code. You never know what you were thinking a few months ago, or if someone else has to pick up the project. I know that people are normally bad at this, but hey, spending a few minutes now will save you hours of work later.

Clone this wiki locally