Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[iQue] Match z_sram #2426

Merged
merged 8 commits into from
Jan 17, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,7 @@ EGCS_O_FILES += $(BUILD_DIR)/src/code/z_construct.o
# EGCS_O_FILES += $(BUILD_DIR)/src/code/z_kanfont.o
# EGCS_O_FILES += $(BUILD_DIR)/src/code/z_message.o
EGCS_O_FILES += $(BUILD_DIR)/src/code/z_parameter.o
# EGCS_O_FILES += $(BUILD_DIR)/src/code/z_sram.o
EGCS_O_FILES += $(BUILD_DIR)/src/code/z_sram.o
EGCS_O_FILES += $(BUILD_DIR)/src/overlays/actors/ovl_En_Mag/z_en_mag.o
EGCS_O_FILES += $(BUILD_DIR)/src/overlays/actors/ovl_End_Title/z_end_title.o
EGCS_O_FILES += $(BUILD_DIR)/src/overlays/actors/ovl_Fishing/z_fishing.o
Expand Down
6 changes: 5 additions & 1 deletion include/z64save.h
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ typedef struct Inventory {
/* 0x5C */ s16 gsTokens;
} Inventory; // size = 0x5E

typedef struct Checksum {
/* 0x00 */ u16 value;
} Checksum; // size = 0x02

typedef struct SavedSceneFlags {
/* 0x00 */ u32 chest;
/* 0x04 */ u32 swch;
Expand Down Expand Up @@ -254,7 +258,7 @@ typedef struct SaveInfo {
/* 0x12AA 0x12C6 */ u8 scarecrowSpawnSong[0x80];
/* 0x132A 0x1346 */ char unk_1346[0x02];
/* 0x132C 0x1348 */ HorseData horseData;
/* 0x1336 0x1352 */ u16 checksum; // "check_sum"
/* 0x1336 0x1352 */ Checksum checksum; // "check_sum"
} SaveInfo;

typedef struct Save {
Expand Down
2 changes: 1 addition & 1 deletion include/z64sram.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ typedef enum SramHeaderField {
/* 0x00 */ SRAM_HEADER_SOUND,
/* 0x01 */ SRAM_HEADER_ZTARGET,
/* 0x02 */ SRAM_HEADER_LANGUAGE,
/* 0x03 */ SRAM_HEADER_MAGIC // must be the value of `sZeldaMagic` for save to be considered valid
/* 0x03 */ SRAM_HEADER_MAGIC // must be the value in `sSramDefaultHeader` for save to be considered valid
} SramHeaderField;

#endif
2 changes: 1 addition & 1 deletion src/boot/z_std_dma.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#endif

#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \
"ntsc-1.2:70 pal-1.0:68 pal-1.1:68"
"ntsc-1.2:68 pal-1.0:66 pal-1.1:66"

StackEntry sDmaMgrStackInfo;
OSMesgQueue sDmaMgrMsgQueue;
Expand Down
2 changes: 1 addition & 1 deletion src/code/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ extern struct IrqMgr gIrqMgr;
#endif

#pragma increment_block_number "gc-eu:144 gc-eu-mq:144 gc-jp:144 gc-jp-ce:144 gc-jp-mq:144 gc-us:144 gc-us-mq:144" \
"ntsc-1.0:130 ntsc-1.1:130 ntsc-1.2:130 pal-1.0:128 pal-1.1:128"
"ntsc-1.0:127 ntsc-1.1:127 ntsc-1.2:127 pal-1.0:125 pal-1.1:125"

extern u8 _buffersSegmentEnd[];

Expand Down
2 changes: 1 addition & 1 deletion src/code/z_camera.c
Original file line number Diff line number Diff line change
Expand Up @@ -3639,7 +3639,7 @@ s32 Camera_KeepOn3(Camera* camera) {
}

#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \
"ntsc-1.0:133 ntsc-1.1:133 ntsc-1.2:133 pal-1.0:131 pal-1.1:131"
"ntsc-1.0:130 ntsc-1.1:130 ntsc-1.2:130 pal-1.0:128 pal-1.1:128"

s32 Camera_KeepOn4(Camera* camera) {
static Vec3f D_8015BD50;
Expand Down
2 changes: 1 addition & 1 deletion src/code/z_kaleido_scope_call.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#pragma increment_block_number "gc-eu:192 gc-eu-mq:192 gc-jp:224 gc-jp-ce:224 gc-jp-mq:224 gc-us:224 gc-us-mq:224" \
#pragma increment_block_number "gc-eu:192 gc-eu-mq:192 gc-jp:192 gc-jp-ce:192 gc-jp-mq:192 gc-us:192 gc-us-mq:192" \
"ntsc-1.0:224 ntsc-1.1:224 ntsc-1.2:224 pal-1.0:224 pal-1.1:224"

#include "global.h"
Expand Down
4 changes: 2 additions & 2 deletions src/code/z_kankyo.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#pragma increment_block_number "gc-eu:220 gc-eu-mq:220 gc-jp:212 gc-jp-ce:212 gc-jp-mq:212 gc-us:212 gc-us-mq:212" \
"ntsc-1.0:224 ntsc-1.1:224 ntsc-1.2:224 pal-1.0:228 pal-1.1:228"
#pragma increment_block_number "gc-eu:216 gc-eu-mq:216 gc-jp:212 gc-jp-ce:212 gc-jp-mq:212 gc-us:212 gc-us-mq:212" \
"ntsc-1.0:208 ntsc-1.1:208 ntsc-1.2:208 pal-1.0:228 pal-1.1:228"

#include "global.h"
#include "ultra64.h"
Expand Down
Loading