Skip to content

Commit

Permalink
Fix other versions
Browse files Browse the repository at this point in the history
  • Loading branch information
ethteck committed Sep 12, 2024
1 parent 41c2545 commit c05e24b
Show file tree
Hide file tree
Showing 12 changed files with 170 additions and 299 deletions.
5 changes: 1 addition & 4 deletions include/include_asset.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
#define INCLUDE_IMG(FILENAME, SYMBOLNAME) \
_INCLUDE_IMG(FILENAME, SYMBOLNAME)

#define _INCLUDE_PAL(FILENAME, SYMBOLNAME) \
#define INCLUDE_PAL(FILENAME, SYMBOLNAME) \
extern unsigned short SYMBOLNAME[]; \
__asm__( \
".globl " #SYMBOLNAME"\n" \
Expand All @@ -39,9 +39,6 @@
POPSECTION \
)

#define INCLUDE_PAL(FILENAME, SYMBOLNAME) \
_INCLUDE_PAL(FILENAME, SYMBOLNAME)

#define INCLUDE_RAW(FILENAME, SYMBOLNAME) \
extern unsigned char SYMBOLNAME[]; \
__asm__( \
Expand Down
21 changes: 18 additions & 3 deletions src/charset/charset.c
Original file line number Diff line number Diff line change
@@ -1,9 +1,22 @@
#include "include_asset.h"

#if VERSION_JP
INCLUDE_RAW("charset/kana.dat", charset_kana_OFFSET);
INCLUDE_RAW("charset/latin.dat", charset_latin_OFFSET);
INCLUDE_RAW("charset/kanji.dat", charset_kanji_OFFSET);
INCLUDE_RAW("charset/buttons.dat", charset_buttons_OFFSET);
INCLUDE_RAW("charset/menu_kana.dat", charset_menu_kana_OFFSET);
INCLUDE_RAW("charset/menu_latin.dat", charset_menu_latin_OFFSET);
#else
INCLUDE_RAW("charset/standard.dat", charset_standard_OFFSET);
#endif

INCLUDE_RAW("charset/standard/palette.dat", charset_standard_pal_OFFSET);
INCLUDE_RAW("charset/title.dat", charset_title_OFFSET);
INCLUDE_RAW("charset/subtitle.dat", charset_subtitle_OFFSET);
#if VERSION_IQUE
static int padding[] = {0, 0, 0, 0, 0, 0};
#endif
INCLUDE_RAW("charset/subtitle/palette.dat", charset_subtitle_pal_OFFSET);
INCLUDE_RAW("charset/title/palette.dat", charset_title_pal_OFFSET);

Expand Down Expand Up @@ -49,6 +62,8 @@ INCLUDE_PAL("charset/letter_content_11.pal", charset_letter_content_11_pal_OFFSE
INCLUDE_IMG("charset/letter_content_12.png", charset_letter_content_12_OFFSET);
INCLUDE_PAL("charset/letter_content_12.pal", charset_letter_content_12_pal_OFFSET);

int something[] = {
0, 0, 0x03E00008
};
#if VERSION_US || VERSION_PAL
static int padding2[] = {0, 0};
#endif

int something = 0x03E00008;
10 changes: 10 additions & 0 deletions src/charset/charset.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,17 @@

#include "charset/peach_letter.png.h"

#if VERSION_JP
extern unsigned char charset_kana_OFFSET[];
extern unsigned char charset_latin_OFFSET[];
extern unsigned char charset_kanji_OFFSET[];
extern unsigned char charset_buttons_OFFSET[];
extern unsigned char charset_menu_kana_OFFSET[];
extern unsigned char charset_menu_latin_OFFSET[];
#else
extern unsigned char charset_standard_OFFSET[];
#endif

extern unsigned char charset_standard_pal_OFFSET[];

extern unsigned char charset_title_OFFSET[];
Expand Down
2 changes: 2 additions & 0 deletions src/filemenu/filemenu_msg.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
#include "filemenu.h"
#include "ld_addrs.h"

#include "charset/charset.h"

s32 msg_get_print_char_width(s32 character, s32 charset, s32 variation, f32 msgScale, s32 overrideCharWidth, u8 flags);

extern MessageCharset* MsgCharsets[5];
Expand Down
1 change: 1 addition & 0 deletions src/msg_draw.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
#include "message_ids.h"
#include "sprite.h"

#include "charset/charset.h"
#include "charset/postcard.png.h"
#include "charset/letter_content_1.png.h"

Expand Down
107 changes: 40 additions & 67 deletions ver/ique/splat.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -968,73 +968,46 @@ segments:
vram: 0
start: 0x10E120
subsegments:
- [0x10E120, linker_offset, standard]
- [0x10E120, pm_charset, standard, 16, 16, 0x9E0]
- [0x15D120, linker_offset, standard_pal]
- [0x15D120, pm_charset_palettes, standard, 0x50]
- [0x15D620, linker_offset, title]
- [0x15D620, pm_charset, title, 12, 15, 0x29]
- [0x15E580, linker_offset, subtitle]
- [0x15E580, pm_charset, subtitle, 12, 12, 0x29]
- [0x15F108, bin] # padding
- [0x15F120, linker_offset, credits_pal]
- [0x15F120, pm_charset_palettes, subtitle, 1]
- [0x15F130, pm_charset_palettes, title, 1]
- [0x15F140, ci8, peach_letter, 150, 105]
- [0x162EC8, palette, peach_letter]
- [0x1630C8, linker_offset, postcard]
- [0x1630C8, ci4, postcard, 150, 105]
- [0x164F90, linker_offset, postcard_pal]
- [0x164F90, palette, postcard]
- [0x164FB0, linker_offset, letter_content_1]
- [0x164FB0, ci8, letter_content_1, 70, 95]
- [0x1669B0, linker_offset, letter_content_1_pal]
- [0x1669B0, palette, letter_content_1]
- [0x166BB0, linker_offset, letter_content_2]
- [0x166BB0, ci8, letter_content_2, 70, 95]
- [0x1685B0, linker_offset, letter_content_2_pal]
- [0x1685B0, palette, letter_content_2]
- [0x1687B0, linker_offset, letter_content_3]
- [0x1687B0, ci8, letter_content_3, 70, 95]
- [0x16A1B0, linker_offset, letter_content_3_pal]
- [0x16A1B0, palette, letter_content_3]
- [0x16A3B0, linker_offset, letter_content_4]
- [0x16A3B0, ci8, letter_content_4, 70, 95]
- [0x16BDB0, linker_offset, letter_content_4_pal]
- [0x16BDB0, palette, letter_content_4]
- [0x16BFB0, linker_offset, letter_content_5]
- [0x16BFB0, ci8, letter_content_5, 70, 95]
- [0x16D9B0, linker_offset, letter_content_5_pal]
- [0x16D9B0, palette, letter_content_5]
- [0x16DBB0, linker_offset, letter_content_6]
- [0x16DBB0, ci8, letter_content_6, 70, 95]
- [0x16F5B0, linker_offset, letter_content_6_pal]
- [0x16F5B0, palette, letter_content_6]
- [0x16F7B0, linker_offset, letter_content_7]
- [0x16F7B0, ci8, letter_content_7, 70, 95]
- [0x1711B0, linker_offset, letter_content_7_pal]
- [0x1711B0, palette, letter_content_7]
- [0x1713B0, linker_offset, letter_content_8]
- [0x1713B0, ci8, letter_content_8, 70, 95]
- [0x172DB0, linker_offset, letter_content_8_pal]
- [0x172DB0, palette, letter_content_8]
- [0x172FB0, linker_offset, letter_content_9]
- [0x172FB0, ci8, letter_content_9, 70, 95]
- [0x1749B0, linker_offset, letter_content_9_pal]
- [0x1749B0, palette, letter_content_9]
- [0x174BB0, linker_offset, letter_content_10]
- [0x174BB0, ci8, letter_content_10, 70, 95]
- [0x1765B0, linker_offset, letter_content_10_pal]
- [0x1765B0, palette, letter_content_10]
- [0x1767B0, linker_offset, letter_content_11]
- [0x1767B0, ci8, letter_content_11, 70, 95]
- [0x1781B0, linker_offset, letter_content_11_pal]
- [0x1781B0, palette, letter_content_11]
- [0x1783B0, linker_offset, letter_content_12]
- [0x1783B0, ci8, letter_content_12, 70, 95]
- [0x179DB0, linker_offset, letter_content_12_pal]
- [0x179DB0, palette, letter_content_12]
- [0x179FB0, bin]
- [auto, c, charset]
- type: .data
name: charset
subsegments:
- [0x10E120, pm_charset, standard, 16, 16, 0x9E0]
- [0x15D120, pm_charset_palettes, standard, 0x50]
- [0x15D620, pm_charset, title, 12, 15, 0x29]
- [0x15E580, pm_charset, subtitle, 12, 12, 0x29]
- [0x15F108] # padding
- [0x15F120, pm_charset_palettes, subtitle, 1]
- [0x15F130, pm_charset_palettes, title, 1]
- [0x15F140, ci8, peach_letter, 150, 105]
- [0x162EC8, palette, peach_letter]
- [0x1630C8, ci4, postcard, 150, 105]
- [0x164F90, palette, postcard]
- [0x164FB0, ci8, letter_content_1, 70, 95]
- [0x1669B0, palette, letter_content_1]
- [0x166BB0, ci8, letter_content_2, 70, 95]
- [0x1685B0, palette, letter_content_2]
- [0x1687B0, ci8, letter_content_3, 70, 95]
- [0x16A1B0, palette, letter_content_3]
- [0x16A3B0, ci8, letter_content_4, 70, 95]
- [0x16BDB0, palette, letter_content_4]
- [0x16BFB0, ci8, letter_content_5, 70, 95]
- [0x16D9B0, palette, letter_content_5]
- [0x16DBB0, ci8, letter_content_6, 70, 95]
- [0x16F5B0, palette, letter_content_6]
- [0x16F7B0, ci8, letter_content_7, 70, 95]
- [0x1711B0, palette, letter_content_7]
- [0x1713B0, ci8, letter_content_8, 70, 95]
- [0x172DB0, palette, letter_content_8]
- [0x172FB0, ci8, letter_content_9, 70, 95]
- [0x1749B0, palette, letter_content_9]
- [0x174BB0, ci8, letter_content_10, 70, 95]
- [0x1765B0, palette, letter_content_10]
- [0x1767B0, ci8, letter_content_11, 70, 95]
- [0x1781B0, palette, letter_content_11]
- [0x1783B0, ci8, letter_content_12, 70, 95]
- [0x179DB0, palette, letter_content_12]
- [0x179FB0]
- name: ui_images_filemenu_pause
type: code
start: 0x179FC0
Expand Down
84 changes: 4 additions & 80 deletions ver/ique/symbol_addrs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ theater_walls_png = 0x80073250;
__osMaxControllers = 0x800991D2;
__osFlashMsgBuf = 0x800991D4;
__osCurrentTime = 0x800991D8;
__osCurrentTime + 4 = 0x800991DC;
__osContLastCmd = 0x800991F0;
__osEepromTimerMsg = 0x800991F4;
__osBbLastVCount = 0x800991E8;
Expand All @@ -46,16 +45,13 @@ sin_rad = 0x80029e3c;
cos_rad = 0x80029ea0;
D_8009A5EC = 0x800991b8;

__osContPifRam + 0x3C = 0x800AF94C;
__osEepromTimerQ = 0x800d8e20;
TitleScreen_ImgList_Copyright = 0x8009d38c;
__osBbIsBb = 0x80000388;

main_BSS_START = 0x80099170;
main_BSS_SIZE = 0x41770;
nuBootStack + 0x2000 = 0x800B4FE0;
piAccessBuf = 0x800af700;
__osFlashHandler + 0xC = 0x800D7C2C;
D_800A08E4 = 0x8009d2f4;
D_800A08E8 = 0x8009d2f8;
D_800A08EC = 0x8009d2fc;
Expand All @@ -73,7 +69,6 @@ osViModeMpalLan1 = 0x80094490;
nuAuTaskStop = 0x80076de0;
AlFrameSize = 0x800a0044;
AlCmdListBuffers = 0x8009ff20;
nusched + 0x678 = 0x800D8E18;
AlMinFrameSize = 0x800a0048;
n_aspMain_text_bin = 0x80071e10;
n_aspMain_data_bin = 0x80096700;
Expand All @@ -84,7 +79,6 @@ nuAuDmaMesgBuf = 0x800a0068;
nuAuDmaMesgQ = 0x800a0050;
auSynDriver = 0x800b7bf0;
nuAuMgrThread = 0x8009d968;
nuAuDmaBufList + 0x10 = 0x800A0600;
nuAuPreNMIFunc = 0x80076dd4;
nuAuHeap = 0x800d7d10;
alHeapInit = 0x800575e0;
Expand Down Expand Up @@ -378,7 +372,6 @@ __umoddi3 = 0x8006de80;
strcpy = 0x8006e350;
decode_yay0 = 0x8006e380;
__osPfsPifRam = 0x800D8360; // size:0x40
__osPfsPifRam + 0x3C = 0x800D839C;
__osBbEepromSize = 0x80000360;
__osBbEepromAddress = 0x8000035c;
__osBbSramSize = 0x80000370;
Expand All @@ -398,25 +391,12 @@ __osCurrentHandle = 0x80094540;

__osSiAccessQueue = 0x800d9008; // size:0x18
siAccessBuf = 0x800ad300;
__Dom1SpeedParam + 0x4 = 0x800b2f6c;
__Dom1SpeedParam + 0x5 = 0x800b2f6d;
__Dom1SpeedParam + 0x6 = 0x800B2F6E;
__Dom1SpeedParam + 0x7 = 0x800B2F6F;
__Dom1SpeedParam + 0x8 = 0x800b2f70;
tmp_task = 0x800ad2c0; // size:0x40
__osBbRCountWraps = 0x80099198;
__osBbLastRCount = 0x800991a4;

__Dom2SpeedParam + 0x4 = 0x800b0548;
__Dom2SpeedParam + 0x5 = 0x800b0549;
__Dom2SpeedParam + 0x6 = 0x800b054a;
__Dom2SpeedParam + 0x7 = 0x800b054b;
__Dom2SpeedParam + 0x8 = 0x800b054c;

piThread = 0x800ae530; // size:432
__CartRomHandle = 0x800b2d58; // size:116
__CartRomHandle + 0x4 = 0x800B2D5C;
__CartRomHandle + 0xC = 0x800B2D64;
piEventBuf = 0x800af6f8;
piEventQueue = 0x800af6e0; // size:24
__osEventStateTab = 0x800d825c; // size:0x110
Expand Down Expand Up @@ -468,17 +448,6 @@ hud_element_draw_next = 0x80142f54;
draw_number = 0x80125a4c;

gPlayerData = 0x8010d670;
gPlayerData + 0x1 = 0x8010d671;
gPlayerData + 0x2 = 0x8010d672;
gPlayerData + 0x3 = 0x8010d673;
gPlayerData + 0x5 = 0x8010d675;
gPlayerData + 0x6 = 0x8010d676;
gPlayerData + 0x8 = 0x8010d678;
gPlayerData + 0x9 = 0x8010d679;
gPlayerData + 0xC = 0x8010d67C;
gPlayerData + 0xF = 0x8010d67F;
gPlayerData + 0x10 = 0x8010d680;
gPlayerData + 0x2BC = 0x8010D92C;
gPauseWS_10 = 0x8026fbb0;
gPauseStatsBootsMessages = 0x8024f390;
gPauseStatsHammerMessages = 0x8024f3a0;
Expand Down Expand Up @@ -550,8 +519,6 @@ MsgCharImgSubtitle = 0x802f39d0;
sfx_play_sound_with_params = 0x80148248;
heap_malloc = 0x8002a9b4;
D_80159180 = 0x8015b500;
charset_postcard_png = 0x00054fa8;
charset_postcard_pal + 5 = 0x00056e70;
D_80159B50 = 0x8015bed0;
gOverrideFlags = 0x80099228;
ItemSpawnWithinPlayerPickupDelay = 0x80158926;
Expand Down Expand Up @@ -4457,53 +4424,6 @@ spr_get_npc_color_variations = 0x802DEA6C;
battle_partner_twink_IsPeachBattle = 0x80238000;
battle_partner_watt = 0x802390B0;
battle_item_egg_missile_EVS_UseItem = 0x802A25A0;
gItemTable + 0xC = 0x8008654C;
gItemTable + 0x12A0 = 0x800877E0;
gItemTable + 0x1CE4 = 0x80088224;
gItemTable + 0x1F04 = 0x80088444;
gMoveTable + 0x4 = 0x8008DCC4;
gMoveTable + 0x11 = 0x8008DCD1;
gMoveTable + 0x13 = 0x8008DCD3;
gMoveTable + 0x7C = 0x8008DD3C;
gMoveTable + 0x248 = 0x8008DF08;
gBattleAreas + 0x1C = 0x800946CC;
gCurrentEncounter + 0x5 = 0x800AF955;
gCurrentEncounter + 0x9 = 0x800AF959;
gCameras + 0x558 = 0x800B0D28;
gCameras + 0x5C4 = 0x800B0D94;
gCameras + 0xAB0 = 0x800B1280;
gBattleStatus + 0x4 = 0x800DA454;
gBattleStatus + 0x8 = 0x800DA458;
gBattleStatus + 0x70 = 0x800DA4C0;
gBattleStatus + 0x74 = 0x800DA4C4;
gBattleStatus + 0x78 = 0x800DA4C8;
gBattleStatus + 0x81 = 0x800DA4D1;
gBattleStatus + 0x83 = 0x800DA4D3;
gBattleStatus + 0x84 = 0x800DA4D4;
gBattleStatus + 0x85 = 0x800DA4D5;
gBattleStatus + 0x86 = 0x800DA4D6;
gBattleStatus + 0x87 = 0x800DA4D7;
gBattleStatus + 0x8D = 0x800DA4DD;
gBattleStatus + 0xD8 = 0x800DA528;
gBattleStatus + 0xDC = 0x800DA52C;
gBattleStatus + 0x17A = 0x800DA5CA;
gBattleStatus + 0x180 = 0x800DA5D0;
gBattleStatus + 0x184 = 0x800DA5D4;
gBattleStatus + 0x188 = 0x800DA5D8;
gBattleStatus + 0x19A = 0x800DA5EA;
gBattleStatus + 0x1A7 = 0x800DA5F7;
gBattleStatus + 0x1A8 = 0x800DA5F8;
gBattleStatus + 0x210 = 0x800DA660;
gBattleStatus + 0x214 = 0x800DA664;
gBattleStatus + 0x218 = 0x800DA668;
gBattleStatus + 0x224 = 0x800DA674;
gBattleStatus + 0x434 = 0x800DA884;
gBattleStatus + 0x438 = 0x800DA888;
gCurrentBattleID + 0x2 = 0x800DA8CA;
NpcHitQueryBehindCollider + 0x3 = 0x8010AD4B;
gPlayerData + 0xA = 0x8010D67A;
gPlayerData + 0x28A = 0x8010D8FA;
gWindows + 0x12E = 0x8015C1FE;
HES_level_up_small_red_digit_7 = 0x802AA5F4;
ui_battle_menu_unused_png = 0x802893C0; // rom:0x200D60
ui_battle_menu_unused_pal = 0x802895C0; // rom:0x200F60
Expand Down Expand Up @@ -4832,3 +4752,7 @@ D_802A6670_7A45B0 = 0x802A6670; // rom:0x7ED000

D_09000218_398DD8 = 0x09000218; // rom:0x3E1828
D_09001518_39A0D8 = 0x09001518; // rom:0x3E2B28

charset_peach_letter_png = 0x00051020; //rom:0x15F140
charset_postcard_png = 0x00054FA8; //rom:0x1630C8
charset_letter_content_1_png = 0x00056E90; //rom:0x164FB0
Loading

0 comments on commit c05e24b

Please sign in to comment.