Skip to content

AlemSnyder/Fun-Game

Fun-Game

I will be the reason copilot doesn't work.

Setup

Windows

  1. Install MSys2
  2. Install packages:
pacman -Su \
    base-devel \
    mingw-w64-x86_64-toolchain \
    mingw-w64-x86_64-cmake \
    mingw-w64-x86_64-ninja \
    mingw-w64-x86_64-glew \
    mingw-w64-x86_64-glfw \
    mingw-w64-x86_64-glm

Building

cd build
cmake -G Ninja .. -DCMAKE_BUILD_TYPE=Debug
ninja

Release

cd build
cmake -G Ninja .. -DCMAKE_BUILD_TYPE=Release

ninja
ninja package
ninja package_source

Profile

cd build
cmake -DCMAKE_CXX_FLAGS=-pg -DCMAKE_EXE_LINKER_FLAGS=-pg -DCMAKE_SHARED_LINKER_FLAGS=-pg -G Ninja .. -DCMAKE_BUILD_TYPE=Debug
ninja

./FunGame <args>
gprof ./FunGame gmon.out | gprof2dot | dot -Tsvg -o output.svg

To turn off

rm -rf build # or
cmake --fresh

gprof doesn't work with multi-threading. For that we can use perf.

perf record -ag ./FunGame Start # or any other commands
perf script report flamegraph # this will ask to download something
firefox flamegraph.html

Formatting

POSIX shells only

shopt -s extglob                   # For making ** apply to any number of dirs
clang-format src/**/*.{h,c}pp -i

Personally I like this one better:

git ls-files --exclude-standard | grep -E '\.(cpp|hpp|c|cc|cxx|hxx|ixx)$' | xargs clang-format -i

About

I am just practicing c++. Feel free to enjoy.

Resources

License

Unknown and 3 other licenses found

Licenses found

Unknown
LICENSE
Unknown
LICENSE-ARTWORK
CC-BY-4.0
LICENSE-GAMEPLAY
GPL-2.0
LICENSE-SOFTWARE

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors