Emscripten compatibility fixes.

This commit is contained in:
2024-03-29 21:04:55 -05:00
parent 826aae50f0
commit 282f918d1d
8 changed files with 49 additions and 46 deletions
@@ -51,7 +51,7 @@ All rights reserved.
#include "ProgressBar.h"
#include "MenuItemLabel.h"
#ifndef __EMSCRIPTEN__
#include <isteamuserstats.h>
#include "steam/isteamuserstats.h"
#endif
INCLUDE_game
@@ -103,16 +103,14 @@ namespace CharacterMenuWindow{
if(SelectedEquipIsDifferent(comp)){ //If we find that the opposite ring slot is equipped to us, this would be an item swap or the exact same ring, therefore no stat calculations apply.
Inventory::EquipItem(comp.lock()->GetItem(),EquipSlot(comp.lock()->I(Attribute::EQUIP_TYPE)));
#pragma region Achievement Stuff
if(SteamUserStats()){
#pragma region Fully Decked Out Achievement
#pragma region Fully Decked Out Achievement
STEAMUSERSTATS(
datafile&unlock=DATA.GetProperty("Achievement.Equip Unlocks.Fully Decked Out");
if(Inventory::EquipsFullyMaxedOut(unlock["Weapon Max Level"].GetInt(),unlock["Armor Max Level"].GetInt())){
SteamUserStats()->SetAchievement(unlock["API Name"].GetString().c_str());
SteamUserStats()->StoreStats();
}
#pragma endregion
}
)
#pragma endregion
if(Menu::IsCurrentlyActive(data.menu.GetType())){