mirror of https://github.com/PrimeDecomp/prime.git
Match CMemoryCardDriver::ImportPersistentOptions
This commit is contained in:
parent
8487d3751b
commit
46335059ec
|
@ -480,7 +480,7 @@ ExportPersistentOptions__17CMemoryCardDriverFv:
|
||||||
/* 8024C7FC 0024975C 48 0F 29 D1 */ bl __ct__15CMemoryInStreamFPCvUl
|
/* 8024C7FC 0024975C 48 0F 29 D1 */ bl __ct__15CMemoryInStreamFPCvUl
|
||||||
/* 8024C800 00249760 38 61 00 B8 */ addi r3, r1, 0xb8
|
/* 8024C800 00249760 38 61 00 B8 */ addi r3, r1, 0xb8
|
||||||
/* 8024C804 00249764 38 81 00 08 */ addi r4, r1, 8
|
/* 8024C804 00249764 38 81 00 08 */ addi r4, r1, 8
|
||||||
/* 8024C808 00249768 4B F8 91 61 */ bl __ct__14CSystemOptionsFRC12CInputStream
|
/* 8024C808 00249768 4B F8 91 61 */ bl __ct__14CSystemOptionsFR12CInputStream
|
||||||
/* 8024C80C 0024976C 80 6D A0 80 */ lwz r3, gpGameState@sda21(r13)
|
/* 8024C80C 0024976C 80 6D A0 80 */ lwz r3, gpGameState@sda21(r13)
|
||||||
/* 8024C810 00249770 38 81 00 B8 */ addi r4, r1, 0xb8
|
/* 8024C810 00249770 38 81 00 B8 */ addi r4, r1, 0xb8
|
||||||
/* 8024C814 00249774 4B F8 74 F5 */ bl ExportPersistentOptions__10CGameStateFRC14CSystemOptions
|
/* 8024C814 00249774 4B F8 74 F5 */ bl ExportPersistentOptions__10CGameStateFRC14CSystemOptions
|
||||||
|
@ -523,7 +523,7 @@ ImportPersistentOptions__17CMemoryCardDriverFv:
|
||||||
/* 8024C89C 002497FC 48 0F 29 31 */ bl __ct__15CMemoryInStreamFPCvUl
|
/* 8024C89C 002497FC 48 0F 29 31 */ bl __ct__15CMemoryInStreamFPCvUl
|
||||||
/* 8024C8A0 00249800 38 61 00 2C */ addi r3, r1, 0x2c
|
/* 8024C8A0 00249800 38 61 00 2C */ addi r3, r1, 0x2c
|
||||||
/* 8024C8A4 00249804 38 81 00 08 */ addi r4, r1, 8
|
/* 8024C8A4 00249804 38 81 00 08 */ addi r4, r1, 8
|
||||||
/* 8024C8A8 00249808 4B F8 90 C1 */ bl __ct__14CSystemOptionsFRC12CInputStream
|
/* 8024C8A8 00249808 4B F8 90 C1 */ bl __ct__14CSystemOptionsFR12CInputStream
|
||||||
/* 8024C8AC 0024980C 80 6D A0 80 */ lwz r3, gpGameState@sda21(r13)
|
/* 8024C8AC 0024980C 80 6D A0 80 */ lwz r3, gpGameState@sda21(r13)
|
||||||
/* 8024C8B0 00249810 38 81 00 2C */ addi r4, r1, 0x2c
|
/* 8024C8B0 00249810 38 81 00 2C */ addi r4, r1, 0x2c
|
||||||
/* 8024C8B4 00249814 4B F8 76 19 */ bl ImportPersistentOptions__10CGameStateFRC14CSystemOptions
|
/* 8024C8B4 00249814 4B F8 76 19 */ bl ImportPersistentOptions__10CGameStateFRC14CSystemOptions
|
||||||
|
|
|
@ -666,7 +666,7 @@ ReadSystemOptions__10CGameStateFR12CInputStream:
|
||||||
/* 801D404C 001D0FAC 93 E1 00 EC */ stw r31, 0xec(r1)
|
/* 801D404C 001D0FAC 93 E1 00 EC */ stw r31, 0xec(r1)
|
||||||
/* 801D4050 001D0FB0 7C 7F 1B 78 */ mr r31, r3
|
/* 801D4050 001D0FB0 7C 7F 1B 78 */ mr r31, r3
|
||||||
/* 801D4054 001D0FB4 38 61 00 08 */ addi r3, r1, 8
|
/* 801D4054 001D0FB4 38 61 00 08 */ addi r3, r1, 8
|
||||||
/* 801D4058 001D0FB8 48 00 19 11 */ bl __ct__14CSystemOptionsFRC12CInputStream
|
/* 801D4058 001D0FB8 48 00 19 11 */ bl __ct__14CSystemOptionsFR12CInputStream
|
||||||
/* 801D405C 001D0FBC 38 7F 00 A8 */ addi r3, r31, 0xa8
|
/* 801D405C 001D0FBC 38 7F 00 A8 */ addi r3, r31, 0xa8
|
||||||
/* 801D4060 001D0FC0 38 81 00 08 */ addi r4, r1, 8
|
/* 801D4060 001D0FC0 38 81 00 08 */ addi r4, r1, 8
|
||||||
/* 801D4064 001D0FC4 4B E2 F9 69 */ bl __as__14CSystemOptionsFRC14CSystemOptions
|
/* 801D4064 001D0FC4 4B E2 F9 69 */ bl __as__14CSystemOptionsFRC14CSystemOptions
|
||||||
|
@ -2501,8 +2501,8 @@ lbl_801D5954:
|
||||||
/* 801D5960 001D28C0 38 21 00 A0 */ addi r1, r1, 0xa0
|
/* 801D5960 001D28C0 38 21 00 A0 */ addi r1, r1, 0xa0
|
||||||
/* 801D5964 001D28C4 4E 80 00 20 */ blr
|
/* 801D5964 001D28C4 4E 80 00 20 */ blr
|
||||||
|
|
||||||
.global __ct__14CSystemOptionsFRC12CInputStream
|
.global __ct__14CSystemOptionsFR12CInputStream
|
||||||
__ct__14CSystemOptionsFRC12CInputStream:
|
__ct__14CSystemOptionsFR12CInputStream:
|
||||||
/* 801D5968 001D28C8 94 21 FF 60 */ stwu r1, -0xa0(r1)
|
/* 801D5968 001D28C8 94 21 FF 60 */ stwu r1, -0xa0(r1)
|
||||||
/* 801D596C 001D28CC 7C 08 02 A6 */ mflr r0
|
/* 801D596C 001D28CC 7C 08 02 A6 */ mflr r0
|
||||||
/* 801D5970 001D28D0 90 01 00 A4 */ stw r0, 0xa4(r1)
|
/* 801D5970 001D28D0 90 01 00 A4 */ stw r0, 0xa4(r1)
|
||||||
|
|
|
@ -29,6 +29,9 @@ public:
|
||||||
CAssetId CurrentWorldAssetId();
|
CAssetId CurrentWorldAssetId();
|
||||||
void WriteBackupBuf();
|
void WriteBackupBuf();
|
||||||
|
|
||||||
|
void ImportPersistentOptions(const CSystemOptions&);
|
||||||
|
void ExportPersistentOptions(CSystemOptions&);
|
||||||
|
|
||||||
CSystemOptions& SystemOptions() { return xa8_systemOptions; }
|
CSystemOptions& SystemOptions() { return xa8_systemOptions; }
|
||||||
CGameOptions& GameOptions() { return x17c_gameOptions; }
|
CGameOptions& GameOptions() { return x17c_gameOptions; }
|
||||||
CHintOptions& HintOptions() { return x1f8_hintOptions; }
|
CHintOptions& HintOptions() { return x1f8_hintOptions; }
|
||||||
|
|
|
@ -12,6 +12,8 @@
|
||||||
class CSystemOptions {
|
class CSystemOptions {
|
||||||
public:
|
public:
|
||||||
CSystemOptions();
|
CSystemOptions();
|
||||||
|
explicit CSystemOptions(CInputStream&);
|
||||||
|
~CSystemOptions();
|
||||||
|
|
||||||
void SetHasFusion(bool v);
|
void SetHasFusion(bool v);
|
||||||
bool GetHasFusion() const { return xd0_28_fusionSuitActive; }
|
bool GetHasFusion() const { return xd0_28_fusionSuitActive; }
|
||||||
|
|
|
@ -741,7 +741,11 @@ void CMemoryCardDriver::BuildExistingFileSlot(int saveIdx) {
|
||||||
gpGameState->WriteSystemOptions(w);
|
gpGameState->WriteSystemOptions(w);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CMemoryCardDriver::ImportPersistentOptions() {}
|
void CMemoryCardDriver::ImportPersistentOptions() {
|
||||||
|
CMemoryInStream r(x30_systemData.data(), x30_systemData.capacity());
|
||||||
|
CSystemOptions opts(r);
|
||||||
|
gpGameState->ImportPersistentOptions(opts);
|
||||||
|
}
|
||||||
|
|
||||||
void CMemoryCardDriver::ExportPersistentOptions() {}
|
void CMemoryCardDriver::ExportPersistentOptions() {}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue