diff --git a/Makefile b/Makefile index 1ac081e07..ab274635c 100644 --- a/Makefile +++ b/Makefile @@ -712,7 +712,7 @@ setup: venv $(V)$(PYTHON) tools/extract_incbins.py $(EXTRACTED_DIR)/baserom $(EXTRACTED_DIR)/incbin -v $(VERSION) $(V)$(PYTHON) tools/extract_text.py $(EXTRACTED_DIR)/baserom $(EXTRACTED_DIR)/text -v $(VERSION) $(V)$(PYTHON) tools/extract_assets.py $(EXTRACTED_DIR)/baserom $(EXTRACTED_DIR)/assets -v $(VERSION) -j$(N_THREADS) - $(V)$(PYTHON) tools/extract_audio.py -o $(EXTRACTED_DIR) -v $(VERSION) --read-xml + $(V)$(PYTHON) tools/extract_audio.py -b $(EXTRACTED_DIR)/baserom -o $(EXTRACTED_DIR) -v $(VERSION) --read-xml $(call print_no_args,Extracting files: Done!) run: rom diff --git a/include/audiothread_cmd.h b/include/audiothread_cmd.h index c0576b82b..c4a343631 100644 --- a/include/audiothread_cmd.h +++ b/include/audiothread_cmd.h @@ -44,7 +44,7 @@ typedef enum AudioThreadCmdOp { /* 0xE1 */ AUDIOCMD_OP_GLOBAL_SET_SFX_FONT, /* 0xE2 */ AUDIOCMD_OP_GLOBAL_SET_INSTRUMENT_FONT, /* 0xE3 */ AUDIOCMD_OP_GLOBAL_POP_PERSISTENT_CACHE, - /* 0xF0 */ AUDIOCMD_OP_GLOBAL_SET_SOUND_MODE = 0xF0, + /* 0xF0 */ AUDIOCMD_OP_GLOBAL_SET_SOUND_OUTPUT_MODE = 0xF0, /* 0xF1 */ AUDIOCMD_OP_GLOBAL_MUTE, /* 0xF2 */ AUDIOCMD_OP_GLOBAL_UNMUTE, /* 0xF3 */ AUDIOCMD_OP_GLOBAL_SYNC_LOAD_INSTRUMENT, @@ -412,12 +412,12 @@ typedef enum AudioThreadCmdOp { AudioThread_QueueCmdS32(AUDIO_MK_CMD(AUDIOCMD_OP_GLOBAL_POP_PERSISTENT_CACHE, 0, 0, 0), tableType) /** - * Change the sound mode of audio + * Change the sound output mode * - * @param soundMode (s32) see the `SoundMode` enum + * @param soundOutputMode (s32) see the `SoundOutputMode` enum */ -#define AUDIOCMD_GLOBAL_SET_SOUND_MODE(soundMode) \ - AudioThread_QueueCmdS32(AUDIO_MK_CMD(AUDIOCMD_OP_GLOBAL_SET_SOUND_MODE, 0, 0, 0), soundMode) +#define AUDIOCMD_GLOBAL_SET_SOUND_OUTPUT_MODE(soundOutputMode) \ + AudioThread_QueueCmdS32(AUDIO_MK_CMD(AUDIOCMD_OP_GLOBAL_SET_SOUND_OUTPUT_MODE, 0, 0, 0), soundOutputMode) /** * Mute all sequence players diff --git a/include/functions.h b/include/functions.h index 376c75c34..493b6a017 100644 --- a/include/functions.h +++ b/include/functions.h @@ -4,38 +4,31 @@ #include "z64.h" #include "macros.h" -void bootproc(void); -void Main_ThreadEntry(void* arg); void Idle_ThreadEntry(void* arg); -void ViConfig_UpdateVi(u32 black); -void ViConfig_UpdateBlack(void); + #if DEBUG_FEATURES void isPrintfInit(void); #endif void rmonPrintf(const char* fmt, ...); + #if DEBUG_FEATURES void* is_proutSyncPrintf(void* arg, const char* str, size_t count); NORETURN void func_80002384(const char* exp, const char* file, int line); #endif + OSPiHandle* osDriveRomInit(void); + void Mio0_Decompress(u8* src, u8* dst); void FlagSet_Update(PlayState* play); // ENABLE_EVENT_EDITOR -void SaveContext_Init(void); - void* MemCpy(void* dest, const void* src, s32 len); -void MapMark_Init(PlayState* play); -void MapMark_ClearPointers(PlayState* play); -void MapMark_Draw(PlayState* play); -void Sched_FlushTaskQueue(void); - -void PlayerCall_InitFuncPtrs(void); void TransitionTile_Destroy(TransitionTile* this); TransitionTile* TransitionTile_Init(TransitionTile* this, s32 cols, s32 rows); void TransitionTile_Draw(TransitionTile* this, Gfx** gfxP); void TransitionTile_Update(TransitionTile* this); + void TransitionTriforce_Start(void* thisx); void* TransitionTriforce_Init(void* thisx); void TransitionTriforce_Destroy(void* thisx); @@ -44,6 +37,7 @@ void TransitionTriforce_SetColor(void* thisx, u32 color); void TransitionTriforce_SetType(void* thisx, s32 type); void TransitionTriforce_Draw(void* thisx, Gfx** gfxP); s32 TransitionTriforce_IsDone(void* thisx); + void TransitionWipe_Start(void* thisx); void* TransitionWipe_Init(void* thisx); void TransitionWipe_Destroy(void* thisx); @@ -52,6 +46,7 @@ void TransitionWipe_Draw(void* thisx, Gfx** gfxP); s32 TransitionWipe_IsDone(void* thisx); void TransitionWipe_SetType(void* thisx, s32 type); void TransitionWipe_SetColor(void* thisx, u32 color); + void TransitionCircle_Start(void* thisx); void* TransitionCircle_Init(void* thisx); void TransitionCircle_Destroy(void* thisx); @@ -61,6 +56,7 @@ s32 TransitionCircle_IsDone(void* thisx); void TransitionCircle_SetType(void* thisx, s32 type); void TransitionCircle_SetColor(void* thisx, u32 color); void TransitionCircle_SetUnkColor(void* thisx, u32 color); + void TransitionFade_Start(void* thisx); void* TransitionFade_Init(void* thisx); void TransitionFade_Destroy(void* thisx); @@ -70,24 +66,6 @@ s32 TransitionFade_IsDone(void* thisx); void TransitionFade_SetColor(void* thisx, u32 color); void TransitionFade_SetType(void* thisx, s32 type); -void PreRender_SetValuesSave(PreRender* this, u32 width, u32 height, void* fbuf, void* zbuf, void* cvg); -void PreRender_Init(PreRender* this); -void PreRender_SetValues(PreRender* this, u32 width, u32 height, void* fbuf, void* zbuf); -void PreRender_Destroy(PreRender* this); - -// ENABLE_PAUSE_BG_AA -void func_800C170C(PreRender* this, Gfx** gfxP, void* buf, void* bufSave, u32 r, u32 g, u32 b, u32 a); -void func_800C1AE8(PreRender* this, Gfx** gfxP, void* fbuf, void* fbufSave); -void PreRender_SaveZBuffer(PreRender* this, Gfx** gfxP); -void PreRender_SaveFramebuffer(PreRender* this, Gfx** gfxP); -void PreRender_DrawCoverage(PreRender* this, Gfx** gfxP); -void PreRender_RestoreZBuffer(PreRender* this, Gfx** gfxP); -void func_800C213C(PreRender* this, Gfx** gfxP); -void PreRender_RestoreFramebuffer(PreRender* this, Gfx** gfxP); -void PreRender_CopyImageRegion(PreRender* this, Gfx** gfxP); -void PreRender_ApplyFilters(PreRender* this); -void Graph_ThreadEntry(void*); - void SysCfb_Init(s32 n64dd); void* SysCfb_GetFbPtr(s32 idx); void* SysCfb_GetFbEnd(void); @@ -97,10 +75,6 @@ void RcpUtils_Reset(void); void SystemHeap_Init(void* start, u32 size); -f32 absf(f32); - -void Regs_InitData(PlayState* play); - #if ENABLE_PROFILER #include "debug/profiler_inline.h" #endif diff --git a/include/gfx.h b/include/gfx.h index 72edcf315..e9a489d04 100644 --- a/include/gfx.h +++ b/include/gfx.h @@ -125,4 +125,6 @@ void Graph_CloseDisps(Gfx** dispRefs, GraphicsContext* gfxCtx, const char* file, #endif +void Graph_ThreadEntry(void*); + #endif diff --git a/include/libc64/malloc.h b/include/libc64/malloc.h index 52aad9fed..d2a2e675f 100644 --- a/include/libc64/malloc.h +++ b/include/libc64/malloc.h @@ -32,5 +32,6 @@ void SystemArena_Display(void); #endif extern Arena gSystemArena; +extern s32 gSystemArenaLogSeverity; #endif diff --git a/include/prerender.h b/include/prerender.h index 4231234a8..0674fac02 100644 --- a/include/prerender.h +++ b/include/prerender.h @@ -26,4 +26,19 @@ typedef struct PreRender { /* 0x4C */ u32 unk_4C; } PreRender; // size = 0x50 +void PreRender_SetValuesSave(PreRender* this, u32 width, u32 height, void* fbuf, void* zbuf, void* cvg); +void PreRender_Init(PreRender* this); +void PreRender_SetValues(PreRender* this, u32 width, u32 height, void* fbuf, void* zbuf); +void PreRender_Destroy(PreRender* this); +void func_800C170C(PreRender* this, Gfx** gfxP, void* buf, void* bufSave, u32 r, u32 g, u32 b, u32 a); +void func_800C1AE8(PreRender* this, Gfx** gfxP, void* fbuf, void* fbufSave); +void PreRender_SaveZBuffer(PreRender* this, Gfx** gfxP); +void PreRender_SaveFramebuffer(PreRender* this, Gfx** gfxP); +void PreRender_DrawCoverage(PreRender* this, Gfx** gfxP); +void PreRender_RestoreZBuffer(PreRender* this, Gfx** gfxP); +void func_800C213C(PreRender* this, Gfx** gfxP); +void PreRender_RestoreFramebuffer(PreRender* this, Gfx** gfxP); +void PreRender_CopyImageRegion(PreRender* this, Gfx** gfxP); +void PreRender_ApplyFilters(PreRender* this); + #endif diff --git a/include/regs.h b/include/regs.h index 8c0c74c5d..db5485a71 100644 --- a/include/regs.h +++ b/include/regs.h @@ -5,6 +5,8 @@ #include "ultra64.h" #include "versions.h" +struct PlayState; + #define REG_GROUPS 29 // number of REG groups, i.e. REG, SREG, OREG, etc. #define REG_PAGES 6 #define REGS_PER_PAGE 16 @@ -419,6 +421,8 @@ typedef struct RegEditor { /* 0x14 */ s16 data[REG_GROUPS * REGS_PER_GROUP]; // Accessed through *REG macros, see regs.h } RegEditor; // size = 0x15D4 +void Regs_InitData(struct PlayState* play); + extern RegEditor* gRegEditor; #endif diff --git a/include/sched.h b/include/sched.h index 2d20e7ec0..bf204bc6d 100644 --- a/include/sched.h +++ b/include/sched.h @@ -69,6 +69,7 @@ typedef struct Scheduler { void Sched_Notify(Scheduler* sc); void Sched_Init(Scheduler* sc, void* stack, OSPri priority, u8 viModeType, UNK_TYPE arg4, IrqMgr* irqMgr); +void Sched_FlushTaskQueue(void); extern Scheduler gScheduler; diff --git a/include/seqcmd.h b/include/seqcmd.h index 5acce7c49..53fce27bf 100644 --- a/include/seqcmd.h +++ b/include/seqcmd.h @@ -56,7 +56,7 @@ typedef enum SeqCmdSetupCmdOp { // Subset of `SEQCMD_OP_GLOBAL_CMD` typedef enum SeqCmdSubCmdOp { - /* 0x0 */ SEQCMD_SUB_OP_GLOBAL_SET_SOUND_MODE, + /* 0x0 */ SEQCMD_SUB_OP_GLOBAL_SET_SOUND_OUTPUT_MODE, /* 0x1 */ SEQCMD_SUB_OP_GLOBAL_DISABLE_NEW_SEQUENCES } SeqCmdSubCmdOp; @@ -479,12 +479,12 @@ typedef enum SeqCmdSubCmdOp { */ /** - * Change the sound mode of audio + * Change the sound output mode * - * @param soundMode see the `SoundMode` enum + * @param soundOutputMode see the `SoundOutputMode` enum */ -#define SEQCMD_SET_SOUND_MODE(soundMode) \ - Audio_QueueSeqCmd((SEQCMD_OP_GLOBAL_CMD << 28) | (SEQCMD_SUB_OP_GLOBAL_SET_SOUND_MODE << 8) | (u8)(soundMode)) +#define SEQCMD_SET_SOUND_OUTPUT_MODE(soundOutputMode) \ + Audio_QueueSeqCmd((SEQCMD_OP_GLOBAL_CMD << 28) | (SEQCMD_SUB_OP_GLOBAL_SET_SOUND_OUTPUT_MODE << 8) | (u8)(soundOutputMode)) /** * Disable (or reenable) new sequences from starting diff --git a/include/variables.h b/include/variables.h index 3e70fae46..2fc149a93 100644 --- a/include/variables.h +++ b/include/variables.h @@ -32,13 +32,8 @@ extern u32 __osBbSramSize; extern u32 __osBbSramAddress; extern u32 __osBbHackFlags; -extern s8 D_80009430; -extern vu8 gViConfigBlack; -extern u8 gViConfigAdditionalScanLines; -extern u32 gViConfigFeatures; -extern f32 gViConfigXScale; -extern f32 gViConfigYScale; extern OSPiHandle* gCartHandle; + extern u32 __osPiAccessQueueEnabled; extern OSViMode osViModePalLan1; extern s32 osViClock; @@ -59,11 +54,13 @@ extern OSViContext* __osViNext; extern OSViMode osViModeFpalLan1; extern OSViMode gCustomViModePal60Lan1; extern u32 __additional_scanline; -extern const char* gBuildAuthor; -extern const char* gCommitAuthor; -extern const char* gBuildDate; -extern const char* gBuildGitVersion; -extern const char* gCommitGitString; + +extern const char gBuildAuthor[]; +extern const char gCommitAuthor[]; +extern const char gBuildDate[]; +extern const char gBuildGitVersion[]; +extern const char gCommitGitString[]; + extern OSMesgQueue gPiMgrCmdQueue; extern OSViMode gViConfigMode; extern u8 gViConfigModeType; @@ -80,7 +77,6 @@ extern s16 gSpoilingItemReverts[3]; // 4 16-colors palettes extern u64 gMojiFontTLUTs[4][4]; // original name: "moji_tlut" extern u64 gMojiFontTex[]; // original name: "font_ff" -extern u8 gBossMarkState; extern s16* gWaveSamples[9]; extern f32 gBendPitchOneOctaveFrequencies[256]; @@ -130,11 +126,10 @@ extern u8 gStartSeqDisabled; #if IS_AUDIO_DEBUG_ENABLED extern u8 gAudioDebugPrintSeqCmd; #endif -extern u8 gSoundModeList[]; +extern u8 gSoundOutputModes[]; extern u8 gAudioSpecId; extern u8 D_80133418; extern AudioSpec gAudioSpecs[18]; -extern s32 gSystemArenaLogSeverity; extern u8 __osPfsInodeCacheBank; extern s32 __osPfsLastChannel; @@ -147,6 +142,7 @@ extern u8 gSequenceTable[]; extern AudioTable gSampleBankTable; extern struct MapData* gMapData; +extern u8 gBossMarkState; extern f32 gBossMarkScale; extern u32 D_8016139C; extern PauseMapMarksData* gLoadedPauseMarkDataTable; diff --git a/include/vi_mode.h b/include/vi_mode.h index 89de610a8..5c2f1bace 100644 --- a/include/vi_mode.h +++ b/include/vi_mode.h @@ -42,4 +42,14 @@ void ViMode_Init(ViMode* viMode); void ViMode_Destroy(ViMode* viMode); void ViMode_Update(ViMode* viMode, Input* input); +void ViConfig_UpdateVi(u32 black); +void ViConfig_UpdateBlack(void); + +extern s8 D_80009430; +extern vu8 gViConfigBlack; +extern u8 gViConfigAdditionalScanLines; +extern u32 gViConfigFeatures; +extern f32 gViConfigXScale; +extern f32 gViConfigYScale; + #endif diff --git a/include/z64audio.h b/include/z64audio.h index ab3eec75e..890055c76 100644 --- a/include/z64audio.h +++ b/include/z64audio.h @@ -75,12 +75,12 @@ typedef enum SoundSetting { /* 3 */ SOUND_SETTING_SURROUND } SoundSetting; -typedef enum SoundMode { - /* 0 */ SOUNDMODE_STEREO, - /* 1 */ SOUNDMODE_HEADSET, - /* 2 */ SOUNDMODE_SURROUND, - /* 3 */ SOUNDMODE_MONO -} SoundMode; +typedef enum SoundOutputMode { + /* 0 */ SOUND_OUTPUT_STEREO, + /* 1 */ SOUND_OUTPUT_HEADSET, + /* 2 */ SOUND_OUTPUT_SURROUND, + /* 3 */ SOUND_OUTPUT_MONO +} SoundOutputMode; typedef enum AdsrStatus { /* 0 */ ADSR_STATE_DISABLED, @@ -936,7 +936,7 @@ typedef struct AudioContext { /* 0x2890 */ s32 maxAudioCmds; /* 0x2894 */ s32 numNotes; /* 0x2898 */ s16 maxTempo; // Maximum possible tempo (seqTicks per minute), using every tick as a seqTick to process a .seq file - /* 0x289A */ s8 soundMode; + /* 0x289A */ s8 soundOutputMode; /* 0x289C */ s32 totalTaskCount; // The total number of times the top-level function on the audio thread has run since audio was initialized /* 0x28A0 */ s32 curAudioFrameDmaCount; /* 0x28A4 */ s32 rspTaskIndex; @@ -1204,7 +1204,7 @@ void func_800F64E0(u8 arg0); void Audio_ToggleMalonSinging(u8 malonSingingDisabled); void Audio_SetEnvReverb(s8 reverb); void Audio_SetCodeReverb(s8 reverb); -void Audio_SetSoundMode(s8 soundSetting); +void Audio_SetSoundOutputMode(s8 soundSetting); void Audio_SetBaseFilter(u8); void Audio_SetExtraFilter(u8); void Audio_SetCutsceneFlag(s8 flag); diff --git a/include/z64map_mark.h b/include/z64map_mark.h index 0c55efa3a..b56649111 100644 --- a/include/z64map_mark.h +++ b/include/z64map_mark.h @@ -3,6 +3,8 @@ #include "ultra64.h" +struct PlayState; + #define MAP_MARK_NONE -1 #define MAP_MARK_CHEST 0 #define MAP_MARK_BOSS 1 @@ -20,6 +22,10 @@ typedef struct MapMarkIconData { typedef MapMarkIconData MapMarkData[3]; // size = 0x72 +void MapMark_Init(struct PlayState* play); +void MapMark_ClearPointers(struct PlayState* play); +void MapMark_Draw(struct PlayState* play); + extern MapMarkData* gMapMarkDataTable[]; #endif diff --git a/include/z64save.h b/include/z64save.h index 6214c5c5c..47e5315a9 100644 --- a/include/z64save.h +++ b/include/z64save.h @@ -1008,6 +1008,7 @@ typedef enum IngoRaceState { #define EVENTINF_30 0x30 +void SaveContext_Init(void); extern SaveContext gSaveContext; diff --git a/spec/spec b/spec/spec index 0dddcdcf9..e4d84057d 100644 --- a/spec/spec +++ b/spec/spec @@ -797,14 +797,14 @@ beginseg include "$(BUILD_DIR)/src/libc/memmove.o" #elif PLATFORM_GC include "$(BUILD_DIR)/src/libc/sqrt.o" - include "$(BUILD_DIR)/src/libc/absf.o" + include "$(BUILD_DIR)/src/libc/fabsf.o" include "$(BUILD_DIR)/src/libc/fmodf.o" include "$(BUILD_DIR)/src/libc/memset.o" include "$(BUILD_DIR)/src/libc/memmove.o" #elif PLATFORM_IQUE include "$(BUILD_DIR)/src/libc/fmodf.o" include "$(BUILD_DIR)/src/libc/memmove.o" - include "$(BUILD_DIR)/src/libc/absf.o" + include "$(BUILD_DIR)/src/libc/fabsf.o" include "$(BUILD_DIR)/src/libc/sqrt.o" #endif diff --git a/src/audio/data.c b/src/audio/data.c index 627d6c5c6..ef99eafec 100644 --- a/src/audio/data.c +++ b/src/audio/data.c @@ -59,11 +59,11 @@ u8 gStartSeqDisabled = false; u8 gAudioDebugPrintSeqCmd = true; #endif -u8 gSoundModeList[] = { - SOUNDMODE_STEREO, - SOUNDMODE_HEADSET, - SOUNDMODE_SURROUND, - SOUNDMODE_MONO, +u8 gSoundOutputModes[] = { + SOUND_OUTPUT_STEREO, + SOUND_OUTPUT_HEADSET, + SOUND_OUTPUT_SURROUND, + SOUND_OUTPUT_MONO, }; u8 gAudioSpecId = 0; diff --git a/src/audio/debug.inc.c b/src/audio/debug.inc.c index a41254001..e6d2dd89c 100644 --- a/src/audio/debug.inc.c +++ b/src/audio/debug.inc.c @@ -847,7 +847,7 @@ void AudioDebug_ProcessInput_SndCont(void) { &gSfxDefaultReverb); break; case 4: - Audio_SetSoundMode(sAudioSndContWork[sAudioSndContSel]); + Audio_SetSoundOutputMode(sAudioSndContWork[sAudioSndContSel]); break; case 5: SEQCMD_DISABLE_PLAY_SEQUENCES(sAudioSndContWork[sAudioSndContSel]); diff --git a/src/audio/general.c b/src/audio/general.c index 761b4b269..bd6eb2468 100644 --- a/src/audio/general.c +++ b/src/audio/general.c @@ -140,9 +140,9 @@ f32 D_801305F4 = 1.0f; u8 sGanonsTowerLevelsVol[8] = { 127, 80, 75, 73, 70, 68, 65, 60 }; u8 sEnterGanonsTowerTimer = 0; #if DEBUG_FEATURES -s8 sSoundMode = SOUNDMODE_SURROUND; +s8 sSoundOutputMode = SOUND_OUTPUT_SURROUND; #else -s8 sSoundMode = SOUNDMODE_STEREO; +s8 sSoundOutputMode = SOUND_OUTPUT_STEREO; #endif s8 D_80130608 = 0; s8 sAudioCutsceneFlag = 0; @@ -2633,7 +2633,7 @@ void Audio_SetSfxProperties(u8 bankId, u8 entryIdx, u8 channelIndex) { case BANK_ENV: case BANK_ENEMY: case BANK_VOICE: - if (sSoundMode == SOUNDMODE_SURROUND) { + if (sSoundOutputMode == SOUND_OUTPUT_SURROUND) { combFilterGain = func_800F3990(*entry->posY, entry->sfxParams); } FALLTHROUGH; @@ -2645,7 +2645,7 @@ void Audio_SetSfxProperties(u8 bankId, u8 entryIdx, u8 channelIndex) { pan = Audio_ComputeSfxPanSigned(*entry->posX, *entry->posZ, entry->token); freqScale = Audio_ComputeSfxFreqScale(bankId, entryIdx) * *entry->freqScale; - if (sSoundMode == SOUNDMODE_SURROUND) { + if (sSoundOutputMode == SOUND_OUTPUT_SURROUND) { behindScreenZ = sBehindScreenZ[(entry->sfxParams & SFX_FLAG_10) >> SFX_FLAG_10_SHIFT]; if (!(entry->sfxParams & SFX_FLAG_11)) { if (*entry->posZ < behindScreenZ) { @@ -2677,7 +2677,7 @@ void Audio_SetSfxProperties(u8 bankId, u8 entryIdx, u8 channelIndex) { if ((baseFilter | sAudioExtraFilter) != 0) { filter = (baseFilter | sAudioExtraFilter); - } else if ((sSoundMode == SOUNDMODE_SURROUND) && !(entry->sfxParams & SFX_FLAG_13)) { + } else if ((sSoundOutputMode == SOUND_OUTPUT_SURROUND) && !(entry->sfxParams & SFX_FLAG_13)) { filter = func_800F37B8(behindScreenZ, entry, pan); } break; @@ -2884,7 +2884,7 @@ void func_800F4578(Vec3f* pos, u16 sfxId, f32 arg2) { void func_800F45D0(f32 arg0) { func_800F4414(&gSfxDefaultPos, NA_SE_IT_FISHING_REEL_SLOW - SFX_FLAG, arg0); - func_800F436C(&gSfxDefaultPos, 0, (0.15f * arg0) + 1.4f); + func_800F436C(&gSfxDefaultPos, NA_SE_NONE, (0.15f * arg0) + 1.4f); } void Audio_PlaySfxRiver(Vec3f* pos, f32 freqScale) { @@ -3775,32 +3775,40 @@ void Audio_SetCodeReverb(s8 reverb) { } } -void Audio_SetSoundMode(s8 soundSetting) { - s8 soundModeIndex; +/** + * Sets the Sound Output Mode. + * + * This function translates the game-side `SoundSetting` to an internal `SoundOutputMode` value. + * The order of each value between the two enums is slightly different. + * + * Original name: Na_SetSoundOutputMode + */ +void Audio_SetSoundOutputMode(s8 soundSetting) { + s8 soundOutputMode; switch (soundSetting) { case SOUND_SETTING_STEREO: - soundModeIndex = SOUNDMODE_STEREO; - sSoundMode = SOUNDMODE_STEREO; + soundOutputMode = SOUND_OUTPUT_STEREO; + sSoundOutputMode = SOUND_OUTPUT_STEREO; break; case SOUND_SETTING_MONO: - soundModeIndex = SOUNDMODE_MONO; - sSoundMode = SOUNDMODE_MONO; + soundOutputMode = SOUND_OUTPUT_MONO; + sSoundOutputMode = SOUND_OUTPUT_MONO; break; case SOUND_SETTING_HEADSET: - soundModeIndex = SOUNDMODE_HEADSET; - sSoundMode = SOUNDMODE_HEADSET; + soundOutputMode = SOUND_OUTPUT_HEADSET; + sSoundOutputMode = SOUND_OUTPUT_HEADSET; break; case SOUND_SETTING_SURROUND: - soundModeIndex = SOUNDMODE_STEREO; - sSoundMode = SOUNDMODE_SURROUND; + soundOutputMode = SOUND_OUTPUT_STEREO; + sSoundOutputMode = SOUND_OUTPUT_SURROUND; break; } - SEQCMD_SET_SOUND_MODE(soundModeIndex); + SEQCMD_SET_SOUND_OUTPUT_MODE(soundOutputMode); } void Audio_SetBaseFilter(u8 filter) { @@ -4048,7 +4056,7 @@ void Audio_PlayNatureAmbienceSequence(u8 natureAmbienceId) { SEQCMD_SET_CHANNEL_IO(SEQ_PLAYER_BGM_MAIN, channelIdx, ioPort, ioData); } - SEQCMD_SET_CHANNEL_IO(SEQ_PLAYER_BGM_MAIN, NATURE_CHANNEL_UNK, CHANNEL_IO_PORT_7, sSoundMode); + SEQCMD_SET_CHANNEL_IO(SEQ_PLAYER_BGM_MAIN, NATURE_CHANNEL_UNK, CHANNEL_IO_PORT_7, sSoundOutputMode); } } diff --git a/src/audio/lib/load.c b/src/audio/lib/load.c index d4c1ea864..4a0b8388e 100644 --- a/src/audio/lib/load.c +++ b/src/audio/lib/load.c @@ -1192,7 +1192,7 @@ void AudioLoad_Init(void* heap, u32 heapSize) { gAudioCtx.totalTaskCount = 0; gAudioCtx.rspTaskIndex = 0; gAudioCtx.curAiBufIndex = 0; - gAudioCtx.soundMode = SOUNDMODE_STEREO; + gAudioCtx.soundOutputMode = SOUND_OUTPUT_STEREO; gAudioCtx.curTask = NULL; gAudioCtx.rspTask[0].task.t.data_size = 0; gAudioCtx.rspTask[1].task.t.data_size = 0; diff --git a/src/audio/lib/playback.c b/src/audio/lib/playback.c index 9c1b8126e..b84fa31df 100644 --- a/src/audio/lib/playback.c +++ b/src/audio/lib/playback.c @@ -31,7 +31,7 @@ void Audio_InitNoteSub(Note* note, NoteSubEu* sub, NoteSubAttributes* attrs) { sub->bitField0.stereoStrongLeft = false; sub->bitField0.stereoHeadsetEffects = stereoData.stereoHeadsetEffects; sub->bitField0.usesHeadsetPanEffects = stereoData.usesHeadsetPanEffects; - if (stereoHeadsetEffects && (gAudioCtx.soundMode == SOUNDMODE_HEADSET)) { + if (stereoHeadsetEffects && (gAudioCtx.soundOutputMode == SOUND_OUTPUT_HEADSET)) { halfPanIndex = pan >> 1; if (halfPanIndex > 0x3F) { halfPanIndex = 0x3F; @@ -43,7 +43,7 @@ void Audio_InitNoteSub(Note* note, NoteSubEu* sub, NoteSubAttributes* attrs) { volLeft = gHeadsetPanVolume[pan]; volRight = gHeadsetPanVolume[0x7F - pan]; - } else if (stereoHeadsetEffects && (gAudioCtx.soundMode == SOUNDMODE_STEREO)) { + } else if (stereoHeadsetEffects && (gAudioCtx.soundOutputMode == SOUND_OUTPUT_STEREO)) { strongLeft = strongRight = 0; sub->haasEffectLeftDelaySize = 0; sub->haasEffectRightDelaySize = 0; @@ -80,7 +80,7 @@ void Audio_InitNoteSub(Note* note, NoteSubEu* sub, NoteSubAttributes* attrs) { break; } - } else if (gAudioCtx.soundMode == SOUNDMODE_MONO) { + } else if (gAudioCtx.soundOutputMode == SOUND_OUTPUT_MONO) { sub->bitField0.stereoHeadsetEffects = false; sub->bitField0.usesHeadsetPanEffects = false; volLeft = 0.707f; // approx 1/sqrt(2) diff --git a/src/audio/lib/synthesis.c b/src/audio/lib/synthesis.c index 85fb8d261..72bec4390 100644 --- a/src/audio/lib/synthesis.c +++ b/src/audio/lib/synthesis.c @@ -647,7 +647,7 @@ Acmd* AudioSynth_DoOneAudioUpdate(s16* aiBuf, s32 aiBufLen, Acmd* cmd, s32 updat #if OOT_VERSION < NTSC_1_1 || !PLATFORM_N64 if ((reverb->leakRtl != 0) || (reverb->leakLtr != 0)) #else - if (((reverb->leakRtl != 0) || (reverb->leakLtr != 0)) && (gAudioCtx.soundMode != SOUNDMODE_MONO)) + if (((reverb->leakRtl != 0) || (reverb->leakLtr != 0)) && (gAudioCtx.soundOutputMode != SOUND_OUTPUT_MONO)) #endif { cmd = AudioSynth_LeakReverb(cmd, reverb); diff --git a/src/audio/lib/thread.c b/src/audio/lib/thread.c index f47dbade7..6bc793e3f 100644 --- a/src/audio/lib/thread.c +++ b/src/audio/lib/thread.c @@ -226,8 +226,8 @@ void AudioThread_ProcessGlobalCmd(AudioCmd* cmd) { } break; - case AUDIOCMD_OP_GLOBAL_SET_SOUND_MODE: - gAudioCtx.soundMode = cmd->asUInt; + case AUDIOCMD_OP_GLOBAL_SET_SOUND_OUTPUT_MODE: + gAudioCtx.soundOutputMode = cmd->asUInt; break; case AUDIOCMD_OP_GLOBAL_MUTE: diff --git a/src/audio/sequence.c b/src/audio/sequence.c index a5180223c..8f6f44fed 100644 --- a/src/audio/sequence.c +++ b/src/audio/sequence.c @@ -370,9 +370,9 @@ void Audio_ProcessSeqCmd(u32 cmd) { subOp = (cmd & 0xF00) >> 8; val = cmd & 0xFF; switch (subOp) { - case SEQCMD_SUB_OP_GLOBAL_SET_SOUND_MODE: - // Set sound mode - AUDIOCMD_GLOBAL_SET_SOUND_MODE(gSoundModeList[val]); + case SEQCMD_SUB_OP_GLOBAL_SET_SOUND_OUTPUT_MODE: + // Set sound output mode + AUDIOCMD_GLOBAL_SET_SOUND_OUTPUT_MODE(gSoundOutputModes[val]); break; case SEQCMD_SUB_OP_GLOBAL_DISABLE_NEW_SEQUENCES: diff --git a/src/boot/idle.c b/src/boot/idle.c index 80f9ab607..a349a6a8a 100644 --- a/src/boot/idle.c +++ b/src/boot/idle.c @@ -5,6 +5,7 @@ #include "stackcheck.h" #include "terminal.h" #include "versions.h" +#include "vi_mode.h" #include "z64thread.h" #include "global.h" diff --git a/src/boot/z_locale.c b/src/boot/z_locale.c index a463ade7d..4d05dc5e0 100644 --- a/src/boot/z_locale.c +++ b/src/boot/z_locale.c @@ -5,6 +5,7 @@ #include "region.h" #include "terminal.h" #include "versions.h" +#include "vi_mode.h" #include "z_locale.h" #include "macros.h" diff --git a/src/boot/z_std_dma.c b/src/boot/z_std_dma.c index 341de6b28..e54c0eae1 100644 --- a/src/boot/z_std_dma.c +++ b/src/boot/z_std_dma.c @@ -36,8 +36,8 @@ #include "global.h" -#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:12 pal-1.0:10 pal-1.1:10" +#pragma increment_block_number "gc-eu:0 gc-eu-mq:0 gc-jp:0 gc-jp-ce:0 gc-jp-mq:0 gc-us:0 gc-us-mq:0 ntsc-1.2:20" \ + "pal-1.0:18 pal-1.1:18" StackEntry sDmaMgrStackInfo; OSMesgQueue sDmaMgrMsgQueue; diff --git a/src/code/graph.c b/src/code/graph.c index e53cb63ea..5f73b48b9 100644 --- a/src/code/graph.c +++ b/src/code/graph.c @@ -20,6 +20,7 @@ #include "title_setup_state.h" #include "ucode_disas.h" #include "versions.h" +#include "vi_mode.h" #include "z_game_dlftbls.h" #include "z64audio.h" #include "z64save.h" diff --git a/src/code/main.c b/src/code/main.c index 0d55858ed..014b0c14c 100644 --- a/src/code/main.c +++ b/src/code/main.c @@ -16,6 +16,7 @@ extern struct IrqMgr gIrqMgr; #include "audiomgr.h" #include "debug_arena.h" #include "fault.h" +#include "gfx.h" #include "padmgr.h" #include "prenmi_buff.h" #include "regs.h" @@ -35,7 +36,7 @@ extern struct IrqMgr gIrqMgr; #include "global.h" #pragma increment_block_number "gc-eu:32 gc-eu-mq:32 gc-jp:32 gc-jp-ce:32 gc-jp-mq:32 gc-us:32 gc-us-mq:32 ique-cn:32" \ - "ntsc-1.0:13 ntsc-1.1:13 ntsc-1.2:13 pal-1.0:11 pal-1.1:11" + "ntsc-1.0:6 ntsc-1.1:6 ntsc-1.2:6 pal-1.0:4 pal-1.1:4" extern u8 _buffersSegmentEnd[]; diff --git a/src/code/sched.c b/src/code/sched.c index 40d93f9fb..2da2e5bb5 100644 --- a/src/code/sched.c +++ b/src/code/sched.c @@ -46,6 +46,7 @@ #include "regs.h" #include "sched.h" #include "versions.h" +#include "vi_mode.h" #include "z64thread.h" #include "macros.h" diff --git a/src/code/title_setup.c b/src/code/title_setup.c index ba259e72a..cf736cf8e 100644 --- a/src/code/title_setup.c +++ b/src/code/title_setup.c @@ -1,6 +1,8 @@ #include "console_logo_state.h" #include "setup_state.h" +#include "z64save.h" + #include "global.h" void Setup_InitImpl(SetupState* this) { diff --git a/src/code/z_camera.c b/src/code/z_camera.c index 28353e3c8..69497bf7d 100644 --- a/src/code/z_camera.c +++ b/src/code/z_camera.c @@ -3656,7 +3656,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" \ - "ique-cn:128 ntsc-1.0:95 ntsc-1.1:95 ntsc-1.2:95 pal-1.0:93 pal-1.1:93" + "ique-cn:128 ntsc-1.0:102 ntsc-1.1:102 ntsc-1.2:102 pal-1.0:100 pal-1.1:100" s32 Camera_KeepOn4(Camera* camera) { static Vec3f D_8015BD50; diff --git a/src/code/z_kaleido_scope_call.c b/src/code/z_kaleido_scope_call.c index cacd46abe..2803e5299 100644 --- a/src/code/z_kaleido_scope_call.c +++ b/src/code/z_kaleido_scope_call.c @@ -1,5 +1,5 @@ -#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" \ - "ique-cn:128 ntsc-1.0:144 ntsc-1.1:144 ntsc-1.2:144 pal-1.0:144 pal-1.1:144" +#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" \ + "ique-cn:144 ntsc-1.0:144 ntsc-1.1:144 ntsc-1.2:144 pal-1.0:144 pal-1.1:144" #include "libu64/debug.h" #include "kaleido_manager.h" diff --git a/src/code/z_kankyo.c b/src/code/z_kankyo.c index 14ac015a6..36a30e175 100644 --- a/src/code/z_kankyo.c +++ b/src/code/z_kankyo.c @@ -904,9 +904,9 @@ void Environment_PrintDebugInfo(PlayState* play, Gfx** gfx) { GfxPrint_SetPos(&printer, 22, 6); if (!IS_DAY) { - GfxPrint_Printf(&printer, "%s", "YORU"); // "night" + GfxPrint_Printf(&printer, "%s", T("YORU", "NIGHT")); } else { - GfxPrint_Printf(&printer, "%s", "HIRU"); // "day" + GfxPrint_Printf(&printer, "%s", T("HIRU", "DAY")); } *gfx = GfxPrint_Close(&printer); diff --git a/src/code/z_map_exp.c b/src/code/z_map_exp.c index 348850eba..79766680d 100644 --- a/src/code/z_map_exp.c +++ b/src/code/z_map_exp.c @@ -9,6 +9,7 @@ #include "sfx.h" #include "sys_matrix.h" #include "terminal.h" +#include "z64map_mark.h" #include "z64play.h" #include "z64player.h" #include "z64save.h" diff --git a/src/code/z_play.c b/src/code/z_play.c index 69d289357..c6b769cd4 100644 --- a/src/code/z_play.c +++ b/src/code/z_play.c @@ -48,7 +48,7 @@ #include "global.h" #pragma increment_block_number "gc-eu:0 gc-eu-mq:0 gc-jp:0 gc-jp-ce:0 gc-jp-mq:0 gc-us:0 gc-us-mq:0 ique-cn:0" \ - "ntsc-1.0:224 ntsc-1.1:224 ntsc-1.2:224 pal-1.0:224 pal-1.1:224" + "ntsc-1.0:240 ntsc-1.1:240 ntsc-1.2:240 pal-1.0:240 pal-1.1:240" TransitionTile gTransitionTile; s32 gTransitionTileState; diff --git a/src/code/z_prenmi.c b/src/code/z_prenmi.c index ceb489690..7c8dcc90b 100644 --- a/src/code/z_prenmi.c +++ b/src/code/z_prenmi.c @@ -4,6 +4,7 @@ #include "regs.h" #include "terminal.h" #include "versions.h" +#include "vi_mode.h" #include "macros.h" #include "global.h" diff --git a/src/code/z_rumble.c b/src/code/z_rumble.c index 52897d629..fc811cfcc 100644 --- a/src/code/z_rumble.c +++ b/src/code/z_rumble.c @@ -15,6 +15,7 @@ #include "padmgr.h" #include "z64math.h" +static s32 sUnused[4]; RumbleMgr sRumbleMgr; /** diff --git a/src/code/z_skin.c b/src/code/z_skin.c index 508943cdd..7861acb89 100644 --- a/src/code/z_skin.c +++ b/src/code/z_skin.c @@ -6,13 +6,8 @@ #include "z64skin.h" #include "z64skin_matrix.h" -#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" \ - "pal-1.1:128" - MtxF gSkinLimbMatrices[60]; // holds matrices for each limb of the skeleton currently being drawn -static s32 sUnused; - void Skin_UpdateVertices(MtxF* mtx, SkinVertex* skinVertices, SkinLimbModif* modifEntry, Vtx* vtxBuf, Vec3f* pos) { Vtx* vtx; SkinVertex* vertexEntry; diff --git a/src/code/z_sram.c b/src/code/z_sram.c index 72823743f..8d6585ae0 100644 --- a/src/code/z_sram.c +++ b/src/code/z_sram.c @@ -1058,7 +1058,7 @@ void Sram_InitSram(GameState* gameState, SramContext* sramCtx) { PRINTF("Na_SetSoundOutputMode = %d\n", gSaveContext.soundSetting); PRINTF("Na_SetSoundOutputMode = %d\n", gSaveContext.soundSetting); PRINTF_RST(); - Audio_SetSoundMode(gSaveContext.soundSetting); + Audio_SetSoundOutputMode(gSaveContext.soundSetting); } void Sram_Alloc(GameState* gameState, SramContext* sramCtx) { diff --git a/src/libc/absf.s b/src/libc/fabsf.s similarity index 82% rename from src/libc/absf.s rename to src/libc/fabsf.s index 58450e779..6f27b4ca1 100644 --- a/src/libc/absf.s +++ b/src/libc/fabsf.s @@ -3,7 +3,7 @@ .text -LEAF(absf) +LEAF(fabsf) abs.s fv0, fa0 jr ra -END(absf) +END(fabsf) diff --git a/src/libultra/os/initialize.c b/src/libultra/os/initialize.c index 300f2743d..2da86c4a0 100644 --- a/src/libultra/os/initialize.c +++ b/src/libultra/os/initialize.c @@ -55,7 +55,7 @@ void OSINITIALIZE_FUNC(void) { __osFinalrom = true; __osSetSR(__osGetSR() | SR_CU1); - __osSetFpcCsr(FPCSR_FS | FPCSR_EV); + __osSetFpcCsr(FPCSR_FS | FPCSR_EV | FPCSR_RM_RN); #if LIBULTRA_VERSION >= LIBULTRA_VERSION_K __osSetWatchLo(0x04900000); #endif diff --git a/src/overlays/actors/ovl_Bg_Bdan_Objects/z_bg_bdan_objects.c b/src/overlays/actors/ovl_Bg_Bdan_Objects/z_bg_bdan_objects.c index c92746556..48c637d28 100644 --- a/src/overlays/actors/ovl_Bg_Bdan_Objects/z_bg_bdan_objects.c +++ b/src/overlays/actors/ovl_Bg_Bdan_Objects/z_bg_bdan_objects.c @@ -107,7 +107,9 @@ s32 BgBdanObjects_GetProperty(BgBdanObjects* this, s32 arg1) { case JABU_OBJECTS_GET_PROP_CAM_SETTING_DUNGEON1: return this->cameraSetting == CAM_SET_DUNGEON1; default: - PRINTF("Bg_Bdan_Objects_Get_Contact_Ru1\nそんな受信モードは無い%d!!!!!!!!\n", arg1); + PRINTF(T("Bg_Bdan_Objects_Get_Contact_Ru1\nそんな受信モードは無い%d!!!!!!!!\n", + "Bg_Bdan_Objects_Get_Contact_Ru1\nThere is no such receiving mode %d!!!!!!!!\n"), + arg1); return -1; } } @@ -124,7 +126,9 @@ void BgBdanObjects_SetProperty(BgBdanObjects* this, s32 arg1) { SET_INFTABLE(INFTABLE_146); break; default: - PRINTF("Bg_Bdan_Objects_Set_Contact_Ru1\nそんな送信モードは無い%d!!!!!!!!\n", arg1); + PRINTF(T("Bg_Bdan_Objects_Set_Contact_Ru1\nそんな送信モードは無い%d!!!!!!!!\n", + "Bg_Bdan_Objects_Set_Contact_Ru1\nThere is no such transmission mode %d!!!!!!!!\n"), + arg1); } } diff --git a/src/overlays/actors/ovl_Bg_Bdan_Switch/z_bg_bdan_switch.c b/src/overlays/actors/ovl_Bg_Bdan_Switch/z_bg_bdan_switch.c index 4fdf0d7de..9be1e9fbc 100644 --- a/src/overlays/actors/ovl_Bg_Bdan_Switch/z_bg_bdan_switch.c +++ b/src/overlays/actors/ovl_Bg_Bdan_Switch/z_bg_bdan_switch.c @@ -111,8 +111,9 @@ void BgBdanSwitch_InitDynaPoly(BgBdanSwitch* this, PlayState* play, CollisionHea if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_bdan_switch.c", 325, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_bdan_switch.c", 325, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -206,11 +207,13 @@ void BgBdanSwitch_Init(Actor* thisx, PlayState* play) { } break; default: - PRINTF("不正な ARG_DATA(arg_data 0x%04x)(%s %d)\n", this->dyna.actor.params, "../z_bg_bdan_switch.c", 454); + PRINTF(T("不正な", "Invalid") " ARG_DATA(arg_data 0x%04x)(%s %d)\n", this->dyna.actor.params, + "../z_bg_bdan_switch.c", 454); Actor_Kill(&this->dyna.actor); return; } - PRINTF("(巨大魚ダンジョン 専用スイッチ)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF(T("(巨大魚ダンジョン 専用スイッチ)", "(Giant Fish Dungeon Special Switch)") "(arg_data 0x%04x)\n", + this->dyna.actor.params); } void BgBdanSwitch_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Bom_Guard/z_bg_bom_guard.c b/src/overlays/actors/ovl_Bg_Bom_Guard/z_bg_bom_guard.c index ae816120b..fda95eba8 100644 --- a/src/overlays/actors/ovl_Bg_Bom_Guard/z_bg_bom_guard.c +++ b/src/overlays/actors/ovl_Bg_Bom_Guard/z_bg_bom_guard.c @@ -47,7 +47,7 @@ void BgBomGuard_Init(Actor* thisx, PlayState* play) { this->dyna.bgId = DynaPoly_SetBgActor(play, &play->colCtx.dyna, thisx, colHeader); PRINTF("\n\n"); - PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ 透明ガード出現 ☆☆☆☆☆ \n" VT_RST); + PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ " T("透明ガード出現", "Transparent guard appears") " ☆☆☆☆☆ \n" VT_RST); thisx->scale.x = 1.0f; thisx->scale.y = 1.0f; diff --git a/src/overlays/actors/ovl_Bg_Bombwall/z_bg_bombwall.c b/src/overlays/actors/ovl_Bg_Bombwall/z_bg_bombwall.c index b97d4c80b..deb347316 100644 --- a/src/overlays/actors/ovl_Bg_Bombwall/z_bg_bombwall.c +++ b/src/overlays/actors/ovl_Bg_Bombwall/z_bg_bombwall.c @@ -97,9 +97,8 @@ void BgBombwall_InitDynapoly(BgBombwall* this, PlayState* play) { this->dyna.bgId = DynaPoly_SetBgActor(play, &play->colCtx.dyna, &this->dyna.actor, colHeader); if (this->dyna.bgId == BG_ACTOR_MAX) { - // "Warning : move BG login failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_bombwall.c", 243, - this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", "Warning : move BG registration failed") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_bombwall.c", 243, this->dyna.actor.params); } } @@ -155,8 +154,8 @@ void BgBombwall_Init(Actor* thisx, PlayState* play) { func_8086ED50(this, play); } - PRINTF("(field keep 汎用爆弾壁)(arg_data 0x%04x)(angY %d)\n", this->dyna.actor.params, - this->dyna.actor.shape.rot.y); + PRINTF("(field keep " T("汎用爆弾壁", "general purpose bomb wall") ")(arg_data 0x%04x)(angY %d)\n", + this->dyna.actor.params, this->dyna.actor.shape.rot.y); } void BgBombwall_DestroyCollision(BgBombwall* this, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c b/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c index 377efc13e..f02f399f3 100644 --- a/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c +++ b/src/overlays/actors/ovl_Bg_Bowl_Wall/z_bg_bowl_wall.c @@ -72,7 +72,9 @@ void BgBowlWall_Init(Actor* thisx, PlayState* play) { this->dyna.bgId = DynaPoly_SetBgActor(play, &play->colCtx.dyna, &this->dyna.actor, colHeader); this->initPos = this->dyna.actor.world.pos; PRINTF("\n\n"); - PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ ボーリングおじゃま壁発生 ☆☆☆☆☆ %d\n" VT_RST, this->dyna.actor.params); + PRINTF( + VT_FGCOL(GREEN) " ☆☆☆☆☆ " T("ボーリングおじゃま壁発生", "Bowling obstacle wall appears") " ☆☆☆☆☆ %d\n" VT_RST, + this->dyna.actor.params); this->actionFunc = BgBowlWall_SpawnBullseyes; this->dyna.actor.scale.x = this->dyna.actor.scale.y = this->dyna.actor.scale.z = 1.0f; } diff --git a/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c b/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c index eb35f5249..39fd92089 100644 --- a/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c +++ b/src/overlays/actors/ovl_Bg_Dy_Yoseizo/z_bg_dy_yoseizo.c @@ -102,8 +102,7 @@ void BgDyYoseizo_Init(Actor* thisx, PlayState* play2) { this->actor.focus.pos = this->actor.world.pos; if (play->sceneId == SCENE_GREAT_FAIRYS_FOUNTAIN_MAGIC) { - // "Great Fairy Fountain" - PRINTF(VT_FGCOL(GREEN) "☆☆☆☆☆ 大妖精の泉 ☆☆☆☆☆ %d\n" VT_RST, play->spawn); + PRINTF(VT_FGCOL(GREEN) "☆☆☆☆☆ " T("大妖精の泉", "Great Fairy Fountain") " ☆☆☆☆☆ %d\n" VT_RST, play->spawn); SkelAnime_InitFlex(play, &this->skelAnime, &gGreatFairySkel, &gGreatFairySittingTransitionAnim, this->jointTable, this->morphTable, 28); #if OOT_VERSION < NTSC_1_1 @@ -113,8 +112,7 @@ void BgDyYoseizo_Init(Actor* thisx, PlayState* play2) { } #endif } else { - // "Stone/Jewel Fairy Fountain" - PRINTF(VT_FGCOL(GREEN) "☆☆☆☆☆ 石妖精の泉 ☆☆☆☆☆ %d\n" VT_RST, play->spawn); + PRINTF(VT_FGCOL(GREEN) "☆☆☆☆☆ " T("石妖精の泉", "Stone Fairy Fountain") " ☆☆☆☆☆ %d\n" VT_RST, play->spawn); SkelAnime_InitFlex(play, &this->skelAnime, &gGreatFairySkel, &gGreatFairyLayingDownTransitionAnim, this->jointTable, this->morphTable, 28); #if OOT_VERSION < NTSC_1_1 @@ -251,8 +249,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) { #endif Player_SetCsActionWithHaltedActors(play, &this->actor, PLAYER_CSACTION_1); - // "Mode" - PRINTF(VT_FGCOL(YELLOW) "☆☆☆☆☆ もうど ☆☆☆☆☆ %d\n" VT_RST, play->msgCtx.ocarinaMode); + PRINTF(VT_FGCOL(YELLOW) "☆☆☆☆☆ " T("もうど", "Mode") " ☆☆☆☆☆ %d\n" VT_RST, play->msgCtx.ocarinaMode); givingReward = false; if (play->sceneId != SCENE_GREAT_FAIRYS_FOUNTAIN_MAGIC) { @@ -277,24 +274,22 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) { switch (this->fountainType) { case FAIRY_UPGRADE_MAGIC: if (!gSaveContext.save.info.playerData.isMagicAcquired || BREG(2)) { - // "Spin Attack speed UP" - PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ 回転切り速度UP ☆☆☆☆☆ \n" VT_RST); + PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ " T("回転切り速度UP", "Turning speed UP") " ☆☆☆☆☆ \n" VT_RST); this->givingSpell = true; givingReward = true; } break; case FAIRY_UPGRADE_DOUBLE_MAGIC: if (!gSaveContext.save.info.playerData.isDoubleMagicAcquired) { - // "Magic Meter doubled" - PRINTF(VT_FGCOL(YELLOW) " ☆☆☆☆☆ 魔法ゲージメーター倍増 ☆☆☆☆☆ \n" VT_RST); + PRINTF(VT_FGCOL(YELLOW) " ☆☆☆☆☆ " T("魔法ゲージメーター倍増", + "Magic Gauge Meter Doubled") " ☆☆☆☆☆ \n" VT_RST); this->givingSpell = true; givingReward = true; } break; case FAIRY_UPGRADE_DOUBLE_DEFENSE: if (!gSaveContext.save.info.playerData.isDoubleDefenseAcquired) { - // "Damage halved" - PRINTF(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ ダメージ半減 ☆☆☆☆☆ \n" VT_RST); + PRINTF(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ " T("ダメージ半減", "Damage halved") " ☆☆☆☆☆ \n" VT_RST); this->givingSpell = true; givingReward = true; } diff --git a/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c b/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c index 9385ed95b..b18437bfc 100644 --- a/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c +++ b/src/overlays/actors/ovl_Bg_Gate_Shutter/z_bg_gate_shutter.c @@ -60,7 +60,7 @@ void BgGateShutter_Init(Actor* thisx, PlayState* play) { thisx->scale.y = 1.0f; thisx->scale.z = 1.0f; PRINTF("\n\n"); - PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ 柵でたなぁ ☆☆☆☆☆ \n" VT_RST); + PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ " T("柵でたなぁ", "There's a fence") " ☆☆☆☆☆ \n" VT_RST); this->actionFunc = func_8087828C; } diff --git a/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c b/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c index b28c155ed..f4e67de5a 100644 --- a/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c +++ b/src/overlays/actors/ovl_Bg_Haka_Ship/z_bg_haka_ship.c @@ -104,7 +104,7 @@ void BgHakaShip_WaitForSong(BgHakaShip* this, PlayState* play) { if (this->counter == 0) { this->counter = 130; this->actionFunc = BgHakaShip_CutsceneStationary; - PRINTF("シーン 外輪船 ... アァクション!!\n"); + PRINTF(T("シーン 外輪船 ... アァクション!!\n", "Scene paddle steamer... action!!\n")); OnePointCutscene_Init(play, 3390, 999, &this->dyna.actor, CAM_ID_MAIN); } } diff --git a/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c b/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c index ba6d3f526..7ac4c02ca 100644 --- a/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c +++ b/src/overlays/actors/ovl_Bg_Heavy_Block/z_bg_heavy_block.c @@ -162,8 +162,7 @@ void BgHeavyBlock_Init(Actor* thisx, PlayState* play) { this->actionFunc = BgHeavyBlock_Wait; break; } - // "Largest Block Save Bit %x" - PRINTF(VT_FGCOL(CYAN) " 最大 ブロック セーブビット %x\n" VT_RST, thisx->params); + PRINTF(VT_FGCOL(CYAN) T(" 最大 ブロック セーブビット %x\n", " Largest Block Save Bit %x\n") VT_RST, thisx->params); } void BgHeavyBlock_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c b/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c index a20a0a042..989ac74f5 100644 --- a/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c +++ b/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c @@ -85,9 +85,9 @@ void BgHidanCurtain_Init(Actor* thisx, PlayState* play) { Actor_SetFocus(&this->actor, 20.0f); this->type = PARAMS_GET_U(thisx->params, 12, 4); if (this->type > 6) { - // "Type is not set" - PRINTF("Error : object のタイプが設定されていない(%s %d)(arg_data 0x%04x)\n", "../z_bg_hidan_curtain.c", 352, - this->actor.params); + PRINTF(T("Error : object のタイプが設定されていない", + "Error : object type is not set") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_hidan_curtain.c", 352, this->actor.params); Actor_Kill(&this->actor); return; } @@ -98,9 +98,9 @@ void BgHidanCurtain_Init(Actor* thisx, PlayState* play) { thisx->params &= 0x3F; if (DEBUG_FEATURES && ((this->actor.params < 0) || (this->actor.params > 0x3F))) { - // "Save bit is not set" - PRINTF("Warning : object のセーブビットが設定されていない(%s %d)(arg_data 0x%04x)\n", "../z_bg_hidan_curtain.c", - 373, this->actor.params); + PRINTF(T("Warning : object のセーブビットが設定されていない", + "Warning : object save bit is not set") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_hidan_curtain.c", 373, this->actor.params); } Actor_SetScale(&this->actor, hcParams->scale); diff --git a/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c b/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c index 92ba5dd5b..e433e8984 100644 --- a/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c +++ b/src/overlays/actors/ovl_Bg_Hidan_Hamstep/z_bg_hidan_hamstep.c @@ -192,13 +192,11 @@ void BgHidanHamstep_Init(Actor* thisx, PlayState* play) { this->dyna.actor.minVelocityY = -12.0f; if (PARAMS_GET_U(this->dyna.actor.params, 0, 8) == 0) { - // "Fire Temple Object [Hammer Step] appears" - PRINTF("◯◯◯炎の神殿オブジェクト【ハンマーステップ】出現\n"); + PRINTF(T("◯◯◯炎の神殿オブジェクト【ハンマーステップ】出現\n", "◯◯◯Fire Temple object [Hammer Step] appears\n")); if (BgHidanHamstep_SpawnChildren(this, play) == 0) { step = this; - // "[Hammer Step] I can't create a step!" - PRINTF("【ハンマーステップ】 足場産れない!!\n"); + PRINTF(T("【ハンマーステップ】 足場産れない!!\n", "[Hammer Step] I can't create a step!!\n")); PRINTF("%s %d\n", "../z_bg_hidan_hamstep.c", 425); while (step != NULL) { @@ -362,8 +360,9 @@ void func_80888A58(BgHidanHamstep* this, PlayState* play) { #if DEBUG_FEATURES if (PARAMS_GET_U(this->dyna.actor.params, 0, 8) <= 0 || PARAMS_GET_U(this->dyna.actor.params, 0, 8) >= 6) { - // "[Hammer Step] arg_data strange (arg_data = %d)" - PRINTF("【ハンマーステップ】 arg_data おかしい (arg_data = %d)", this->dyna.actor.params); + PRINTF(T("【ハンマーステップ】 arg_data おかしい (arg_data = %d)", + "[Hammer Step] arg_data strange (arg_data = %d)"), + this->dyna.actor.params); PRINTF("%s %d\n", "../z_bg_hidan_hamstep.c", 696); } #endif diff --git a/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c b/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c index bce57124e..90068065c 100644 --- a/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c +++ b/src/overlays/actors/ovl_Bg_Hidan_Kousi/z_bg_hidan_kousi.c @@ -79,14 +79,15 @@ void BgHidanKousi_Init(Actor* thisx, PlayState* play) { DynaPolyActor_Init(&this->dyna, 0); Actor_SetFocus(thisx, 50.0f); - PRINTF("◯◯◯炎の神殿オブジェクト【格子(arg_data : %0x)】出現 (%d %d)\n", thisx->params, - PARAMS_GET_U(thisx->params, 0, 8), PARAMS_GET_U((s32)thisx->params, 8, 8)); + PRINTF(T("◯◯◯炎の神殿オブジェクト【格子(arg_data : %0x)】出現 (%d %d)\n", + "◯◯◯ Fire Temple object [lattice (arg_data : %0x)] appeared (%d %d)\n"), + thisx->params, PARAMS_GET_U(thisx->params, 0, 8), PARAMS_GET_U((s32)thisx->params, 8, 8)); Actor_ProcessInitChain(thisx, sInitChain); #if DEBUG_FEATURES if (PARAMS_GET_U(thisx->params, 0, 8) < 0 || PARAMS_GET_U(thisx->params, 0, 8) >= 3) { - PRINTF("arg_data おかしい 【格子】\n"); + PRINTF(T("arg_data おかしい 【格子】\n", "arg_data is strange [lattice]\n")); } #endif diff --git a/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c b/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c index 27312b4fa..bf97dee41 100644 --- a/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c +++ b/src/overlays/actors/ovl_Bg_Hidan_Kowarerukabe/z_bg_hidan_kowarerukabe.c @@ -129,9 +129,10 @@ void BgHidanKowarerukabe_Init(Actor* thisx, PlayState* play) { if (PARAMS_GET_U(this->dyna.actor.params, 0, 8) < CRACKED_STONE_FLOOR || PARAMS_GET_U(this->dyna.actor.params, 0, 8) > LARGE_BOMBABLE_WALL) { - // "Error: Fire Temple Breakable Walls. arg_data I can't determine the (%s %d)(arg_data 0x%04x)" - PRINTF("Error : 炎の神殿 壊れる壁 の arg_data が判別出来ない(%s %d)(arg_data 0x%04x)\n", - "../z_bg_hidan_kowarerukabe.c", 254, this->dyna.actor.params); + PRINTF( + T("Error : 炎の神殿 壊れる壁 の arg_data が判別出来ない", + "Error : arg_data for the Fire Temple breakable wall cannot be determined") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_hidan_kowarerukabe.c", 254, this->dyna.actor.params); Actor_Kill(&this->dyna.actor); return; } @@ -145,8 +146,8 @@ void BgHidanKowarerukabe_Init(Actor* thisx, PlayState* play) { Actor_SetScale(&this->dyna.actor, 0.1f); BgHidanKowarerukabe_InitColliderSphere(this, play); BgHidanKowarerukabe_OffsetActorYPos(this); - // "(fire walls, floors, destroyed by bombs)(arg_data 0x%04x)" - PRINTF("(hidan 爆弾で壊れる 壁 床)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF(T("(hidan 爆弾で壊れる 壁 床)", "(hidan bomb destroys walls and floors)") "(arg_data 0x%04x)\n", + this->dyna.actor.params); } void BgHidanKowarerukabe_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c b/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c index 0b19f74e6..38810434a 100644 --- a/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c +++ b/src/overlays/actors/ovl_Bg_Ice_Shelter/z_bg_ice_shelter.c @@ -135,9 +135,9 @@ void BgIceShelter_InitDynaPoly(BgIceShelter* this, PlayState* play, CollisionHea if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG registration failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_ice_shelter.c", 362, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_ice_shelter.c", 362, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Bg_Jya_1flift/z_bg_jya_1flift.c b/src/overlays/actors/ovl_Bg_Jya_1flift/z_bg_jya_1flift.c index 94fd0883d..f5420e381 100644 --- a/src/overlays/actors/ovl_Bg_Jya_1flift/z_bg_jya_1flift.c +++ b/src/overlays/actors/ovl_Bg_Jya_1flift/z_bg_jya_1flift.c @@ -85,9 +85,9 @@ void BgJya1flift_InitDynapoly(BgJya1flift* this, PlayState* play, CollisionHeade if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG login failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_jya_1flift.c", 179, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_jya_1flift.c", 179, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -102,8 +102,7 @@ void BgJya1flift_InitCollision(Actor* thisx, PlayState* play) { void BgJya1flift_Init(Actor* thisx, PlayState* play) { BgJya1flift* this = (BgJya1flift*)thisx; - // "1 F lift" - PRINTF("(1Fリフト)(flag %d)(room %d)\n", sIsSpawned, play->roomCtx.curRoom.num); + PRINTF(T("(1Fリフト)", "1F lift") "(flag %d)(room %d)\n", sIsSpawned, play->roomCtx.curRoom.num); this->hasInitialized = false; if (sIsSpawned) { Actor_Kill(thisx); diff --git a/src/overlays/actors/ovl_Bg_Jya_Amishutter/z_bg_jya_amishutter.c b/src/overlays/actors/ovl_Bg_Jya_Amishutter/z_bg_jya_amishutter.c index e97451e86..dc6b02fb5 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Amishutter/z_bg_jya_amishutter.c +++ b/src/overlays/actors/ovl_Bg_Jya_Amishutter/z_bg_jya_amishutter.c @@ -60,8 +60,9 @@ void BgJyaAmishutter_InitDynaPoly(BgJyaAmishutter* this, PlayState* play, Collis if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_jya_amishutter.c", 129, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_jya_amishutter.c", 129, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c b/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c index 7a3606213..185d11c57 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c +++ b/src/overlays/actors/ovl_Bg_Jya_Bigmirror/z_bg_jya_bigmirror.c @@ -83,8 +83,8 @@ void BgJyaBigmirror_HandleCobra(Actor* thisx, PlayState* play) { #if DEBUG_FEATURES if (curCobraInfo->cobra->dyna.actor.update == NULL) { - // "Cobra deleted" - PRINTF("Error : コブラ削除された (%s %d)\n", "../z_bg_jya_bigmirror.c", 203); + PRINTF("Error : " T("コブラ削除された", "Cobra deleted") " (%s %d)\n", "../z_bg_jya_bigmirror.c", + 203); } #endif } else { @@ -94,8 +94,8 @@ void BgJyaBigmirror_HandleCobra(Actor* thisx, PlayState* play) { this->actor.child = NULL; if (curCobraInfo->cobra == NULL) { - // "Cobra generation failed" - PRINTF("Error : コブラ発生失敗 (%s %d)\n", "../z_bg_jya_bigmirror.c", 221); + PRINTF("Error : " T("コブラ発生失敗", "Cobra generation failed") " (%s %d)\n", + "../z_bg_jya_bigmirror.c", 221); } } } @@ -162,8 +162,8 @@ void BgJyaBigmirror_HandleMirRay(Actor* thisx, PlayState* play) { #if DEBUG_FEATURES if (this->lightBeams[i] == NULL) { - // "Mir Ray generation failed" - PRINTF("Error : Mir Ray 発生失敗 (%s %d)\n", "../z_bg_jya_bigmirror.c", 310); + PRINTF("Error : " T("Mir Ray 発生失敗", "Mir Ray generation failed") " (%s %d)\n", + "../z_bg_jya_bigmirror.c", 310); } #endif } @@ -194,8 +194,7 @@ void BgJyaBigmirror_Init(Actor* thisx, PlayState* play) { this->spawned = true; this->mirRayObjectSlot = -1; - // "jya Bigmirror" - PRINTF("(jya 大鏡)(arg_data 0x%04x)\n", this->actor.params); + PRINTF("(jya " T("大鏡", "Big mirror") ")(arg_data 0x%04x)\n", this->actor.params); } void BgJyaBigmirror_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c b/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c index 5b1c869ea..2491cb5d4 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c +++ b/src/overlays/actors/ovl_Bg_Jya_Bombchuiwa/z_bg_jya_bombchuiwa.c @@ -193,9 +193,8 @@ void BgJyaBombchuiwa_SpawnLightRay(BgJyaBombchuiwa* this, PlayState* play) { BgJyaBombchuiwa_SetDrawFlags(this, 4); if (Actor_Spawn(&play->actorCtx, play, ACTOR_MIR_RAY, this->actor.world.pos.x, this->actor.world.pos.y, this->actor.world.pos.z, 0, 0, 0, 0) == NULL) { - // "Occurrence failure" - PRINTF("Error : Mir_Ray 発生失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_jya_bombchuiwa.c", 410, - this->actor.params); + PRINTF(T("Error : Mir_Ray 発生失敗", "Error : Mir_Ray failed to occur") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_jya_bombchuiwa.c", 410, this->actor.params); } } diff --git a/src/overlays/actors/ovl_Bg_Jya_Bombiwa/z_bg_jya_bombiwa.c b/src/overlays/actors/ovl_Bg_Jya_Bombiwa/z_bg_jya_bombiwa.c index ea2dd59eb..a1c5f82a4 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Bombiwa/z_bg_jya_bombiwa.c +++ b/src/overlays/actors/ovl_Bg_Jya_Bombiwa/z_bg_jya_bombiwa.c @@ -81,9 +81,9 @@ void BgJyaBombiwa_SetupDynaPoly(BgJyaBombiwa* this, PlayState* play, CollisionHe if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning: move BG registration failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_jya_bombiwa.c", 174, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_jya_bombiwa.c", 174, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -100,10 +100,9 @@ void BgJyaBombiwa_Init(Actor* thisx, PlayState* play) { if (PARAMS_GET_U(this->dyna.actor.params, 0, 6) != 0x29) { PRINTF_COLOR_WARNING(); - - // "Warning: Switch Number changed (%s %d)(SW %d)" - PRINTF("Warning : Switch Number が変更された(%s %d)(SW %d)\n", "../z_bg_jya_bombiwa.c", 218, - PARAMS_GET_U(this->dyna.actor.params, 0, 6)); + PRINTF(T("Warning : Switch Number が変更された", + "Warning : Switch Number has been changed") "(%s %d)(SW %d)\n", + "../z_bg_jya_bombiwa.c", 218, PARAMS_GET_U(this->dyna.actor.params, 0, 6)); PRINTF_RST(); } BgJyaBombiwa_SetupDynaPoly(this, play, &gBombiwaCol, 0); @@ -113,8 +112,7 @@ void BgJyaBombiwa_Init(Actor* thisx, PlayState* play) { } else { Actor_ProcessInitChain(&this->dyna.actor, sInitChain); - // "Rock destroyed by jya bomb" - PRINTF("(jya 爆弾で破壊岩)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF(T("(jya 爆弾で破壊岩)", "(jya bomb destroys rocks)") "(arg_data 0x%04x)\n", this->dyna.actor.params); } } diff --git a/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c b/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c index 6380e0cf6..67ac8f8b8 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c +++ b/src/overlays/actors/ovl_Bg_Jya_Cobra/z_bg_jya_cobra.c @@ -137,9 +137,9 @@ void BgJyaCobra_InitDynapoly(BgJyaCobra* this, PlayState* play, CollisionHeader* if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG Registration Failure" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_jya_cobra.c", 247, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_jya_cobra.c", 247, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -151,8 +151,8 @@ void BgJyaCobra_SpawnRay(BgJyaCobra* this, PlayState* play) { #if DEBUG_FEATURES if (this->dyna.actor.child == NULL) { PRINTF_COLOR_RED(); - // "Error : Mir Ray occurrence failure" - PRINTF("Error : Mir Ray 発生失敗 (%s %d)\n", "../z_bg_jya_cobra.c", 270); + PRINTF(T("Error : Mir Ray 発生失敗", "Error : Mir Ray failed to occur") " (%s %d)\n", + "../z_bg_jya_cobra.c", 270); PRINTF_RST(); } #endif @@ -437,8 +437,7 @@ void BgJyaCobra_Init(Actor* thisx, PlayState* play) { BgJyaCobra_UpdateShadowFromTop(this); } - // "(jya cobra)" - PRINTF("(jya コブラ)(arg_data 0x%04x)(act %x)(txt %x)(txt16 %x)\n", this->dyna.actor.params, this, + PRINTF("(jya " T("コブラ", "cobra") ")(arg_data 0x%04x)(act %x)(txt %x)(txt16 %x)\n", this->dyna.actor.params, this, &this->shadowTextureBuffer, COBRA_SHADOW_TEX_PTR(this)); } diff --git a/src/overlays/actors/ovl_Bg_Jya_Ironobj/z_bg_jya_ironobj.c b/src/overlays/actors/ovl_Bg_Jya_Ironobj/z_bg_jya_ironobj.c index 3ecb0cb2f..ead84b2fc 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Ironobj/z_bg_jya_ironobj.c +++ b/src/overlays/actors/ovl_Bg_Jya_Ironobj/z_bg_jya_ironobj.c @@ -117,7 +117,8 @@ void BgJyaIronobj_SpawnPillarParticles(BgJyaIronobj* this, PlayState* play, EnIk #if DEBUG_FEATURES if (enIk->unk_2FF <= 0 || enIk->unk_2FF >= 4) { - PRINTF("Error 攻撃方法が分からない(%s %d)\n", "../z_bg_jya_ironobj.c", 233); + PRINTF(T("Error 攻撃方法が分からない(%s %d)\n", "Error I don't know how to attack(%s %d)\n"), + "../z_bg_jya_ironobj.c", 233); return; } #endif @@ -183,7 +184,8 @@ void BgJyaIronobj_SpawnThroneParticles(BgJyaIronobj* this, PlayState* play, EnIk #if DEBUG_FEATURES if (enIk->unk_2FF <= 0 || enIk->unk_2FF >= 4) { - PRINTF("Error 攻撃方法が分からない(%s %d)\n", "../z_bg_jya_ironobj.c", 362); + PRINTF(T("Error 攻撃方法が分からない(%s %d)\n", "Error I don't know how to attack(%s %d)\n"), + "../z_bg_jya_ironobj.c", 362); return; } #endif diff --git a/src/overlays/actors/ovl_Bg_Jya_Kanaami/z_bg_jya_kanaami.c b/src/overlays/actors/ovl_Bg_Jya_Kanaami/z_bg_jya_kanaami.c index 7aead7406..59a9bf772 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Kanaami/z_bg_jya_kanaami.c +++ b/src/overlays/actors/ovl_Bg_Jya_Kanaami/z_bg_jya_kanaami.c @@ -59,8 +59,9 @@ void BgJyaKanaami_InitDynaPoly(BgJyaKanaami* this, PlayState* play, CollisionHea if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_jya_kanaami.c", 145, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_jya_kanaami.c", 145, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -75,7 +76,7 @@ void BgJyaKanaami_Init(Actor* thisx, PlayState* play) { } else { func_80899880(this); } - PRINTF("(jya 金網)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF("(jya " T("金網", "wire mesh") ")(arg_data 0x%04x)\n", this->dyna.actor.params); } void BgJyaKanaami_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Jya_Lift/z_bg_jya_lift.c b/src/overlays/actors/ovl_Bg_Jya_Lift/z_bg_jya_lift.c index 50571f8ac..d11b694b8 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Lift/z_bg_jya_lift.c +++ b/src/overlays/actors/ovl_Bg_Jya_Lift/z_bg_jya_lift.c @@ -66,8 +66,7 @@ void BgJyaLift_Init(Actor* thisx, PlayState* play) { return; } - // "Goddess lift CT" - PRINTF("女神リフト CT\n"); + PRINTF(T("女神リフト CT\n", "Goddess lift CT\n")); BgJyaLift_InitDynapoly(this, play, &gLiftCol, 0); Actor_ProcessInitChain(thisx, sInitChain); if (Flags_GetSwitch(play, PARAMS_GET_U(thisx->params, 0, 6))) { @@ -85,8 +84,7 @@ void BgJyaLift_Destroy(Actor* thisx, PlayState* play) { if (this->isSpawned) { - // "Goddess Lift DT" - PRINTF("女神リフト DT\n"); + PRINTF(T("女神リフト DT\n", "Goddess lift DT\n")); sIsSpawned = false; DynaPoly_DeleteBgActor(play, &play->colCtx.dyna, this->dyna.bgId); } diff --git a/src/overlays/actors/ovl_Bg_Jya_Zurerukabe/z_bg_jya_zurerukabe.c b/src/overlays/actors/ovl_Bg_Jya_Zurerukabe/z_bg_jya_zurerukabe.c index 4dea26882..2cd57e7d9 100644 --- a/src/overlays/actors/ovl_Bg_Jya_Zurerukabe/z_bg_jya_zurerukabe.c +++ b/src/overlays/actors/ovl_Bg_Jya_Zurerukabe/z_bg_jya_zurerukabe.c @@ -78,8 +78,9 @@ void BgJyaZurerukabe_InitDynaPoly(BgJyaZurerukabe* this, PlayState* play, Collis if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_jya_zurerukabe.c", 194, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_jya_zurerukabe.c", 194, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -133,14 +134,14 @@ void BgJyaZurerukabe_Init(Actor* thisx, PlayState* play) { if (i == ARRAY_COUNT(D_8089B9F0)) { PRINTF_COLOR_ERROR(); - PRINTF("home pos が変更されたみたい(%s %d)(arg_data 0x%04x)\n", "../z_bg_jya_zurerukabe.c", 299, - this->dyna.actor.params); + PRINTF(T("home pos が変更されたみたい", "It seems that the home pos has changed") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_jya_zurerukabe.c", 299, this->dyna.actor.params); PRINTF_RST(); } this->unk_16E = D_8089B9F8[this->unk_168]; func_8089B7B4(this); - PRINTF("(jya ずれる壁)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF("(jya " T("ずれる壁", "sliding wall") ")(arg_data 0x%04x)\n", this->dyna.actor.params); } void BgJyaZurerukabe_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c b/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c index 787739822..56c1dae9e 100644 --- a/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c +++ b/src/overlays/actors/ovl_Bg_Mizu_Bwall/z_bg_mizu_bwall.c @@ -208,8 +208,9 @@ void BgMizuBwall_Init(Actor* thisx, PlayState* play) { Collider_InitTris(play, &this->collider); if (!Collider_SetTris(play, &this->collider, &this->dyna.actor, &sTrisInitFloor, this->colliderElements)) { - PRINTF("Error : コリジョンデータセット失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_mizu_bwall.c", 484, - this->dyna.actor.params); + PRINTF(T("Error : コリジョンデータセット失敗", + "Error : Collision data set failure") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_mizu_bwall.c", 484, this->dyna.actor.params); Actor_Kill(&this->dyna.actor); } else { sin = Math_SinS(this->dyna.actor.shape.rot.y); @@ -248,8 +249,9 @@ void BgMizuBwall_Init(Actor* thisx, PlayState* play) { Collider_InitTris(play, &this->collider); if (!Collider_SetTris(play, &this->collider, &this->dyna.actor, &sTrisInitRutoWall, this->colliderElements)) { - PRINTF("Error : コリジョンデータセット失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_mizu_bwall.c", 558, - this->dyna.actor.params); + PRINTF(T("Error : コリジョンデータセット失敗", + "Error : Collision data set failure") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_mizu_bwall.c", 558, this->dyna.actor.params); Actor_Kill(&this->dyna.actor); } else { sin = Math_SinS(this->dyna.actor.shape.rot.y); @@ -288,8 +290,9 @@ void BgMizuBwall_Init(Actor* thisx, PlayState* play) { Collider_InitTris(play, &this->collider); if (!Collider_SetTris(play, &this->collider, &this->dyna.actor, &sTrisInitUnusedWall, this->colliderElements)) { - PRINTF("Error : コリジョンデータセット失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_mizu_bwall.c", 638, - this->dyna.actor.params); + PRINTF(T("Error : コリジョンデータセット失敗", + "Error : Collision data set failure") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_mizu_bwall.c", 638, this->dyna.actor.params); Actor_Kill(&this->dyna.actor); } else { sin = Math_SinS(this->dyna.actor.shape.rot.y); @@ -330,8 +333,9 @@ void BgMizuBwall_Init(Actor* thisx, PlayState* play) { Collider_InitTris(play, &this->collider); if (!Collider_SetTris(play, &this->collider, &this->dyna.actor, &sTrisInitStingerWall, this->colliderElements)) { - PRINTF("Error : コリジョンデータセット失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_mizu_bwall.c", 724, - this->dyna.actor.params); + PRINTF(T("Error : コリジョンデータセット失敗", + "Error : Collision data set failure") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_mizu_bwall.c", 724, this->dyna.actor.params); Actor_Kill(&this->dyna.actor); } else { sin = Math_SinS(this->dyna.actor.shape.rot.y); @@ -372,8 +376,9 @@ void BgMizuBwall_Init(Actor* thisx, PlayState* play) { Collider_InitTris(play, &this->collider); if (!Collider_SetTris(play, &this->collider, &this->dyna.actor, &sTrisInitStingerWall, this->colliderElements)) { - PRINTF("Error : コリジョンデータセット失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_mizu_bwall.c", 798, - this->dyna.actor.params); + PRINTF(T("Error : コリジョンデータセット失敗", + "Error : Collision data set failure") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_mizu_bwall.c", 798, this->dyna.actor.params); Actor_Kill(&this->dyna.actor); } else { sin = Math_SinS(this->dyna.actor.shape.rot.y); diff --git a/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c b/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c index 5a59ddd68..ab3ef48c6 100644 --- a/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c +++ b/src/overlays/actors/ovl_Bg_Mizu_Water/z_bg_mizu_water.c @@ -120,7 +120,8 @@ void BgMizuWater_Init(Actor* thisx, PlayState* play) { switch (this->type) { case 0: if (bREG(15) == 0) { - PRINTF("<コンストラクト>%x %x %x\n", Flags_GetSwitch(play, WATER_TEMPLE_WATER_F1_FLAG), + PRINTF(T("<コンストラクト>", "") "%x %x %x\n", + Flags_GetSwitch(play, WATER_TEMPLE_WATER_F1_FLAG), Flags_GetSwitch(play, WATER_TEMPLE_WATER_F2_FLAG), Flags_GetSwitch(play, WATER_TEMPLE_WATER_F3_FLAG)); } diff --git a/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c b/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c index 9bc16b1fe..3370bf4b8 100644 --- a/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c +++ b/src/overlays/actors/ovl_Bg_Mori_Bigst/z_bg_mori_bigst.c @@ -72,9 +72,9 @@ void BgMoriBigst_InitDynapoly(BgMoriBigst* this, PlayState* play, CollisionHeade if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG login failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_mori_bigst.c", 190, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_mori_bigst.c", 190, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -83,17 +83,16 @@ void BgMoriBigst_Init(Actor* thisx, PlayState* play) { s32 pad; BgMoriBigst* this = (BgMoriBigst*)thisx; - // "mori (bigST.keyceiling)" - PRINTF("mori (bigST.鍵型天井)(arg : %04x)(sw %d)(noE %d)(roomC %d)(playerPosY %f)\n", this->dyna.actor.params, - Flags_GetSwitch(play, PARAMS_GET_U(this->dyna.actor.params, 8, 6)), + PRINTF(T("mori (bigST.鍵型天井)", + "mori (bigST. key-shaped ceiling)") "(arg : %04x)(sw %d)(noE %d)(roomC %d)(playerPosY %f)\n", + this->dyna.actor.params, Flags_GetSwitch(play, PARAMS_GET_U(this->dyna.actor.params, 8, 6)), Flags_GetTempClear(play, this->dyna.actor.room), Flags_GetClear(play, this->dyna.actor.room), GET_PLAYER(play)->actor.world.pos.y); BgMoriBigst_InitDynapoly(this, play, &gMoriBigstCol, 0); Actor_ProcessInitChain(&this->dyna.actor, sInitChain); this->moriTexObjectSlot = Object_GetSlot(&play->objectCtx, OBJECT_MORI_TEX); if (this->moriTexObjectSlot < 0) { - // "【Big Stalfos key ceiling】 bank danger!" - PRINTF("【ビッグスタルフォス鍵型天井】 バンク危険!\n"); + PRINTF(T("【ビッグスタルフォス鍵型天井】 バンク危険!\n", "[Big Stalfos Key-shaped Ceiling] Bank danger!\n")); PRINTF("%s %d\n", "../z_bg_mori_bigst.c", 234); Actor_Kill(&this->dyna.actor); return; @@ -150,8 +149,7 @@ void BgMoriBigst_SetupStalfosFight(BgMoriBigst* this, PlayState* play) { this->dyna.actor.child = NULL; this->dyna.actor.home.rot.z++; } else { - // "Second Stalfos failure" - PRINTF("Warning : 第2スタルフォス発生失敗\n"); + PRINTF(T("Warning : 第2スタルフォス発生失敗\n", "Warning : Second Stalfos failed to generate\n")); } Flags_SetClear(play, this->dyna.actor.room); } @@ -212,8 +210,7 @@ void BgMoriBigst_SetupStalfosPairFight(BgMoriBigst* this, PlayState* play) { this->dyna.actor.child = NULL; this->dyna.actor.home.rot.z++; } else { - // "Warning: 3-1 Stalfos failure" - PRINTF("Warning : 第3-1スタルフォス発生失敗\n"); + PRINTF(T("Warning : 第3-1スタルフォス発生失敗\n", "Warning : 3-1 Stalfos generation failure\n")); } stalfos2 = Actor_SpawnAsChild(&play->actorCtx, &this->dyna.actor, play, ACTOR_EN_TEST, 170.0f, 827.0f, -3260.0f, 0, 0, 0, 5); @@ -221,8 +218,7 @@ void BgMoriBigst_SetupStalfosPairFight(BgMoriBigst* this, PlayState* play) { this->dyna.actor.child = NULL; this->dyna.actor.home.rot.z++; } else { - // "Warning: 3-2 Stalfos failure" - PRINTF("Warning : 第3-2スタルフォス発生失敗\n"); + PRINTF(T("Warning : 第3-2スタルフォス発生失敗\n", "Warning : 3-2 Stalfos generation failure\n")); } Flags_SetClear(play, this->dyna.actor.room); } diff --git a/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c b/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c index 53206ecf7..5a27f36ff 100644 --- a/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c +++ b/src/overlays/actors/ovl_Bg_Mori_Elevator/z_bg_mori_elevator.c @@ -103,16 +103,16 @@ void BgMoriElevator_Init(Actor* thisx, PlayState* play) { #if DEBUG_FEATURES if (this->moriTexObjectSlot < 0) { Actor_Kill(thisx); - // "Forest Temple obj elevator Bank Danger!" - PRINTF("Error : 森の神殿 obj elevator バンク危険!(%s %d)\n", "../z_bg_mori_elevator.c", 277); + PRINTF(T("Error : 森の神殿 obj elevator バンク危険!(%s %d)\n", + "Error : Forest Temple obj elevator bank danger! (%s %d)\n"), + "../z_bg_mori_elevator.c", 277); return; } #endif switch (sIsSpawned) { case false: - // "Forest Temple elevator CT" - PRINTF("森の神殿 elevator CT\n"); + PRINTF(T("森の神殿 elevator CT\n", "Forest Temple elevator CT\n")); sIsSpawned = true; this->dyna.actor.room = -1; Actor_ProcessInitChain(&this->dyna.actor, sInitChain); @@ -131,8 +131,7 @@ void BgMoriElevator_Destroy(Actor* thisx, PlayState* play) { BgMoriElevator* this = (BgMoriElevator*)thisx; if (this->unk_172 == 0) { - // "Forest Temple elevator DT" - PRINTF("森の神殿 elevator DT\n"); + PRINTF(T("森の神殿 elevator DT\n", "Forest Temple elevator DT\n")); DynaPoly_DeleteBgActor(play, &play->colCtx.dyna, this->dyna.bgId); sIsSpawned = false; } @@ -155,8 +154,9 @@ void BgMoriElevator_WaitAfterInit(BgMoriElevator* this, PlayState* play) { this->dyna.actor.world.pos.y = 73.0f; BgMoriElevator_SetupSetPosition(this); } else { - // "Error: Forest Temple obj elevator Room setting is dangerous" - PRINTF("Error : 森の神殿 obj elevator 部屋設定が危険(%s %d)\n", "../z_bg_mori_elevator.c", 371); + PRINTF(T("Error : 森の神殿 obj elevator 部屋設定が危険(%s %d)\n", + "Error : Forest Temple obj elevator room setting is dangerous(%s %d)\n"), + "../z_bg_mori_elevator.c", 371); } } else { BgMoriElevator_SetupSetPosition(this); @@ -217,7 +217,9 @@ void BgMoriElevator_SetPosition(BgMoriElevator* this, PlayState* play) { BgMoriElevator_StopMovement(this); } else { // "Error:Forest Temple obj elevator Room setting is dangerous(%s %d)" - PRINTF("Error : 森の神殿 obj elevator 部屋設定が危険(%s %d)\n", "../z_bg_mori_elevator.c", 479); + PRINTF(T("Error : 森の神殿 obj elevator 部屋設定が危険(%s %d)\n", + "Error : Forest Temple obj elevator room setting is dangerous(%s %d)\n"), + "../z_bg_mori_elevator.c", 479); } } else if ((play->roomCtx.curRoom.num == 2) && (this->dyna.actor.world.pos.y < -275.0f)) { this->targetY = 233.0f; diff --git a/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c b/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c index b75117adc..dfb4b78c7 100644 --- a/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c +++ b/src/overlays/actors/ovl_Bg_Mori_Hashigo/z_bg_mori_hashigo.c @@ -99,9 +99,9 @@ void BgMoriHashigo_InitDynapoly(BgMoriHashigo* this, PlayState* play, CollisionH if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG login failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_mori_hashigo.c", 164, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_mori_hashigo.c", 164, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -137,9 +137,8 @@ s32 BgMoriHashigo_SpawnLadder(BgMoriHashigo* this, PlayState* play) { if (ladder != NULL) { return true; } else { - // "Ladder failure" - PRINTF("Error : 梯子の発生失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_mori_hashigo.c", 220, - this->dyna.actor.params); + PRINTF("Error : " T("梯子の発生失敗", "Ladder spawn failure") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_mori_hashigo.c", 220, this->dyna.actor.params); return false; } } @@ -179,14 +178,13 @@ void BgMoriHashigo_Init(Actor* thisx, PlayState* play) { } this->moriTexObjectSlot = Object_GetSlot(&play->objectCtx, OBJECT_MORI_TEX); if (this->moriTexObjectSlot < 0) { - // "Bank danger!" - PRINTF("Error : バンク危険!(arg_data 0x%04x)(%s %d)\n", this->dyna.actor.params, "../z_bg_mori_hashigo.c", - 312); + PRINTF("Error : " T("バンク危険!", "Bank danger!") "(arg_data 0x%04x)(%s %d)\n", this->dyna.actor.params, + "../z_bg_mori_hashigo.c", 312); Actor_Kill(&this->dyna.actor); } else { BgMoriHashigo_SetupWaitForMoriTex(this); - // "(Forest Temple Ladder and its clasp)" - PRINTF("(森の神殿 梯子とその留め金)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF(T("(森の神殿 梯子とその留め金)", "(Forest Temple Ladder and its clasp)") "(arg_data 0x%04x)\n", + this->dyna.actor.params); } } diff --git a/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c b/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c index 9f3b50dad..3754749db 100644 --- a/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c +++ b/src/overlays/actors/ovl_Bg_Mori_Hashira4/z_bg_mori_hashira4.c @@ -70,9 +70,9 @@ void BgMoriHashira4_InitDynaPoly(BgMoriHashira4* this, PlayState* play, Collisio if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG login failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_mori_hashira4.c", 155, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_mori_hashira4.c", 155, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -93,9 +93,8 @@ void BgMoriHashira4_Init(Actor* thisx, PlayState* play) { this->moriTexObjectSlot = Object_GetSlot(&play->objectCtx, OBJECT_MORI_TEX); if (this->moriTexObjectSlot < 0) { Actor_Kill(&this->dyna.actor); - // "Bank danger!" - PRINTF("Error : バンク危険!(arg_data 0x%04x)(%s %d)\n", this->dyna.actor.params, "../z_bg_mori_hashira4.c", - 196); + PRINTF("Error : " T("バンク危険!", "Bank danger!") "(arg_data 0x%04x)(%s %d)\n", this->dyna.actor.params, + "../z_bg_mori_hashira4.c", 196); return; } if ((this->dyna.actor.params != 0) && Flags_GetSwitch(play, this->switchFlag)) { @@ -104,8 +103,7 @@ void BgMoriHashira4_Init(Actor* thisx, PlayState* play) { } Actor_SetFocus(&this->dyna.actor, 50.0f); BgMoriHashira4_SetupWaitForMoriTex(this); - // "(4 pillars of the Forest Temple) Bank danger" - PRINTF("(森の神殿 4本柱)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF(T("(森の神殿 4本柱)", "Forest Temple 4 Pillars") "(arg_data 0x%04x)\n", this->dyna.actor.params); sUnkTimer = 0; } diff --git a/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c b/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c index 051e7c687..875f177ab 100644 --- a/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c +++ b/src/overlays/actors/ovl_Bg_Mori_Idomizu/z_bg_mori_idomizu.c @@ -78,16 +78,15 @@ void BgMoriIdomizu_Init(Actor* thisx, PlayState* play) { this->moriTexObjectSlot = Object_GetSlot(&play->objectCtx, OBJECT_MORI_TEX); if (this->moriTexObjectSlot < 0) { Actor_Kill(&this->actor); - // "Bank danger!" - PRINTF("Error : バンク危険!(arg_data 0x%04x)(%s %d)\n", this->actor.params, "../z_bg_mori_idomizu.c", 202); + PRINTF("Error : " T("バンク危険!", "Bank danger!") "(arg_data 0x%04x)(%s %d)\n", this->actor.params, + "../z_bg_mori_idomizu.c", 202); return; } BgMoriIdomizu_SetupWaitForMoriTex(this); sIsSpawned = true; this->isLoaded = true; this->actor.room = -1; - // "Forest Temple well water" - PRINTF("(森の神殿 井戸水)(arg_data 0x%04x)\n", this->actor.params); + PRINTF(T("(森の神殿 井戸水)", "(Forest Temple well water)") "(arg_data 0x%04x)\n", this->actor.params); } void BgMoriIdomizu_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c b/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c index 0b22e202b..0e5748ae9 100644 --- a/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c +++ b/src/overlays/actors/ovl_Bg_Mori_Kaitenkabe/z_bg_mori_kaitenkabe.c @@ -60,8 +60,9 @@ void BgMoriKaitenkabe_Init(Actor* thisx, PlayState* play) { BgMoriKaitenkabe* this = (BgMoriKaitenkabe*)thisx; CollisionHeader* colHeader = NULL; - // "Forest Temple object 【Rotating Wall (arg_data: 0x% 04x)】 appears" - PRINTF("◯◯◯森の神殿オブジェクト【回転壁(arg_data : 0x%04x)】出現 \n", this->dyna.actor.params); + PRINTF(T("◯◯◯森の神殿オブジェクト【回転壁(arg_data : 0x%04x)】出現 \n", + "◯◯◯Forest Temple object [Rotating wall(arg_data : 0x%04x)] appears \n"), + this->dyna.actor.params); Actor_ProcessInitChain(&this->dyna.actor, sInitChain); DynaPolyActor_Init(&this->dyna, 0); CollisionHeader_GetVirtual(&gMoriKaitenkabeCol, &colHeader); @@ -69,8 +70,8 @@ void BgMoriKaitenkabe_Init(Actor* thisx, PlayState* play) { this->moriTexObjectSlot = Object_GetSlot(&play->objectCtx, OBJECT_MORI_TEX); if (this->moriTexObjectSlot < 0) { Actor_Kill(&this->dyna.actor); - // "【Rotating wall】 Bank danger!" - PRINTF("【回転壁】 バンク危険!(%s %d)\n", "../z_bg_mori_kaitenkabe.c", 176); + PRINTF(T("【回転壁】 バンク危険!(%s %d)\n", "[Rotating wall] Bank danger! (%s %d)\n"), + "../z_bg_mori_kaitenkabe.c", 176); } else { this->actionFunc = BgMoriKaitenkabe_WaitForMoriTex; } diff --git a/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c b/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c index b331b15b2..4b0443696 100644 --- a/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c +++ b/src/overlays/actors/ovl_Bg_Mori_Rakkatenjo/z_bg_mori_rakkatenjo.c @@ -65,24 +65,25 @@ void BgMoriRakkatenjo_Init(Actor* thisx, PlayState* play) { DynaPolyActor_Init(&this->dyna, DYNA_TRANSFORM_POS); #if DEBUG_FEATURES - // "Forest Temple obj. Falling Ceiling" - PRINTF("森の神殿 obj. 落下天井 (home posY %f)\n", this->dyna.actor.home.pos.y); + PRINTF(T("森の神殿 obj. 落下天井", "Forest Temple obj. Falling Ceiling") " (home posY %f)\n", + this->dyna.actor.home.pos.y); if ((fabsf(1991.0f - this->dyna.actor.home.pos.x) > 0.001f) || (fabsf(683.0f - this->dyna.actor.home.pos.y) > 0.001f) || (fabsf(-2520.0f - this->dyna.actor.home.pos.z) > 0.001f)) { - // "The set position has been changed. Let's fix the program." - PRINTF("Warning : セット位置が変更されています。プログラムを修正しましょう。\n"); + PRINTF(T("Warning : セット位置が変更されています。プログラムを修正しましょう。\n", + "Warning : The set position has been changed. Let's fix the program.\n")); } if (this->dyna.actor.home.rot.y != 0x8000) { - // "The set Angle has changed. Let's fix the program." - PRINTF("Warning : セット Angle が変更されています。プログラムを修正しましょう。\n"); + PRINTF(T("Warning : セット Angle が変更されています。プログラムを修正しましょう。\n", + "Warning : The set Angle has changed. Let's fix the program.\n")); } #endif this->moriTexObjectSlot = Object_GetSlot(&play->objectCtx, OBJECT_MORI_TEX); if (this->moriTexObjectSlot < 0) { - // "Forest Temple obj Falling Ceiling Bank Danger!" - PRINTF("Error : 森の神殿 obj 落下天井 バンク危険!(%s %d)\n", "../z_bg_mori_rakkatenjo.c", 205); + PRINTF(T("Error : 森の神殿 obj 落下天井 バンク危険!(%s %d)\n", + "Error : Forest Temple obj Falling Ceiling Bank danger! (%s %d)\n"), + "../z_bg_mori_rakkatenjo.c", 205); Actor_Kill(&this->dyna.actor); return; } diff --git a/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c b/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c index 33f96d547..413e0a49e 100644 --- a/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c +++ b/src/overlays/actors/ovl_Bg_Spot01_Fusya/z_bg_spot01_fusya.c @@ -9,6 +9,7 @@ #include "gfx.h" #include "gfx_setupdl.h" #include "ichain.h" +#include "sfx.h" #include "sys_matrix.h" #include "z_lib.h" #include "z64audio.h" @@ -74,7 +75,7 @@ void func_808AAA50(BgSpot01Fusya* this, PlayState* play) { } thisx->shape.rot.z += this->unk_154; temp = ((this->unk_154 - 100.0f) / 1700.0f) + 1.0f; - func_800F436C(&thisx->projectedPos, 0x2085, temp); + func_800F436C(&thisx->projectedPos, NA_SE_EV_WINDMILL_LEVEL - SFX_FLAG, temp); Math_ApproachF(&this->unk_154, this->unk_158, this->unk_15C, 100.0f); } diff --git a/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c b/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c index d5a21a8b6..1e187bc0b 100644 --- a/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c +++ b/src/overlays/actors/ovl_Bg_Spot01_Idohashira/z_bg_spot01_idohashira.c @@ -191,7 +191,8 @@ f32 func_808AB1DC(f32 arg0, f32 arg1, u16 arg2, u16 arg3, u16 arg4) { temp_f12 = regFloat * diff43; return (((((arg1 - arg0) - temp_f12) / SQ(diff23)) * diff43) * diff43) + temp_f12; } - PRINTF(VT_FGCOL(RED) "Bg_Spot01_Idohashira_Get_FreeFallで割り算出来ない!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("Bg_Spot01_Idohashira_Get_FreeFallで割り算出来ない!!!!!!!!!!!!!!\n", + "Bg_Spot01_Idohashira_Get_FreeFall Cannot divide by!!!!!!!!!!!!!!\n") VT_RST); return 0.0f; } @@ -266,7 +267,8 @@ void func_808AB444(BgSpot01Idohashira* this, PlayState* play) { Actor_Kill(&this->dyna.actor); break; default: - PRINTF("Bg_Spot01_Idohashira_Check_DemoMode:そんな動作は無い!!!!!!!!\n"); + PRINTF(T("Bg_Spot01_Idohashira_Check_DemoMode:そんな動作は無い!!!!!!!!\n", + "Bg_Spot01_Idohashira_Check_DemoMode: There is no such action!!!!!!!!\n")); } this->cueId = nextCueId; @@ -296,7 +298,8 @@ void BgSpot01Idohashira_Update(Actor* thisx, PlayState* play) { BgSpot01Idohashira* this = (BgSpot01Idohashira*)thisx; if (this->action < 0 || this->action >= 4 || sActionFuncs[this->action] == NULL) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -347,7 +350,8 @@ void BgSpot01Idohashira_Draw(Actor* thisx, PlayState* play) { BgSpot01Idohashira* this = (BgSpot01Idohashira*)thisx; if (this->drawConfig < 0 || this->drawConfig > 0 || sDrawFuncs[this->drawConfig] == NULL) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_Bg_Spot01_Objects2/z_bg_spot01_objects2.c b/src/overlays/actors/ovl_Bg_Spot01_Objects2/z_bg_spot01_objects2.c index 4b7e9eed8..72644d4c2 100644 --- a/src/overlays/actors/ovl_Bg_Spot01_Objects2/z_bg_spot01_objects2.c +++ b/src/overlays/actors/ovl_Bg_Spot01_Objects2/z_bg_spot01_objects2.c @@ -67,8 +67,8 @@ void BgSpot01Objects2_Init(Actor* thisx, PlayState* play) { if (this->objectId >= 0) { this->requiredObjectSlot = Object_GetSlot(&play->objectCtx, this->objectId); if (this->requiredObjectSlot < 0) { - // "There was no bank setting." - PRINTF("-----------------------------バンク設定ありませんでした."); + PRINTF(T("-----------------------------バンク設定ありませんでした.", + "----------------------------- There was no bank setting.")); Actor_Kill(&this->dyna.actor); return; } @@ -98,8 +98,7 @@ void func_808AC2BC(BgSpot01Objects2* this, PlayState* play) { Vec3f position; if (Object_IsLoaded(&play->objectCtx, this->requiredObjectSlot)) { - // "---- Successful bank switching!!" - PRINTF("-----バンク切り換え成功!!\n"); + PRINTF(T("-----バンク切り換え成功!!\n", "----- Successful bank switching!!\n")); gSegments[6] = VIRTUAL_TO_PHYSICAL(play->objectCtx.slots[this->requiredObjectSlot].segment); this->dyna.actor.objectSlot = this->requiredObjectSlot; diff --git a/src/overlays/actors/ovl_Bg_Spot08_Iceblock/z_bg_spot08_iceblock.c b/src/overlays/actors/ovl_Bg_Spot08_Iceblock/z_bg_spot08_iceblock.c index 4f0bb3756..d389b0219 100644 --- a/src/overlays/actors/ovl_Bg_Spot08_Iceblock/z_bg_spot08_iceblock.c +++ b/src/overlays/actors/ovl_Bg_Spot08_Iceblock/z_bg_spot08_iceblock.c @@ -61,9 +61,9 @@ void BgSpot08Iceblock_InitDynaPoly(BgSpot08Iceblock* this, PlayState* play, Coll if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning: move BG registration failed" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_spot08_iceblock.c", 0xD9, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_spot08_iceblock.c", 0xD9, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -75,9 +75,9 @@ void BgSpot08Iceblock_CheckParams(BgSpot08Iceblock* this) { this->dyna.actor.params = 0x10; break; default: - // "Error: arg_data setting error" - PRINTF("Error : arg_data 設定ミスです。(%s %d)(arg_data 0x%04x)\n", "../z_bg_spot08_iceblock.c", 0xF6, - this->dyna.actor.params); + PRINTF( + T("Error : arg_data 設定ミスです。", "Error : arg_data setting error. ") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_spot08_iceblock.c", 0xF6, this->dyna.actor.params); this->dyna.actor.params = 0x10; break; case 1: @@ -298,8 +298,7 @@ void BgSpot08Iceblock_Init(Actor* thisx, PlayState* play) { BgSpot08Iceblock* this = (BgSpot08Iceblock*)thisx; CollisionHeader* colHeader; - // "spot08 ice floe" - PRINTF("(spot08 流氷)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF("(spot08 " T("流氷", "ice floe") ")(arg_data 0x%04x)\n", this->dyna.actor.params); BgSpot08Iceblock_CheckParams(this); switch (PARAMS_GET_NOSHIFT(this->dyna.actor.params, 9, 1)) { diff --git a/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c b/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c index 449091faa..f9adf04c8 100644 --- a/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c +++ b/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c @@ -145,12 +145,13 @@ s32 func_808B1D44(BgSpot09Obj* this, PlayState* play) { void BgSpot09Obj_Init(Actor* thisx, PlayState* play) { BgSpot09Obj* this = (BgSpot09Obj*)thisx; - PRINTF("Spot09 Object [arg_data : 0x%04x](大工救出フラグ 0x%x)\n", this->dyna.actor.params, - GET_EVENTCHKINF_CARPENTERS_RESCUED_FLAGS()); + PRINTF("Spot09 Object [arg_data : 0x%04x](" T("大工救出フラグ", "Carpenter Rescue Flag") " 0x%x)\n", + this->dyna.actor.params, GET_EVENTCHKINF_CARPENTERS_RESCUED_FLAGS()); this->dyna.actor.params &= 0xFF; if ((this->dyna.actor.params < 0) || (this->dyna.actor.params >= 5)) { - PRINTF("Error : Spot 09 object の arg_data が判別出来ない(%s %d)(arg_data 0x%04x)\n", "../z_bg_spot09_obj.c", - 322, this->dyna.actor.params); + PRINTF(T("Error : Spot 09 object の arg_data が判別出来ない", + "Error : Spot 09 object arg_data cannot be determined") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_spot09_obj.c", 322, this->dyna.actor.params); } if (!func_808B1C70(this, play)) { diff --git a/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c b/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c index 1aafed883..a69b16bbd 100644 --- a/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c +++ b/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c @@ -128,7 +128,7 @@ void BgSpot11Bakudankabe_Init(Actor* thisx, PlayState* play) { CollisionHeader_GetVirtual(&gDesertColossusBombableWallCol, &colHeader); this->dyna.bgId = DynaPoly_SetBgActor(play, &play->colCtx.dyna, &this->dyna.actor, colHeader); Actor_SetScale(&this->dyna.actor, 1.0f); - PRINTF("(spot11 爆弾壁)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF("(spot11 " T("爆弾壁", "Bomb Wall") ")(arg_data 0x%04x)\n", this->dyna.actor.params); } void BgSpot11Bakudankabe_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Spot12_Gate/z_bg_spot12_gate.c b/src/overlays/actors/ovl_Bg_Spot12_Gate/z_bg_spot12_gate.c index 9a36eb287..29f8c107a 100644 --- a/src/overlays/actors/ovl_Bg_Spot12_Gate/z_bg_spot12_gate.c +++ b/src/overlays/actors/ovl_Bg_Spot12_Gate/z_bg_spot12_gate.c @@ -62,8 +62,9 @@ void BgSpot12Gate_InitDynaPoly(BgSpot12Gate* this, PlayState* play, CollisionHea if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_spot12_gate.c", 145, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_spot12_gate.c", 145, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Bg_Spot12_Saku/z_bg_spot12_saku.c b/src/overlays/actors/ovl_Bg_Spot12_Saku/z_bg_spot12_saku.c index 1edeb5946..a186c1329 100644 --- a/src/overlays/actors/ovl_Bg_Spot12_Saku/z_bg_spot12_saku.c +++ b/src/overlays/actors/ovl_Bg_Spot12_Saku/z_bg_spot12_saku.c @@ -59,8 +59,9 @@ void func_808B3420(BgSpot12Saku* this, PlayState* play, CollisionHeader* collisi if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_spot12_saku.c", 140, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_spot12_saku.c", 140, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Bg_Spot15_Rrbox/z_bg_spot15_rrbox.c b/src/overlays/actors/ovl_Bg_Spot15_Rrbox/z_bg_spot15_rrbox.c index d0655135a..deb85fa11 100644 --- a/src/overlays/actors/ovl_Bg_Spot15_Rrbox/z_bg_spot15_rrbox.c +++ b/src/overlays/actors/ovl_Bg_Spot15_Rrbox/z_bg_spot15_rrbox.c @@ -76,8 +76,9 @@ void func_808B3960(BgSpot15Rrbox* this, PlayState* play, CollisionHeader* collis if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_bg_spot15_rrbox.c", 171, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_bg_spot15_rrbox.c", 171, this->dyna.actor.id, this->dyna.actor.params); } #endif } @@ -142,7 +143,7 @@ void BgSpot15Rrbox_Init(Actor* thisx, PlayState* play) { } else { func_808B4084(this, play); } - PRINTF("(spot15 ロンロン木箱)(arg_data 0x%04x)\n", this->dyna.actor.params); + PRINTF("(spot15 " T("ロンロン木箱", "Lon Lon Wooden Box") ")(arg_data 0x%04x)\n", this->dyna.actor.params); } void BgSpot15Rrbox_Destroy(Actor* thisx, PlayState* play) { @@ -329,9 +330,8 @@ void func_808B43D0(BgSpot15Rrbox* this, PlayState* play) { Actor_MoveXZGravity(actor); if (actor->world.pos.y <= BGCHECK_Y_MIN + 10.0f) { - // "Lon Lon wooden crate fell too much" - PRINTF("Warning : ロンロン木箱落ちすぎた(%s %d)(arg_data 0x%04x)\n", "../z_bg_spot15_rrbox.c", 599, - actor->params); + PRINTF("Warning : " T("ロンロン木箱落ちすぎた", "Lon Lon Wooden Box fell too far") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_spot15_rrbox.c", 599, actor->params); Actor_Kill(actor); diff --git a/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c b/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c index b014d7faf..f7251066e 100644 --- a/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c +++ b/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c @@ -187,7 +187,7 @@ void func_808B4D04(BgSpot16Bombstone* this, PlayState* play) { s32 func_808B4D9C(BgSpot16Bombstone* this, PlayState* play) { if (Flags_GetSwitch(play, this->switchFlag)) { - PRINTF("Spot16 obj 爆弾石 破壊済み\n"); + PRINTF(T("Spot16 obj 爆弾石 破壊済み\n", "Spot16 obj Bomb Stone destroyed\n")); return false; } Actor_ProcessInitChain(&this->actor, sInitChainBoulder); @@ -237,7 +237,8 @@ s32 func_808B4E58(BgSpot16Bombstone* this, PlayState* play) { this->requiredObjectSlot = Object_GetSlot(&play->objectCtx, OBJECT_BOMBIWA); if (this->requiredObjectSlot < 0) { - PRINTF("Error : バンク危険!(arg_data 0x%04x)(%s %d)\n", actor->params, "../z_bg_spot16_bombstone.c", 589); + PRINTF("Error : " T("バンク危険!", "Bank danger! ") "(arg_data 0x%04x)(%s %d)\n", actor->params, + "../z_bg_spot16_bombstone.c", 589); return false; } @@ -269,8 +270,8 @@ void BgSpot16Bombstone_Init(Actor* thisx, PlayState* play) { #if DEBUG_FEATURES default: - PRINTF("Error : arg_data おかしいな(%s %d)(arg_data 0x%04x)\n", "../z_bg_spot16_bombstone.c", 668, - this->actor.params); + PRINTF(T("Error : arg_data おかしいな", "Error : arg_data is strange") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_spot16_bombstone.c", 668, this->actor.params); shouldLive = false; break; #endif @@ -280,7 +281,8 @@ void BgSpot16Bombstone_Init(Actor* thisx, PlayState* play) { Actor_Kill(&this->actor); return; } - PRINTF("Spot16 obj 爆弾石 (scaleX %f)(arg_data 0x%04x)\n", this->actor.scale.x, this->actor.params); + PRINTF("Spot16 obj " T("爆弾石", "Bomb Stone") " (scaleX %f)(arg_data 0x%04x)\n", this->actor.scale.x, + this->actor.params); } void BgSpot16Bombstone_Destroy(Actor* thisx, PlayState* play) { @@ -403,8 +405,8 @@ void func_808B56BC(BgSpot16Bombstone* this, PlayState* play) { player->actor.world.pos.x += sinValue * this->sinRotation; player->actor.world.pos.z += sinValue * this->cosRotation; } else { - PRINTF("Error 補正出来ない(%s %d)(arg_data 0x%04x)(hosei_angY %x)\n", "../z_bg_spot16_bombstone.c", 935, - this->actor.params, adjustedYawDiff); + PRINTF(T("Error 補正出来ない", "Error Can't correct") "(%s %d)(arg_data 0x%04x)(hosei_angY %x)\n", + "../z_bg_spot16_bombstone.c", 935, this->actor.params, adjustedYawDiff); } } } diff --git a/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c b/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c index c6cf246bc..46d58d17f 100644 --- a/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c +++ b/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c @@ -83,7 +83,7 @@ void BgSpot16Doughnut_Init(Actor* thisx, PlayState* play) { } else { this->fireFlag |= 1; } - PRINTF("(spot16 ドーナツ雲)(arg_data 0x%04x)\n", this->actor.params); + PRINTF(T("(spot16 ドーナツ雲)", "(spot16 Donut Cloud)") "(arg_data 0x%04x)\n", this->actor.params); } } diff --git a/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c b/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c index 84973d0b1..b16563394 100644 --- a/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c +++ b/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c @@ -42,7 +42,7 @@ void BgSpot17Funen_Init(Actor* thisx, PlayState* play) { BgSpot17Funen* this = (BgSpot17Funen*)thisx; Actor_ProcessInitChain(&this->actor, sInitChain); - PRINTF("spot17 obj. 噴煙 (arg_data 0x%04x)\n", this->actor.params); + PRINTF("spot17 obj. " T("噴煙", "volcanic smoke") " (arg_data 0x%04x)\n", this->actor.params); } void BgSpot17Funen_Destroy(Actor* thisx, PlayState* play) { diff --git a/src/overlays/actors/ovl_Bg_Spot18_Basket/z_bg_spot18_basket.c b/src/overlays/actors/ovl_Bg_Spot18_Basket/z_bg_spot18_basket.c index 2f36cd503..aeb92b63a 100644 --- a/src/overlays/actors/ovl_Bg_Spot18_Basket/z_bg_spot18_basket.c +++ b/src/overlays/actors/ovl_Bg_Spot18_Basket/z_bg_spot18_basket.c @@ -168,7 +168,8 @@ void BgSpot18Basket_Init(Actor* thisx, PlayState* play) { if (this->dyna.actor.child == NULL) { PRINTF_COLOR_RED(); - PRINTF("Error : 変化壷蓋発生失敗(%s %d)\n", "../z_bg_spot18_basket.c", 351); + PRINTF(T("Error : 変化壷蓋発生失敗", "Error : Failed to generate the change pot cover") "(%s %d)\n", + "../z_bg_spot18_basket.c", 351); PRINTF_RST(); Actor_Kill(&this->dyna.actor); } diff --git a/src/overlays/actors/ovl_Bg_Spot18_Obj/z_bg_spot18_obj.c b/src/overlays/actors/ovl_Bg_Spot18_Obj/z_bg_spot18_obj.c index 7012e9023..ba3c7ac56 100644 --- a/src/overlays/actors/ovl_Bg_Spot18_Obj/z_bg_spot18_obj.c +++ b/src/overlays/actors/ovl_Bg_Spot18_Obj/z_bg_spot18_obj.c @@ -105,8 +105,8 @@ s32 func_808B8910(BgSpot18Obj* this, PlayState* play) { } else if (LINK_AGE_IN_YEARS == YEARS_CHILD) { age = 0; } else { - PRINTF("Error : リンク年齢不詳 (%s %d)(arg_data 0x%04x)\n", "../z_bg_spot18_obj.c", 182, - this->dyna.actor.params); + PRINTF(T("Error : リンク年齢不詳", "Error : Link age unknown") " (%s %d)(arg_data 0x%04x)\n", + "../z_bg_spot18_obj.c", 182, this->dyna.actor.params); return 0; } @@ -114,16 +114,17 @@ s32 func_808B8910(BgSpot18Obj* this, PlayState* play) { case 0: case 1: if (D_808B90F0[PARAMS_GET_U(this->dyna.actor.params, 0, 4)][age] == 0) { - PRINTF("出現しない Object (0x%04x)\n", this->dyna.actor.params); + PRINTF(T("出現しない Object (0x%04x)\n", "Non-appearing Object (0x%04x)\n"), this->dyna.actor.params); } return D_808B90F0[PARAMS_GET_U(this->dyna.actor.params, 0, 4)][age]; case 2: - PRINTF("Error : Obj出現判定が設定されていない(%s %d)(arg_data 0x%04x)\n", "../z_bg_spot18_obj.c", 202, - this->dyna.actor.params); + PRINTF(T("Error : Obj出現判定が設定されていない", + "Error : Obj appearance detection is not set") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_spot18_obj.c", 202, this->dyna.actor.params); return 0; default: - PRINTF("Error : Obj出現判定失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_spot18_obj.c", 210, - this->dyna.actor.params); + PRINTF(T("Error : Obj出現判定失敗", "Error : Obj appearance check failed") "(%s %d)(arg_data 0x%04x)\n", + "../z_bg_spot18_obj.c", 210, this->dyna.actor.params); } return 0; } diff --git a/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c b/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c index 68bacc26c..9312b311d 100644 --- a/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c +++ b/src/overlays/actors/ovl_Bg_Zg/z_bg_zg.c @@ -108,8 +108,8 @@ void BgZg_Update(Actor* thisx, PlayState* play) { s32 action = this->action; if (((action < 0) || (1 < action)) || (sActionFuncs[action] == NULL)) { - // "Main Mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { sActionFuncs[action](this, play); } @@ -155,8 +155,8 @@ void BgZg_Draw(Actor* thisx, PlayState* play) { s32 drawConfig = this->drawConfig; if (((drawConfig < 0) || (drawConfig > 0)) || sDrawFuncs[drawConfig] == NULL) { - // "Drawing mode is wrong !!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { sDrawFuncs[drawConfig](this, play); } diff --git a/src/overlays/actors/ovl_Demo_Du/z_demo_du.c b/src/overlays/actors/ovl_Demo_Du/z_demo_du.c index 9a1993da1..9b7fbb03c 100644 --- a/src/overlays/actors/ovl_Demo_Du/z_demo_du.c +++ b/src/overlays/actors/ovl_Demo_Du/z_demo_du.c @@ -977,8 +977,8 @@ void DemoDu_Update(Actor* thisx, PlayState* play) { DemoDu* this = (DemoDu*)thisx; if (this->updateIndex < 0 || this->updateIndex >= 29 || sUpdateFuncs[this->updateIndex] == NULL) { - // "The main mode is abnormal!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sUpdateFuncs[this->updateIndex](this, play); @@ -1048,8 +1048,8 @@ void DemoDu_Draw(Actor* thisx, PlayState* play) { DemoDu* this = (DemoDu*)thisx; if (this->drawIndex < 0 || this->drawIndex >= 3 || sDrawFuncs[this->drawIndex] == NULL) { - // "The drawing mode is abnormal!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawIndex](thisx, play); diff --git a/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c b/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c index 303c4f724..4bfb16e01 100644 --- a/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c +++ b/src/overlays/actors/ovl_Demo_Ec/z_demo_ec.c @@ -1334,8 +1334,8 @@ void DemoEc_Update(Actor* thisx, PlayState* play) { s32 updateMode = this->updateMode; if ((updateMode < 0) || (updateMode >= ARRAY_COUNT(sUpdateFuncs)) || sUpdateFuncs[updateMode] == NULL) { - // "The main mode is strange !!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { if (updateMode != EC_UPDATE_COMMON) { DemoEc_UseAnimationObject(this, play); @@ -1367,8 +1367,8 @@ void DemoEc_Draw(Actor* thisx, PlayState* play) { s32 drawConfig = this->drawConfig; if ((drawConfig < 0) || (drawConfig >= ARRAY_COUNT(sDrawFuncs)) || sDrawFuncs[drawConfig] == NULL) { - // "The main mode is strange !!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { if (drawConfig != EC_DRAW_COMMON) { DemoEc_UseDrawObject(this, play); diff --git a/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c b/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c index 55713d413..a81f86562 100644 --- a/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c +++ b/src/overlays/actors/ovl_Demo_Ext/z_demo_ext.c @@ -183,8 +183,8 @@ void DemoExt_Update(Actor* thisx, PlayState* play) { DemoExt* this = (DemoExt*)thisx; if ((this->action < EXT_WAIT) || (this->action > EXT_DISPELL) || sActionFuncs[this->action] == NULL) { - // "Main mode is abnormal!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { sActionFuncs[this->action](this, play); } @@ -237,8 +237,8 @@ void DemoExt_Draw(Actor* thisx, PlayState* play) { if ((this->drawMode < EXT_DRAW_NOTHING) || (this->drawMode > EXT_DRAW_VORTEX) || sDrawFuncs[this->drawMode] == NULL) { - // "Draw mode is abnormal!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { sDrawFuncs[this->drawMode](thisx, play); } diff --git a/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c b/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c index b70210c38..feca7aa69 100644 --- a/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c +++ b/src/overlays/actors/ovl_Demo_Geff/z_demo_geff.c @@ -218,7 +218,8 @@ void DemoGeff_Update(Actor* thisx, PlayState* play) { DemoGeff* this = (DemoGeff*)thisx; if (this->action < 0 || this->action >= 2 || sActionFuncs[this->action] == NULL) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -232,7 +233,8 @@ void DemoGeff_Draw(Actor* thisx, PlayState* play) { s32 drawConfig = this->drawConfig; if (drawConfig < 0 || drawConfig >= 2 || sDrawFuncs[drawConfig] == NULL) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } if (drawConfig != 0) { diff --git a/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c b/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c index 1cfb0ef82..6009eb11f 100644 --- a/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c +++ b/src/overlays/actors/ovl_Demo_Gj/z_demo_gj.c @@ -1375,8 +1375,8 @@ void DemoGj_Update(Actor* thisx, PlayState* play) { if (this->updateMode < 0 || this->updateMode >= ARRAY_COUNT(sUpdateFuncs) || sUpdateFuncs[this->updateMode] == NULL) { - // "The main mode is abnormal!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } @@ -1467,8 +1467,8 @@ void DemoGj_Draw(Actor* thisx, PlayState* play) { DemoGj* this = (DemoGj*)thisx; if (this->drawConfig < 0 || this->drawConfig >= ARRAY_COUNT(sDrawFuncs) || sDrawFuncs[this->drawConfig] == NULL) { - // "The drawing mode is abnormal!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } diff --git a/src/overlays/actors/ovl_Demo_Go/z_demo_go.c b/src/overlays/actors/ovl_Demo_Go/z_demo_go.c index 139e38a45..d8e5fa65f 100644 --- a/src/overlays/actors/ovl_Demo_Go/z_demo_go.c +++ b/src/overlays/actors/ovl_Demo_Go/z_demo_go.c @@ -330,7 +330,8 @@ void DemoGo_Update(Actor* thisx, PlayState* play) { DemoGo* this = (DemoGo*)thisx; if (this->action < 0 || this->action >= 7 || D_8097D44C[this->action] == NULL) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } D_8097D44C[this->action](this, play); @@ -371,7 +372,8 @@ void DemoGo_Draw(Actor* thisx, PlayState* play) { DemoGo* this = (DemoGo*)thisx; if (this->drawConfig < 0 || this->drawConfig >= 2 || D_8097D468[this->drawConfig] == NULL) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } D_8097D468[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c b/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c index ebb9da34e..0a9b04aee 100644 --- a/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c +++ b/src/overlays/actors/ovl_Demo_Gt/z_demo_gt.c @@ -1734,8 +1734,8 @@ void DemoGt_Update(Actor* thisx, PlayState* play) { DemoGtUpdateFunc updateFunc; if ((this->updateMode < 0) || (this->updateMode >= 19) || (updateFunc = sUpdateFuncs[this->updateMode]) == NULL) { - // "The main mode is strange!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } @@ -1790,8 +1790,8 @@ void DemoGt_Draw(Actor* thisx, PlayState* play) { DemoGtDrawFunc drawFunc; if ((this->drawConfig < 0) || (this->drawConfig >= 9) || (drawFunc = sDrawFuncs[this->drawConfig]) == NULL) { - // "The drawing mode is strange !!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } diff --git a/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c b/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c index cab53df6a..c6d0a8f12 100644 --- a/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c +++ b/src/overlays/actors/ovl_Demo_Ik/z_demo_ik.c @@ -478,8 +478,8 @@ void DemoIk_Update(Actor* thisx, PlayState* play) { if (this->actionMode < 0 || this->actionMode >= ARRAY_COUNT(sActionFuncs) || sActionFuncs[this->actionMode] == NULL) { - // "The main mode is strange" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->actionMode](this, play); @@ -499,8 +499,8 @@ void DemoIk_Draw(Actor* thisx, PlayState* play) { DemoIk* this = (DemoIk*)thisx; if (this->drawMode < 0 || this->drawMode >= ARRAY_COUNT(sDrawFuncs) || sDrawFuncs[this->drawMode] == NULL) { - // "The draw mode is strange" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawMode](this, play); diff --git a/src/overlays/actors/ovl_Demo_Im/z_demo_im.c b/src/overlays/actors/ovl_Demo_Im/z_demo_im.c index 95d68dd2b..b3a15d6b6 100644 --- a/src/overlays/actors/ovl_Demo_Im/z_demo_im.c +++ b/src/overlays/actors/ovl_Demo_Im/z_demo_im.c @@ -1122,7 +1122,8 @@ void DemoIm_Update(Actor* thisx, PlayState* play) { DemoIm* this = (DemoIm*)thisx; if ((this->action < 0) || (this->action >= 31) || (sActionFuncs[this->action] == NULL)) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -1233,7 +1234,8 @@ void DemoIm_Draw(Actor* thisx, PlayState* play) { DemoIm* this = (DemoIm*)thisx; if ((this->drawConfig < 0) || (this->drawConfig >= 3) || (sDrawFuncs[this->drawConfig] == NULL)) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c b/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c index 3b6ed448d..adaa614e2 100644 --- a/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c +++ b/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c @@ -779,7 +779,8 @@ void DemoSa_Update(Actor* thisx, PlayState* play) { DemoSa* this = (DemoSa*)thisx; if (this->action < 0 || this->action >= 21 || sActionFuncs[this->action] == NULL) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -849,7 +850,8 @@ void DemoSa_Draw(Actor* thisx, PlayState* play) { DemoSa* this = (DemoSa*)thisx; if (this->drawConfig < 0 || this->drawConfig >= 3 || sDrawFuncs[this->drawConfig] == NULL) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_En_Eg/z_en_eg.c b/src/overlays/actors/ovl_En_Eg/z_en_eg.c index 9023f99ea..bfc53052c 100644 --- a/src/overlays/actors/ovl_En_Eg/z_en_eg.c +++ b/src/overlays/actors/ovl_En_Eg/z_en_eg.c @@ -73,8 +73,8 @@ void EnEg_Update(Actor* thisx, PlayState* play) { s32 action = this->action; if (((action < 0) || (0 < action)) || (sActionFuncs[action] == NULL)) { - // "Main Mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { sActionFuncs[action](this, play); } diff --git a/src/overlays/actors/ovl_En_Ik/z_en_ik.c b/src/overlays/actors/ovl_En_Ik/z_en_ik.c index 61573e535..4882166b3 100644 --- a/src/overlays/actors/ovl_En_Ik/z_en_ik.c +++ b/src/overlays/actors/ovl_En_Ik/z_en_ik.c @@ -1412,7 +1412,8 @@ void EnIk_UpdateCutscene(Actor* thisx, PlayState* play) { EnIk* this = (EnIk*)thisx; if (this->csAction < 0 || this->csAction >= ARRAY_COUNT(sCsActionFuncs) || sCsActionFuncs[this->csAction] == NULL) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } @@ -1506,7 +1507,8 @@ void EnIk_DrawCutscene(Actor* thisx, PlayState* play) { if (this->csDrawMode < 0 || this->csDrawMode >= ARRAY_COUNT(sCsDrawFuncs) || sCsDrawFuncs[this->csDrawMode] == NULL) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } diff --git a/src/overlays/actors/ovl_En_Mag/z_en_mag.c b/src/overlays/actors/ovl_En_Mag/z_en_mag.c index 2d944c895..f07672c7f 100644 --- a/src/overlays/actors/ovl_En_Mag/z_en_mag.c +++ b/src/overlays/actors/ovl_En_Mag/z_en_mag.c @@ -72,7 +72,7 @@ void EnMag_ResetSram(void) { SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8007800), buffer, 0x800, 1); gSaveContext.soundSetting = gSaveContext.zTargetSetting = 0; // SOUND_SETTING_STEREO/Z_TARGET_SETTING_SWITCH - Audio_SetSoundMode(gSaveContext.soundSetting); + Audio_SetSoundOutputMode(gSaveContext.soundSetting); } #endif diff --git a/src/overlays/actors/ovl_En_Nb/z_en_nb.c b/src/overlays/actors/ovl_En_Nb/z_en_nb.c index 4b615342c..1bfd258d9 100644 --- a/src/overlays/actors/ovl_En_Nb/z_en_nb.c +++ b/src/overlays/actors/ovl_En_Nb/z_en_nb.c @@ -1458,8 +1458,8 @@ void EnNb_Update(Actor* thisx, PlayState* play) { EnNb* this = (EnNb*)thisx; if (this->action < 0 || this->action > 30 || sActionFuncs[this->action] == NULL) { - // "Main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } @@ -1566,8 +1566,8 @@ void EnNb_Draw(Actor* thisx, PlayState* play) { EnNb* this = (EnNb*)thisx; if (this->drawMode < 0 || this->drawMode >= 5 || sDrawFuncs[this->drawMode] == NULL) { - // "Draw mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } diff --git a/src/overlays/actors/ovl_En_Rl/z_en_rl.c b/src/overlays/actors/ovl_En_Rl/z_en_rl.c index 56e27591f..ba9d3e10e 100644 --- a/src/overlays/actors/ovl_En_Rl/z_en_rl.c +++ b/src/overlays/actors/ovl_En_Rl/z_en_rl.c @@ -349,7 +349,8 @@ void EnRl_Update(Actor* thisx, PlayState* play) { EnRl* this = (EnRl*)thisx; if ((this->action < 0) || (this->action > 7) || (sActionFuncs[this->action] == NULL)) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -398,7 +399,8 @@ void EnRl_Draw(Actor* thisx, PlayState* play) { EnRl* this = (EnRl*)thisx; if (this->drawConfig < 0 || this->drawConfig >= 3 || sDrawFuncs[this->drawConfig] == NULL) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c index 16bc86f02..32b129b71 100644 --- a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c +++ b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c @@ -2266,8 +2266,8 @@ void EnRu1_Update(Actor* thisx, PlayState* play) { EnRu1* this = (EnRu1*)thisx; if (this->action < 0 || this->action >= ARRAY_COUNT(sActionFuncs) || sActionFuncs[this->action] == NULL) { - // "Main mode is improper!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } @@ -2420,8 +2420,8 @@ void EnRu1_Draw(Actor* thisx, PlayState* play) { EnRu1* this = (EnRu1*)thisx; if (this->drawConfig < 0 || this->drawConfig >= ARRAY_COUNT(sDrawFuncs) || sDrawFuncs[this->drawConfig] == NULL) { - // "Draw mode is improper!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c b/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c index 402bb2329..373d397d2 100644 --- a/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c +++ b/src/overlays/actors/ovl_En_Ru2/z_en_ru2.c @@ -921,8 +921,8 @@ void EnRu2_Update(Actor* thisx, PlayState* play) { EnRu2* this = (EnRu2*)thisx; if ((this->action < 0) || (this->action >= ARRAY_COUNT(sActionFuncs)) || (sActionFuncs[this->action] == NULL)) { - // "Main Mode is improper!" - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -982,8 +982,8 @@ void EnRu2_Draw(Actor* thisx, PlayState* play) { if ((this->drawConfig < 0) || (this->drawConfig >= ARRAY_COUNT(sDrawFuncs)) || (sDrawFuncs[this->drawConfig] == NULL)) { - // "Draw Mode is improper!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_En_Xc/z_en_xc.c b/src/overlays/actors/ovl_En_Xc/z_en_xc.c index 833973d4e..d5d0c9796 100644 --- a/src/overlays/actors/ovl_En_Xc/z_en_xc.c +++ b/src/overlays/actors/ovl_En_Xc/z_en_xc.c @@ -2349,7 +2349,8 @@ void EnXc_Update(Actor* thisx, PlayState* play) { s32 action = this->action; if ((action < 0) || (action >= ARRAY_COUNT(sActionFuncs)) || (sActionFuncs[action] == NULL)) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { sActionFuncs[action](this, play); } @@ -2466,8 +2467,8 @@ void EnXc_Draw(Actor* thisx, PlayState* play) { EnXc* this = (EnXc*)thisx; if (this->drawMode < 0 || this->drawMode > 5 || sDrawFuncs[this->drawMode] == NULL) { - // "Draw mode is abnormal!!!!!!!!!!!!!!!!!!!!!!!!!" - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); } else { sDrawFuncs[this->drawMode](thisx, play); } diff --git a/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c b/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c index e88530391..3e7866ffe 100644 --- a/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c +++ b/src/overlays/actors/ovl_En_Zl2/z_en_zl2.c @@ -1646,7 +1646,8 @@ void EnZl2_Update(Actor* thisx, PlayState* play) { EnZl2* this = (EnZl2*)thisx; if (this->action < 0 || this->action >= 0x24 || sActionFuncs[this->action] == NULL) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -1742,7 +1743,8 @@ void EnZl2_Draw(Actor* thisx, PlayState* play) { EnZl2* this = (EnZl2*)thisx; if ((this->drawConfig < 0) || (this->drawConfig >= 3) || (sDrawFuncs[this->drawConfig] == NULL)) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c b/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c index 11f0861dc..a05109b63 100644 --- a/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c +++ b/src/overlays/actors/ovl_En_Zl3/z_en_zl3.c @@ -2704,7 +2704,8 @@ void EnZl3_Update(Actor* thisx, PlayState* play) { EnZl3* this = (EnZl3*)thisx; if (this->action < 0 || this->action >= ARRAY_COUNT(sActionFuncs) || sActionFuncs[this->action] == NULL) { - PRINTF(VT_FGCOL(RED) "メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("メインモードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The main mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sActionFuncs[this->action](this, play); @@ -2813,7 +2814,8 @@ void EnZl3_Draw(Actor* thisx, PlayState* play) { EnZl3* this = (EnZl3*)thisx; if (this->drawConfig < 0 || this->drawConfig >= 3 || sDrawFuncs[this->drawConfig] == NULL) { - PRINTF(VT_FGCOL(RED) "描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n" VT_RST); + PRINTF(VT_FGCOL(RED) T("描画モードがおかしい!!!!!!!!!!!!!!!!!!!!!!!!!\n", + "The drawing mode is wrong!!!!!!!!!!!!!!!!!!!!!!!!!\n") VT_RST); return; } sDrawFuncs[this->drawConfig](this, play); diff --git a/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c b/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c index f2837d848..e25e8977c 100644 --- a/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c +++ b/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c @@ -161,8 +161,9 @@ void ObjBean_InitDynaPoly(ObjBean* this, PlayState* play, CollisionHeader* colli if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_obj_bean.c", 374, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_obj_bean.c", 374, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Obj_Elevator/z_obj_elevator.c b/src/overlays/actors/ovl_Obj_Elevator/z_obj_elevator.c index fd9d335b6..2bfd5f151 100644 --- a/src/overlays/actors/ovl_Obj_Elevator/z_obj_elevator.c +++ b/src/overlays/actors/ovl_Obj_Elevator/z_obj_elevator.c @@ -61,8 +61,9 @@ void func_80B92B08(ObjElevator* this, PlayState* play, CollisionHeader* collisio if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_obj_elevator.c", 136, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_obj_elevator.c", 136, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c b/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c index e76c10465..90b531ae2 100644 --- a/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c +++ b/src/overlays/actors/ovl_Obj_Hsblock/z_obj_hsblock.c @@ -73,8 +73,9 @@ void func_80B93B68(ObjHsblock* this, PlayState* play, CollisionHeader* collision if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_obj_hsblock.c", 163, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_obj_hsblock.c", 163, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Obj_Lift/z_obj_lift.c b/src/overlays/actors/ovl_Obj_Lift/z_obj_lift.c index 1545430f1..a392c9088 100644 --- a/src/overlays/actors/ovl_Obj_Lift/z_obj_lift.c +++ b/src/overlays/actors/ovl_Obj_Lift/z_obj_lift.c @@ -81,8 +81,9 @@ void ObjLift_InitDynaPoly(ObjLift* this, PlayState* play, CollisionHeader* colli if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_obj_lift.c", 188, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_obj_lift.c", 188, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c b/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c index 729c55332..f91ebe201 100644 --- a/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c +++ b/src/overlays/actors/ovl_Obj_Oshihiki/z_obj_oshihiki.c @@ -108,9 +108,9 @@ void ObjOshihiki_InitDynapoly(ObjOshihiki* this, PlayState* play, CollisionHeade if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG registration failure" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_obj_oshihiki.c", 280, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_obj_oshihiki.c", 280, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c b/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c index 9556f8c31..d9f3d7ea6 100644 --- a/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c +++ b/src/overlays/actors/ovl_Obj_Switch/z_obj_switch.c @@ -215,9 +215,9 @@ void ObjSwitch_InitDynaPoly(ObjSwitch* this, PlayState* play, CollisionHeader* c if (this->dyna.bgId == BG_ACTOR_MAX) { s32 pad2; - // "Warning : move BG registration failure" - PRINTF("Warning : move BG 登録失敗(%s %d)(name %d)(arg_data 0x%04x)\n", "../z_obj_switch.c", 531, - this->dyna.actor.id, this->dyna.actor.params); + PRINTF(T("Warning : move BG 登録失敗", + "Warning : move BG registration failed") "(%s %d)(name %d)(arg_data 0x%04x)\n", + "../z_obj_switch.c", 531, this->dyna.actor.id, this->dyna.actor.params); } #endif } diff --git a/src/overlays/gamestates/ovl_file_choose/z_file_nameset.c b/src/overlays/gamestates/ovl_file_choose/z_file_nameset.c index 2c1e49fb5..999b34efa 100644 --- a/src/overlays/gamestates/ovl_file_choose/z_file_nameset.c +++ b/src/overlays/gamestates/ovl_file_choose/z_file_nameset.c @@ -1369,7 +1369,7 @@ void FileSelect_UpdateOptionsMenu(GameState* thisx) { PRINTF("Na_SetSoundOutputMode = %d\n", gSaveContext.soundSetting); PRINTF("Na_SetSoundOutputMode = %d\n", gSaveContext.soundSetting); PRINTF_RST(); - Audio_SetSoundMode(gSaveContext.soundSetting); + Audio_SetSoundOutputMode(gSaveContext.soundSetting); PRINTF("終了\n"); return; } diff --git a/sym_info.py b/sym_info.py index 08f6027cc..9887ae2d9 100755 --- a/sym_info.py +++ b/sym_info.py @@ -6,11 +6,13 @@ import argparse import bisect from dataclasses import dataclass +import os from pathlib import Path from typing import Optional import struct import sys +import colorama import elftools.elf.elffile import mapfile_parser @@ -228,9 +230,13 @@ def find_symbols_by_name( return infos -def print_map_file(map_file: mapfile_parser.mapfile.MapFile): +def print_map_file(map_file: mapfile_parser.mapfile.MapFile, *, colors: bool): for segment in map_file: - print(f"{segment.name}") + print( + f"{colorama.Fore.GREEN if colors else ""}" + f"{segment.name}" + f"{colorama.Fore.RESET if colors else ""}" + ) for file in segment: # Ignore debug sections if ( @@ -239,7 +245,11 @@ def print_map_file(map_file: mapfile_parser.mapfile.MapFile): or file.sectionType.startswith(".mdebug") ): continue - print(f" {file.asStr()}") + print( + f"{colorama.Fore.CYAN if colors else ""}" + f" {file.asStr()}" + f"{colorama.Fore.RESET if colors else ""}" + ) for sym in file: vram_str = f"{sym.vram:08X}" if sym.vrom is None: @@ -265,6 +275,12 @@ def sym_info_main(): action="store_true", help="use the map file and elf in expected/build/ instead of build/", ) + parser.add_argument( + "--color", + help="Whether to print using colors or not", + choices=("never", "always", "auto"), + default="auto", + ) parser.add_argument( "-v", "--version", @@ -276,6 +292,17 @@ def sym_info_main(): args = parser.parse_args() filename = f"oot-{args.oot_version}" if args.oot_version != "hackeroot-mq" else "hackeroot-mq" + if args.color == "never": + colors = False + elif args.color == "always": + colors = True + else: + # auto + if os.getenv("NO_COLOR"): + colors = False + else: + colors = sys.stdout.isatty() + BUILTMAP = Path("build") / args.oot_version / f"{filename}.map" BUILTELF = Path("build") / args.oot_version / f"{filename}.elf" @@ -302,7 +329,7 @@ def sym_info_main(): sym_name = args.symname if sym_name is None: - print_map_file(map_file) + print_map_file(map_file, colors=colors) sys.exit(0) infos: list[mapfile_parser.mapfile.FoundSymbolInfo] = [] diff --git a/tools/audio/extraction/audio_extract.py b/tools/audio/extraction/audio_extract.py index 29bf632e3..a524312be 100644 --- a/tools/audio/extraction/audio_extract.py +++ b/tools/audio/extraction/audio_extract.py @@ -49,7 +49,7 @@ BASEROM_DEBUG = False # Run # ====================================================================================================================== -def collect_sample_banks(audiotable_seg : memoryview, extracted_dir : str, version_info : GameVersionInfo, +def collect_sample_banks(audiotable_seg : memoryview, output_dir : str, version_info : GameVersionInfo, table : AudioCodeTable, samplebank_descs : Dict[int, SampleBankExtractionDescription]): sample_banks : List[Union[AudioTableFile, int]] = [] @@ -76,7 +76,7 @@ def collect_sample_banks(audiotable_seg : memoryview, extracted_dir : str, versi extraction_desc=samplebank_descs.get(i, None)) if BASEROM_DEBUG: - bank.dump_bin(f"{extracted_dir}/baserom_audiotest/audiotable_files/{bank.file_name}.bin") + bank.dump_bin(f"{output_dir}/baserom_audiotest/audiotable_files/{bank.file_name}.bin") sample_banks.append(bank) @@ -90,7 +90,7 @@ def bank_data_lookup(sample_banks : List[Union[AudioTableFile, int]], e : Union[ else: return e -def collect_soundfonts(audiobank_seg : memoryview, extracted_dir : str, version_info : GameVersionInfo, +def collect_soundfonts(audiobank_seg : memoryview, output_dir : str, version_info : GameVersionInfo, sound_font_table : AudioCodeTable, soundfont_descs : Dict[int, SoundFontExtractionDescription], sample_banks : List[Union[AudioTableFile, int]]): soundfonts = [] @@ -110,7 +110,7 @@ def collect_soundfonts(audiobank_seg : memoryview, extracted_dir : str, version_ if BASEROM_DEBUG: # Write the individual file for debugging and comparison - soundfont.dump_bin(f"{extracted_dir}/baserom_audiotest/audiobank_files/{soundfont.file_name}.bin") + soundfont.dump_bin(f"{output_dir}/baserom_audiotest/audiobank_files/{soundfont.file_name}.bin") return soundfonts @@ -133,17 +133,17 @@ def aifc_extract_one_bin(base_path : str, sample : AudioTableData): else: sample.to_file(f"{base_path}/{sample.filename}") -def extract_samplebank(pool : ThreadPool, extracted_dir : str, sample_banks : List[Union[AudioTableFile, int]], +def extract_samplebank(pool : ThreadPool, output_dir : str, sample_banks : List[Union[AudioTableFile, int]], bank : AudioTableFile, write_xml : bool): # deal with remaining gaps, have to blob them unless we can find an exact match in another bank bank.finalize_coverage(sample_banks) # assign names bank.assign_names() - base_path = f"{extracted_dir}/assets/audio/samples/{bank.name}" + base_path = f"{output_dir}/assets/audio/samples/{bank.name}" # write xml - with open(f"{extracted_dir}/assets/audio/samplebanks/{bank.file_name}.xml", "w") as outfile: + with open(f"{output_dir}/assets/audio/samplebanks/{bank.file_name}.xml", "w") as outfile: outfile.write(bank.to_xml(f"assets/audio/samples/{bank.name}")) # write the extraction xml if specified @@ -175,17 +175,17 @@ def extract_samplebank(pool : ThreadPool, extracted_dir : str, sample_banks : Li if not BASEROM_DEBUG: shutil.rmtree(f"{base_path}/aifc") -def disassemble_one_sequence(extracted_dir : str, version_info : GameVersionInfo, soundfonts : List[AudiobankFile], +def disassemble_one_sequence(output_dir : str, version_info : GameVersionInfo, soundfonts : List[AudiobankFile], enum_names : List[str], id : int, data : bytes, name : str, filename : str, fonts : memoryview): - out_filename = f"{extracted_dir}/assets/audio/sequences/{filename}.seq" + out_filename = f"{output_dir}/assets/audio/sequences/{filename}.seq" disas = SequenceDisassembler(id, data, version_info.seq_disas_tables.get(id, None), CMD_SPEC, version_info.mml_version, out_filename, name, [soundfonts[i] for i in fonts], enum_names) disas.analyze() disas.emit() -def extract_sequences(audioseq_seg : memoryview, extracted_dir : str, version_info : GameVersionInfo, write_xml : bool, +def extract_sequences(audioseq_seg : memoryview, output_dir : str, version_info : GameVersionInfo, write_xml : bool, sequence_table : AudioCodeTable, sequence_font_table : memoryview, sequence_descs : Dict[int, SequenceExtractionDescription], soundfonts : List[AudiobankFile]): @@ -198,9 +198,9 @@ def extract_sequences(audioseq_seg : memoryview, extracted_dir : str, version_in assert len(seq_enum_names) == len(sequence_table) if BASEROM_DEBUG: - os.makedirs(f"{extracted_dir}/baserom_audiotest/audioseq_files", exist_ok=True) + os.makedirs(f"{output_dir}/baserom_audiotest/audioseq_files", exist_ok=True) - os.makedirs(f"{extracted_dir}/assets/audio/sequences", exist_ok=True) + os.makedirs(f"{output_dir}/assets/audio/sequences", exist_ok=True) if write_xml: os.makedirs(f"assets/xml/audio/sequences", exist_ok=True) @@ -235,7 +235,7 @@ def extract_sequences(audioseq_seg : memoryview, extracted_dir : str, version_in if BASEROM_DEBUG: # Extract original sequence binary for comparison - with open(f"{extracted_dir}/baserom_audiotest/audioseq_files/seq_{i}{ext}.aseq", "wb") as outfile: + with open(f"{output_dir}/baserom_audiotest/audioseq_files/seq_{i}{ext}.aseq", "wb") as outfile: outfile.write(seq_data) extraction_desc = sequence_descs.get(i, None) @@ -301,12 +301,12 @@ def extract_sequences(audioseq_seg : memoryview, extracted_dir : str, version_in # Disassemble to text for job in disas_jobs: - disassemble_one_sequence(extracted_dir, version_info, soundfonts, seq_enum_names, *job) + disassemble_one_sequence(output_dir, version_info, soundfonts, seq_enum_names, *job) dt = time.time() - t print(f"Sequences extraction took {dt:.3f}s") -def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : str, read_xml : bool, write_xml : bool): +def extract_audio_for_version(version_info : GameVersionInfo, output_dir : str, baserom_segments_dir : str, read_xml : bool, write_xml : bool): print("Setting up...") # Open baserom segments @@ -316,16 +316,16 @@ def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : st audiobank_seg = None audioseq_seg = None - with open(f"{extracted_dir}/baserom/code", "rb") as infile: + with open(f"{baserom_segments_dir}/code", "rb") as infile: code_seg = memoryview(infile.read()) - with open(f"{extracted_dir}/baserom/Audiotable", "rb") as infile: + with open(f"{baserom_segments_dir}/Audiotable", "rb") as infile: audiotable_seg = memoryview(infile.read()) - with open(f"{extracted_dir}/baserom/Audiobank", "rb") as infile: + with open(f"{baserom_segments_dir}/Audiobank", "rb") as infile: audiobank_seg = memoryview(infile.read()) - with open(f"{extracted_dir}/baserom/Audioseq", "rb") as infile: + with open(f"{baserom_segments_dir}/Audioseq", "rb") as infile: audioseq_seg = memoryview(infile.read()) # ================================================================================================================== @@ -342,18 +342,18 @@ def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : st if BASEROM_DEBUG: # Extract Table Binaries - os.makedirs(f"{extracted_dir}/baserom_audiotest/audio_code_tables/", exist_ok=True) + os.makedirs(f"{output_dir}/baserom_audiotest/audio_code_tables/", exist_ok=True) - with open(f"{extracted_dir}/baserom_audiotest/audio_code_tables/samplebank_table.bin", "wb") as outfile: + with open(f"{output_dir}/baserom_audiotest/audio_code_tables/samplebank_table.bin", "wb") as outfile: outfile.write(sample_bank_table.data) - with open(f"{extracted_dir}/baserom_audiotest/audio_code_tables/soundfont_table.bin", "wb") as outfile: + with open(f"{output_dir}/baserom_audiotest/audio_code_tables/soundfont_table.bin", "wb") as outfile: outfile.write(sound_font_table.data) - with open(f"{extracted_dir}/baserom_audiotest/audio_code_tables/sequence_table.bin", "wb") as outfile: + with open(f"{output_dir}/baserom_audiotest/audio_code_tables/sequence_table.bin", "wb") as outfile: outfile.write(sequence_table.data) - with open(f"{extracted_dir}/baserom_audiotest/audio_code_tables/sequence_font_table.bin", "wb") as outfile: + with open(f"{output_dir}/baserom_audiotest/audio_code_tables/sequence_font_table.bin", "wb") as outfile: outfile.write(sequence_font_table) # ================================================================================================================== @@ -384,16 +384,16 @@ def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : st # ================================================================================================================== if BASEROM_DEBUG: - os.makedirs(f"{extracted_dir}/baserom_audiotest/audiotable_files", exist_ok=True) - sample_banks = collect_sample_banks(audiotable_seg, extracted_dir, version_info, sample_bank_table, samplebank_descs) + os.makedirs(f"{output_dir}/baserom_audiotest/audiotable_files", exist_ok=True) + sample_banks = collect_sample_banks(audiotable_seg, output_dir, version_info, sample_bank_table, samplebank_descs) # ================================================================================================================== # Collect soundfonts # ================================================================================================================== if BASEROM_DEBUG: - os.makedirs(f"{extracted_dir}/baserom_audiotest/audiobank_files", exist_ok=True) - soundfonts = collect_soundfonts(audiobank_seg, extracted_dir, version_info, sound_font_table, soundfont_descs, + os.makedirs(f"{output_dir}/baserom_audiotest/audiobank_files", exist_ok=True) + soundfonts = collect_soundfonts(audiobank_seg, output_dir, version_info, sound_font_table, soundfont_descs, sample_banks) # ================================================================================================================== @@ -413,14 +413,14 @@ def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : st # Check that the sampleconv binary is available assert os.path.isfile(SAMPLECONV_PATH) , "Compile sampleconv" - os.makedirs(f"{extracted_dir}/assets/audio/samplebanks", exist_ok=True) + os.makedirs(f"{output_dir}/assets/audio/samplebanks", exist_ok=True) if write_xml: os.makedirs(f"assets/xml/audio/samplebanks", exist_ok=True) with ThreadPool(processes=os.cpu_count()) as pool: for bank in sample_banks: if isinstance(bank, AudioTableFile): - extract_samplebank(pool, extracted_dir, sample_banks, bank, write_xml) + extract_samplebank(pool, output_dir, sample_banks, bank, write_xml) # ================================================================================================================== # Extract soundfonts @@ -428,7 +428,7 @@ def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : st print("Extracting soundfonts...") - os.makedirs(f"{extracted_dir}/assets/audio/soundfonts", exist_ok=True) + os.makedirs(f"{output_dir}/assets/audio/soundfonts", exist_ok=True) if write_xml: os.makedirs(f"assets/xml/audio/soundfonts", exist_ok=True) @@ -441,7 +441,7 @@ def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : st sf.finalize() # write the soundfont xml itself - with open(f"{extracted_dir}/assets/audio/soundfonts/{sf.file_name}.xml", "w") as outfile: + with open(f"{output_dir}/assets/audio/soundfonts/{sf.file_name}.xml", "w") as outfile: outfile.write(sf.to_xml(f"Soundfont_{i}", "assets/audio/samplebanks")) # write the extraction xml if specified @@ -454,5 +454,5 @@ def extract_audio_for_version(version_info : GameVersionInfo, extracted_dir : st print("Extracting sequences...") - extract_sequences(audioseq_seg, extracted_dir, version_info, write_xml, sequence_table, sequence_font_table, + extract_sequences(audioseq_seg, output_dir, version_info, write_xml, sequence_table, sequence_font_table, sequence_descs, soundfonts) diff --git a/tools/extract_audio.py b/tools/extract_audio.py index ab5d5b3fb..c67d7b165 100644 --- a/tools/extract_audio.py +++ b/tools/extract_audio.py @@ -14,7 +14,8 @@ from audio.extraction.disassemble_sequence import MMLVersion, SequenceTableSpec, if __name__ == '__main__': parser = argparse.ArgumentParser(description="baserom audio asset extractor") - parser.add_argument("-o", "--extracted-dir", required=True, help="path to extracted directory") + parser.add_argument("-b", "--baserom-segments-dir", required=True, help="Directory of uncompressed ROM segments") + parser.add_argument("-o", "--output-dir", required=True, help="path to output directory") parser.add_argument("-v", "--version", required=True, help="version name") parser.add_argument("--read-xml", required=False, action="store_true", help="Read extraction xml files") parser.add_argument("--write-xml", required=False, action="store_true", help="Write extraction xml files") @@ -196,4 +197,4 @@ if __name__ == '__main__': audiotable_buffer_bugs, seq_disas_tables) - extract_audio_for_version(version_info, args.extracted_dir, args.read_xml, args.write_xml) + extract_audio_for_version(version_info, args.output_dir, args.baserom_segments_dir, args.read_xml, args.write_xml)