mirror of
https://codeberg.org/KeybadeBlox/JSRF-Decompilation.git
synced 2026-02-20 10:17:03 +03:00
Populate JSRF/GameData.cpp
This commit is contained in:
parent
cbcc22ec9d
commit
44a8d704ef
6 changed files with 476 additions and 24 deletions
|
|
@ -4,7 +4,363 @@ Save data and closely-related runtime data.
|
|||
|
||||
#pragma bss_seg(".data")
|
||||
|
||||
#include "../XDK/Win32.hpp"
|
||||
#include "GameData.hpp"
|
||||
|
||||
|
||||
GameData g_gameData = GameData();
|
||||
|
||||
|
||||
|
||||
// Address: 0x00039B50
|
||||
// Matching: no
|
||||
BOOL GameData::checkFlagCondition(unsigned cond) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039BE0
|
||||
// Matching: no
|
||||
void GameData::writeStateFlag(unsigned flagVal) {
|
||||
}
|
||||
|
||||
// Address: 0x00039C70
|
||||
// Matching: no
|
||||
void GameData::incrementChapter() {
|
||||
}
|
||||
|
||||
// Address: 0x00039C80
|
||||
// Matching: no
|
||||
void GameData::setMissionDigits34(unsigned val) {
|
||||
}
|
||||
|
||||
// Address: 0x00039C90
|
||||
// Matching: no
|
||||
void GameData::setSpawnPosIndex(unsigned val) {
|
||||
}
|
||||
|
||||
// Address: 0x00039CA0
|
||||
// Matching: no
|
||||
unsigned GameData::getSpawnPosIndex() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039CB0
|
||||
// Matching: no
|
||||
void GameData::unlockCharacter(unsigned charId) {
|
||||
}
|
||||
|
||||
// Address: 0x00039CF0
|
||||
// Matching: no
|
||||
void GameData::lockCharacter(unsigned charId) {
|
||||
}
|
||||
|
||||
// Address: 0x00039D10
|
||||
// Matching: no
|
||||
BOOL GameData::characterUnlocked(unsigned charId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039D40
|
||||
// Matching: no
|
||||
BOOL GameData::checkFlagConditions(unsigned * conds, unsigned count) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039D80
|
||||
// Matching: no
|
||||
void GameData::writeStateFlags(unsigned * writes, unsigned count) {
|
||||
}
|
||||
|
||||
// Address: 0x00039DB0
|
||||
// Matching: no
|
||||
BOOL GameData::checkFlagConditionUnpacked(FlagList flagList, unsigned index) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039DE0
|
||||
// Matching: no
|
||||
void GameData::writeStateFlagUnpacked(FlagList flagList, unsigned index, unsigned val) {
|
||||
}
|
||||
|
||||
// Address: 0x00039E10
|
||||
// Matching: no
|
||||
void GameData::setSoulSpawned(unsigned soulId) {
|
||||
}
|
||||
|
||||
// Address: 0x00039E40
|
||||
// Matching: no
|
||||
BOOL GameData::getSoulSpawned(unsigned soulId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039E80
|
||||
// Matching: no
|
||||
void GameData::setSoulCollected(unsigned soulId) {
|
||||
}
|
||||
|
||||
// Address: 0x00039EB0
|
||||
// Matching: no
|
||||
BOOL GameData::getSoulHeld(unsigned soulId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039EF0
|
||||
// Matching: no
|
||||
BOOL GameData::soulSpawnedUncollected(unsigned soulId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x00039F40
|
||||
// Matching: no
|
||||
void GameData::clearHeldSouls() {
|
||||
}
|
||||
|
||||
// Address: 0x00039F60
|
||||
// Matching: no
|
||||
void GameData::restoreHeldSouls() {
|
||||
}
|
||||
|
||||
// Address: 0x00039FD0
|
||||
// Matching: no
|
||||
unsigned GameData::getSoulCount() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A0A0
|
||||
// Matching: no
|
||||
unsigned GameData::getTotalSoulsInStage(unsigned stageId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A130
|
||||
// Matching: no
|
||||
unsigned GameData::getHeldSoulsInStage(unsigned stageId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A2B0
|
||||
// Matching: no
|
||||
BOOL GameData::getSoulCollectedBySize(TagSize size, unsigned index) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A2F0
|
||||
// Matching: no
|
||||
void GameData::setUnusedPerStageBitmask(unsigned stageId, unsigned index) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A340
|
||||
// Matching: no
|
||||
int GameData::getTagState(unsigned stageId, unsigned tagIndex, BOOL rivalTag) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A3A0
|
||||
// Matching: no
|
||||
void GameData::setTagState(unsigned stageId, unsigned tagIndex, BOOL rivalTag, unsigned val) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A400
|
||||
// Matching: no
|
||||
void GameData::setTagCovered(unsigned stageId, unsigned tagIndex, BOOL rivalTag, unsigned gangOrPlayer) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A4A0
|
||||
// Matching: no
|
||||
void GameData::setVolumeSettings(float volMusic, float volSfx) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A4C0
|
||||
// Matching: no
|
||||
void GameData::getVolumeSettings(float * outMusic, float * outSfx) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A4E0
|
||||
// Matching: no
|
||||
void GameData::setRumbleEnabled(BOOL val) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A4F0
|
||||
// Matching: no
|
||||
BOOL GameData::getRumbleEnabled() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A500
|
||||
// Matching: no
|
||||
void GameData::setGarageMusic(unsigned songId) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A510
|
||||
// Matching: no
|
||||
unsigned GameData::getGarageMusic() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A520
|
||||
// Matching: no
|
||||
void GameData::setUnusedBitfield(unsigned index) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A550
|
||||
// Matching: no
|
||||
void GameData::setMiscObjective(unsigned index) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A580
|
||||
// Matching: no
|
||||
BOOL GameData::getMiscObjective(unsigned index) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A5C0
|
||||
// Matching: no
|
||||
unsigned GameData::countMiscObjectives() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A690
|
||||
// Matching: no
|
||||
BOOL GameData::getHighScore(unsigned stageId, TestRunType type, unsigned rank, TestRunScore * out) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A750
|
||||
// Matching: no
|
||||
void GameData::incrementTimer(Timer timer) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A780
|
||||
// Matching: no
|
||||
unsigned GameData::getTimer(Timer timer) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A7B0
|
||||
// Matching: no
|
||||
void GameData::setTimer(Timer timer, unsigned frames) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A7F0
|
||||
// Matching: no
|
||||
void GameData::setSelectedTag(unsigned gangOrPlayer, TagSize size, unsigned tagId, BOOL multiplayer) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A820
|
||||
// Matching: no
|
||||
unsigned GameData::getSelectedTag(unsigned gangOrPlayer, TagSize size, BOOL multiplayer) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A840
|
||||
// Matching: no
|
||||
void GameData::setCustomTagSelected(unsigned gangOrPlayer, TagSize size, BOOL active, BOOL multiplayer) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A870
|
||||
// Matching: no
|
||||
BOOL GameData::getCustomTagSelected(unsigned gangOrPlayer, TagSize size, BOOL multiplayer) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A890
|
||||
// Matching: no
|
||||
void GameData::setEventSeen(unsigned eventId) {
|
||||
}
|
||||
|
||||
// Address: 0x0003A8C0
|
||||
// Matching: no
|
||||
BOOL GameData::eventSeen(unsigned eventId) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003A900
|
||||
// Matching: no
|
||||
void GameData::incrementPlaytime() {
|
||||
}
|
||||
|
||||
// Address: 0x0003A910
|
||||
// Matching: yes
|
||||
unsigned GameData::getSaveDataSize() {
|
||||
// 0x50 byte key + 0x3508 actual save data + 0x8 extra (why extra?)
|
||||
return 0x50 + sizeof this->saveActive + 0x8;
|
||||
}
|
||||
|
||||
// Address: 0x0003A920
|
||||
// Matching: no
|
||||
BOOL GameData::decrypt(char * saveData) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Address: 0x0003AB60
|
||||
// Matching: no
|
||||
void GameData::encrypt(char * outSaveData) {
|
||||
}
|
||||
|
||||
// Address: 0x0003AE00
|
||||
// Matching: no
|
||||
void GameData::getSaveDescription(SaveDescription * outDesc) {
|
||||
}
|
||||
|
||||
// Address: 0x0003AE20
|
||||
// Matching: no
|
||||
void GameData::clearStateFlags(FlagListOrPtr flagList) {
|
||||
}
|
||||
|
||||
// Address: 0x0003AEA0
|
||||
// Matching: no
|
||||
void GameData::resetTimer(Timer timer) {
|
||||
}
|
||||
|
||||
// Address: 0x0003AED0
|
||||
// Matching: no
|
||||
GameData::GameData() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B3C0
|
||||
// Matching: no
|
||||
void GameData::resetSelectedTags() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B420
|
||||
// Matching: no
|
||||
void GameData::resetExceptSettingsAndSouls() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B5A0
|
||||
// Matching: no
|
||||
void GameData::resetExceptSettingsAndHighScores() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B640
|
||||
// Matching: no
|
||||
void GameData::resetExceptSettings() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B680
|
||||
// Matching: no
|
||||
void GameData::stash() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B6A0
|
||||
// Matching: no
|
||||
void GameData::stashRestoreExceptSpecialFlags() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B6F0
|
||||
// Matching: no
|
||||
void GameData::stashRestoreExceptHighScores() {
|
||||
}
|
||||
|
||||
// Address: 0x0003B790
|
||||
// Matching: no
|
||||
void GameData::stashRestore() {
|
||||
}
|
||||
|
||||
// Optimized out
|
||||
GameData::~GameData() {}
|
||||
|
||||
// Address: 0x0003B7E0
|
||||
// Matching: no
|
||||
void GameData::addHighScore(unsigned stageId, TestRunType type, TestRunScore * score) {
|
||||
}
|
||||
|
|
|
|||
|
|
@ -96,6 +96,11 @@ struct TestRunScore {
|
|||
// Numeric IDs for different timers
|
||||
enum Timer { TIMER_DEATHBALLPRACTICE, TIMER_CLUTCH, TIMER_UNUSED };
|
||||
|
||||
// Info showed in save/load menu
|
||||
struct SaveDescription { unsigned chapter, playtimeSeconds; };
|
||||
|
||||
union FlagListOrPtr { FlagList list; unsigned * ptr; };
|
||||
|
||||
// Save data-ish data structure used at runtime
|
||||
extern struct GameData {
|
||||
SaveData saveActive;
|
||||
|
|
@ -137,7 +142,7 @@ extern struct GameData {
|
|||
unsigned getSoulCount ();
|
||||
unsigned getTotalSoulsInStage(unsigned stageId);
|
||||
unsigned getHeldSoulsInStage (unsigned stageId);
|
||||
unsigned setSoulCollectedBySize(TagSize size, unsigned index);
|
||||
BOOL getSoulCollectedBySize(TagSize size, unsigned index);
|
||||
void setUnusedPerStageBitmask(unsigned stageId, unsigned index);
|
||||
int getTagState (unsigned stageId, unsigned index, BOOL rivalTag);
|
||||
void setTagState (unsigned stageId, unsigned index, BOOL rivalTag, unsigned val);
|
||||
|
|
@ -156,9 +161,33 @@ extern struct GameData {
|
|||
void incrementTimer (Timer timer);
|
||||
unsigned getTimer (Timer timer);
|
||||
void setTimer (Timer timer, unsigned frames);
|
||||
void setSelectedTag (unsigned gangOrPlayer, TagSize size, unsigned tagId, BOOL multiplayer);
|
||||
unsigned getSelectedTag (unsigned gangOrPlayer, TagSize size, BOOL multiplayer);
|
||||
void setCustomTagSelected(unsigned gangOrPlayer, TagSize size, BOOL active, BOOL multiplayer);
|
||||
BOOL getCustomTagSelected(unsigned gangOrPlayer, TagSize size, BOOL multiplayer);
|
||||
void setEventSeen (unsigned eventId);
|
||||
BOOL eventSeen (unsigned eventId);
|
||||
void incrementPlaytime ();
|
||||
unsigned getSaveDataSize ();
|
||||
BOOL decrypt (char * saveData);
|
||||
void encrypt (char * outSaveData);
|
||||
void getSaveDescription (SaveDescription * outDesc);
|
||||
void clearStateFlags (FlagListOrPtr flags);
|
||||
void resetTimer (Timer timer);
|
||||
GameData();
|
||||
void resetSelectedTags ();
|
||||
|
||||
void resetExceptSettingsAndSouls ();
|
||||
void resetExceptSettingsAndHighScores();
|
||||
void resetExceptSettings ();
|
||||
|
||||
void stash ();
|
||||
void stashRestoreExceptSpecialFlags();
|
||||
void stashRestoreExceptHighScores ();
|
||||
void stashRestore ();
|
||||
|
||||
GameData();
|
||||
virtual ~GameData();
|
||||
void addHighScore(unsigned stageId, TestRunType type, TestRunScore * score);
|
||||
} g_gameData;
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue