|
|
|
@ -1,9 +1,9 @@ |
|
|
|
|
#Compiles emscripten instance of this project for the web. |
|
|
|
|
#C++ |
|
|
|
|
if [ -d "assets" ]; then |
|
|
|
|
em++ -std=c++17 -O2 -s ALLOW_MEMORY_GROWTH=1 -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_LIBPNG=1 $(find . -type f -name "*.cpp") -o ${PROJECT_NAME}.html -I pixelGameEngine.h --preload-file ./assets |
|
|
|
|
em++ -std=c++17 -O2 -s ALLOW_MEMORY_GROWTH=1 -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 $(find . -type f -name "*.cpp") -o ${PROJECT_NAME}.html -I pixelGameEngine.h --preload-file ./assets |
|
|
|
|
else |
|
|
|
|
em++ -std=c++17 -O2 -s ALLOW_MEMORY_GROWTH=1 -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_LIBPNG=1 $(find . -type f -name "*.cpp") -o ${PROJECT_NAME}.html -I pixelGameEngine.h |
|
|
|
|
em++ -std=c++17 -O2 -s ALLOW_MEMORY_GROWTH=1 -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 $(find . -type f -name "*.cpp") -o ${PROJECT_NAME}.html -I pixelGameEngine.h |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
cp buildtemplate.html ${PROJECT_NAME}.html |
|
|
|
@ -15,3 +15,4 @@ if [ "$1" == "headless" ]; then |
|
|
|
|
else |
|
|
|
|
emrun --serve_after_close ${PROJECT_NAME}.html |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|