mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Correctly savestate the atrac ids.
This commit is contained in:
parent
b4269bce53
commit
d6de868108
1 changed files with 10 additions and 1 deletions
|
@ -304,7 +304,16 @@ void __AtracInit() {
|
|||
|
||||
void __AtracDoState(PointerWrap &p) {
|
||||
p.Do(atracInited);
|
||||
p.DoArray(atracIDs, PSP_NUM_ATRAC_IDS);
|
||||
for (int i = 0; i < PSP_NUM_ATRAC_IDS; ++i) {
|
||||
bool valid = atracIDs[i] != NULL;
|
||||
p.Do(valid);
|
||||
if (valid) {
|
||||
p.Do(atracIDs[i]);
|
||||
} else {
|
||||
delete atracIDs[i];
|
||||
atracIDs[i] = NULL;
|
||||
}
|
||||
}
|
||||
p.DoArray(atracIDTypes, PSP_NUM_ATRAC_IDS);
|
||||
|
||||
p.DoMarker("sceAtrac");
|
||||
|
|
Loading…
Add table
Reference in a new issue