Fix Linux build and implementations with new systems and C++20 features
Co-authored-by: sigonasr2 <sigonasr2@gmail.com>
This commit is contained in:
parent
92ac7e5cf8
commit
5c73ed6cd3
3
.gitignore
vendored
3
.gitignore
vendored
@ -28,7 +28,7 @@ memoryleak.txt
|
|||||||
[Dd]ebugPublic/
|
[Dd]ebugPublic/
|
||||||
*.tlog/
|
*.tlog/
|
||||||
Crawler/x64/
|
Crawler/x64/
|
||||||
Crawler/assets/saves/
|
Crawler/assets/saves/*
|
||||||
[Rr]eleases/
|
[Rr]eleases/
|
||||||
x86/
|
x86/
|
||||||
[Ww][Ii][Nn]32/
|
[Ww][Ii][Nn]32/
|
||||||
@ -381,3 +381,4 @@ Crawler/pixelGameEngine_wasm.o
|
|||||||
/CMakeCache.txt
|
/CMakeCache.txt
|
||||||
/cmake_install.cmake
|
/cmake_install.cmake
|
||||||
/Makefile
|
/Makefile
|
||||||
|
Crawler/out
|
||||||
|
@ -30,7 +30,7 @@ CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
|
|||||||
ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||||
SUCH DAMAGE.
|
SUCH DAMAGE.
|
||||||
|
|
||||||
Portions of this software are copyright © 2023 The FreeType
|
Portions of this software are copyright <EFBFBD> 2023 The FreeType
|
||||||
Project (www.freetype.org). Please see LICENSE_FT.txt for more information.
|
Project (www.freetype.org). Please see LICENSE_FT.txt for more information.
|
||||||
All rights reserved.
|
All rights reserved.
|
||||||
*/
|
*/
|
||||||
@ -96,10 +96,11 @@ public:
|
|||||||
return get_readOnly(ItemAttribute::Get(a));
|
return get_readOnly(ItemAttribute::Get(a));
|
||||||
}
|
}
|
||||||
inline const float&get_readOnly(const ItemAttribute&a)const{
|
inline const float&get_readOnly(const ItemAttribute&a)const{
|
||||||
|
static float DEFAULT=0;
|
||||||
if(attributes.count(a)){
|
if(attributes.count(a)){
|
||||||
return attributes.at(a);
|
return attributes.at(a);
|
||||||
}
|
}
|
||||||
return 0;
|
return DEFAULT;
|
||||||
}
|
}
|
||||||
inline auto begin()const{
|
inline auto begin()const{
|
||||||
return attributes.begin();
|
return attributes.begin();
|
||||||
|
@ -4,4 +4,4 @@ debug.sh:8125f303032b6cbc137223df63d10096 -
|
|||||||
lines.sh:3b907786f7fc9204025993016c9080de -
|
lines.sh:3b907786f7fc9204025993016c9080de -
|
||||||
release.sh:b1ce8461a303e8e7aa9ed74259db3873 -
|
release.sh:b1ce8461a303e8e7aa9ed74259db3873 -
|
||||||
temp:d41d8cd98f00b204e9800998ecf8427e -
|
temp:d41d8cd98f00b204e9800998ecf8427e -
|
||||||
web.sh:cd3b8a99e208244dee7576bc23c0dc80 -
|
web.sh:1adf54f3c200922572a24573a0998110 -
|
||||||
|
@ -12,12 +12,12 @@ source ../emsdk/emsdk_env.sh
|
|||||||
if [ ! -f "pixelGameEngine_wasm.o" ]
|
if [ ! -f "pixelGameEngine_wasm.o" ]
|
||||||
then
|
then
|
||||||
printf "Pixel Game Engine compile object missing. Compiling for the first time..."
|
printf "Pixel Game Engine compile object missing. Compiling for the first time..."
|
||||||
em++ -std=c++20 -O2 ${EMSCRIPTEN_CUSTOM_PARAMS} -s ALLOW_MEMORY_GROWTH=1 -s MAXIMUM_MEMORY=4GB -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 -c pixelGameEngine.cpp -o pixelGameEngine_wasm.o
|
em++ -std=c++20 -O2 ${EMSCRIPTEN_CUSTOM_PARAMS} -s ALLOW_MEMORY_GROWTH=1 -s MAXIMUM_MEMORY=4GB -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 -s USE_FREETYPE=1 -c pixelGameEngine.cpp -o pixelGameEngine_wasm.o
|
||||||
fi
|
fi
|
||||||
if [ -d "assets" ]; then
|
if [ -d "assets" ]; then
|
||||||
em++ -std=c++20 -O2 ${EMSCRIPTEN_CUSTOM_PARAMS} -s ALLOW_MEMORY_GROWTH=1 -s MAXIMUM_MEMORY=4GB -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 $(find . -type f -name "*.cpp" -not -path "./test/*" -not -name "pixelGameEngine.cpp") pixelGameEngine_wasm.o -o ${PROJECT_NAME}.html --preload-file ./assets
|
em++ -std=c++20 -O2 ${EMSCRIPTEN_CUSTOM_PARAMS} -s ALLOW_MEMORY_GROWTH=1 -s MAXIMUM_MEMORY=4GB -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 -s USE_FREETYPE=1 $(find . -type f -name "*.cpp" -not -path "./test/*" -not -name "pixelGameEngine.cpp") pixelGameEngine_wasm.o -o ${PROJECT_NAME}.html --preload-file ./assets
|
||||||
else
|
else
|
||||||
em++ -std=c++20 -O2 ${EMSCRIPTEN_CUSTOM_PARAMS} -s ALLOW_MEMORY_GROWTH=1 -s MAXIMUM_MEMORY=4GB -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 $(find . -type f -name "*.cpp" -not -path "./test/*" -not -name "pixelGameEngine.cpp") pixelGameEngine_wasm.o -o ${PROJECT_NAME}.html
|
em++ -std=c++20 -O2 ${EMSCRIPTEN_CUSTOM_PARAMS} -s ALLOW_MEMORY_GROWTH=1 -s MAXIMUM_MEMORY=4GB -s MAX_WEBGL_VERSION=2 -s MIN_WEBGL_VERSION=2 -s USE_SDL_MIXER=2 -s USE_LIBPNG=1 -s USE_FREETYPE=1 $(find . -type f -name "*.cpp" -not -path "./test/*" -not -name "pixelGameEngine.cpp") pixelGameEngine_wasm.o -o ${PROJECT_NAME}.html
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cp buildtemplate.html ${PROJECT_NAME}.html
|
cp buildtemplate.html ${PROJECT_NAME}.html
|
||||||
|
BIN
Crawler/Crawler
BIN
Crawler/Crawler
Binary file not shown.
@ -57,11 +57,9 @@ class ScrollableWindowComponent;
|
|||||||
#define STARTING_DEPTH 999999
|
#define STARTING_DEPTH 999999
|
||||||
|
|
||||||
enum MenuType{
|
enum MenuType{
|
||||||
#pragma region Enum Start //DO NOT REMOVE
|
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
/*DO NOT REMOVE!!*/ENUM_START,///////////////////////////////
|
/*DO NOT REMOVE!!*/ENUM_START,///////////////////////////////
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
#pragma endregion
|
|
||||||
INVENTORY_CONSUMABLES,
|
INVENTORY_CONSUMABLES,
|
||||||
CLASS_INFO,
|
CLASS_INFO,
|
||||||
CLASS_SELECTION,
|
CLASS_SELECTION,
|
||||||
@ -81,11 +79,9 @@ enum MenuType{
|
|||||||
CONSUMABLE_CRAFT_ITEM,
|
CONSUMABLE_CRAFT_ITEM,
|
||||||
SAVE_FILE_NAME,
|
SAVE_FILE_NAME,
|
||||||
LOAD_GAME,
|
LOAD_GAME,
|
||||||
#pragma region Enum End //DO NOT REMOVE
|
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
/*DO NOT REMOVE!!*/ENUM_END////////////////////////////////
|
/*DO NOT REMOVE!!*/ENUM_END////////////////////////////////
|
||||||
///////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////
|
||||||
#pragma endregion
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class Menu:public IAttributable{
|
class Menu:public IAttributable{
|
||||||
|
0
Crawler/assets/saves/metadata.dat
Normal file
0
Crawler/assets/saves/metadata.dat
Normal file
@ -7,6 +7,11 @@
|
|||||||
#include <dxgi.h>
|
#include <dxgi.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include <cstdint>
|
||||||
|
|
||||||
|
#undef None
|
||||||
|
#undef Status
|
||||||
|
|
||||||
namespace discord {
|
namespace discord {
|
||||||
|
|
||||||
enum class Result {
|
enum class Result {
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include "types.h"
|
#include "types.h"
|
||||||
|
#include <cstdint>
|
||||||
|
|
||||||
namespace discord {
|
namespace discord {
|
||||||
|
|
||||||
|
@ -3,7 +3,7 @@ export AUTO_UPDATE=true
|
|||||||
source utils/define.sh
|
source utils/define.sh
|
||||||
|
|
||||||
define PROJECT_NAME "Crawler"
|
define PROJECT_NAME "Crawler"
|
||||||
define CUSTOM_PARAMS "-I/usr/include/freetype2 -I/usr/include/libpng16 -std=c++20 -lGL -lX11 -lpthread -lpng -lstdc++fs -lfreetype -I/usr/include/lua5.3"
|
define CUSTOM_PARAMS "-Idiscord-files -I/usr/include/freetype2 -I/usr/include/libpng16 -std=c++20 -lGL -lX11 -lpthread -lpng -lstdc++fs -lfreetype -I/usr/include/lua5.3 ./discord_game_sdk.so"
|
||||||
define EMSCRIPTEN_CUSTOM_PARAMS "-s MAXIMUM_MEMORY=4GB"
|
define EMSCRIPTEN_CUSTOM_PARAMS "-s MAXIMUM_MEMORY=4GB"
|
||||||
define LANGUAGE "C++"
|
define LANGUAGE "C++"
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user