MonsterData should be loading graphics from Resource Packs instead. This should solve the issues with Issue #70. Release Build 11566.

This commit is contained in:
sigonasr2 2024-09-17 13:28:01 -05:00
parent 669a267a67
commit 004f896953
8 changed files with 7 additions and 7 deletions

View File

@ -41,11 +41,13 @@ All rights reserved.
#include "DEFINES.h"
#include "safemap.h"
#include "Item.h"
#include "AdventuresInLestoria.h"
INCLUDE_DATA
INCLUDE_STRATEGY_DATA
INCLUDE_ANIMATION_DATA
INCLUDE_ITEM_DATA
INCLUDE_game
std::map<std::string,MonsterData>MONSTER_DATA;
@ -72,7 +74,7 @@ void MonsterData::InitializeMonsterData(){
if(!MonsterData::imgs.count(MonsterImgName)){
MonsterData::imgs[MonsterImgName]=NEW Renderable();
const rcode imgLoadResult=MonsterData::imgs[MonsterImgName]->Load("assets/monsters/commercial_assets/"+MonsterImgName+".png");
const rcode imgLoadResult{game->LoadResource(*MonsterData::imgs[MonsterImgName],"assets/monsters/commercial_assets/"+MonsterImgName+".png")};
if(imgLoadResult!=OK)ERR(std::format("WARNING! Image loading for Monster {} failed with result {}",MonsterImgName,int(imgLoadResult)));
}

View File

@ -39,7 +39,7 @@ All rights reserved.
#define VERSION_MAJOR 1
#define VERSION_MINOR 3
#define VERSION_PATCH 0
#define VERSION_BUILD 11565
#define VERSION_BUILD 11566
#define stringify(a) stringify_(a)
#define stringify_(a) #a

View File

@ -11,6 +11,7 @@ cp -R "Adventures in Lestoria/assets/backgrounds" bin/assets
rm -R bin/assets/backgrounds/commercial_assets
rm -R bin/assets/maps/commercial_assets
cp -R "Adventures in Lestoria/assets/monsters" bin/assets
rm -R bin/assets/monsters/commercial_assets
cp -R "Adventures in Lestoria/assets/music" bin/assets
rm -R bin/assets/music/commercial_assets
cp -R "Adventures in Lestoria/assets/npcs" bin/assets

View File

@ -11,6 +11,7 @@ cp -R "Adventures in Lestoria/assets/backgrounds" bin/assets
rm -R bin/assets/backgrounds/commercial_assets
rm -R bin/assets/maps/commercial_assets
cp -R "Adventures in Lestoria/assets/monsters" bin/assets
rm -R bin/assets/monsters/commercial_assets
cp -R "Adventures in Lestoria/assets/music" bin/assets
rm -R bin/assets/music/commercial_assets
cp -R "Adventures in Lestoria/assets/npcs" bin/assets

View File

@ -12,6 +12,7 @@ cp -R "Adventures in Lestoria/assets/backgrounds" bin/assets
rm -R bin/assets/backgrounds/commercial_assets
rm -R bin/assets/maps/commercial_assets
cp -R "Adventures in Lestoria/assets/monsters" bin/assets
rm -R bin/assets/monsters/commercial_assets
cp -R "Adventures in Lestoria/assets/music" bin/assets
rm -R bin/assets/music/commercial_assets
cp -R "Adventures in Lestoria/assets/npcs" bin/assets

View File

@ -1,5 +0,0 @@
git update-index --assume-unchanged "Adventures in Lestoria/packkey.cpp"
clear
source ./emsdk/emsdk_env.sh
emcmake cmake -DCMAKE_BUILD_TYPE=Debug -D_DEBUG=1 .
cmake --build . -j 20