--check: 938/3256 method bodies compile for x86_64 (28.8%), 32-bit layout asserts hold; boot path 3/626 curated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
58 lines
1.9 KiB
C++
58 lines
1.9 KiB
C++
#include "classes.h"
|
|
|
|
// 005b1530
|
|
uint8_t Card::IsCard()
|
|
{
|
|
int temp_5f0a49bdf4;
|
|
|
|
temp_5f0a49bdf4 = *GHIDRA_CAST<int *>((GHIDRA_CAST<char *>(this) + 0x58));
|
|
if ((((temp_5f0a49bdf4 == 0) || (temp_5f0a49bdf4 == 1)) || (temp_5f0a49bdf4 == 3)) ||
|
|
(temp_5f0a49bdf4 == 5)) {
|
|
return 1;
|
|
}
|
|
return 0;
|
|
}
|
|
|
|
// 005b1550
|
|
uint8_t Card::IsRune()
|
|
{
|
|
return *GHIDRA_CAST<int *>((GHIDRA_CAST<char *>(this) + 0x58)) == 2;
|
|
}
|
|
|
|
// 00730aa0
|
|
uint32_t Card::IsAvailable()
|
|
{
|
|
Entity_Player *achievementID;
|
|
undefined3 extraout_var;
|
|
int *in_ECX;
|
|
Game *game;
|
|
uint8_t isUnlocked;
|
|
|
|
game = g_game;
|
|
if (g_game != GHIDRA_CAST<Game *>(0x0)) {
|
|
if (((char)in_ECX[0x14] == '\0') &&
|
|
((achievementID = GHIDRA_CAST<Entity_Player *>(g_game->_difficulty), achievementID == GHIDRA_CAST<Entity_Player *>(0x2)
|
|
|| (achievementID == GHIDRA_CAST<Entity_Player *>(0x3))))) goto LAB_00730af6;
|
|
if (*in_ECX == 0x2e) {
|
|
achievementID = (GHIDRA_CAST<PlayerManager *>((&g_game->_playerManager)))->PlayerManager::FirstPlayerByType(0x13);
|
|
if (achievementID != GHIDRA_CAST<Entity_Player *>(0x0)) goto LAB_00730af6;
|
|
}
|
|
if (1 < *GHIDRA_CAST<int *>(&game->_deathmatchManager)) {
|
|
achievementID =
|
|
(Entity_Player *)
|
|
(**(code **)(**GHIDRA_CAST<int **>(&(*GHIDRA_CAST<uint8_t *>((GHIDRA_CAST<char *>(&((game->_deathmatchManager))) + 0xc)))) + 0x24))(*in_ECX);
|
|
if ((char)achievementID != '\0') goto LAB_00730af6;
|
|
}
|
|
}
|
|
achievementID = GHIDRA_CAST<Entity_Player *>(in_ECX[1]);
|
|
if (-1 < GHIDRA_INT(achievementID)) {
|
|
isUnlocked = (GHIDRA_CAST<PersistentGameData *>((&g_manager->_persistentGameData)))->PersistentGameData::Unlocked(GHIDRA_INT(achievementID));
|
|
achievementID = GHIDRA_CAST<Entity_Player *>(CONCAT31(extraout_var,isUnlocked));
|
|
if (isUnlocked == 0) {
|
|
LAB_00730af6:
|
|
return GHIDRA_UINT(achievementID) & 0xffffff00;
|
|
}
|
|
}
|
|
return CONCAT31((int3)(GHIDRA_UINT(achievementID) >> 8),1);
|
|
}
|