mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-03 06:24:30 +00:00
Replace most osSyncPrintf calls with PRINTF macro (#1598)
* Replace most osSyncPrintf calls with PRINTF macro * DEBUG -> OOT_DEBUG
This commit is contained in:
parent
6eb3bf401c
commit
324db1d578
297 changed files with 2642 additions and 2679 deletions
6
Makefile
6
Makefile
|
@ -134,8 +134,10 @@ ifeq ($(COMPILER),gcc)
|
|||
CFLAGS += -G 0 -nostdinc $(INC) -march=vr4300 -mfix4300 -mabi=32 -mno-abicalls -mdivide-breaks -fno-zero-initialized-in-bss -fno-toplevel-reorder -ffreestanding -fno-common -fno-merge-constants -mno-explicit-relocs -mno-split-addresses $(CHECK_WARNINGS) -funsigned-char
|
||||
MIPS_VERSION := -mips3
|
||||
else
|
||||
# we support Microsoft extensions such as anonymous structs, which the compiler does support but warns for their usage. Surpress the warnings with -woff.
|
||||
CFLAGS += -G 0 -non_shared -fullwarn -verbose -Xcpluscomm $(INC) -Wab,-r4300_mul -woff 516,649,838,712
|
||||
# Suppress warnings for wrong number of macro arguments (to fake variadic
|
||||
# macros) and Microsoft extensions such as anonymous structs (which the
|
||||
# compiler does support but warns for their usage).
|
||||
CFLAGS += -G 0 -non_shared -fullwarn -verbose -Xcpluscomm $(INC) -Wab,-r4300_mul -woff 516,609,649,838,712
|
||||
MIPS_VERSION := -mips2
|
||||
endif
|
||||
|
||||
|
|
|
@ -120,7 +120,7 @@ Optional arguments are `-o output` to output to a different file and `-v` to giv
|
|||
|
||||
## vt_fmt
|
||||
|
||||
This turns the strange strings in the `osSyncPrintf`s into the human-readable equivalent instructions. Copy the contents, including the quotation marks, and run
|
||||
This turns the strange strings in the `PRINTF`s into the human-readable equivalent instructions. Copy the contents, including the quotation marks, and run
|
||||
```sh
|
||||
./tools/vt_fmt.py "contents"
|
||||
```
|
||||
|
|
|
@ -101,6 +101,21 @@
|
|||
#define CHECK_FLAG_ALL(flags, mask) (((flags) & (mask)) == (mask))
|
||||
|
||||
#ifdef OOT_DEBUG
|
||||
#define PRINTF osSyncPrintf
|
||||
#else
|
||||
#ifdef __GNUC__
|
||||
#define PRINTF(format, ...) (void)0
|
||||
#else
|
||||
// IDO doesn't support variadic macros, but it merely throws a warning for the
|
||||
// number of arguments not matching the definition (warning 609) instead of
|
||||
// throwing an error. We suppress this warning and rely on GCC to catch macro
|
||||
// argument errors instead.
|
||||
#define PRINTF(args) (void)0
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef OOT_DEBUG
|
||||
|
||||
#define LOG(exp, value, format, file, line) \
|
||||
do { \
|
||||
LogUtils_LogThreadId(file, line); \
|
||||
|
|
|
@ -326,9 +326,9 @@ void Audio_ChooseActiveSfx(u8 bankId) {
|
|||
} else {
|
||||
if (entry->dist > 0x7FFFFFD0) {
|
||||
entry->dist = 0x70000008;
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "<INAGAKI CHECK> dist over! "
|
||||
"flag:%04X ptr:%08X pos:%f-%f-%f" VT_RST "\n",
|
||||
entry->sfxId, entry->posX, entry->posZ, *entry->posX, *entry->posY, *entry->posZ);
|
||||
PRINTF(VT_COL(RED, WHITE) "<INAGAKI CHECK> dist over! "
|
||||
"flag:%04X ptr:%08X pos:%f-%f-%f" VT_RST "\n",
|
||||
entry->sfxId, entry->posX, entry->posZ, *entry->posX, *entry->posY, *entry->posZ);
|
||||
}
|
||||
temp3 = entry->sfxId; // fake
|
||||
entry->priority = (u32)entry->dist + (SQ(0xFF - sfxImportance) * SQ(76)) + temp3 - temp3;
|
||||
|
|
|
@ -19,36 +19,35 @@ f32 gViConfigYScale = 1.0;
|
|||
void Main_ThreadEntry(void* arg) {
|
||||
OSTime time;
|
||||
|
||||
osSyncPrintf("mainx 実行開始\n");
|
||||
PRINTF("mainx 実行開始\n");
|
||||
DmaMgr_Init();
|
||||
osSyncPrintf("codeセグメントロード中...");
|
||||
PRINTF("codeセグメントロード中...");
|
||||
time = osGetTime();
|
||||
DMA_REQUEST_SYNC(_codeSegmentStart, (uintptr_t)_codeSegmentRomStart, _codeSegmentRomEnd - _codeSegmentRomStart,
|
||||
"../idle.c", 238);
|
||||
time -= osGetTime();
|
||||
osSyncPrintf("\rcodeセグメントロード中...完了\n");
|
||||
osSyncPrintf("転送時間 %6.3f\n");
|
||||
PRINTF("\rcodeセグメントロード中...完了\n");
|
||||
PRINTF("転送時間 %6.3f\n");
|
||||
bzero(_codeSegmentBssStart, _codeSegmentBssEnd - _codeSegmentBssStart);
|
||||
osSyncPrintf("codeセグメントBSSクリア完了\n");
|
||||
PRINTF("codeセグメントBSSクリア完了\n");
|
||||
Main(arg);
|
||||
osSyncPrintf("mainx 実行終了\n");
|
||||
PRINTF("mainx 実行終了\n");
|
||||
}
|
||||
|
||||
void Idle_ThreadEntry(void* arg) {
|
||||
osSyncPrintf("アイドルスレッド(idleproc)実行開始\n");
|
||||
osSyncPrintf("作製者 : %s\n", gBuildTeam);
|
||||
osSyncPrintf("作成日時 : %s\n", gBuildDate);
|
||||
osSyncPrintf("MAKEOPTION: %s\n", gBuildMakeOption);
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("RAMサイズは %d キロバイトです(osMemSize/osGetMemSize)\n", (s32)osMemSize / 1024);
|
||||
osSyncPrintf("_bootSegmentEnd(%08x) 以降のRAM領域はクリアされました(boot)\n", _bootSegmentEnd);
|
||||
osSyncPrintf("Zバッファのサイズは %d キロバイトです\n", 0x96);
|
||||
osSyncPrintf("ダイナミックバッファのサイズは %d キロバイトです\n", 0x92);
|
||||
osSyncPrintf("FIFOバッファのサイズは %d キロバイトです\n", 0x60);
|
||||
osSyncPrintf("YIELDバッファのサイズは %d キロバイトです\n", 3);
|
||||
osSyncPrintf("オーディオヒープのサイズは %d キロバイトです\n",
|
||||
((intptr_t)gSystemHeap - (intptr_t)gAudioHeap) / 1024);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("アイドルスレッド(idleproc)実行開始\n");
|
||||
PRINTF("作製者 : %s\n", gBuildTeam);
|
||||
PRINTF("作成日時 : %s\n", gBuildDate);
|
||||
PRINTF("MAKEOPTION: %s\n", gBuildMakeOption);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("RAMサイズは %d キロバイトです(osMemSize/osGetMemSize)\n", (s32)osMemSize / 1024);
|
||||
PRINTF("_bootSegmentEnd(%08x) 以降のRAM領域はクリアされました(boot)\n", _bootSegmentEnd);
|
||||
PRINTF("Zバッファのサイズは %d キロバイトです\n", 0x96);
|
||||
PRINTF("ダイナミックバッファのサイズは %d キロバイトです\n", 0x92);
|
||||
PRINTF("FIFOバッファのサイズは %d キロバイトです\n", 0x60);
|
||||
PRINTF("YIELDバッファのサイズは %d キロバイトです\n", 3);
|
||||
PRINTF("オーディオヒープのサイズは %d キロバイトです\n", ((intptr_t)gSystemHeap - (intptr_t)gAudioHeap) / 1024);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
osCreateViManager(OS_PRIORITY_VIMGR);
|
||||
|
||||
|
|
|
@ -4,8 +4,8 @@
|
|||
f32 LogUtils_CheckFloatRange(const char* exp, s32 line, const char* valueName, f32 value, const char* minName, f32 min,
|
||||
const char* maxName, f32 max) {
|
||||
if (value < min || max < value) {
|
||||
osSyncPrintf("%s %d: range error %s(%f) < %s(%f) < %s(%f)\n", exp, line, minName, min, valueName, value,
|
||||
maxName, max);
|
||||
PRINTF("%s %d: range error %s(%f) < %s(%f) < %s(%f)\n", exp, line, minName, min, valueName, value, maxName,
|
||||
max);
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
@ -13,8 +13,8 @@ f32 LogUtils_CheckFloatRange(const char* exp, s32 line, const char* valueName, f
|
|||
s32 LogUtils_CheckIntRange(const char* exp, s32 line, const char* valueName, s32 value, const char* minName, s32 min,
|
||||
const char* maxName, s32 max) {
|
||||
if (value < min || max < value) {
|
||||
osSyncPrintf("%s %d: range error %s(%d) < %s(%d) < %s(%d)\n", exp, line, minName, min, valueName, value,
|
||||
maxName, max);
|
||||
PRINTF("%s %d: range error %s(%d) < %s(%d) < %s(%d)\n", exp, line, minName, min, valueName, value, maxName,
|
||||
max);
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
@ -26,21 +26,21 @@ void LogUtils_LogHexDump(void* ptr, s32 size0) {
|
|||
s32 i;
|
||||
u32 off;
|
||||
|
||||
osSyncPrintf("dump(%08x, %u)\n", addr, size);
|
||||
osSyncPrintf("address off +0 +1 +2 +3 +4 +5 +6 +7 +8 +9 +a +b +c +d +e +f 0123456789abcdef\n");
|
||||
PRINTF("dump(%08x, %u)\n", addr, size);
|
||||
PRINTF("address off +0 +1 +2 +3 +4 +5 +6 +7 +8 +9 +a +b +c +d +e +f 0123456789abcdef\n");
|
||||
|
||||
off = 0;
|
||||
while (size > 0) {
|
||||
|
||||
osSyncPrintf("%08x %04x", addr, off);
|
||||
PRINTF("%08x %04x", addr, off);
|
||||
rest = (size < 0x10) ? size : 0x10;
|
||||
|
||||
i = 0;
|
||||
while (true) {
|
||||
if (i < rest) {
|
||||
osSyncPrintf(" %02x", *((u8*)addr + i));
|
||||
PRINTF(" %02x", *((u8*)addr + i));
|
||||
} else {
|
||||
osSyncPrintf(" ");
|
||||
PRINTF(" ");
|
||||
}
|
||||
|
||||
i++;
|
||||
|
@ -48,16 +48,16 @@ void LogUtils_LogHexDump(void* ptr, s32 size0) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
osSyncPrintf(" ");
|
||||
PRINTF(" ");
|
||||
|
||||
i = 0;
|
||||
while (true) {
|
||||
if (i < rest) {
|
||||
u8 a = *(addr + i);
|
||||
|
||||
osSyncPrintf("%c", (a >= 0x20 && a < 0x7F) ? a : '.');
|
||||
PRINTF("%c", (a >= 0x20 && a < 0x7F) ? a : '.');
|
||||
} else {
|
||||
osSyncPrintf(" ");
|
||||
PRINTF(" ");
|
||||
}
|
||||
|
||||
i++;
|
||||
|
@ -65,7 +65,7 @@ void LogUtils_LogHexDump(void* ptr, s32 size0) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
size -= rest;
|
||||
addr += rest;
|
||||
off += rest;
|
||||
|
@ -73,40 +73,39 @@ void LogUtils_LogHexDump(void* ptr, s32 size0) {
|
|||
}
|
||||
|
||||
void LogUtils_LogPointer(s32 value, u32 max, void* ptr, const char* name, const char* file, s32 line) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "%s %d %s[%d] max=%u ptr=%08x\n" VT_RST, file, line, name, value, max, ptr);
|
||||
PRINTF(VT_COL(RED, WHITE) "%s %d %s[%d] max=%u ptr=%08x\n" VT_RST, file, line, name, value, max, ptr);
|
||||
}
|
||||
|
||||
void LogUtils_CheckBoundary(const char* name, s32 value, s32 unk, const char* file, s32 line) {
|
||||
u32 mask = (unk - 1);
|
||||
|
||||
if (value & mask) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "%s %d:%s(%08x) は バウンダリ(%d)違反です\n" VT_RST, file, line, name, value,
|
||||
unk);
|
||||
PRINTF(VT_COL(RED, WHITE) "%s %d:%s(%08x) は バウンダリ(%d)違反です\n" VT_RST, file, line, name, value, unk);
|
||||
}
|
||||
}
|
||||
|
||||
void LogUtils_CheckNullPointer(const char* exp, void* ptr, const char* file, s32 line) {
|
||||
if (ptr == NULL) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "%s %d:%s は はヌルポインタです\n" VT_RST, file, line, exp);
|
||||
PRINTF(VT_COL(RED, WHITE) "%s %d:%s は はヌルポインタです\n" VT_RST, file, line, exp);
|
||||
}
|
||||
}
|
||||
|
||||
void LogUtils_CheckValidPointer(const char* exp, void* ptr, const char* file, s32 line) {
|
||||
if (ptr == NULL || (u32)ptr < 0x80000000 || (0x80000000 + osMemSize) <= (u32)ptr) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "%s %d:ポインタ %s(%08x) が異常です\n" VT_RST, file, line, exp, ptr);
|
||||
PRINTF(VT_COL(RED, WHITE) "%s %d:ポインタ %s(%08x) が異常です\n" VT_RST, file, line, exp, ptr);
|
||||
}
|
||||
}
|
||||
|
||||
void LogUtils_LogThreadId(const char* name, s32 line) {
|
||||
osSyncPrintf("<%d %s %d>", osGetThreadId(NULL), name, line);
|
||||
PRINTF("<%d %s %d>", osGetThreadId(NULL), name, line);
|
||||
}
|
||||
|
||||
void LogUtils_HungupThread(const char* name, s32 line) {
|
||||
osSyncPrintf("*** HungUp in thread %d, [%s:%d] ***\n", osGetThreadId(NULL), name, line);
|
||||
PRINTF("*** HungUp in thread %d, [%s:%d] ***\n", osGetThreadId(NULL), name, line);
|
||||
Fault_AddHungupAndCrash(name, line);
|
||||
}
|
||||
|
||||
void LogUtils_ResetHungup(void) {
|
||||
osSyncPrintf("*** Reset ***\n");
|
||||
PRINTF("*** Reset ***\n");
|
||||
Fault_AddHungupAndCrash("Reset", 0);
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ void StackCheck_Init(StackEntry* entry, void* stackBottom, void* stackTop, u32 i
|
|||
iter = sStackInfoListStart;
|
||||
while (iter) {
|
||||
if (iter == entry) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "stackcheck_init: %08x は既にリスト中にある\n" VT_RST, entry);
|
||||
PRINTF(VT_COL(RED, WHITE) "stackcheck_init: %08x は既にリスト中にある\n" VT_RST, entry);
|
||||
return;
|
||||
}
|
||||
iter = iter->next;
|
||||
|
@ -68,7 +68,7 @@ void StackCheck_Cleanup(StackEntry* entry) {
|
|||
}
|
||||
}
|
||||
if (inconsistency) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "stackcheck_cleanup: %08x リスト不整合です\n" VT_RST, entry);
|
||||
PRINTF(VT_COL(RED, WHITE) "stackcheck_cleanup: %08x リスト不整合です\n" VT_RST, entry);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -89,18 +89,18 @@ u32 StackCheck_GetState(StackEntry* entry) {
|
|||
|
||||
if (free == 0) {
|
||||
ret = STACK_STATUS_OVERFLOW;
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
} else if (free < (u32)entry->minSpace && entry->minSpace != -1) {
|
||||
ret = STACK_STATUS_WARNING;
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
} else {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
ret = STACK_STATUS_OK;
|
||||
}
|
||||
|
||||
osSyncPrintf("head=%08x tail=%08x last=%08x used=%08x free=%08x [%s]\n", entry->head, entry->tail, last, used, free,
|
||||
entry->name != NULL ? entry->name : "(null)");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("head=%08x tail=%08x last=%08x used=%08x free=%08x [%s]\n", entry->head, entry->tail, last, used, free,
|
||||
entry->name != NULL ? entry->name : "(null)");
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if (ret != STACK_STATUS_OK) {
|
||||
LogUtils_LogHexDump(entry->head, (uintptr_t)entry->tail - (uintptr_t)entry->head);
|
||||
|
|
|
@ -8,7 +8,7 @@ void ViConfig_UpdateVi(u32 black) {
|
|||
if (black) {
|
||||
// Black the screen on next call to ViConfig_UpdateBlack, skip most VI configuration
|
||||
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "osViSetYScale1(%f);\n" VT_RST, 1.0f);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "osViSetYScale1(%f);\n" VT_RST, 1.0f);
|
||||
|
||||
if (osTvType == OS_TV_PAL) {
|
||||
osViSetMode(&osViModePalLan1);
|
||||
|
@ -34,7 +34,7 @@ void ViConfig_UpdateVi(u32 black) {
|
|||
}
|
||||
|
||||
if (gViConfigYScale != 1.0f) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "osViSetYScale3(%f);\n" VT_RST, gViConfigYScale);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "osViSetYScale3(%f);\n" VT_RST, gViConfigYScale);
|
||||
osViSetYScale(gViConfigYScale);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,14 +19,14 @@ void Locale_Init(void) {
|
|||
gCurrentRegion = REGION_EU;
|
||||
break;
|
||||
default:
|
||||
osSyncPrintf(VT_COL(RED, WHITE));
|
||||
osSyncPrintf("z_locale_init: 日本用かアメリカ用か判別できません\n");
|
||||
PRINTF(VT_COL(RED, WHITE));
|
||||
PRINTF("z_locale_init: 日本用かアメリカ用か判別できません\n");
|
||||
LogUtils_HungupThread("../z_locale.c", 118);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
break;
|
||||
}
|
||||
|
||||
osSyncPrintf("z_locale_init:日本用かアメリカ用か3コンで判断させる\n");
|
||||
PRINTF("z_locale_init:日本用かアメリカ用か3コンで判断させる\n");
|
||||
}
|
||||
|
||||
void Locale_ResetRegion(void) {
|
||||
|
|
|
@ -109,8 +109,8 @@ s32 DmaMgr_DmaRomToRam(uintptr_t rom, void* ram, size_t size) {
|
|||
ioMsg.size = buffSize;
|
||||
|
||||
if (gDmaMgrVerbose == 10) {
|
||||
osSyncPrintf("%10lld ノーマルDMA %08x %08x %08x (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), ioMsg.dramAddr,
|
||||
ioMsg.devAddr, ioMsg.size, MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
PRINTF("%10lld ノーマルDMA %08x %08x %08x (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), ioMsg.dramAddr,
|
||||
ioMsg.devAddr, ioMsg.size, MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
}
|
||||
|
||||
ret = osEPiStartDma(gCartHandle, &ioMsg, OS_READ);
|
||||
|
@ -119,14 +119,12 @@ s32 DmaMgr_DmaRomToRam(uintptr_t rom, void* ram, size_t size) {
|
|||
}
|
||||
|
||||
if (gDmaMgrVerbose == 10) {
|
||||
osSyncPrintf("%10lld ノーマルDMA START (%d)\n", OS_CYCLES_TO_USEC(osGetTime()),
|
||||
MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
PRINTF("%10lld ノーマルDMA START (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
}
|
||||
|
||||
osRecvMesg(&queue, NULL, OS_MESG_BLOCK);
|
||||
if (gDmaMgrVerbose == 10) {
|
||||
osSyncPrintf("%10lld ノーマルDMA END (%d)\n", OS_CYCLES_TO_USEC(osGetTime()),
|
||||
MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
PRINTF("%10lld ノーマルDMA END (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
}
|
||||
|
||||
size -= buffSize;
|
||||
|
@ -143,8 +141,8 @@ s32 DmaMgr_DmaRomToRam(uintptr_t rom, void* ram, size_t size) {
|
|||
ioMsg.size = size;
|
||||
|
||||
if (gDmaMgrVerbose == 10) {
|
||||
osSyncPrintf("%10lld ノーマルDMA %08x %08x %08x (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), ioMsg.dramAddr,
|
||||
ioMsg.devAddr, ioMsg.size, MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
PRINTF("%10lld ノーマルDMA %08x %08x %08x (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), ioMsg.dramAddr,
|
||||
ioMsg.devAddr, ioMsg.size, MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
}
|
||||
|
||||
ret = osEPiStartDma(gCartHandle, &ioMsg, OS_READ);
|
||||
|
@ -154,7 +152,7 @@ s32 DmaMgr_DmaRomToRam(uintptr_t rom, void* ram, size_t size) {
|
|||
|
||||
osRecvMesg(&queue, NULL, OS_MESG_BLOCK);
|
||||
if (gDmaMgrVerbose == 10) {
|
||||
osSyncPrintf("%10lld ノーマルDMA END (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
PRINTF("%10lld ノーマルDMA END (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
}
|
||||
|
||||
end:
|
||||
|
@ -182,13 +180,13 @@ s32 DmaMgr_AudioDmaHandler(OSPiHandle* pihandle, OSIoMesg* mb, s32 direction) {
|
|||
ASSERT(mb != NULL, "mb != NULL", "../z_std_dma.c", 532);
|
||||
|
||||
if (gDmaMgrVerbose == 10) {
|
||||
osSyncPrintf("%10lld サウンドDMA %08x %08x %08x (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), mb->dramAddr,
|
||||
mb->devAddr, mb->size, MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
PRINTF("%10lld サウンドDMA %08x %08x %08x (%d)\n", OS_CYCLES_TO_USEC(osGetTime()), mb->dramAddr, mb->devAddr,
|
||||
mb->size, MQ_GET_COUNT(&gPiMgrCmdQueue));
|
||||
}
|
||||
|
||||
ret = osEPiStartDma(pihandle, mb, direction);
|
||||
if (ret != 0) {
|
||||
osSyncPrintf("OOPS!!\n");
|
||||
PRINTF("OOPS!!\n");
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
@ -238,20 +236,20 @@ NORETURN void DmaMgr_Error(DmaRequest* req, const char* file, const char* errorN
|
|||
char buff1[80];
|
||||
char buff2[80];
|
||||
|
||||
osSyncPrintf("%c", BEL);
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF("%c", BEL);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "DMA Fatal Error"
|
||||
osSyncPrintf("DMA致命的エラー(%s)\nROM:%X RAM:%X SIZE:%X %s\n",
|
||||
errorDesc != NULL ? errorDesc : (errorName != NULL ? errorName : "???"), vrom, ram, size,
|
||||
file != NULL ? file : "???");
|
||||
PRINTF("DMA致命的エラー(%s)\nROM:%X RAM:%X SIZE:%X %s\n",
|
||||
errorDesc != NULL ? errorDesc : (errorName != NULL ? errorName : "???"), vrom, ram, size,
|
||||
file != NULL ? file : "???");
|
||||
|
||||
if (req->filename != NULL) { // Source file name that issued the DMA request
|
||||
osSyncPrintf("DMA ERROR: %s %d", req->filename, req->line);
|
||||
PRINTF("DMA ERROR: %s %d", req->filename, req->line);
|
||||
} else if (sDmaMgrCurFileName != NULL) {
|
||||
osSyncPrintf("DMA ERROR: %s %d", sDmaMgrCurFileName, sDmaMgrCurFileLine);
|
||||
PRINTF("DMA ERROR: %s %d", sDmaMgrCurFileName, sDmaMgrCurFileLine);
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if (req->filename != NULL) {
|
||||
sprintf(buff1, "DMA ERROR: %s %d", req->filename, req->line);
|
||||
|
@ -320,7 +318,7 @@ void DmaMgr_ProcessRequest(DmaRequest* req) {
|
|||
// The string is defined in .rodata but not used, suggesting a debug print is here but was optimized out in
|
||||
// some way. The last arg of this print looks like it may be filename, but filename above this block does not
|
||||
// match.
|
||||
osSyncPrintf("DMA ROM:%08X RAM:%08X SIZE:%08X %s\n");
|
||||
PRINTF("DMA ROM:%08X RAM:%08X SIZE:%08X %s\n");
|
||||
}
|
||||
|
||||
// Get the filename (for debugging)
|
||||
|
@ -350,7 +348,7 @@ void DmaMgr_ProcessRequest(DmaRequest* req) {
|
|||
found = true;
|
||||
|
||||
if (0) {
|
||||
osSyncPrintf("No Press ROM:%08X RAM:%08X SIZE:%08X\n", vrom, ram, size);
|
||||
PRINTF("No Press ROM:%08X RAM:%08X SIZE:%08X\n", vrom, ram, size);
|
||||
}
|
||||
} else {
|
||||
// File is compressed. Files that are stored compressed must be loaded into RAM all at once.
|
||||
|
@ -382,7 +380,7 @@ void DmaMgr_ProcessRequest(DmaRequest* req) {
|
|||
found = true;
|
||||
|
||||
if (0) {
|
||||
osSyncPrintf(" Press ROM:%X RAM:%X SIZE:%X\n", vrom, ram, size);
|
||||
PRINTF(" Press ROM:%X RAM:%X SIZE:%X\n", vrom, ram, size);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -404,7 +402,7 @@ void DmaMgr_ProcessRequest(DmaRequest* req) {
|
|||
DmaMgr_DmaRomToRam(vrom, ram, size);
|
||||
|
||||
if (0) {
|
||||
osSyncPrintf("No Press ROM:%08X RAM:%08X SIZE:%08X (非公式)\n", vrom, ram, size);
|
||||
PRINTF("No Press ROM:%08X RAM:%08X SIZE:%08X (非公式)\n", vrom, ram, size);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -415,7 +413,7 @@ void DmaMgr_ThreadEntry(void* arg) {
|
|||
DmaRequest* req;
|
||||
|
||||
// "DMA manager thread execution start"
|
||||
osSyncPrintf("DMAマネージャスレッド実行開始\n");
|
||||
PRINTF("DMAマネージャスレッド実行開始\n");
|
||||
|
||||
while (true) {
|
||||
// Wait for DMA Requests to arrive from other threads
|
||||
|
@ -426,7 +424,7 @@ void DmaMgr_ThreadEntry(void* arg) {
|
|||
}
|
||||
|
||||
if (0) {
|
||||
osSyncPrintf("DMA登録受付 dmap=%08x\n", req);
|
||||
PRINTF("DMA登録受付 dmap=%08x\n", req);
|
||||
}
|
||||
|
||||
// Process the DMA request
|
||||
|
@ -436,13 +434,13 @@ void DmaMgr_ThreadEntry(void* arg) {
|
|||
if (req->notifyQueue != NULL) {
|
||||
osSendMesg(req->notifyQueue, req->notifyMsg, OS_MESG_NOBLOCK);
|
||||
if (0) {
|
||||
osSyncPrintf("osSendMesg: dmap=%08x, mq=%08x, m=%08x \n", req, req->notifyQueue, req->notifyMsg);
|
||||
PRINTF("osSendMesg: dmap=%08x, mq=%08x, m=%08x \n", req, req->notifyQueue, req->notifyMsg);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// "DMA manager thread execution end"
|
||||
osSyncPrintf("DMAマネージャスレッド実行終了\n");
|
||||
PRINTF("DMAマネージャスレッド実行終了\n");
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -477,13 +475,13 @@ s32 DmaMgr_RequestAsync(DmaRequest* req, void* ram, uintptr_t vrom, size_t size,
|
|||
|
||||
if (1 && (sDmaMgrQueueFullLogged == 0) && MQ_IS_FULL(&sDmaMgrMsgQueue)) {
|
||||
sDmaMgrQueueFullLogged++;
|
||||
osSyncPrintf("%c", BEL);
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF("%c", BEL);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "dmaEntryMsgQ is full. Reconsider your queue size."
|
||||
osSyncPrintf("dmaEntryMsgQが一杯です。キューサイズの再検討をおすすめします。");
|
||||
PRINTF("dmaEntryMsgQが一杯です。キューサイズの再検討をおすすめします。");
|
||||
LOG_NUM("(sizeof(dmaEntryMsgBufs) / sizeof(dmaEntryMsgBufs[0]))", ARRAY_COUNT(sDmaMgrMsgBuf), "../z_std_dma.c",
|
||||
952);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
osSendMesg(&sDmaMgrMsgQueue, (OSMesg)req, OS_MESG_BLOCK);
|
||||
|
@ -523,7 +521,7 @@ void DmaMgr_Init(void) {
|
|||
// DMA the dma data table to RAM
|
||||
DmaMgr_DmaRomToRam((uintptr_t)_dmadataSegmentRomStart, _dmadataSegmentStart,
|
||||
(u32)(_dmadataSegmentRomEnd - _dmadataSegmentRomStart));
|
||||
osSyncPrintf("dma_rom_ad[]\n");
|
||||
PRINTF("dma_rom_ad[]\n");
|
||||
|
||||
sDmaMgrIsRomCompressed = false;
|
||||
name = sDmaMgrFileNames;
|
||||
|
@ -536,10 +534,9 @@ void DmaMgr_Init(void) {
|
|||
sDmaMgrIsRomCompressed = true;
|
||||
}
|
||||
|
||||
osSyncPrintf(
|
||||
"%3d %08x %08x %08x %08x %08x %c %s\n", idx, iter->vromStart, iter->vromEnd, iter->romStart, iter->romEnd,
|
||||
(iter->romEnd != 0) ? iter->romEnd - iter->romStart : iter->vromEnd - iter->vromStart,
|
||||
(((iter->romEnd != 0) ? iter->romEnd - iter->romStart : 0) > 0x10000) ? '*' : ' ', name ? *name : "");
|
||||
PRINTF("%3d %08x %08x %08x %08x %08x %c %s\n", idx, iter->vromStart, iter->vromEnd, iter->romStart,
|
||||
iter->romEnd, (iter->romEnd != 0) ? iter->romEnd - iter->romStart : iter->vromEnd - iter->vromStart,
|
||||
(((iter->romEnd != 0) ? iter->romEnd - iter->romStart : 0) > 0x10000) ? '*' : ' ', name ? *name : "");
|
||||
|
||||
idx++;
|
||||
iter++;
|
||||
|
@ -551,8 +548,8 @@ void DmaMgr_Init(void) {
|
|||
|
||||
// Ensure that the boot segment always follows after the makerom segment.
|
||||
if ((uintptr_t)_bootSegmentRomStart != gDmaDataTable[0].vromEnd) {
|
||||
osSyncPrintf("_bootSegmentRomStart(%08x) != dma_rom_ad[0].rom_b(%08x)\n", _bootSegmentRomStart,
|
||||
gDmaDataTable[0].vromEnd);
|
||||
PRINTF("_bootSegmentRomStart(%08x) != dma_rom_ad[0].rom_b(%08x)\n", _bootSegmentRomStart,
|
||||
gDmaDataTable[0].vromEnd);
|
||||
//! @bug The main code file where fault.c resides is not yet loaded
|
||||
Fault_AddHungupAndCrash("../z_std_dma.c", 1055);
|
||||
}
|
||||
|
|
|
@ -584,7 +584,7 @@ void PreRender_AntiAliasFilter(PreRender* this, s32 x, s32 y) {
|
|||
}
|
||||
|
||||
if (buffCvg[7] == 7) {
|
||||
osSyncPrintf("Error, should not be in here \n");
|
||||
PRINTF("Error, should not be in here \n");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -742,10 +742,10 @@ void PreRender_DivotFilter(PreRender* this) {
|
|||
|
||||
if ((R_HREG_MODE == HREG_MODE_PRERENDER ? R_PRERENDER_DIVOT_CONTROL : 0) ==
|
||||
PRERENDER_DIVOT_PRINT_COLOR) {
|
||||
osSyncPrintf("red=%3d %3d %3d %3d grn=%3d %3d %3d %3d blu=%3d %3d %3d %3d \n", windowR[0],
|
||||
windowR[1], windowR[2], MEDIAN3(windowR[0], windowR[1], windowR[2]), windowG[0],
|
||||
windowG[1], windowG[2], MEDIAN3(windowG[0], windowG[1], windowG[2]), windowB[0],
|
||||
windowB[1], windowB[2], MEDIAN3(windowB[0], windowB[1], windowB[2]));
|
||||
PRINTF("red=%3d %3d %3d %3d grn=%3d %3d %3d %3d blu=%3d %3d %3d %3d \n", windowR[0], windowR[1],
|
||||
windowR[2], MEDIAN3(windowR[0], windowR[1], windowR[2]), windowG[0], windowG[1],
|
||||
windowG[2], MEDIAN3(windowG[0], windowG[1], windowG[2]), windowB[0], windowB[1],
|
||||
windowB[2], MEDIAN3(windowB[0], windowB[1], windowB[2]));
|
||||
}
|
||||
|
||||
// Sample the median value from the 3 pixel wide window
|
||||
|
|
|
@ -82,7 +82,7 @@ void AudioMgr_HandleRetrace(AudioMgr* audioMgr) {
|
|||
*/
|
||||
void AudioMgr_HandlePreNMI(AudioMgr* audioMgr) {
|
||||
// "Audio manager received OS_SC_PRE_NMI_MSG"
|
||||
osSyncPrintf("オーディオマネージャが OS_SC_PRE_NMI_MSG を受け取りました\n");
|
||||
PRINTF("オーディオマネージャが OS_SC_PRE_NMI_MSG を受け取りました\n");
|
||||
Audio_PreNMI();
|
||||
}
|
||||
|
||||
|
@ -92,7 +92,7 @@ void AudioMgr_ThreadEntry(void* arg) {
|
|||
s16* msg = NULL;
|
||||
|
||||
// "Start running audio manager thread"
|
||||
osSyncPrintf("オーディオマネージャスレッド実行開始\n");
|
||||
PRINTF("オーディオマネージャスレッド実行開始\n");
|
||||
|
||||
// Initialize audio driver
|
||||
Audio_Init();
|
||||
|
|
|
@ -39,13 +39,13 @@ void DynaPolyActor_UpdateCarriedActorPos(CollisionContext* colCtx, s32 bgId, Act
|
|||
if (BGCHECK_XYZ_ABSMAX <= pos.x || pos.x <= -BGCHECK_XYZ_ABSMAX || BGCHECK_XYZ_ABSMAX <= pos.y ||
|
||||
pos.y <= -BGCHECK_XYZ_ABSMAX || BGCHECK_XYZ_ABSMAX <= pos.z || pos.z <= -BGCHECK_XYZ_ABSMAX) {
|
||||
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
//! @bug file and line are not passed to osSyncPrintf
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
//! @bug file and line are not passed to PRINTF
|
||||
// "Position is not valid"
|
||||
osSyncPrintf(
|
||||
PRINTF(
|
||||
"BGCheckCollection_typicalActorPos():位置が妥当ではありません。\npos (%f,%f,%f) file:%s line:%d\n",
|
||||
pos.x, pos.y, pos.z);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -286,7 +286,7 @@ u8 Inventory_DeleteEquipment(PlayState* play, s16 equipment) {
|
|||
u16 equipValue = gSaveContext.save.info.equips.equipment & gEquipMasks[equipment];
|
||||
|
||||
// "Erasing equipment item = %d zzz=%d"
|
||||
osSyncPrintf("装備アイテム抹消 = %d zzz=%d\n", equipment, equipValue);
|
||||
PRINTF("装備アイテム抹消 = %d zzz=%d\n", equipment, equipValue);
|
||||
|
||||
if (equipValue) {
|
||||
equipValue >>= gEquipShifts[equipment];
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
u32 gIsCtrlr2Valid = false;
|
||||
|
||||
NORETURN void func_800D31A0(void) {
|
||||
osSyncPrintf(VT_FGCOL(RED) "\n**** Freeze!! ****\n" VT_RST);
|
||||
PRINTF(VT_FGCOL(RED) "\n**** Freeze!! ****\n" VT_RST);
|
||||
while (true) {
|
||||
Sleep_Msec(1000);
|
||||
}
|
||||
|
|
|
@ -408,24 +408,24 @@ void func_800B44E0(DebugCam* debugCam, Camera* cam) {
|
|||
void DebugCamera_PrintPoints(const char* name, s16 count, CutsceneCameraPoint* points) {
|
||||
s32 i;
|
||||
|
||||
osSyncPrintf("@@@static SplinedatZ %s[] = {\n", name);
|
||||
PRINTF("@@@static SplinedatZ %s[] = {\n", name);
|
||||
for (i = 0; i < count; i++) {
|
||||
osSyncPrintf("@@@ /* key frame %2d */ {\n", i);
|
||||
osSyncPrintf("@@@ /* code */ %d,\n", points[i].continueFlag);
|
||||
osSyncPrintf("@@@ /* z */ %d,\n", points[i].cameraRoll);
|
||||
osSyncPrintf("@@@ /* T */ %d,\n", points[i].nextPointFrame);
|
||||
osSyncPrintf("@@@ /* zoom */ %f,\n", points[i].viewAngle);
|
||||
osSyncPrintf("@@@ /* pos */ { %d, %d, %d }\n", points[i].pos.x, points[i].pos.y, points[i].pos.z);
|
||||
osSyncPrintf("@@@ },\n");
|
||||
PRINTF("@@@ /* key frame %2d */ {\n", i);
|
||||
PRINTF("@@@ /* code */ %d,\n", points[i].continueFlag);
|
||||
PRINTF("@@@ /* z */ %d,\n", points[i].cameraRoll);
|
||||
PRINTF("@@@ /* T */ %d,\n", points[i].nextPointFrame);
|
||||
PRINTF("@@@ /* zoom */ %f,\n", points[i].viewAngle);
|
||||
PRINTF("@@@ /* pos */ { %d, %d, %d }\n", points[i].pos.x, points[i].pos.y, points[i].pos.z);
|
||||
PRINTF("@@@ },\n");
|
||||
}
|
||||
osSyncPrintf("@@@};\n@@@\n");
|
||||
PRINTF("@@@};\n@@@\n");
|
||||
}
|
||||
|
||||
void DebugCamera_PrintF32Bytes(f32 value) {
|
||||
f32 b = value;
|
||||
char* a = (char*)&b;
|
||||
|
||||
osSyncPrintf("\n@@@%d,%d,%d,%d,", a[0], a[1], a[2], a[3]);
|
||||
PRINTF("\n@@@%d,%d,%d,%d,", a[0], a[1], a[2], a[3]);
|
||||
}
|
||||
|
||||
void DebugCamera_PrintU16Bytes(u16 value) {
|
||||
|
@ -433,7 +433,7 @@ void DebugCamera_PrintU16Bytes(u16 value) {
|
|||
u16 b = value;
|
||||
char* a = (char*)&b;
|
||||
|
||||
osSyncPrintf("\n@@@%d,%d,", a[0], a[1]);
|
||||
PRINTF("\n@@@%d,%d,", a[0], a[1]);
|
||||
}
|
||||
|
||||
void DebugCamera_PrintS16Bytes(s16 value) {
|
||||
|
@ -441,7 +441,7 @@ void DebugCamera_PrintS16Bytes(s16 value) {
|
|||
s16 b = value;
|
||||
char* a = (char*)&b;
|
||||
|
||||
osSyncPrintf("\n@@@%d,%d,", a[0], a[1]);
|
||||
PRINTF("\n@@@%d,%d,", a[0], a[1]);
|
||||
}
|
||||
|
||||
void DebugCamera_PrintCutBytes(DebugCamCut* cut) {
|
||||
|
@ -450,55 +450,55 @@ void DebugCamera_PrintCutBytes(DebugCamCut* cut) {
|
|||
s32 i;
|
||||
|
||||
points = cut->lookAt;
|
||||
osSyncPrintf("\n@@@ 0,0,0,2,\t/* Look Camera\t*/");
|
||||
osSyncPrintf("\n@@@ 0,1,\t/* dousa\t*/");
|
||||
PRINTF("\n@@@ 0,0,0,2,\t/* Look Camera\t*/");
|
||||
PRINTF("\n@@@ 0,1,\t/* dousa\t*/");
|
||||
|
||||
osSyncPrintf("\n@@@ 0,0,\t/* Start Flame\t*/");
|
||||
PRINTF("\n@@@ 0,0,\t/* Start Flame\t*/");
|
||||
DebugCamera_PrintU16Bytes(cut->nFrames);
|
||||
osSyncPrintf("\t/* End Flame\t*/");
|
||||
PRINTF("\t/* End Flame\t*/");
|
||||
|
||||
osSyncPrintf("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
PRINTF("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
for (i = 0; i < cut->nPoints; i++) {
|
||||
point = points + i;
|
||||
osSyncPrintf("\n@@@ %d, /* code */", point->continueFlag);
|
||||
osSyncPrintf("\n@@@ %d, /* z */", point->cameraRoll);
|
||||
PRINTF("\n@@@ %d, /* code */", point->continueFlag);
|
||||
PRINTF("\n@@@ %d, /* z */", point->cameraRoll);
|
||||
DebugCamera_PrintU16Bytes(point->nextPointFrame);
|
||||
osSyncPrintf("\t/* sokudo\t*/");
|
||||
PRINTF("\t/* sokudo\t*/");
|
||||
DebugCamera_PrintF32Bytes(point->viewAngle);
|
||||
osSyncPrintf("\t/* zoom\t*/");
|
||||
PRINTF("\t/* zoom\t*/");
|
||||
DebugCamera_PrintS16Bytes(point->pos.x);
|
||||
osSyncPrintf("\t/* x pos\t*/");
|
||||
PRINTF("\t/* x pos\t*/");
|
||||
DebugCamera_PrintS16Bytes(point->pos.y);
|
||||
osSyncPrintf("\t/* y pos\t*/");
|
||||
PRINTF("\t/* y pos\t*/");
|
||||
DebugCamera_PrintS16Bytes(point->pos.z);
|
||||
osSyncPrintf("\t/* z pos\t*/\n");
|
||||
osSyncPrintf("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
PRINTF("\t/* z pos\t*/\n");
|
||||
PRINTF("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
}
|
||||
|
||||
points = cut->position;
|
||||
osSyncPrintf("\n@@@ 0,0,0,1,\t/* Position Camera */");
|
||||
osSyncPrintf("\n@@@ 0,1,\t/* dousa\t*/");
|
||||
PRINTF("\n@@@ 0,0,0,1,\t/* Position Camera */");
|
||||
PRINTF("\n@@@ 0,1,\t/* dousa\t*/");
|
||||
|
||||
osSyncPrintf("\n@@@ 0,0,\t/* Start Flame\t*/");
|
||||
PRINTF("\n@@@ 0,0,\t/* Start Flame\t*/");
|
||||
DebugCamera_PrintU16Bytes(cut->nFrames);
|
||||
osSyncPrintf("\t/* End Flame\t*/");
|
||||
PRINTF("\t/* End Flame\t*/");
|
||||
|
||||
osSyncPrintf("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
PRINTF("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
for (i = 0; i < cut->nPoints; i++) {
|
||||
point = points + i;
|
||||
osSyncPrintf("\n@@@ %d, /* code */", point->continueFlag);
|
||||
osSyncPrintf("\n@@@ %d, /* z */", point->cameraRoll);
|
||||
PRINTF("\n@@@ %d, /* code */", point->continueFlag);
|
||||
PRINTF("\n@@@ %d, /* z */", point->cameraRoll);
|
||||
DebugCamera_PrintU16Bytes(point->nextPointFrame);
|
||||
osSyncPrintf("\t/* sokudo\t*/");
|
||||
PRINTF("\t/* sokudo\t*/");
|
||||
DebugCamera_PrintF32Bytes(point->viewAngle);
|
||||
osSyncPrintf("\t/* zoom\t*/");
|
||||
PRINTF("\t/* zoom\t*/");
|
||||
DebugCamera_PrintS16Bytes(point->pos.x);
|
||||
osSyncPrintf("\t/* x pos\t*/");
|
||||
PRINTF("\t/* x pos\t*/");
|
||||
DebugCamera_PrintS16Bytes(point->pos.y);
|
||||
osSyncPrintf("\t/* y pos\t*/");
|
||||
PRINTF("\t/* y pos\t*/");
|
||||
DebugCamera_PrintS16Bytes(point->pos.z);
|
||||
osSyncPrintf("\t/* z pos\t*/");
|
||||
osSyncPrintf("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
PRINTF("\t/* z pos\t*/");
|
||||
PRINTF("\n@@@0,0,\t/* Dammy\t*/\n@@@ ");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -992,13 +992,13 @@ void DebugCamera_Update(DebugCam* debugCam, Camera* cam) {
|
|||
CHECK_BTN_ALL(sPlay->state.input[DEBUG_CAM_CONTROLLER_PORT].cur.button, BTN_L)) {
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_GET_RUPY, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
osSyncPrintf("@@@\n@@@\n@@@/* *** spline point data ** start here *** */\n@@@\n");
|
||||
PRINTF("@@@\n@@@\n@@@/* *** spline point data ** start here *** */\n@@@\n");
|
||||
DebugCamera_PrintPoints("Lookat", debugCam->sub.nPoints, debugCam->sub.lookAt);
|
||||
DebugCamera_PrintPoints("Position", debugCam->sub.nPoints, debugCam->sub.position);
|
||||
osSyncPrintf("@@@static short nPoints = %d;\n@@@\n", debugCam->sub.nPoints);
|
||||
osSyncPrintf("@@@static short nFrames = %d;\n@@@\n", debugCam->sub.nFrames);
|
||||
osSyncPrintf("@@@static short Mode = %d;\n@@@\n", debugCam->sub.mode);
|
||||
osSyncPrintf("@@@\n@@@\n@@@/* *** spline point data ** finish! *** */\n@@@\n");
|
||||
PRINTF("@@@static short nPoints = %d;\n@@@\n", debugCam->sub.nPoints);
|
||||
PRINTF("@@@static short nFrames = %d;\n@@@\n", debugCam->sub.nFrames);
|
||||
PRINTF("@@@static short Mode = %d;\n@@@\n", debugCam->sub.mode);
|
||||
PRINTF("@@@\n@@@\n@@@/* *** spline point data ** finish! *** */\n@@@\n");
|
||||
} else if (CHECK_BTN_ALL(sPlay->state.input[DEBUG_CAM_CONTROLLER_PORT].press.button, BTN_CLEFT)) {
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_CURSOR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
|
@ -1541,14 +1541,14 @@ char DebugCamera_InitCut(s32 idx, DebugCamSub* sub) {
|
|||
sDebugCamCuts[idx].lookAt = DebugArena_MallocDebug(i, "../db_camera.c", 2748);
|
||||
if (sDebugCamCuts[idx].lookAt == NULL) {
|
||||
// "Debug camera memory allocation failure"
|
||||
osSyncPrintf("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2751);
|
||||
PRINTF("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2751);
|
||||
return '?';
|
||||
}
|
||||
|
||||
sDebugCamCuts[idx].position = DebugArena_MallocDebug(i, "../db_camera.c", 2754);
|
||||
if (sDebugCamCuts[idx].position == NULL) {
|
||||
// "Debug camera memory allocation failure"
|
||||
osSyncPrintf("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2757);
|
||||
PRINTF("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2757);
|
||||
DebugArena_FreeDebug(sDebugCamCuts[idx].lookAt, "../db_camera.c", 2758);
|
||||
sDebugCamCuts[idx].lookAt = NULL;
|
||||
return '?';
|
||||
|
@ -1626,7 +1626,7 @@ s32 DebugCamera_LoadCallback(char* c) {
|
|||
sDebugCamCuts[i].lookAt = DebugArena_MallocDebug(ALIGN32(size), "../db_camera.c", 2844);
|
||||
if (sDebugCamCuts[i].lookAt == NULL) {
|
||||
// "Debug camera memory allocation failure"
|
||||
osSyncPrintf("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2847);
|
||||
PRINTF("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2847);
|
||||
return false;
|
||||
}
|
||||
if (!Mempak_Read(DEBUG_CAM_CONTROLLER_PORT, *c, sDebugCamCuts[i].lookAt, off, ALIGN32(size))) {
|
||||
|
@ -1637,7 +1637,7 @@ s32 DebugCamera_LoadCallback(char* c) {
|
|||
sDebugCamCuts[i].position = DebugArena_MallocDebug(ALIGN32(size), "../db_camera.c", 2855);
|
||||
if (sDebugCamCuts[i].position == NULL) {
|
||||
// "Debug camera memory allocation failure"
|
||||
osSyncPrintf("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2858);
|
||||
PRINTF("%s: %d: デバッグカメラ メモリ確保失敗!!\n", "../db_camera.c", 2858);
|
||||
return false;
|
||||
}
|
||||
if (!Mempak_Read(DEBUG_CAM_CONTROLLER_PORT, *c, sDebugCamCuts[i].position, off, ALIGN32(size))) {
|
||||
|
@ -1728,24 +1728,24 @@ void DebugCamera_PrintAllCuts(Camera* cam) {
|
|||
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_GET_RUPY, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
osSyncPrintf("@@@\n@@@\n@@@/* ****** spline point data ** start here ***** */\n@@@\n");
|
||||
PRINTF("@@@\n@@@\n@@@/* ****** spline point data ** start here ***** */\n@@@\n");
|
||||
|
||||
for (i = 0; i < ARRAY_COUNT(sDebugCamCuts) - 1; i++) {
|
||||
DebugCamCut* cut = &sDebugCamCuts[i];
|
||||
if (cut->nPoints != 0) {
|
||||
if (i != 0) {
|
||||
osSyncPrintf("@@@\n@@@/* ** %d ** */\n@@@\n", i);
|
||||
PRINTF("@@@\n@@@/* ** %d ** */\n@@@\n", i);
|
||||
}
|
||||
|
||||
DebugCamera_PrintPoints("Lookat", cut->nPoints, cut->lookAt);
|
||||
DebugCamera_PrintPoints("Position", cut->nPoints, cut->position);
|
||||
osSyncPrintf("@@@static short nPoints = %d;\n@@@\n", cut->nPoints);
|
||||
osSyncPrintf("@@@static short nFrames = %d;\n@@@\n", cut->nFrames);
|
||||
osSyncPrintf("@@@static short Mode = %d;\n@@@\n", cut->mode);
|
||||
PRINTF("@@@static short nPoints = %d;\n@@@\n", cut->nPoints);
|
||||
PRINTF("@@@static short nFrames = %d;\n@@@\n", cut->nFrames);
|
||||
PRINTF("@@@static short Mode = %d;\n@@@\n", cut->mode);
|
||||
}
|
||||
}
|
||||
|
||||
osSyncPrintf("@@@\n@@@\n@@@/* ****** spline point data ** finish! ***** */\n@@@\n");
|
||||
PRINTF("@@@\n@@@\n@@@/* ****** spline point data ** finish! ***** */\n@@@\n");
|
||||
}
|
||||
|
||||
char D_8012D114[] = GFXP_KATAKANA "フレ-ム ";
|
||||
|
@ -2310,9 +2310,9 @@ s32 DebugCamera_UpdateDemoControl(DebugCam* debugCam, Camera* cam) {
|
|||
if (CHECK_BTN_ALL(sPlay->state.input[DEBUG_CAM_CONTROLLER_PORT].cur.button, BTN_L) &&
|
||||
CHECK_BTN_ALL(sPlay->state.input[DEBUG_CAM_CONTROLLER_PORT].press.button, BTN_CRIGHT)) {
|
||||
for (i = 0; i < ARRAY_COUNT(sDebugCamCuts) - 1; i++) {
|
||||
osSyncPrintf("###%2d:(%c) (%d %d) %d %d %d\n", i, sDebugCamCuts[i].letter,
|
||||
sDebugCamCuts[i].position, sDebugCamCuts[i].lookAt, sDebugCamCuts[i].nFrames,
|
||||
sDebugCamCuts[i].nPoints, sDebugCamCuts[i].mode);
|
||||
PRINTF("###%2d:(%c) (%d %d) %d %d %d\n", i, sDebugCamCuts[i].letter, sDebugCamCuts[i].position,
|
||||
sDebugCamCuts[i].lookAt, sDebugCamCuts[i].nFrames, sDebugCamCuts[i].nPoints,
|
||||
sDebugCamCuts[i].mode);
|
||||
}
|
||||
DebugCamera_PrintAllCuts(cam);
|
||||
} else if (CHECK_BTN_ALL(sPlay->state.input[DEBUG_CAM_CONTROLLER_PORT].cur.button, BTN_L) &&
|
||||
|
@ -2321,7 +2321,7 @@ s32 DebugCamera_UpdateDemoControl(DebugCam* debugCam, Camera* cam) {
|
|||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
for (i = 0; i < ARRAY_COUNT(sDebugCamCuts) - 1; i++) {
|
||||
if (sDebugCamCuts[i].nPoints != 0) {
|
||||
osSyncPrintf("\n@@@ /* CUT [%d]\t*/", i);
|
||||
PRINTF("\n@@@ /* CUT [%d]\t*/", i);
|
||||
DebugCamera_PrintCutBytes(&sDebugCamCuts[i]);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -11,13 +11,13 @@ void DebugArena_CheckPointer(void* ptr, u32 size, const char* name, const char*
|
|||
if (ptr == NULL) {
|
||||
if (gDebugArenaLogSeverity >= LOG_SEVERITY_ERROR) {
|
||||
// "%s: %u bytes %s failed\n"
|
||||
osSyncPrintf("%s: %u バイトの%sに失敗しました\n", name, size, action);
|
||||
PRINTF("%s: %u バイトの%sに失敗しました\n", name, size, action);
|
||||
__osDisplayArena(&sDebugArena);
|
||||
return;
|
||||
}
|
||||
} else if (gDebugArenaLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
// "%s: %u bytes %s succeeded\n"
|
||||
osSyncPrintf("%s: %u バイトの%sに成功しました\n", name, size, action);
|
||||
PRINTF("%s: %u バイトの%sに成功しました\n", name, size, action);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -84,7 +84,7 @@ void* DebugArena_Calloc(u32 num, u32 size) {
|
|||
|
||||
void DebugArena_Display(void) {
|
||||
// "Zelda heap display" ("Zelda" should probably have been changed to "Debug")
|
||||
osSyncPrintf("ゼルダヒープ表示\n");
|
||||
PRINTF("ゼルダヒープ表示\n");
|
||||
__osDisplayArena(&sDebugArena);
|
||||
}
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ void GameState_FaultPrint(void) {
|
|||
static char sBtnChars[] = "ABZSuldr*+LRudlr";
|
||||
s32 i;
|
||||
|
||||
osSyncPrintf("last_button=%04x\n", sLastButtonPressed);
|
||||
PRINTF("last_button=%04x\n", sLastButtonPressed);
|
||||
FaultDrawer_DrawText(120, 180, "%08x", sLastButtonPressed);
|
||||
for (i = 0; i < ARRAY_COUNT(sBtnChars); i++) {
|
||||
if (sLastButtonPressed & (1 << i)) {
|
||||
|
@ -179,7 +179,7 @@ void GameState_Draw(GameState* gameState, GraphicsContext* gfxCtx) {
|
|||
DebugArena_Display();
|
||||
SystemArena_Display();
|
||||
// "%08x bytes left until the death of Hyrule (game_alloc)"
|
||||
osSyncPrintf("ハイラル滅亡まであと %08x バイト(game_alloc)\n", THA_GetRemaining(&gameState->tha));
|
||||
PRINTF("ハイラル滅亡まであと %08x バイト(game_alloc)\n", THA_GetRemaining(&gameState->tha));
|
||||
R_ENABLE_ARENA_DBG = 0;
|
||||
}
|
||||
|
||||
|
@ -333,14 +333,14 @@ void GameState_Update(GameState* gameState) {
|
|||
void GameState_InitArena(GameState* gameState, size_t size) {
|
||||
void* arena;
|
||||
|
||||
osSyncPrintf("ハイラル確保 サイズ=%u バイト\n"); // "Hyrule reserved size = %u bytes"
|
||||
PRINTF("ハイラル確保 サイズ=%u バイト\n"); // "Hyrule reserved size = %u bytes"
|
||||
arena = GameAlloc_MallocDebug(&gameState->alloc, size, "../game.c", 992);
|
||||
if (arena != NULL) {
|
||||
THA_Init(&gameState->tha, arena, size);
|
||||
osSyncPrintf("ハイラル確保成功\n"); // "Successful Hyral"
|
||||
PRINTF("ハイラル確保成功\n"); // "Successful Hyral"
|
||||
} else {
|
||||
THA_Init(&gameState->tha, NULL, 0);
|
||||
osSyncPrintf("ハイラル確保失敗\n"); // "Failure to secure Hyrule"
|
||||
PRINTF("ハイラル確保失敗\n"); // "Failure to secure Hyrule"
|
||||
Fault_AddHungupAndCrash("../game.c", 999);
|
||||
}
|
||||
}
|
||||
|
@ -355,27 +355,27 @@ void GameState_Realloc(GameState* gameState, size_t size) {
|
|||
|
||||
THA_Destroy(&gameState->tha);
|
||||
GameAlloc_Free(alloc, thaStart);
|
||||
osSyncPrintf("ハイラル一時解放!!\n"); // "Hyrule temporarily released!!"
|
||||
PRINTF("ハイラル一時解放!!\n"); // "Hyrule temporarily released!!"
|
||||
SystemArena_GetSizes(&systemMaxFree, &systemFree, &systemAlloc);
|
||||
if ((systemMaxFree - 0x10) < size) {
|
||||
osSyncPrintf("%c", BEL);
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF("%c", BEL);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
|
||||
// "Not enough memory. Change the hyral size to the largest possible value"
|
||||
osSyncPrintf("メモリが足りません。ハイラルサイズを可能な最大値に変更します\n");
|
||||
osSyncPrintf("(hyral=%08x max=%08x free=%08x alloc=%08x)\n", size, systemMaxFree, systemFree, systemAlloc);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("メモリが足りません。ハイラルサイズを可能な最大値に変更します\n");
|
||||
PRINTF("(hyral=%08x max=%08x free=%08x alloc=%08x)\n", size, systemMaxFree, systemFree, systemAlloc);
|
||||
PRINTF(VT_RST);
|
||||
size = systemMaxFree - 0x10;
|
||||
}
|
||||
|
||||
osSyncPrintf("ハイラル再確保 サイズ=%u バイト\n", size); // "Hyral reallocate size = %u bytes"
|
||||
PRINTF("ハイラル再確保 サイズ=%u バイト\n", size); // "Hyral reallocate size = %u bytes"
|
||||
gameArena = GameAlloc_MallocDebug(alloc, size, "../game.c", 1033);
|
||||
if (gameArena != NULL) {
|
||||
THA_Init(&gameState->tha, gameArena, size);
|
||||
osSyncPrintf("ハイラル再確保成功\n"); // "Successful reacquisition of Hyrule"
|
||||
PRINTF("ハイラル再確保成功\n"); // "Successful reacquisition of Hyrule"
|
||||
} else {
|
||||
THA_Init(&gameState->tha, NULL, 0);
|
||||
osSyncPrintf("ハイラル再確保失敗\n"); // "Failure to secure Hyral"
|
||||
PRINTF("ハイラル再確保失敗\n"); // "Failure to secure Hyral"
|
||||
SystemArena_Display();
|
||||
Fault_AddHungupAndCrash("../game.c", 1044);
|
||||
}
|
||||
|
@ -385,7 +385,7 @@ void GameState_Init(GameState* gameState, GameStateFunc init, GraphicsContext* g
|
|||
OSTime startTime;
|
||||
OSTime endTime;
|
||||
|
||||
osSyncPrintf("game コンストラクタ開始\n"); // "game constructor start"
|
||||
PRINTF("game コンストラクタ開始\n"); // "game constructor start"
|
||||
gameState->gfxCtx = gfxCtx;
|
||||
gameState->frames = 0;
|
||||
gameState->main = NULL;
|
||||
|
@ -397,13 +397,13 @@ void GameState_Init(GameState* gameState, GameStateFunc init, GraphicsContext* g
|
|||
endTime = osGetTime();
|
||||
|
||||
// "game_set_next_game_null processing time %d us"
|
||||
osSyncPrintf("game_set_next_game_null 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
PRINTF("game_set_next_game_null 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
startTime = endTime;
|
||||
GameAlloc_Init(&gameState->alloc);
|
||||
|
||||
endTime = osGetTime();
|
||||
// "gamealloc_init processing time %d us"
|
||||
osSyncPrintf("gamealloc_init 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
PRINTF("gamealloc_init 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
|
||||
startTime = endTime;
|
||||
GameState_InitArena(gameState, 0x100000);
|
||||
|
@ -412,7 +412,7 @@ void GameState_Init(GameState* gameState, GameStateFunc init, GraphicsContext* g
|
|||
|
||||
endTime = osGetTime();
|
||||
// "init processing time %d us"
|
||||
osSyncPrintf("init 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
PRINTF("init 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
|
||||
startTime = endTime;
|
||||
LogUtils_CheckNullPointer("this->cleanup", gameState->destroy, "../game.c", 1088);
|
||||
|
@ -428,15 +428,15 @@ void GameState_Init(GameState* gameState, GameStateFunc init, GraphicsContext* g
|
|||
|
||||
endTime = osGetTime();
|
||||
// "Other initialization processing time %d us"
|
||||
osSyncPrintf("その他初期化 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
PRINTF("その他初期化 処理時間 %d us\n", OS_CYCLES_TO_USEC(endTime - startTime));
|
||||
|
||||
Fault_AddClient(&sGameFaultClient, GameState_FaultPrint, NULL, NULL);
|
||||
|
||||
osSyncPrintf("game コンストラクタ終了\n"); // "game constructor end"
|
||||
PRINTF("game コンストラクタ終了\n"); // "game constructor end"
|
||||
}
|
||||
|
||||
void GameState_Destroy(GameState* gameState) {
|
||||
osSyncPrintf("game デストラクタ開始\n"); // "game destructor start"
|
||||
PRINTF("game デストラクタ開始\n"); // "game destructor start"
|
||||
AudioMgr_StopAllSfx();
|
||||
func_800F3054();
|
||||
osRecvMesg(&gameState->gfxCtx->queue, NULL, OS_MESG_BLOCK);
|
||||
|
@ -457,7 +457,7 @@ void GameState_Destroy(GameState* gameState) {
|
|||
SystemArena_Display();
|
||||
Fault_RemoveClient(&sGameFaultClient);
|
||||
|
||||
osSyncPrintf("game デストラクタ終了\n"); // "game destructor end"
|
||||
PRINTF("game デストラクタ終了\n"); // "game destructor end"
|
||||
}
|
||||
|
||||
GameStateFunc GameState_GetInit(GameState* gameState) {
|
||||
|
@ -476,24 +476,24 @@ void* GameState_Alloc(GameState* gameState, size_t size, char* file, s32 line) {
|
|||
void* ret;
|
||||
|
||||
if (THA_IsCrash(&gameState->tha)) {
|
||||
osSyncPrintf("ハイラルは滅亡している\n");
|
||||
PRINTF("ハイラルは滅亡している\n");
|
||||
ret = NULL;
|
||||
} else if ((u32)THA_GetRemaining(&gameState->tha) < size) {
|
||||
// "Hyral on the verge of extinction does not have %d bytes left (%d bytes until extinction)"
|
||||
osSyncPrintf("滅亡寸前のハイラルには %d バイトの余力もない(滅亡まであと %d バイト)\n", size,
|
||||
THA_GetRemaining(&gameState->tha));
|
||||
PRINTF("滅亡寸前のハイラルには %d バイトの余力もない(滅亡まであと %d バイト)\n", size,
|
||||
THA_GetRemaining(&gameState->tha));
|
||||
ret = NULL;
|
||||
} else {
|
||||
ret = THA_AllocTailAlign16(&gameState->tha, size);
|
||||
if (THA_IsCrash(&gameState->tha)) {
|
||||
osSyncPrintf("ハイラルは滅亡してしまった\n"); // "Hyrule has been destroyed"
|
||||
PRINTF("ハイラルは滅亡してしまった\n"); // "Hyrule has been destroyed"
|
||||
ret = NULL;
|
||||
}
|
||||
}
|
||||
if (ret != NULL) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("game_alloc(%08x) %08x-%08x [%s:%d]\n", size, ret, (uintptr_t)ret + size, file, line);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("game_alloc(%08x) %08x-%08x [%s:%d]\n", size, ret, (uintptr_t)ret + size, file, line);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
|
|
@ -3,11 +3,11 @@
|
|||
void GameAlloc_Log(GameAlloc* this) {
|
||||
GameAllocEntry* iter;
|
||||
|
||||
osSyncPrintf("this = %08x\n", this);
|
||||
PRINTF("this = %08x\n", this);
|
||||
|
||||
iter = this->base.next;
|
||||
while (iter != &this->base) {
|
||||
osSyncPrintf("ptr = %08x size = %d\n", iter, iter->size);
|
||||
PRINTF("ptr = %08x size = %d\n", iter, iter->size);
|
||||
iter = iter->next;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -341,7 +341,7 @@ void GfxPrint_Open(GfxPrint* this, Gfx* dList) {
|
|||
this->dList = dList;
|
||||
GfxPrint_Setup(this);
|
||||
} else {
|
||||
osSyncPrintf("gfxprint_open:2重オープンです\n");
|
||||
PRINTF("gfxprint_open:2重オープンです\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -67,16 +67,16 @@ void Graph_DisassembleUCode(Gfx* workBuf) {
|
|||
R_UCODE_DISAS_LOAD_COUNT = disassembler.loaducodeCnt;
|
||||
|
||||
if (R_UCODE_DISAS_LOG_MODE == 1 || R_UCODE_DISAS_LOG_MODE == 2) {
|
||||
osSyncPrintf("vtx_cnt=%d\n", disassembler.vtxCnt);
|
||||
osSyncPrintf("spvtx_cnt=%d\n", disassembler.spvtxCnt);
|
||||
osSyncPrintf("tri1_cnt=%d\n", disassembler.tri1Cnt);
|
||||
osSyncPrintf("tri2_cnt=%d\n", disassembler.tri2Cnt);
|
||||
osSyncPrintf("quad_cnt=%d\n", disassembler.quadCnt);
|
||||
osSyncPrintf("line_cnt=%d\n", disassembler.lineCnt);
|
||||
osSyncPrintf("sync_err=%d\n", disassembler.syncErr);
|
||||
osSyncPrintf("loaducode_cnt=%d\n", disassembler.loaducodeCnt);
|
||||
osSyncPrintf("dl_depth=%d\n", disassembler.dlDepth);
|
||||
osSyncPrintf("dl_cnt=%d\n", disassembler.dlCnt);
|
||||
PRINTF("vtx_cnt=%d\n", disassembler.vtxCnt);
|
||||
PRINTF("spvtx_cnt=%d\n", disassembler.spvtxCnt);
|
||||
PRINTF("tri1_cnt=%d\n", disassembler.tri1Cnt);
|
||||
PRINTF("tri2_cnt=%d\n", disassembler.tri2Cnt);
|
||||
PRINTF("quad_cnt=%d\n", disassembler.quadCnt);
|
||||
PRINTF("line_cnt=%d\n", disassembler.lineCnt);
|
||||
PRINTF("sync_err=%d\n", disassembler.syncErr);
|
||||
PRINTF("loaducode_cnt=%d\n", disassembler.loaducodeCnt);
|
||||
PRINTF("dl_depth=%d\n", disassembler.dlDepth);
|
||||
PRINTF("dl_cnt=%d\n", disassembler.dlCnt);
|
||||
}
|
||||
|
||||
UCodeDisas_Destroy(&disassembler);
|
||||
|
@ -168,9 +168,9 @@ void Graph_TaskSet00(GraphicsContext* gfxCtx) {
|
|||
osStopTimer(&timer);
|
||||
|
||||
if (msg == (OSMesg)666) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("RCPが帰ってきませんでした。"); // "RCP did not return."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("RCPが帰ってきませんでした。"); // "RCP did not return."
|
||||
PRINTF(VT_RST);
|
||||
|
||||
LogUtils_LogHexDump((void*)PHYS_TO_K1(SP_BASE_REG), 0x20);
|
||||
LogUtils_LogHexDump((void*)PHYS_TO_K1(DPC_BASE_REG), 0x20);
|
||||
|
@ -334,37 +334,37 @@ void Graph_Update(GraphicsContext* gfxCtx, GameState* gameState) {
|
|||
|
||||
if (pool->headMagic != GFXPOOL_HEAD_MAGIC) {
|
||||
//! @bug (?) : "problem = true;" may be missing
|
||||
osSyncPrintf("%c", BEL);
|
||||
PRINTF("%c", BEL);
|
||||
// "Dynamic area head is destroyed"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "ダイナミック領域先頭が破壊されています\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "ダイナミック領域先頭が破壊されています\n" VT_RST);
|
||||
Fault_AddHungupAndCrash("../graph.c", 1070);
|
||||
}
|
||||
if (pool->tailMagic != GFXPOOL_TAIL_MAGIC) {
|
||||
problem = true;
|
||||
osSyncPrintf("%c", BEL);
|
||||
PRINTF("%c", BEL);
|
||||
// "Dynamic region tail is destroyed"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "ダイナミック領域末尾が破壊されています\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "ダイナミック領域末尾が破壊されています\n" VT_RST);
|
||||
Fault_AddHungupAndCrash("../graph.c", 1076);
|
||||
}
|
||||
}
|
||||
|
||||
if (THGA_IsCrash(&gfxCtx->polyOpa)) {
|
||||
problem = true;
|
||||
osSyncPrintf("%c", BEL);
|
||||
PRINTF("%c", BEL);
|
||||
// "Zelda 0 is dead"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "ゼルダ0は死んでしまった(graph_alloc is empty)\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "ゼルダ0は死んでしまった(graph_alloc is empty)\n" VT_RST);
|
||||
}
|
||||
if (THGA_IsCrash(&gfxCtx->polyXlu)) {
|
||||
problem = true;
|
||||
osSyncPrintf("%c", BEL);
|
||||
PRINTF("%c", BEL);
|
||||
// "Zelda 1 is dead"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "ゼルダ1は死んでしまった(graph_alloc is empty)\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "ゼルダ1は死んでしまった(graph_alloc is empty)\n" VT_RST);
|
||||
}
|
||||
if (THGA_IsCrash(&gfxCtx->overlay)) {
|
||||
problem = true;
|
||||
osSyncPrintf("%c", BEL);
|
||||
PRINTF("%c", BEL);
|
||||
// "Zelda 4 is dead"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "ゼルダ4は死んでしまった(graph_alloc is empty)\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "ゼルダ4は死んでしまった(graph_alloc is empty)\n" VT_RST);
|
||||
}
|
||||
|
||||
if (!problem) {
|
||||
|
@ -401,7 +401,7 @@ void Graph_Update(GraphicsContext* gfxCtx, GameState* gameState) {
|
|||
|
||||
if (gIsCtrlr2Valid && PreNmiBuff_IsResetting(gAppNmiBufferPtr) && !gameState->inPreNMIState) {
|
||||
// "To reset mode"
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "PRE-NMIによりリセットモードに移行します\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "PRE-NMIによりリセットモードに移行します\n" VT_RST);
|
||||
SET_NEXT_GAMESTATE(gameState, PreNMI_Init, PreNMIState);
|
||||
gameState->running = false;
|
||||
}
|
||||
|
@ -415,7 +415,7 @@ void Graph_ThreadEntry(void* arg0) {
|
|||
GameStateOverlay* ovl;
|
||||
char faultMsg[0x50];
|
||||
|
||||
osSyncPrintf("グラフィックスレッド実行開始\n"); // "Start graphic thread execution"
|
||||
PRINTF("グラフィックスレッド実行開始\n"); // "Start graphic thread execution"
|
||||
Graph_Init(&gfxCtx);
|
||||
|
||||
while (nextOvl != NULL) {
|
||||
|
@ -423,12 +423,12 @@ void Graph_ThreadEntry(void* arg0) {
|
|||
Overlay_LoadGameState(ovl);
|
||||
|
||||
size = ovl->instanceSize;
|
||||
osSyncPrintf("クラスサイズ=%dバイト\n", size); // "Class size = %d bytes"
|
||||
PRINTF("クラスサイズ=%dバイト\n", size); // "Class size = %d bytes"
|
||||
|
||||
gameState = SYSTEM_ARENA_MALLOC(size, "../graph.c", 1196);
|
||||
|
||||
if (gameState == NULL) {
|
||||
osSyncPrintf("確保失敗\n"); // "Failure to secure"
|
||||
PRINTF("確保失敗\n"); // "Failure to secure"
|
||||
|
||||
sprintf(faultMsg, "CLASS SIZE= %d bytes", size);
|
||||
Fault_AddHungupAndCrashImpl("GAME CLASS MALLOC FAILED", faultMsg);
|
||||
|
@ -446,15 +446,15 @@ void Graph_ThreadEntry(void* arg0) {
|
|||
Overlay_FreeGameState(ovl);
|
||||
}
|
||||
Graph_Destroy(&gfxCtx);
|
||||
osSyncPrintf("グラフィックスレッド実行終了\n"); // "End of graphic thread execution"
|
||||
PRINTF("グラフィックスレッド実行終了\n"); // "End of graphic thread execution"
|
||||
}
|
||||
|
||||
void* Graph_Alloc(GraphicsContext* gfxCtx, size_t size) {
|
||||
TwoHeadGfxArena* thga = &gfxCtx->polyOpa;
|
||||
|
||||
if (HREG(59) == 1) {
|
||||
osSyncPrintf("graph_alloc siz=%d thga size=%08x bufp=%08x head=%08x tail=%08x\n", size, thga->size, thga->start,
|
||||
thga->p, thga->d);
|
||||
PRINTF("graph_alloc siz=%d thga size=%08x bufp=%08x head=%08x tail=%08x\n", size, thga->size, thga->start,
|
||||
thga->p, thga->d);
|
||||
}
|
||||
return THGA_AllocTail(&gfxCtx->polyOpa, ALIGN16(size));
|
||||
}
|
||||
|
@ -463,8 +463,8 @@ void* Graph_Alloc2(GraphicsContext* gfxCtx, size_t size) {
|
|||
TwoHeadGfxArena* thga = &gfxCtx->polyOpa;
|
||||
|
||||
if (HREG(59) == 1) {
|
||||
osSyncPrintf("graph_alloc siz=%d thga size=%08x bufp=%08x head=%08x tail=%08x\n", size, thga->size, thga->start,
|
||||
thga->p, thga->d);
|
||||
PRINTF("graph_alloc siz=%d thga size=%08x bufp=%08x head=%08x tail=%08x\n", size, thga->size, thga->start,
|
||||
thga->p, thga->d);
|
||||
}
|
||||
return THGA_AllocTail(&gfxCtx->polyOpa, ALIGN16(size));
|
||||
}
|
||||
|
|
|
@ -118,7 +118,7 @@ void IrqMgr_SendMesgToClients(IrqMgr* irqMgr, OSMesg msg) {
|
|||
for (client = irqMgr->clients; client != NULL; client = client->prev) {
|
||||
if (MQ_IS_FULL(client->queue)) {
|
||||
// "irqmgr_SendMesgForClient: Message queue is overflowing mq=%08x cnt=%d"
|
||||
osSyncPrintf(
|
||||
PRINTF(
|
||||
VT_COL(RED, WHITE) "irqmgr_SendMesgForClient:メッセージキューがあふれています mq=%08x cnt=%d\n" VT_RST,
|
||||
client->queue, MQ_GET_COUNT(client->queue));
|
||||
} else {
|
||||
|
@ -141,7 +141,7 @@ void IrqMgr_JamMesgToClients(IrqMgr* irqMgr, OSMesg msg) {
|
|||
for (client = irqMgr->clients; client != NULL; client = client->prev) {
|
||||
if (MQ_IS_FULL(client->queue)) {
|
||||
// "irqmgr_JamMesgForClient: Message queue is overflowing mq=%08x cnt=%d"
|
||||
osSyncPrintf(
|
||||
PRINTF(
|
||||
VT_COL(RED, WHITE) "irqmgr_JamMesgForClient:メッセージキューがあふれています mq=%08x cnt=%d\n" VT_RST,
|
||||
client->queue, MQ_GET_COUNT(client->queue));
|
||||
} else {
|
||||
|
@ -171,19 +171,19 @@ void IrqMgr_HandlePreNMI(IrqMgr* irqMgr) {
|
|||
|
||||
void IrqMgr_CheckStacks(void) {
|
||||
// "0.5 seconds after PRENMI"
|
||||
osSyncPrintf("irqmgr.c: PRENMIから0.5秒経過\n");
|
||||
PRINTF("irqmgr.c: PRENMIから0.5秒経過\n");
|
||||
|
||||
if (StackCheck_Check(NULL) == STACK_STATUS_OK) {
|
||||
// "The stack looks ok"
|
||||
osSyncPrintf("スタックは大丈夫みたいです\n");
|
||||
PRINTF("スタックは大丈夫みたいです\n");
|
||||
} else {
|
||||
osSyncPrintf("%c", BEL);
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF("%c", BEL);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Stack overflow or dangerous"
|
||||
osSyncPrintf("スタックがオーバーフローしたか危険な状態です\n");
|
||||
PRINTF("スタックがオーバーフローしたか危険な状態です\n");
|
||||
// "Increase stack size early or don't consume stack"
|
||||
osSyncPrintf("早々にスタックサイズを増やすか、スタックを消費しないようにしてください\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("早々にスタックサイズを増やすか、スタックを消費しないようにしてください\n");
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -208,7 +208,7 @@ void IrqMgr_HandlePreNMI480(IrqMgr* irqMgr) {
|
|||
result = osAfterPreNMI();
|
||||
if (result != 0) {
|
||||
// "osAfterPreNMI returned %d !?"
|
||||
osSyncPrintf("osAfterPreNMIが %d を返しました!?\n", result);
|
||||
PRINTF("osAfterPreNMIが %d を返しました!?\n", result);
|
||||
// osAfterPreNMI failed, try again in 1ms
|
||||
//! @bug setting the same timer for a second time without letting the first one complete breaks
|
||||
//! the timer linked list
|
||||
|
@ -244,7 +244,7 @@ void IrqMgr_ThreadEntry(void* arg) {
|
|||
u8 exit;
|
||||
|
||||
// "Start IRQ manager thread execution"
|
||||
osSyncPrintf("IRQマネージャスレッド実行開始\n");
|
||||
PRINTF("IRQマネージャスレッド実行開始\n");
|
||||
exit = false;
|
||||
|
||||
while (!exit) {
|
||||
|
@ -254,39 +254,39 @@ void IrqMgr_ThreadEntry(void* arg) {
|
|||
IrqMgr_HandleRetrace(irqMgr);
|
||||
break;
|
||||
case IRQ_PRENMI_MSG:
|
||||
osSyncPrintf("PRE_NMI_MSG\n");
|
||||
PRINTF("PRE_NMI_MSG\n");
|
||||
// "Scheduler: Receives PRE_NMI message"
|
||||
osSyncPrintf("スケジューラ:PRE_NMIメッセージを受信\n");
|
||||
PRINTF("スケジューラ:PRE_NMIメッセージを受信\n");
|
||||
IrqMgr_HandlePreNMI(irqMgr);
|
||||
break;
|
||||
case IRQ_PRENMI450_MSG:
|
||||
osSyncPrintf("PRENMI450_MSG\n");
|
||||
PRINTF("PRENMI450_MSG\n");
|
||||
// "Scheduler: Receives PRENMI450 message"
|
||||
osSyncPrintf("スケジューラ:PRENMI450メッセージを受信\n");
|
||||
PRINTF("スケジューラ:PRENMI450メッセージを受信\n");
|
||||
IrqMgr_HandlePreNMI450(irqMgr);
|
||||
break;
|
||||
case IRQ_PRENMI480_MSG:
|
||||
osSyncPrintf("PRENMI480_MSG\n");
|
||||
PRINTF("PRENMI480_MSG\n");
|
||||
// "Scheduler: Receives PRENMI480 message"
|
||||
osSyncPrintf("スケジューラ:PRENMI480メッセージを受信\n");
|
||||
PRINTF("スケジューラ:PRENMI480メッセージを受信\n");
|
||||
IrqMgr_HandlePreNMI480(irqMgr);
|
||||
break;
|
||||
case IRQ_PRENMI500_MSG:
|
||||
osSyncPrintf("PRENMI500_MSG\n");
|
||||
PRINTF("PRENMI500_MSG\n");
|
||||
// "Scheduler: Receives PRENMI500 message"
|
||||
osSyncPrintf("スケジューラ:PRENMI500メッセージを受信\n");
|
||||
PRINTF("スケジューラ:PRENMI500メッセージを受信\n");
|
||||
exit = true;
|
||||
IrqMgr_HandlePreNMI500(irqMgr);
|
||||
break;
|
||||
default:
|
||||
// "Unexpected message received"
|
||||
osSyncPrintf("irqmgr.c:予期しないメッセージを受け取りました(%08x)\n", msg);
|
||||
PRINTF("irqmgr.c:予期しないメッセージを受け取りました(%08x)\n", msg);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// "End of IRQ manager thread execution"
|
||||
osSyncPrintf("IRQマネージャスレッド実行終了\n");
|
||||
PRINTF("IRQマネージャスレッド実行終了\n");
|
||||
}
|
||||
|
||||
void IrqMgr_Init(IrqMgr* irqMgr, void* stack, OSPri pri, u8 retraceCount) {
|
||||
|
|
|
@ -12,12 +12,12 @@ s32 Overlay_Load(uintptr_t vromStart, uintptr_t vromEnd, void* vramStart, void*
|
|||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
// "Start loading dynamic link function"
|
||||
osSyncPrintf("\nダイナミックリンクファンクションのロードを開始します\n");
|
||||
PRINTF("\nダイナミックリンクファンクションのロードを開始します\n");
|
||||
}
|
||||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
// "DMA transfer of TEXT, DATA, RODATA + rel (%08x-%08x)"
|
||||
osSyncPrintf("TEXT,DATA,RODATA+relをDMA転送します(%08x-%08x)\n", allocatedRamAddr, end);
|
||||
PRINTF("TEXT,DATA,RODATA+relをDMA転送します(%08x-%08x)\n", allocatedRamAddr, end);
|
||||
}
|
||||
|
||||
// DMA the overlay, wait until transfer completes
|
||||
|
@ -29,12 +29,12 @@ s32 Overlay_Load(uintptr_t vromStart, uintptr_t vromEnd, void* vramStart, void*
|
|||
ovlRelocs = (OverlayRelocationSection*)(end - relocSectionOffset);
|
||||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
osSyncPrintf("TEXT(%08x), DATA(%08x), RODATA(%08x), BSS(%08x)\n", ovlRelocs->textSize, ovlRelocs->dataSize,
|
||||
ovlRelocs->rodataSize, ovlRelocs->bssSize);
|
||||
PRINTF("TEXT(%08x), DATA(%08x), RODATA(%08x), BSS(%08x)\n", ovlRelocs->textSize, ovlRelocs->dataSize,
|
||||
ovlRelocs->rodataSize, ovlRelocs->bssSize);
|
||||
}
|
||||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
osSyncPrintf("リロケーションします\n"); // "Relocate"
|
||||
PRINTF("リロケーションします\n"); // "Relocate"
|
||||
}
|
||||
|
||||
// Relocate pointers in overlay code and data
|
||||
|
@ -44,7 +44,7 @@ s32 Overlay_Load(uintptr_t vromStart, uintptr_t vromEnd, void* vramStart, void*
|
|||
if (ovlRelocs->bssSize != 0) {
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
// "Clear BSS area (% 08x-% 08x)"
|
||||
osSyncPrintf("BSS領域をクリアします(%08x-%08x)\n", end, end + ovlRelocs->bssSize);
|
||||
PRINTF("BSS領域をクリアします(%08x-%08x)\n", end, end + ovlRelocs->bssSize);
|
||||
}
|
||||
bzero((void*)end, (s32)ovlRelocs->bssSize);
|
||||
}
|
||||
|
@ -53,7 +53,7 @@ s32 Overlay_Load(uintptr_t vromStart, uintptr_t vromEnd, void* vramStart, void*
|
|||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
// "Clear REL area (%08x-%08x)"
|
||||
osSyncPrintf("REL領域をクリアします(%08x-%08x)\n", ovlRelocs, (uintptr_t)ovlRelocs + size);
|
||||
PRINTF("REL領域をクリアします(%08x-%08x)\n", ovlRelocs, (uintptr_t)ovlRelocs + size);
|
||||
}
|
||||
|
||||
// Clear relocations, this space remains allocated and goes unused
|
||||
|
@ -66,7 +66,7 @@ s32 Overlay_Load(uintptr_t vromStart, uintptr_t vromEnd, void* vramStart, void*
|
|||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
// "Finish loading dynamic link function"
|
||||
osSyncPrintf("ダイナミックリンクファンクションのロードを終了します\n\n");
|
||||
PRINTF("ダイナミックリンクファンクションのロードを終了します\n\n");
|
||||
}
|
||||
return size;
|
||||
}
|
||||
|
|
|
@ -4,9 +4,9 @@ void* Overlay_AllocateAndLoad(uintptr_t vromStart, uintptr_t vromEnd, void* vram
|
|||
void* allocatedRamAddr = SYSTEM_ARENA_MALLOC_R((intptr_t)vramEnd - (intptr_t)vramStart, "../loadfragment2.c", 31);
|
||||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
osSyncPrintf("OVL:SPEC(%08x-%08x) REAL(%08x-%08x) OFFSET(%08x)\n", vramStart, vramEnd, allocatedRamAddr,
|
||||
((uintptr_t)vramEnd - (uintptr_t)vramStart) + (uintptr_t)allocatedRamAddr,
|
||||
(uintptr_t)vramStart - (uintptr_t)allocatedRamAddr);
|
||||
PRINTF("OVL:SPEC(%08x-%08x) REAL(%08x-%08x) OFFSET(%08x)\n", vramStart, vramEnd, allocatedRamAddr,
|
||||
((uintptr_t)vramEnd - (uintptr_t)vramStart) + (uintptr_t)allocatedRamAddr,
|
||||
(uintptr_t)vramStart - (uintptr_t)allocatedRamAddr);
|
||||
}
|
||||
|
||||
if (allocatedRamAddr != NULL) {
|
||||
|
|
|
@ -26,11 +26,10 @@ OSMesgQueue sSerialEventQueue;
|
|||
OSMesg sSerialMsgBuf[1];
|
||||
|
||||
void Main_LogSystemHeap(void) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "System heap size% 08x (% dKB) Start address% 08x"
|
||||
osSyncPrintf("システムヒープサイズ %08x(%dKB) 開始アドレス %08x\n", gSystemHeapSize, gSystemHeapSize / 1024,
|
||||
gSystemHeap);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("システムヒープサイズ %08x(%dKB) 開始アドレス %08x\n", gSystemHeapSize, gSystemHeapSize / 1024, gSystemHeap);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
void Main(void* arg) {
|
||||
|
@ -43,7 +42,7 @@ void Main(void* arg) {
|
|||
u32 debugHeapSize;
|
||||
s16* msg;
|
||||
|
||||
osSyncPrintf("mainproc 実行開始\n"); // "Start running"
|
||||
PRINTF("mainproc 実行開始\n"); // "Start running"
|
||||
gScreenWidth = SCREEN_WIDTH;
|
||||
gScreenHeight = SCREEN_HEIGHT;
|
||||
gAppNmiBufferPtr = (PreNmiBuff*)osAppNMIBuffer;
|
||||
|
@ -54,7 +53,7 @@ void Main(void* arg) {
|
|||
fb = (uintptr_t)SysCfb_GetFbPtr(0);
|
||||
gSystemHeapSize = fb - systemHeapStart;
|
||||
// "System heap initalization"
|
||||
osSyncPrintf("システムヒープ初期化 %08x-%08x %08x\n", systemHeapStart, fb, gSystemHeapSize);
|
||||
PRINTF("システムヒープ初期化 %08x-%08x %08x\n", systemHeapStart, fb, gSystemHeapSize);
|
||||
SystemHeap_Init((void*)systemHeapStart, gSystemHeapSize); // initializes the system heap
|
||||
if (osMemSize >= 0x800000) {
|
||||
debugHeapStart = SysCfb_GetFbEnd();
|
||||
|
@ -63,7 +62,7 @@ void Main(void* arg) {
|
|||
debugHeapSize = 0x400;
|
||||
debugHeapStart = SYSTEM_ARENA_MALLOC(debugHeapSize, "../main.c", 565);
|
||||
}
|
||||
osSyncPrintf("debug_InitArena(%08x, %08x)\n", debugHeapStart, debugHeapSize);
|
||||
PRINTF("debug_InitArena(%08x, %08x)\n", debugHeapStart, debugHeapSize);
|
||||
DebugArena_Init(debugHeapStart, debugHeapSize);
|
||||
Regs_Init();
|
||||
|
||||
|
@ -78,7 +77,7 @@ void Main(void* arg) {
|
|||
StackCheck_Init(&sIrqMgrStackInfo, sIrqMgrStack, STACK_TOP(sIrqMgrStack), 0, 0x100, "irqmgr");
|
||||
IrqMgr_Init(&gIrqMgr, STACK_TOP(sIrqMgrStack), THREAD_PRI_IRQMGR, 1);
|
||||
|
||||
osSyncPrintf("タスクスケジューラの初期化\n"); // "Initialize the task scheduler"
|
||||
PRINTF("タスクスケジューラの初期化\n"); // "Initialize the task scheduler"
|
||||
StackCheck_Init(&sSchedStackInfo, sSchedStack, STACK_TOP(sSchedStack), 0, 0x100, "sched");
|
||||
Sched_Init(&gScheduler, STACK_TOP(sSchedStack), THREAD_PRI_SCHED, gViConfigModeType, 1, &gIrqMgr);
|
||||
|
||||
|
@ -104,13 +103,13 @@ void Main(void* arg) {
|
|||
break;
|
||||
}
|
||||
if (*msg == OS_SC_PRE_NMI_MSG) {
|
||||
osSyncPrintf("main.c: リセットされたみたいだよ\n"); // "Looks like it's been reset"
|
||||
PRINTF("main.c: リセットされたみたいだよ\n"); // "Looks like it's been reset"
|
||||
PreNmiBuff_SetReset(gAppNmiBufferPtr);
|
||||
}
|
||||
}
|
||||
|
||||
osSyncPrintf("mainproc 後始末\n"); // "Cleanup"
|
||||
PRINTF("mainproc 後始末\n"); // "Cleanup"
|
||||
osDestroyThread(&sGraphThread);
|
||||
RcpUtils_Reset();
|
||||
osSyncPrintf("mainproc 実行終了\n"); // "End of execution"
|
||||
PRINTF("mainproc 実行終了\n"); // "End of execution"
|
||||
}
|
||||
|
|
|
@ -88,11 +88,11 @@ s32 Mempak_FindFiles(s32 controllerNum, char start, char end) {
|
|||
}
|
||||
|
||||
bit <<= 1;
|
||||
osSyncPrintf("mempak: find '%c' (%d)\n", letter, error);
|
||||
PRINTF("mempak: find '%c' (%d)\n", letter, error);
|
||||
}
|
||||
|
||||
PadMgr_ReleaseSerialEventQueue(&gPadMgr, serialEventQueue);
|
||||
osSyncPrintf("mempak: find '%c' - '%c' %02x\n", start, end, bits);
|
||||
PRINTF("mempak: find '%c' - '%c' %02x\n", start, end, bits);
|
||||
return bits;
|
||||
}
|
||||
|
||||
|
@ -120,8 +120,8 @@ s32 Mempak_Write(s32 controllerNum, char letter, void* buffer, s32 offset, s32 s
|
|||
if (error == 0) {
|
||||
ret = true;
|
||||
}
|
||||
osSyncPrintf("mempak: write %d byte '%c' (%d)->%d\n", size, letter,
|
||||
sMempakFiles[MEMPAK_LETTER_TO_INDEX(letter)], error);
|
||||
PRINTF("mempak: write %d byte '%c' (%d)->%d\n", size, letter, sMempakFiles[MEMPAK_LETTER_TO_INDEX(letter)],
|
||||
error);
|
||||
}
|
||||
PadMgr_ReleaseSerialEventQueue(&gPadMgr, serialEventQueue);
|
||||
return ret;
|
||||
|
@ -151,8 +151,8 @@ s32 Mempak_Read(s32 controllerNum, char letter, void* buffer, s32 offset, s32 si
|
|||
if (error == 0) {
|
||||
ret = true;
|
||||
}
|
||||
osSyncPrintf("mempak: read %d byte '%c' (%d)<-%d\n", size, letter, sMempakFiles[MEMPAK_LETTER_TO_INDEX(letter)],
|
||||
error);
|
||||
PRINTF("mempak: read %d byte '%c' (%d)<-%d\n", size, letter, sMempakFiles[MEMPAK_LETTER_TO_INDEX(letter)],
|
||||
error);
|
||||
}
|
||||
PadMgr_ReleaseSerialEventQueue(&gPadMgr, serialEventQueue);
|
||||
return ret;
|
||||
|
@ -190,7 +190,7 @@ s32 Mempak_CreateFile(s32 controllerNum, char* letter, s32 size) {
|
|||
if (error == 0) {
|
||||
ret = true;
|
||||
}
|
||||
osSyncPrintf("mempak: alloc %d byte '%c' (%d)\n", size, *letter, error);
|
||||
PRINTF("mempak: alloc %d byte '%c' (%d)\n", size, *letter, error);
|
||||
} else {
|
||||
// File already exists, delete then alloc
|
||||
|
||||
|
@ -204,7 +204,7 @@ s32 Mempak_CreateFile(s32 controllerNum, char* letter, s32 size) {
|
|||
if (error == 0) {
|
||||
ret |= true;
|
||||
}
|
||||
osSyncPrintf("mempak: resize %d byte '%c' (%d)\n", size, *letter, error);
|
||||
PRINTF("mempak: resize %d byte '%c' (%d)\n", size, *letter, error);
|
||||
}
|
||||
} else {
|
||||
// Find first free letter and create a file identified by it
|
||||
|
@ -218,7 +218,7 @@ s32 Mempak_CreateFile(s32 controllerNum, char* letter, s32 size) {
|
|||
sMempakExtName[0] = NCH(*letter);
|
||||
error = osPfsAllocateFile(&sMempakPfsHandle, sMempakCompanyCode, sMempakGameCode, sMempakGameName,
|
||||
sMempakExtName, size, &sMempakFiles[i]);
|
||||
osSyncPrintf("mempak: alloc %d byte '%c' (%d) with search\n", size, *letter, error);
|
||||
PRINTF("mempak: alloc %d byte '%c' (%d) with search\n", size, *letter, error);
|
||||
if (error == 0) {
|
||||
ret = true;
|
||||
}
|
||||
|
@ -246,7 +246,7 @@ s32 Mempak_DeleteFile(s32 controllerNum, char letter) {
|
|||
if (error == 0) {
|
||||
ret = true;
|
||||
}
|
||||
osSyncPrintf("mempak: delete '%c' (%d)\n", letter, error);
|
||||
PRINTF("mempak: delete '%c' (%d)\n", letter, error);
|
||||
|
||||
PadMgr_ReleaseSerialEventQueue(&gPadMgr, serialEventQueue);
|
||||
return ret;
|
||||
|
|
|
@ -31,13 +31,13 @@
|
|||
#include "global.h"
|
||||
#include "terminal.h"
|
||||
|
||||
#define PADMGR_LOG(controllerNum, msg) \
|
||||
if (1) { \
|
||||
osSyncPrintf(VT_FGCOL(YELLOW)); \
|
||||
/* padmgr: Controller %d: %s */ \
|
||||
osSyncPrintf("padmgr: %dコン: %s\n", (controllerNum) + 1, (msg)); \
|
||||
osSyncPrintf(VT_RST); \
|
||||
} \
|
||||
#define PADMGR_LOG(controllerNum, msg) \
|
||||
if (1) { \
|
||||
PRINTF(VT_FGCOL(YELLOW)); \
|
||||
/* padmgr: Controller %d: %s */ \
|
||||
PRINTF("padmgr: %dコン: %s\n", (controllerNum) + 1, (msg)); \
|
||||
PRINTF(VT_RST); \
|
||||
} \
|
||||
(void)0
|
||||
|
||||
#define LOG_SEVERITY_NOLOG 0
|
||||
|
@ -70,16 +70,16 @@ OSMesgQueue* PadMgr_AcquireSerialEventQueue(PadMgr* padMgr) {
|
|||
|
||||
if (gPadMgrLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
// "serialMsgQ Waiting for lock"
|
||||
osSyncPrintf("%2d %d serialMsgQロック待ち %08x %08x %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), padMgr, &padMgr->serialLockQueue, &serialEventQueue);
|
||||
PRINTF("%2d %d serialMsgQロック待ち %08x %08x %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), padMgr, &padMgr->serialLockQueue, &serialEventQueue);
|
||||
}
|
||||
|
||||
osRecvMesg(&padMgr->serialLockQueue, (OSMesg*)&serialEventQueue, OS_MESG_BLOCK);
|
||||
|
||||
if (gPadMgrLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
// "serialMsgQ Locked"
|
||||
osSyncPrintf("%2d %d serialMsgQをロックしました %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), serialEventQueue);
|
||||
PRINTF("%2d %d serialMsgQをロックしました %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), serialEventQueue);
|
||||
}
|
||||
|
||||
return serialEventQueue;
|
||||
|
@ -95,16 +95,16 @@ OSMesgQueue* PadMgr_AcquireSerialEventQueue(PadMgr* padMgr) {
|
|||
void PadMgr_ReleaseSerialEventQueue(PadMgr* padMgr, OSMesgQueue* serialEventQueue) {
|
||||
if (gPadMgrLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
// "serialMsgQ Unlock"
|
||||
osSyncPrintf("%2d %d serialMsgQロック解除します %08x %08x %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), padMgr, &padMgr->serialLockQueue, serialEventQueue);
|
||||
PRINTF("%2d %d serialMsgQロック解除します %08x %08x %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), padMgr, &padMgr->serialLockQueue, serialEventQueue);
|
||||
}
|
||||
|
||||
osSendMesg(&padMgr->serialLockQueue, (OSMesg)serialEventQueue, OS_MESG_BLOCK);
|
||||
|
||||
if (gPadMgrLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
// "serialMsgQ Unlocked"
|
||||
osSyncPrintf("%2d %d serialMsgQロック解除しました %08x %08x %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), padMgr, &padMgr->serialLockQueue, serialEventQueue);
|
||||
PRINTF("%2d %d serialMsgQロック解除しました %08x %08x %08x\n", osGetThreadId(NULL),
|
||||
MQ_GET_COUNT(&padMgr->serialLockQueue), padMgr, &padMgr->serialLockQueue, serialEventQueue);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -393,7 +393,7 @@ void PadMgr_HandleRetrace(PadMgr* padMgr) {
|
|||
} else {
|
||||
LOG_HEX("this->pad_status[i].type", padMgr->padStatus[i].type, "../padmgr.c", 458);
|
||||
// "An unknown type of controller is connected"
|
||||
osSyncPrintf("知らない種類のコントローラが接続されています\n");
|
||||
PRINTF("知らない種類のコントローラが接続されています\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -417,7 +417,7 @@ void PadMgr_HandleRetrace(PadMgr* padMgr) {
|
|||
}
|
||||
|
||||
void PadMgr_HandlePreNMI(PadMgr* padMgr) {
|
||||
osSyncPrintf("padmgr_HandlePreNMI()\n");
|
||||
PRINTF("padmgr_HandlePreNMI()\n");
|
||||
padMgr->isResetting = true;
|
||||
PadMgr_RumbleReset(padMgr);
|
||||
}
|
||||
|
@ -467,13 +467,13 @@ void PadMgr_ThreadEntry(PadMgr* padMgr) {
|
|||
s16* msg = NULL;
|
||||
s32 exit;
|
||||
|
||||
osSyncPrintf("コントローラスレッド実行開始\n"); // "Controller thread execution start"
|
||||
PRINTF("コントローラスレッド実行開始\n"); // "Controller thread execution start"
|
||||
|
||||
exit = false;
|
||||
while (!exit) {
|
||||
if (gPadMgrLogSeverity >= LOG_SEVERITY_VERBOSE && MQ_IS_EMPTY(&padMgr->interruptQueue)) {
|
||||
// "Waiting for controller thread event"
|
||||
osSyncPrintf("コントローラスレッドイベント待ち %lld\n", OS_CYCLES_TO_USEC(osGetTime()));
|
||||
PRINTF("コントローラスレッドイベント待ち %lld\n", OS_CYCLES_TO_USEC(osGetTime()));
|
||||
}
|
||||
|
||||
osRecvMesg(&padMgr->interruptQueue, (OSMesg*)&msg, OS_MESG_BLOCK);
|
||||
|
@ -482,13 +482,13 @@ void PadMgr_ThreadEntry(PadMgr* padMgr) {
|
|||
switch (*msg) {
|
||||
case OS_SC_RETRACE_MSG:
|
||||
if (gPadMgrLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
osSyncPrintf("padmgr_HandleRetraceMsg START %lld\n", OS_CYCLES_TO_USEC(osGetTime()));
|
||||
PRINTF("padmgr_HandleRetraceMsg START %lld\n", OS_CYCLES_TO_USEC(osGetTime()));
|
||||
}
|
||||
|
||||
PadMgr_HandleRetrace(padMgr);
|
||||
|
||||
if (gPadMgrLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
osSyncPrintf("padmgr_HandleRetraceMsg END %lld\n", OS_CYCLES_TO_USEC(osGetTime()));
|
||||
PRINTF("padmgr_HandleRetraceMsg END %lld\n", OS_CYCLES_TO_USEC(osGetTime()));
|
||||
}
|
||||
break;
|
||||
case OS_SC_PRE_NMI_MSG:
|
||||
|
@ -502,11 +502,11 @@ void PadMgr_ThreadEntry(PadMgr* padMgr) {
|
|||
|
||||
IrqMgr_RemoveClient(padMgr->irqMgr, &padMgr->irqClient);
|
||||
|
||||
osSyncPrintf("コントローラスレッド実行終了\n"); // "Controller thread execution end"
|
||||
PRINTF("コントローラスレッド実行終了\n"); // "Controller thread execution end"
|
||||
}
|
||||
|
||||
void PadMgr_Init(PadMgr* padMgr, OSMesgQueue* serialEventQueue, IrqMgr* irqMgr, OSId id, OSPri priority, void* stack) {
|
||||
osSyncPrintf("パッドマネージャ作成 padmgr_Create()\n"); // "Pad Manager creation"
|
||||
PRINTF("パッドマネージャ作成 padmgr_Create()\n"); // "Pad Manager creation"
|
||||
|
||||
bzero(padMgr, sizeof(PadMgr));
|
||||
padMgr->irqMgr = irqMgr;
|
||||
|
|
|
@ -2,17 +2,17 @@
|
|||
|
||||
#define printSpStatus(x, name) \
|
||||
if (x & SP_STATUS_##name) \
|
||||
osSyncPrintf(#name " ")
|
||||
PRINTF(#name " ")
|
||||
|
||||
#define printDpStatus(x, name) \
|
||||
if (x & DPC_STATUS_##name) \
|
||||
osSyncPrintf(#name " ")
|
||||
PRINTF(#name " ")
|
||||
|
||||
void RcpUtils_PrintRegisterStatus(void) {
|
||||
u32 spStatus = __osSpGetStatus();
|
||||
u32 dpStatus = osDpGetStatus();
|
||||
|
||||
osSyncPrintf("osSpGetStatus=%08x: ", spStatus);
|
||||
PRINTF("osSpGetStatus=%08x: ", spStatus);
|
||||
printSpStatus(spStatus, HALT);
|
||||
printSpStatus(spStatus, BROKE);
|
||||
printSpStatus(spStatus, DMA_BUSY);
|
||||
|
@ -28,9 +28,9 @@ void RcpUtils_PrintRegisterStatus(void) {
|
|||
printSpStatus(spStatus, SIG5);
|
||||
printSpStatus(spStatus, SIG6);
|
||||
printSpStatus(spStatus, SIG7);
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
|
||||
osSyncPrintf("osDpGetStatus=%08x:", dpStatus);
|
||||
PRINTF("osDpGetStatus=%08x:", dpStatus);
|
||||
printDpStatus(dpStatus, XBUS_DMEM_DMA);
|
||||
printDpStatus(dpStatus, FREEZE);
|
||||
printDpStatus(dpStatus, FLUSH);
|
||||
|
@ -42,7 +42,7 @@ void RcpUtils_PrintRegisterStatus(void) {
|
|||
printDpStatus(dpStatus, DMA_BUSY);
|
||||
printDpStatus(dpStatus, END_VALID);
|
||||
printDpStatus(dpStatus, START_VALID);
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
}
|
||||
|
||||
void RcpUtils_Reset(void) {
|
||||
|
|
|
@ -68,9 +68,9 @@ void Overlay_Relocate(void* allocatedRamAddress, OverlayRelocationSection* ovlRe
|
|||
relocatedAddress = 0;
|
||||
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
osSyncPrintf("DoRelocation(%08x, %08x, %08x)\n", allocatedRamAddress, ovlRelocs, vramStart);
|
||||
osSyncPrintf("text=%08x, data=%08x, rodata=%08x, bss=%08x\n", ovlRelocs->textSize, ovlRelocs->dataSize,
|
||||
ovlRelocs->rodataSize, ovlRelocs->bssSize);
|
||||
PRINTF("DoRelocation(%08x, %08x, %08x)\n", allocatedRamAddress, ovlRelocs, vramStart);
|
||||
PRINTF("text=%08x, data=%08x, rodata=%08x, bss=%08x\n", ovlRelocs->textSize, ovlRelocs->dataSize,
|
||||
ovlRelocs->rodataSize, ovlRelocs->bssSize);
|
||||
}
|
||||
|
||||
sections[RELOC_SECTION_NULL] = 0;
|
||||
|
@ -157,9 +157,9 @@ void Overlay_Relocate(void* allocatedRamAddress, OverlayRelocationSection* ovlRe
|
|||
FALLTHROUGH;
|
||||
case R_MIPS_LO16 << RELOC_TYPE_SHIFT:
|
||||
if (gOverlayLogSeverity >= 3) {
|
||||
osSyncPrintf("%02d %08x %08x %08x ", dbg, relocDataP, relocatedValue, relocatedAddress);
|
||||
osSyncPrintf(" %08x %08x %08x %08x\n", (uintptr_t)relocDataP + (uintptr_t)vramStart - allocu32,
|
||||
relocData, unrelocatedAddress, relocOffset);
|
||||
PRINTF("%02d %08x %08x %08x ", dbg, relocDataP, relocatedValue, relocatedAddress);
|
||||
PRINTF(" %08x %08x %08x %08x\n", (uintptr_t)relocDataP + (uintptr_t)vramStart - allocu32, relocData,
|
||||
unrelocatedAddress, relocOffset);
|
||||
}
|
||||
// Adding a break prevents matching
|
||||
}
|
||||
|
|
|
@ -66,8 +66,8 @@ void Sched_SwapFrameBufferImpl(CfbInfo* cfbInfo) {
|
|||
cfbInfo->updateTimer = cfbInfo->updateRate;
|
||||
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("osViSwapBuffer %08x %08x %08x\n", osViGetCurrentFramebuffer(), osViGetNextFramebuffer(),
|
||||
(cfbInfo != NULL) ? cfbInfo->swapBuffer : NULL);
|
||||
PRINTF("osViSwapBuffer %08x %08x %08x\n", osViGetCurrentFramebuffer(), osViGetNextFramebuffer(),
|
||||
(cfbInfo != NULL) ? cfbInfo->swapBuffer : NULL);
|
||||
}
|
||||
|
||||
width = (cfbInfo->viMode != NULL) ? cfbInfo->viMode->comRegs.width : (u32)gScreenWidth;
|
||||
|
@ -163,7 +163,7 @@ void Sched_QueueTask(Scheduler* sc, OSScTask* task) {
|
|||
if (type == M_AUDTASK) {
|
||||
if (sLogScheduler) {
|
||||
// "You have entered an audio task"
|
||||
osSyncPrintf("オーディオタスクをエントリしました\n");
|
||||
PRINTF("オーディオタスクをエントリしました\n");
|
||||
}
|
||||
// Add to audio queue
|
||||
if (sc->audioListTail != NULL) {
|
||||
|
@ -178,7 +178,7 @@ void Sched_QueueTask(Scheduler* sc, OSScTask* task) {
|
|||
} else {
|
||||
if (sLogScheduler) {
|
||||
// "Entered graph task"
|
||||
osSyncPrintf("グラフタスクをエントリしました\n");
|
||||
PRINTF("グラフタスクをエントリしました\n");
|
||||
}
|
||||
// Add to graphics queue
|
||||
if (sc->gfxListTail != NULL) {
|
||||
|
@ -203,7 +203,7 @@ void Sched_Yield(Scheduler* sc) {
|
|||
osSpTaskYield();
|
||||
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("%08d:osSpTaskYield\n", (u32)(OS_CYCLES_TO_USEC(osGetTime())));
|
||||
PRINTF("%08d:osSpTaskYield\n", (u32)(OS_CYCLES_TO_USEC(osGetTime())));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -406,7 +406,7 @@ void Sched_RunTask(Scheduler* sc, OSScTask* spTask, OSScTask* dpTask) {
|
|||
osSpTaskStartGo(&spTask->list);
|
||||
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf(
|
||||
PRINTF(
|
||||
"%08d:osSpTaskStartGo(%08x) %s\n", (u32)OS_CYCLES_TO_USEC(osGetTime()), &spTask->list,
|
||||
(spTask->list.t.type == M_AUDTASK ? "AUDIO" : (spTask->list.t.type == M_GFXTASK ? "GRAPH" : "OTHER")));
|
||||
}
|
||||
|
@ -443,7 +443,7 @@ void Sched_HandleNotification(Scheduler* sc) {
|
|||
// be ran as soon as possible.
|
||||
if (sc->doAudio && sc->curRSPTask != NULL) {
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("[YIELD B]");
|
||||
PRINTF("[YIELD B]");
|
||||
}
|
||||
Sched_Yield(sc);
|
||||
return;
|
||||
|
@ -455,13 +455,13 @@ void Sched_HandleNotification(Scheduler* sc) {
|
|||
Sched_RunTask(sc, nextRSP, nextRDP);
|
||||
}
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("EN sc:%08x sp:%08x dp:%08x state:%x\n", sc, nextRSP, nextRDP, state);
|
||||
PRINTF("EN sc:%08x sp:%08x dp:%08x state:%x\n", sc, nextRSP, nextRDP, state);
|
||||
}
|
||||
}
|
||||
|
||||
void Sched_HandleRetrace(Scheduler* sc) {
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("%08d:scHandleRetrace %08x\n", (u32)OS_CYCLES_TO_USEC(osGetTime()), osViGetCurrentFramebuffer());
|
||||
PRINTF("%08d:scHandleRetrace %08x\n", (u32)OS_CYCLES_TO_USEC(osGetTime()), osViGetCurrentFramebuffer());
|
||||
}
|
||||
ViConfig_UpdateBlack();
|
||||
sc->retraceCount++;
|
||||
|
@ -491,9 +491,9 @@ void Sched_HandleRetrace(Scheduler* sc) {
|
|||
}
|
||||
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("%08x %08x %08x %d\n", osViGetCurrentFramebuffer(), osViGetNextFramebuffer(),
|
||||
(sc->pendingSwapBuf1 != NULL) ? sc->pendingSwapBuf1->swapBuffer : NULL,
|
||||
(sc->curBuf != NULL) ? sc->curBuf->updateTimer : 0);
|
||||
PRINTF("%08x %08x %08x %d\n", osViGetCurrentFramebuffer(), osViGetNextFramebuffer(),
|
||||
(sc->pendingSwapBuf1 != NULL) ? sc->pendingSwapBuf1->swapBuffer : NULL,
|
||||
(sc->curBuf != NULL) ? sc->curBuf->updateTimer : 0);
|
||||
}
|
||||
|
||||
// Run the notification handler to enqueue any waiting tasks and possibly run one
|
||||
|
@ -525,12 +525,12 @@ void Sched_HandleRSPDone(Scheduler* sc) {
|
|||
sc->curRSPTask = NULL;
|
||||
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("RSP DONE %d %d", curRSPTask->state & OS_SC_YIELD, osSpTaskYielded(&curRSPTask->list));
|
||||
PRINTF("RSP DONE %d %d", curRSPTask->state & OS_SC_YIELD, osSpTaskYielded(&curRSPTask->list));
|
||||
}
|
||||
|
||||
if ((curRSPTask->state & OS_SC_YIELD) && osSpTaskYielded(&curRSPTask->list)) {
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("[YIELDED]\n");
|
||||
PRINTF("[YIELDED]\n");
|
||||
}
|
||||
// Task yielded, set yielded state
|
||||
curRSPTask->state |= OS_SC_YIELDED;
|
||||
|
@ -542,7 +542,7 @@ void Sched_HandleRSPDone(Scheduler* sc) {
|
|||
}
|
||||
} else {
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("[NOT YIELDED]\n");
|
||||
PRINTF("[NOT YIELDED]\n");
|
||||
}
|
||||
// Task has completed on the RSP, unset RSP flag and check if the task is fully complete
|
||||
curRSPTask->state &= ~OS_SC_SP;
|
||||
|
@ -555,7 +555,7 @@ void Sched_HandleRSPDone(Scheduler* sc) {
|
|||
Sched_RunTask(sc, nextRSP, nextRDP);
|
||||
}
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("SP sc:%08x sp:%08x dp:%08x state:%x\n", sc, nextRSP, nextRDP, state);
|
||||
PRINTF("SP sc:%08x sp:%08x dp:%08x state:%x\n", sc, nextRSP, nextRDP, state);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -589,7 +589,7 @@ void Sched_HandleRDPDone(Scheduler* sc) {
|
|||
Sched_RunTask(sc, nextRSP, nextRDP);
|
||||
}
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("DP sc:%08x sp:%08x dp:%08x state:%x\n", sc, nextRSP, nextRDP, state);
|
||||
PRINTF("DP sc:%08x sp:%08x dp:%08x state:%x\n", sc, nextRSP, nextRDP, state);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -602,7 +602,7 @@ void Sched_HandleRDPDone(Scheduler* sc) {
|
|||
*/
|
||||
void Sched_Notify(Scheduler* sc) {
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("osScKickEntryMsg\n");
|
||||
PRINTF("osScKickEntryMsg\n");
|
||||
}
|
||||
|
||||
osSendMesg(&sc->interruptQueue, (OSMesg)NOTIFY_MSG, OS_MESG_BLOCK);
|
||||
|
@ -615,7 +615,7 @@ void Sched_ThreadEntry(void* arg) {
|
|||
while (true) {
|
||||
if (sLogScheduler) {
|
||||
// "%08d: standby"
|
||||
osSyncPrintf("%08d:待機中\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
PRINTF("%08d:待機中\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
}
|
||||
|
||||
// Await interrupt messages, either from the OS, IrqMgr, or another thread
|
||||
|
@ -624,19 +624,19 @@ void Sched_ThreadEntry(void* arg) {
|
|||
switch ((s32)msg) {
|
||||
case NOTIFY_MSG:
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("%08d:ENTRY_MSG\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
PRINTF("%08d:ENTRY_MSG\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
}
|
||||
Sched_HandleNotification(sc);
|
||||
continue;
|
||||
case RSP_DONE_MSG:
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("%08d:RSP_DONE_MSG\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
PRINTF("%08d:RSP_DONE_MSG\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
}
|
||||
Sched_HandleRSPDone(sc);
|
||||
continue;
|
||||
case RDP_DONE_MSG:
|
||||
if (sLogScheduler) {
|
||||
osSyncPrintf("%08d:RDP_DONE_MSG\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
PRINTF("%08d:RDP_DONE_MSG\n", (u32)OS_CYCLES_TO_USEC(osGetTime()));
|
||||
}
|
||||
Sched_HandleRDPDone(sc);
|
||||
continue;
|
||||
|
|
|
@ -13,7 +13,7 @@ s32 sLetterboxSize = 0;
|
|||
|
||||
void Letterbox_SetSizeTarget(s32 target) {
|
||||
if (R_HREG_MODE == HREG_MODE_LETTERBOX && R_LETTERBOX_ENABLE_LOGS == 1) {
|
||||
osSyncPrintf("shrink_window_setval(%d)\n", target);
|
||||
PRINTF("shrink_window_setval(%d)\n", target);
|
||||
}
|
||||
|
||||
sLetterboxSizeTarget = target;
|
||||
|
@ -25,7 +25,7 @@ u32 Letterbox_GetSizeTarget(void) {
|
|||
|
||||
void Letterbox_SetSize(s32 size) {
|
||||
if (R_HREG_MODE == HREG_MODE_LETTERBOX && R_LETTERBOX_ENABLE_LOGS == 1) {
|
||||
osSyncPrintf("shrink_window_setnowval(%d)\n", size);
|
||||
PRINTF("shrink_window_setnowval(%d)\n", size);
|
||||
}
|
||||
|
||||
sLetterboxSize = size;
|
||||
|
@ -37,7 +37,7 @@ u32 Letterbox_GetSize(void) {
|
|||
|
||||
void Letterbox_Init(void) {
|
||||
if (R_HREG_MODE == HREG_MODE_LETTERBOX && R_LETTERBOX_ENABLE_LOGS == 1) {
|
||||
osSyncPrintf("shrink_window_init()\n");
|
||||
PRINTF("shrink_window_init()\n");
|
||||
}
|
||||
|
||||
sLetterboxState = LETTERBOX_STATE_IDLE;
|
||||
|
@ -47,7 +47,7 @@ void Letterbox_Init(void) {
|
|||
|
||||
void Letterbox_Destroy(void) {
|
||||
if (R_HREG_MODE == HREG_MODE_LETTERBOX && R_LETTERBOX_ENABLE_LOGS == 1) {
|
||||
osSyncPrintf("shrink_window_cleanup()\n");
|
||||
PRINTF("shrink_window_cleanup()\n");
|
||||
}
|
||||
|
||||
sLetterboxSize = 0;
|
||||
|
|
|
@ -182,9 +182,9 @@ void SpeedMeter_DrawAllocEntry(SpeedMeterAllocEntry* this, GraphicsContext* gfxC
|
|||
Gfx* gfx;
|
||||
|
||||
if (this->maxval == 0) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
LOG_NUM("this->maxval", this->maxval, "../speed_meter.c", 313);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
} else {
|
||||
OPEN_DISPS(gfxCtx, "../speed_meter.c", 318);
|
||||
|
||||
|
|
|
@ -9,18 +9,18 @@ void SysCfb_Init(s32 n64dd) {
|
|||
|
||||
if (osMemSize >= 0x800000) {
|
||||
// "8MB or more memory is installed"
|
||||
osSyncPrintf("8Mバイト以上のメモリが搭載されています\n");
|
||||
PRINTF("8Mバイト以上のメモリが搭載されています\n");
|
||||
tmpFbEnd = 0x8044BE80;
|
||||
if (n64dd == 1) {
|
||||
osSyncPrintf("RAM 8M mode (N64DD対応)\n"); // "RAM 8M mode (N64DD compatible)"
|
||||
PRINTF("RAM 8M mode (N64DD対応)\n"); // "RAM 8M mode (N64DD compatible)"
|
||||
sSysCfbEnd = 0x805FB000;
|
||||
} else {
|
||||
// "The margin for this version is %dK bytes"
|
||||
osSyncPrintf("このバージョンのマージンは %dK バイトです\n", (0x4BC00 / 1024));
|
||||
PRINTF("このバージョンのマージンは %dK バイトです\n", (0x4BC00 / 1024));
|
||||
sSysCfbEnd = tmpFbEnd;
|
||||
}
|
||||
} else if (osMemSize >= 0x400000) {
|
||||
osSyncPrintf("RAM4M mode\n");
|
||||
PRINTF("RAM4M mode\n");
|
||||
sSysCfbEnd = 0x80400000;
|
||||
} else {
|
||||
LogUtils_HungupThread("../sys_cfb.c", 354);
|
||||
|
@ -29,11 +29,11 @@ void SysCfb_Init(s32 n64dd) {
|
|||
screenSize = SCREEN_WIDTH * SCREEN_HEIGHT;
|
||||
sSysCfbEnd &= ~0x3F;
|
||||
// "The final address used by the system is %08x"
|
||||
osSyncPrintf("システムが使用する最終アドレスは %08x です\n", sSysCfbEnd);
|
||||
PRINTF("システムが使用する最終アドレスは %08x です\n", sSysCfbEnd);
|
||||
sSysCfbFbPtr[0] = sSysCfbEnd - (screenSize * 4);
|
||||
sSysCfbFbPtr[1] = sSysCfbEnd - (screenSize * 2);
|
||||
// "Frame buffer addresses are %08x and %08x"
|
||||
osSyncPrintf("フレームバッファのアドレスは %08x と %08x です\n", sSysCfbFbPtr[0], sSysCfbFbPtr[1]);
|
||||
PRINTF("フレームバッファのアドレスは %08x と %08x です\n", sSysCfbFbPtr[0], sSysCfbFbPtr[1]);
|
||||
}
|
||||
|
||||
void SysCfb_Reset(void) {
|
||||
|
|
|
@ -120,11 +120,11 @@ void Math3D_LineClosestToPoint(InfiniteLine* line, Vec3f* pos, Vec3f* closestPoi
|
|||
|
||||
dirVectorLengthSq = Math3D_Vec3fMagnitudeSq(&line->dir);
|
||||
if (IS_ZERO(dirVectorLengthSq)) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK));
|
||||
PRINTF(VT_COL(YELLOW, BLACK));
|
||||
// "Math3D_lineVsPosSuisenCross(): No straight line length"
|
||||
osSyncPrintf("Math3D_lineVsPosSuisenCross():直線の長さがありません\n");
|
||||
osSyncPrintf("cross = pos を返します。\n"); // "Returns cross = pos."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Math3D_lineVsPosSuisenCross():直線の長さがありません\n");
|
||||
PRINTF("cross = pos を返します。\n"); // "Returns cross = pos."
|
||||
PRINTF(VT_RST);
|
||||
Math_Vec3f_Copy(closestPoint, pos);
|
||||
//! @bug Missing early return
|
||||
}
|
||||
|
@ -924,10 +924,10 @@ f32 Math3D_Plane(Plane* plane, Vec3f* pointOnPlane) {
|
|||
f32 Math3D_UDistPlaneToPos(f32 nx, f32 ny, f32 nz, f32 originDist, Vec3f* p) {
|
||||
|
||||
if (IS_ZERO(sqrtf(SQ(nx) + SQ(ny) + SQ(nz)))) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK));
|
||||
PRINTF(VT_COL(YELLOW, BLACK));
|
||||
// "Math3DLengthPlaneAndPos(): Normal size is near zero %f %f %f"
|
||||
osSyncPrintf("Math3DLengthPlaneAndPos():法線size がゼロ近いです%f %f %f\n", nx, ny, nz);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Math3DLengthPlaneAndPos():法線size がゼロ近いです%f %f %f\n", nx, ny, nz);
|
||||
PRINTF(VT_RST);
|
||||
return 0.0f;
|
||||
}
|
||||
return fabsf(Math3D_DistPlaneToPos(nx, ny, nz, originDist, p));
|
||||
|
@ -942,10 +942,10 @@ f32 Math3D_DistPlaneToPos(f32 nx, f32 ny, f32 nz, f32 originDist, Vec3f* p) {
|
|||
|
||||
normMagnitude = sqrtf(SQ(nx) + SQ(ny) + SQ(nz));
|
||||
if (IS_ZERO(normMagnitude)) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK));
|
||||
PRINTF(VT_COL(YELLOW, BLACK));
|
||||
// "Math3DSignedLengthPlaneAndPos(): Normal size is close to zero %f %f %f"
|
||||
osSyncPrintf("Math3DSignedLengthPlaneAndPos():法線size がゼロ近いです%f %f %f\n", nx, ny, nz);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Math3DSignedLengthPlaneAndPos():法線size がゼロ近いです%f %f %f\n", nx, ny, nz);
|
||||
PRINTF(VT_RST);
|
||||
return 0.0f;
|
||||
}
|
||||
return Math3D_Planef(nx, ny, nz, originDist, p) / normMagnitude;
|
||||
|
|
|
@ -975,13 +975,13 @@ MtxF* Matrix_CheckFloats(MtxF* mf, char* file, s32 line) {
|
|||
for (i = 0; i < 4; i++) {
|
||||
for (j = 0; j < 4; j++) {
|
||||
if (!(-32768.0f <= mf->mf[i][j]) || !(mf->mf[i][j] < 32768.0f)) {
|
||||
osSyncPrintf("%s %d: [%s] =\n"
|
||||
"/ %12.6f %12.6f %12.6f %12.6f \\\n"
|
||||
"| %12.6f %12.6f %12.6f %12.6f |\n"
|
||||
"| %12.6f %12.6f %12.6f %12.6f |\n"
|
||||
"\\ %12.6f %12.6f %12.6f %12.6f /\n",
|
||||
file, line, "mf", mf->xx, mf->xy, mf->xz, mf->xw, mf->yx, mf->yy, mf->yz, mf->yw, mf->zx,
|
||||
mf->zy, mf->zz, mf->zw, mf->wx, mf->wy, mf->wz, mf->ww);
|
||||
PRINTF("%s %d: [%s] =\n"
|
||||
"/ %12.6f %12.6f %12.6f %12.6f \\\n"
|
||||
"| %12.6f %12.6f %12.6f %12.6f |\n"
|
||||
"| %12.6f %12.6f %12.6f %12.6f |\n"
|
||||
"\\ %12.6f %12.6f %12.6f %12.6f /\n",
|
||||
file, line, "mf", mf->xx, mf->xy, mf->xz, mf->xw, mf->yx, mf->yy, mf->yz, mf->yw, mf->zx, mf->zy,
|
||||
mf->zz, mf->zw, mf->wx, mf->wy, mf->wz, mf->ww);
|
||||
Fault_AddHungupAndCrash(file, line);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -11,13 +11,13 @@ void SystemArena_CheckPointer(void* ptr, u32 size, const char* name, const char*
|
|||
if (ptr == NULL) {
|
||||
if (gSystemArenaLogSeverity >= LOG_SEVERITY_ERROR) {
|
||||
// "%s: %u bytes %s failed\n"
|
||||
osSyncPrintf("%s: %u バイトの%sに失敗しました\n", name, size, action);
|
||||
PRINTF("%s: %u バイトの%sに失敗しました\n", name, size, action);
|
||||
__osDisplayArena(&gSystemArena);
|
||||
return;
|
||||
}
|
||||
} else if (gSystemArenaLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
// "%s: %u bytes %s succeeded\n"
|
||||
osSyncPrintf("%s: %u バイトの%sに成功しました\n", name, size, action);
|
||||
PRINTF("%s: %u バイトの%sに成功しました\n", name, size, action);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -83,7 +83,7 @@ void* SystemArena_Calloc(u32 num, u32 size) {
|
|||
}
|
||||
|
||||
void SystemArena_Display(void) {
|
||||
osSyncPrintf("システムヒープ表示\n"); // "System heap display"
|
||||
PRINTF("システムヒープ表示\n"); // "System heap display"
|
||||
__osDisplayArena(&gSystemArena);
|
||||
}
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
#include "global.h"
|
||||
|
||||
void Setup_InitImpl(SetupState* this) {
|
||||
osSyncPrintf("ゼルダ共通データ初期化\n"); // "Zelda common data initalization"
|
||||
PRINTF("ゼルダ共通データ初期化\n"); // "Zelda common data initalization"
|
||||
SaveContext_Init();
|
||||
this->state.running = false;
|
||||
SET_NEXT_GAMESTATE(&this->state, ConsoleLogo_Init, ConsoleLogoState);
|
||||
|
|
|
@ -46,7 +46,7 @@ typedef void (*UcodeDisasCallback)(UCodeDisas*, u32);
|
|||
|
||||
#define DISAS_LOG \
|
||||
if (this->enableLog) \
|
||||
osSyncPrintf
|
||||
PRINTF
|
||||
|
||||
void* UCodeDisas_TranslateAddr(UCodeDisas* this, uintptr_t addr) {
|
||||
uintptr_t physical = this->segments[SEGMENT_NUMBER(addr)] + SEGMENT_OFFSET(addr);
|
||||
|
@ -283,14 +283,14 @@ void UCodeDisas_PrintRenderMode(UCodeDisas* this, u32 mode) {
|
|||
b = (mode >> 16) & 0x3333;
|
||||
|
||||
// clang-format off
|
||||
if (this->enableLog == 0) {} else { osSyncPrintf("\nGBL_c1(%s, %s, %s, %s)|",
|
||||
if (this->enableLog == 0) {} else { PRINTF("\nGBL_c1(%s, %s, %s, %s)|",
|
||||
sBlenderInputNames[0][a >> 12 & 3], sBlenderInputNames[1][a >> 8 & 3], sBlenderInputNames[2][a >> 4 & 3], sBlenderInputNames[3][a >> 0 & 3]);
|
||||
}
|
||||
// clang-format on
|
||||
|
||||
if (this->enableLog) {
|
||||
osSyncPrintf("\nGBL_c2(%s, %s, %s, %s)", sBlenderInputNames[0][b >> 12 & 3], sBlenderInputNames[1][b >> 8 & 3],
|
||||
sBlenderInputNames[2][b >> 4 & 3], sBlenderInputNames[3][b >> 0 & 3]);
|
||||
PRINTF("\nGBL_c2(%s, %s, %s, %s)", sBlenderInputNames[0][b >> 12 & 3], sBlenderInputNames[1][b >> 8 & 3],
|
||||
sBlenderInputNames[2][b >> 4 & 3], sBlenderInputNames[3][b >> 0 & 3]);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
void Overlay_LoadGameState(GameStateOverlay* overlayEntry) {
|
||||
if (overlayEntry->loadedRamAddr != NULL) {
|
||||
osSyncPrintf("既にリンクされています\n"); // "Already linked"
|
||||
PRINTF("既にリンクされています\n"); // "Already linked"
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -14,16 +14,16 @@ void Overlay_LoadGameState(GameStateOverlay* overlayEntry) {
|
|||
overlayEntry->vramStart, overlayEntry->vramEnd);
|
||||
|
||||
if (overlayEntry->loadedRamAddr == NULL) {
|
||||
osSyncPrintf("ロードに失敗しました\n"); // "Loading failed"
|
||||
PRINTF("ロードに失敗しました\n"); // "Loading failed"
|
||||
return;
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("OVL(d):Seg:%08x-%08x Ram:%08x-%08x Off:%08x %s\n", overlayEntry->vramStart, overlayEntry->vramEnd,
|
||||
overlayEntry->loadedRamAddr,
|
||||
(u32)overlayEntry->loadedRamAddr + (u32)overlayEntry->vramEnd - (u32)overlayEntry->vramStart,
|
||||
(u32)overlayEntry->vramStart - (u32)overlayEntry->loadedRamAddr, "");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("OVL(d):Seg:%08x-%08x Ram:%08x-%08x Off:%08x %s\n", overlayEntry->vramStart, overlayEntry->vramEnd,
|
||||
overlayEntry->loadedRamAddr,
|
||||
(u32)overlayEntry->loadedRamAddr + (u32)overlayEntry->vramEnd - (u32)overlayEntry->vramStart,
|
||||
(u32)overlayEntry->vramStart - (u32)overlayEntry->loadedRamAddr, "");
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if (overlayEntry->unk_14 != NULL) {
|
||||
overlayEntry->unk_14 = (void*)((u32)overlayEntry->unk_14 -
|
||||
|
|
|
@ -836,7 +836,7 @@ void Actor_Destroy(Actor* actor, PlayState* play) {
|
|||
name = overlayEntry->name != NULL ? overlayEntry->name : "";
|
||||
|
||||
// "No Actor class destruct [%s]"
|
||||
osSyncPrintf("Actorクラス デストラクトがありません [%s]\n" VT_RST, name);
|
||||
PRINTF("Actorクラス デストラクトがありません [%s]\n" VT_RST, name);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1369,8 +1369,8 @@ Gfx* func_8002E830(Vec3f* object, Vec3f* eye, Vec3f* lightDir, GraphicsContext*
|
|||
*hilite = GRAPH_ALLOC(gfxCtx, sizeof(Hilite));
|
||||
|
||||
if (R_HREG_MODE == HREG_MODE_PRINT_HILITE_INFO) {
|
||||
osSyncPrintf("z_actor.c 3529 eye=[%f(%f) %f %f] object=[%f %f %f] light_direction=[%f %f %f]\n", correctedEyeX,
|
||||
eye->x, eye->y, eye->z, object->x, object->y, object->z, lightDir->x, lightDir->y, lightDir->z);
|
||||
PRINTF("z_actor.c 3529 eye=[%f(%f) %f %f] object=[%f %f %f] light_direction=[%f %f %f]\n", correctedEyeX,
|
||||
eye->x, eye->y, eye->z, object->x, object->y, object->z, lightDir->x, lightDir->y, lightDir->z);
|
||||
}
|
||||
|
||||
View_ErrorCheckEyePosition(correctedEyeX, eye->y, eye->z);
|
||||
|
@ -1418,8 +1418,8 @@ void func_8002EBCC(Actor* actor, PlayState* play, s32 flag) {
|
|||
lightDir.z = play->envCtx.dirLight1.params.dir.z;
|
||||
|
||||
if (R_HREG_MODE == HREG_MODE_PRINT_HILITE_INFO) {
|
||||
osSyncPrintf("z_actor.c 3637 game_play->view.eye=[%f(%f) %f %f]\n", play->view.eye.x, play->view.eye.y,
|
||||
play->view.eye.z);
|
||||
PRINTF("z_actor.c 3637 game_play->view.eye=[%f(%f) %f %f]\n", play->view.eye.x, play->view.eye.y,
|
||||
play->view.eye.z);
|
||||
}
|
||||
|
||||
hilite = func_8002EABC(&actor->world.pos, &play->view.eye, &lightDir, play->state.gfxCtx);
|
||||
|
@ -1957,7 +1957,7 @@ void Actor_DrawFaroresWindPointer(PlayState* play) {
|
|||
length *= 0.5f;
|
||||
dx = diff - length;
|
||||
yOffset += sqrtf(SQ(length) - SQ(dx)) * 0.2f;
|
||||
osSyncPrintf("-------- DISPLAY Y=%f\n", yOffset);
|
||||
PRINTF("-------- DISPLAY Y=%f\n", yOffset);
|
||||
}
|
||||
|
||||
effectPos.x = curPos->x + Rand_CenteredFloat(6.0f);
|
||||
|
@ -2282,10 +2282,10 @@ void Actor_FaultPrint(Actor* actor, char* command) {
|
|||
overlayEntry = actor->overlayEntry;
|
||||
name = overlayEntry->name != NULL ? overlayEntry->name : "";
|
||||
|
||||
osSyncPrintf("アクターの名前(%08x:%s)\n", actor, name); // "Actor name (%08x:%s)"
|
||||
PRINTF("アクターの名前(%08x:%s)\n", actor, name); // "Actor name (%08x:%s)"
|
||||
|
||||
if (command != NULL) {
|
||||
osSyncPrintf("コメント:%s\n", command); // "Command:%s"
|
||||
PRINTF("コメント:%s\n", command); // "Command:%s"
|
||||
}
|
||||
|
||||
FaultDrawer_SetCursor(48, 24);
|
||||
|
@ -2684,7 +2684,7 @@ void func_80031C3C(ActorContext* actorCtx, PlayState* play) {
|
|||
}
|
||||
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("絶対魔法領域解放\n"); // "Absolute magic field deallocation"
|
||||
PRINTF("絶対魔法領域解放\n"); // "Absolute magic field deallocation"
|
||||
}
|
||||
|
||||
if (actorCtx->absoluteSpace != NULL) {
|
||||
|
@ -2752,27 +2752,27 @@ Actor* Actor_RemoveFromCategory(PlayState* play, ActorContext* actorCtx, Actor*
|
|||
}
|
||||
|
||||
void Actor_FreeOverlay(ActorOverlay* actorOverlay) {
|
||||
osSyncPrintf(VT_FGCOL(CYAN));
|
||||
PRINTF(VT_FGCOL(CYAN));
|
||||
|
||||
if (actorOverlay->numLoaded == 0) {
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("アクタークライアントが0になりました\n"); // "Actor client is now 0"
|
||||
PRINTF("アクタークライアントが0になりました\n"); // "Actor client is now 0"
|
||||
}
|
||||
|
||||
if (actorOverlay->loadedRamAddr != NULL) {
|
||||
if (actorOverlay->allocType & ACTOROVL_ALLOC_PERSISTENT) {
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("オーバーレイ解放しません\n"); // "Overlay will not be deallocated"
|
||||
PRINTF("オーバーレイ解放しません\n"); // "Overlay will not be deallocated"
|
||||
}
|
||||
} else if (actorOverlay->allocType & ACTOROVL_ALLOC_ABSOLUTE) {
|
||||
if (HREG(20) != 0) {
|
||||
// "Absolute magic field reserved, so deallocation will not occur"
|
||||
osSyncPrintf("絶対魔法領域確保なので解放しません\n");
|
||||
PRINTF("絶対魔法領域確保なので解放しません\n");
|
||||
}
|
||||
actorOverlay->loadedRamAddr = NULL;
|
||||
} else {
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("オーバーレイ解放します\n"); // "Overlay deallocated"
|
||||
PRINTF("オーバーレイ解放します\n"); // "Overlay deallocated"
|
||||
}
|
||||
ZELDA_ARENA_FREE(actorOverlay->loadedRamAddr, "../z_actor.c", 6834);
|
||||
actorOverlay->loadedRamAddr = NULL;
|
||||
|
@ -2780,10 +2780,10 @@ void Actor_FreeOverlay(ActorOverlay* actorOverlay) {
|
|||
}
|
||||
} else if (HREG(20) != 0) {
|
||||
// "%d of actor client remains"
|
||||
osSyncPrintf("アクタークライアントはあと %d 残っています\n", actorOverlay->numLoaded);
|
||||
PRINTF("アクタークライアントはあと %d 残っています\n", actorOverlay->numLoaded);
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 posX, f32 posY, f32 posZ, s16 rotX,
|
||||
|
@ -2805,25 +2805,25 @@ Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 pos
|
|||
|
||||
if (HREG(20) != 0) {
|
||||
// "Actor class addition [%d:%s]"
|
||||
osSyncPrintf("アクタークラス追加 [%d:%s]\n", actorId, name);
|
||||
PRINTF("アクタークラス追加 [%d:%s]\n", actorId, name);
|
||||
}
|
||||
|
||||
if (actorCtx->total > ACTOR_NUMBER_MAX) {
|
||||
// "Actor set number exceeded"
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "Actorセット数オーバー\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "Actorセット数オーバー\n" VT_RST);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (overlayEntry->vramStart == NULL) {
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("オーバーレイではありません\n"); // "Not an overlay"
|
||||
PRINTF("オーバーレイではありません\n"); // "Not an overlay"
|
||||
}
|
||||
|
||||
actorInit = overlayEntry->initInfo;
|
||||
} else {
|
||||
if (overlayEntry->loadedRamAddr != NULL) {
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("既にロードされています\n"); // "Already loaded"
|
||||
PRINTF("既にロードされています\n"); // "Already loaded"
|
||||
}
|
||||
} else {
|
||||
if (overlayEntry->allocType & ACTOROVL_ALLOC_ABSOLUTE) {
|
||||
|
@ -2835,7 +2835,7 @@ Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 pos
|
|||
actorCtx->absoluteSpace = ZELDA_ARENA_MALLOC_R(ACTOROVL_ABSOLUTE_SPACE_SIZE, "AMF:絶対魔法領域", 0);
|
||||
if (HREG(20) != 0) {
|
||||
// "Absolute magic field reservation - %d bytes reserved"
|
||||
osSyncPrintf("絶対魔法領域確保 %d バイト確保\n", ACTOROVL_ABSOLUTE_SPACE_SIZE);
|
||||
PRINTF("絶対魔法領域確保 %d バイト確保\n", ACTOROVL_ABSOLUTE_SPACE_SIZE);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2848,20 +2848,20 @@ Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 pos
|
|||
|
||||
if (overlayEntry->loadedRamAddr == NULL) {
|
||||
// "Cannot reserve actor program memory"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "Actorプログラムメモリが確保できません\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "Actorプログラムメモリが確保できません\n" VT_RST);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Overlay_Load(overlayEntry->vromStart, overlayEntry->vromEnd, overlayEntry->vramStart, overlayEntry->vramEnd,
|
||||
overlayEntry->loadedRamAddr);
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("OVL(a):Seg:%08x-%08x Ram:%08x-%08x Off:%08x %s\n", overlayEntry->vramStart,
|
||||
overlayEntry->vramEnd, overlayEntry->loadedRamAddr,
|
||||
(uintptr_t)overlayEntry->loadedRamAddr + (uintptr_t)overlayEntry->vramEnd -
|
||||
(uintptr_t)overlayEntry->vramStart,
|
||||
(uintptr_t)overlayEntry->vramStart - (uintptr_t)overlayEntry->loadedRamAddr, name);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("OVL(a):Seg:%08x-%08x Ram:%08x-%08x Off:%08x %s\n", overlayEntry->vramStart, overlayEntry->vramEnd,
|
||||
overlayEntry->loadedRamAddr,
|
||||
(uintptr_t)overlayEntry->loadedRamAddr + (uintptr_t)overlayEntry->vramEnd -
|
||||
(uintptr_t)overlayEntry->vramStart,
|
||||
(uintptr_t)overlayEntry->vramStart - (uintptr_t)overlayEntry->loadedRamAddr, name);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
overlayEntry->numLoaded = 0;
|
||||
}
|
||||
|
@ -2878,8 +2878,8 @@ Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 pos
|
|||
if ((objectSlot < 0) ||
|
||||
((actorInit->category == ACTORCAT_ENEMY) && Flags_GetClear(play, play->roomCtx.curRoom.num))) {
|
||||
// "No data bank!! <data bank=%d> (profilep->bank=%d)"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "データバンク無し!!<データバンク=%d>(profilep->bank=%d)\n" VT_RST,
|
||||
objectSlot, actorInit->objectId);
|
||||
PRINTF(VT_COL(RED, WHITE) "データバンク無し!!<データバンク=%d>(profilep->bank=%d)\n" VT_RST, objectSlot,
|
||||
actorInit->objectId);
|
||||
Actor_FreeOverlay(overlayEntry);
|
||||
return NULL;
|
||||
}
|
||||
|
@ -2888,8 +2888,8 @@ Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 pos
|
|||
|
||||
if (actor == NULL) {
|
||||
// "Actor class cannot be reserved! %s <size=%d bytes>"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "Actorクラス確保できません! %s <サイズ=%dバイト>\n", VT_RST, name,
|
||||
actorInit->instanceSize);
|
||||
PRINTF(VT_COL(RED, WHITE) "Actorクラス確保できません! %s <サイズ=%dバイト>\n", VT_RST, name,
|
||||
actorInit->instanceSize);
|
||||
Actor_FreeOverlay(overlayEntry);
|
||||
return NULL;
|
||||
}
|
||||
|
@ -2900,7 +2900,7 @@ Actor* Actor_Spawn(ActorContext* actorCtx, PlayState* play, s16 actorId, f32 pos
|
|||
|
||||
if (HREG(20) != 0) {
|
||||
// "Actor client No. %d"
|
||||
osSyncPrintf("アクタークライアントは %d 個目です\n", overlayEntry->numLoaded);
|
||||
PRINTF("アクタークライアントは %d 個目です\n", overlayEntry->numLoaded);
|
||||
}
|
||||
|
||||
Lib_MemSet((u8*)actor, actorInit->instanceSize, 0);
|
||||
|
@ -3000,7 +3000,7 @@ Actor* Actor_Delete(ActorContext* actorCtx, Actor* actor, PlayState* play) {
|
|||
name = overlayEntry->name != NULL ? overlayEntry->name : "";
|
||||
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("アクタークラス削除 [%s]\n", name); // "Actor class deleted [%s]"
|
||||
PRINTF("アクタークラス削除 [%s]\n", name); // "Actor class deleted [%s]"
|
||||
}
|
||||
|
||||
if ((player != NULL) && (actor == player->unk_664)) {
|
||||
|
@ -3029,7 +3029,7 @@ Actor* Actor_Delete(ActorContext* actorCtx, Actor* actor, PlayState* play) {
|
|||
|
||||
if (overlayEntry->vramStart == NULL) {
|
||||
if (HREG(20) != 0) {
|
||||
osSyncPrintf("オーバーレイではありません\n"); // "Not an overlay"
|
||||
PRINTF("オーバーレイではありません\n"); // "Not an overlay"
|
||||
}
|
||||
} else {
|
||||
ASSERT(overlayEntry->loadedRamAddr != NULL, "actor_dlftbl->allocp != NULL", "../z_actor.c", 7251);
|
||||
|
|
|
@ -55,13 +55,13 @@ void ActorOverlayTable_LogPrint(void) {
|
|||
ActorOverlay* overlayEntry;
|
||||
u32 i;
|
||||
|
||||
osSyncPrintf("actor_dlftbls %u\n", gMaxActorId);
|
||||
osSyncPrintf("RomStart RomEnd SegStart SegEnd allocp profile segname\n");
|
||||
PRINTF("actor_dlftbls %u\n", gMaxActorId);
|
||||
PRINTF("RomStart RomEnd SegStart SegEnd allocp profile segname\n");
|
||||
|
||||
for (i = 0, overlayEntry = &gActorOverlayTable[0]; i < (u32)gMaxActorId; i++, overlayEntry++) {
|
||||
osSyncPrintf("%08x %08x %08x %08x %08x %08x %s\n", overlayEntry->vromStart, overlayEntry->vromEnd,
|
||||
overlayEntry->vramStart, overlayEntry->vramEnd, overlayEntry->loadedRamAddr,
|
||||
&overlayEntry->initInfo->id, overlayEntry->name != NULL ? overlayEntry->name : "?");
|
||||
PRINTF("%08x %08x %08x %08x %08x %08x %s\n", overlayEntry->vromStart, overlayEntry->vromEnd,
|
||||
overlayEntry->vramStart, overlayEntry->vramEnd, overlayEntry->loadedRamAddr, &overlayEntry->initInfo->id,
|
||||
overlayEntry->name != NULL ? overlayEntry->name : "?");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -85,11 +85,11 @@ u16 sSurfaceMaterialToSfxOffset[SURFACE_MATERIAL_MAX] = {
|
|||
s32 BgCheck_PosErrorCheck(Vec3f* pos, char* file, s32 line) {
|
||||
if (pos->x >= BGCHECK_XYZ_ABSMAX || pos->x <= -BGCHECK_XYZ_ABSMAX || pos->y >= BGCHECK_XYZ_ABSMAX ||
|
||||
pos->y <= -BGCHECK_XYZ_ABSMAX || pos->z >= BGCHECK_XYZ_ABSMAX || pos->z <= -BGCHECK_XYZ_ABSMAX) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Position is invalid."
|
||||
osSyncPrintf("T_BGCheck_PosErrorCheck():位置が妥当ではありません。pos (%f,%f,%f) file:%s line:%d\n", pos->x,
|
||||
pos->y, pos->z, file, line);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("T_BGCheck_PosErrorCheck():位置が妥当ではありません。pos (%f,%f,%f) file:%s line:%d\n", pos->x, pos->y,
|
||||
pos->z, file, line);
|
||||
PRINTF(VT_RST);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
|
@ -308,11 +308,11 @@ void CollisionPoly_GetVerticesByBgId(CollisionPoly* poly, s32 bgId, CollisionCon
|
|||
Vec3s* vtxList;
|
||||
|
||||
if (poly == NULL || bgId > BG_ACTOR_MAX || dest == NULL) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE));
|
||||
PRINTF(VT_COL(RED, WHITE));
|
||||
// "Argument not appropriate. Processing terminated."
|
||||
osSyncPrintf("T_Polygon_GetVertex_bg_ai(): Error %d %d %d 引数が適切ではありません。処理を終了します。\n",
|
||||
poly == NULL, bgId > BG_ACTOR_MAX, dest == NULL);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("T_Polygon_GetVertex_bg_ai(): Error %d %d %d 引数が適切ではありません。処理を終了します。\n",
|
||||
poly == NULL, bgId > BG_ACTOR_MAX, dest == NULL);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if (dest != NULL) {
|
||||
//! @bug: dest[2] x and y are not set to 0
|
||||
|
@ -1552,18 +1552,18 @@ void BgCheck_Allocate(CollisionContext* colCtx, PlayState* play, CollisionHeader
|
|||
customNodeListMax = -1;
|
||||
|
||||
// "/*---------------- BGCheck Buffer Memory Size -------------*/\n"
|
||||
osSyncPrintf("/*---------------- BGCheck バッファーメモリサイズ -------------*/\n");
|
||||
PRINTF("/*---------------- BGCheck バッファーメモリサイズ -------------*/\n");
|
||||
|
||||
if ((R_SCENE_CAM_TYPE == SCENE_CAM_TYPE_FIXED_SHOP_VIEWPOINT) ||
|
||||
(R_SCENE_CAM_TYPE == SCENE_CAM_TYPE_FIXED_TOGGLE_VIEWPOINT) || (R_SCENE_CAM_TYPE == SCENE_CAM_TYPE_FIXED) ||
|
||||
(R_SCENE_CAM_TYPE == SCENE_CAM_TYPE_FIXED_MARKET)) {
|
||||
if (play->sceneId == SCENE_STABLE) {
|
||||
// "/* BGCheck LonLon Size %dbyte */\n"
|
||||
osSyncPrintf("/* BGCheck LonLonサイズ %dbyte */\n", 0x3520);
|
||||
PRINTF("/* BGCheck LonLonサイズ %dbyte */\n", 0x3520);
|
||||
colCtx->memSize = 0x3520;
|
||||
} else {
|
||||
// "/* BGCheck Mini Size %dbyte */\n"
|
||||
osSyncPrintf("/* BGCheck ミニサイズ %dbyte */\n", 0x4E20);
|
||||
PRINTF("/* BGCheck ミニサイズ %dbyte */\n", 0x4E20);
|
||||
colCtx->memSize = 0x4E20;
|
||||
}
|
||||
colCtx->dyna.polyNodesMax = 500;
|
||||
|
@ -1575,7 +1575,7 @@ void BgCheck_Allocate(CollisionContext* colCtx, PlayState* play, CollisionHeader
|
|||
} else if (BgCheck_IsSpotScene(play) == true) {
|
||||
colCtx->memSize = 0xF000;
|
||||
// "/* BGCheck Spot Size %dbyte */\n"
|
||||
osSyncPrintf("/* BGCheck Spot用サイズ %dbyte */\n", 0xF000);
|
||||
PRINTF("/* BGCheck Spot用サイズ %dbyte */\n", 0xF000);
|
||||
colCtx->dyna.polyNodesMax = 1000;
|
||||
colCtx->dyna.polyListMax = 512;
|
||||
colCtx->dyna.vtxListMax = 512;
|
||||
|
@ -1589,7 +1589,7 @@ void BgCheck_Allocate(CollisionContext* colCtx, PlayState* play, CollisionHeader
|
|||
colCtx->memSize = 0x1CC00;
|
||||
}
|
||||
// "/* BGCheck Normal Size %dbyte */\n"
|
||||
osSyncPrintf("/* BGCheck ノーマルサイズ %dbyte */\n", colCtx->memSize);
|
||||
PRINTF("/* BGCheck ノーマルサイズ %dbyte */\n", colCtx->memSize);
|
||||
colCtx->dyna.polyNodesMax = 1000;
|
||||
colCtx->dyna.polyListMax = 512;
|
||||
colCtx->dyna.vtxListMax = 512;
|
||||
|
@ -1648,9 +1648,9 @@ void BgCheck_Allocate(CollisionContext* colCtx, PlayState* play, CollisionHeader
|
|||
SSNodeList_Alloc(play, &colCtx->polyNodes, tblMax, colCtx->colHeader->numPolygons);
|
||||
|
||||
lookupTblMemSize = BgCheck_InitializeStaticLookup(colCtx, play, colCtx->lookupTbl);
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("/*---結局 BG使用サイズ %dbyte---*/\n", memSize + lookupTblMemSize);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("/*---結局 BG使用サイズ %dbyte---*/\n", memSize + lookupTblMemSize);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
DynaPoly_Init(play, &colCtx->dyna);
|
||||
DynaPoly_Alloc(play, &colCtx->dyna);
|
||||
|
@ -1668,9 +1668,9 @@ CollisionHeader* BgCheck_GetCollisionHeader(CollisionContext* colCtx, s32 bgId)
|
|||
return NULL;
|
||||
}
|
||||
if (!(colCtx->dyna.bgActorFlags[bgId] & BGACTOR_IN_USE)) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK));
|
||||
osSyncPrintf("T_BGCheck_getBGDataInfo():そのbg_actor_indexは使われておりません。index=%d\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK));
|
||||
PRINTF("T_BGCheck_getBGDataInfo():そのbg_actor_indexは使われておりません。index=%d\n");
|
||||
PRINTF(VT_RST);
|
||||
return NULL;
|
||||
}
|
||||
return colCtx->dyna.bgActors[bgId].colHeader;
|
||||
|
@ -1719,7 +1719,7 @@ f32 BgCheck_RaycastDownImpl(PlayState* play, CollisionContext* colCtx, u16 xpFla
|
|||
}
|
||||
if (BgCheck_PosErrorCheck(&checkPos, "../z_bgcheck.c", 4410)) {
|
||||
if (actor != NULL) {
|
||||
osSyncPrintf("こいつ,pself_actor->name %d\n", actor->id);
|
||||
PRINTF("こいつ,pself_actor->name %d\n", actor->id);
|
||||
}
|
||||
}
|
||||
lookup = BgCheck_GetStaticLookup(colCtx, lookupTbl, &checkPos);
|
||||
|
@ -1969,7 +1969,7 @@ s32 BgCheck_CheckWallImpl(CollisionContext* colCtx, u16 xpFlags, Vec3f* posResul
|
|||
if (BgCheck_PosErrorCheck(posNext, "../z_bgcheck.c", 4831) == true ||
|
||||
BgCheck_PosErrorCheck(posPrev, "../z_bgcheck.c", 4832) == true) {
|
||||
if (actor != NULL) {
|
||||
osSyncPrintf("こいつ,pself_actor->name %d\n", actor->id);
|
||||
PRINTF("こいつ,pself_actor->name %d\n", actor->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2157,7 +2157,7 @@ s32 BgCheck_CheckCeilingImpl(CollisionContext* colCtx, u16 xpFlags, f32* outY, V
|
|||
*outY = pos->y;
|
||||
if (BgCheck_PosErrorCheck(pos, "../z_bgcheck.c", 5206) == true) {
|
||||
if (actor != NULL) {
|
||||
osSyncPrintf("こいつ,pself_actor->name %d\n", actor->id);
|
||||
PRINTF("こいつ,pself_actor->name %d\n", actor->id);
|
||||
}
|
||||
}
|
||||
lookupTbl = colCtx->lookupTbl;
|
||||
|
@ -2232,9 +2232,9 @@ s32 BgCheck_CheckLineImpl(CollisionContext* colCtx, u16 xpFlags1, u16 xpFlags2,
|
|||
if (BgCheck_PosErrorCheck(posA, "../z_bgcheck.c", 5334) == true ||
|
||||
BgCheck_PosErrorCheck(posB, "../z_bgcheck.c", 5335) == true) {
|
||||
if (actor != NULL) {
|
||||
osSyncPrintf("こいつ,pself_actor->name %d\n", actor->id);
|
||||
PRINTF("こいつ,pself_actor->name %d\n", actor->id);
|
||||
} else {
|
||||
osSyncPrintf("pself_actor == NULLで犯人不明\n");
|
||||
PRINTF("pself_actor == NULLで犯人不明\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2445,7 +2445,7 @@ s32 BgCheck_SphVsFirstPolyImpl(CollisionContext* colCtx, u16 xpFlags, CollisionP
|
|||
*outBgId = BGCHECK_SCENE;
|
||||
if (BgCheck_PosErrorCheck(center, "../z_bgcheck.c", 5852) == true) {
|
||||
if (actor != NULL) {
|
||||
osSyncPrintf("こいつ,pself_actor->name %d\n", actor->id);
|
||||
PRINTF("こいつ,pself_actor->name %d\n", actor->id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2717,9 +2717,9 @@ s32 DynaPoly_SetBgActor(PlayState* play, DynaCollisionContext* dyna, Actor* acto
|
|||
}
|
||||
|
||||
if (!foundSlot) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("DynaPolyInfo_setActor():ダイナミックポリゴン 空きインデックスはありません\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("DynaPolyInfo_setActor():ダイナミックポリゴン 空きインデックスはありません\n");
|
||||
PRINTF(VT_RST);
|
||||
return BG_ACTOR_MAX;
|
||||
}
|
||||
|
||||
|
@ -2727,9 +2727,9 @@ s32 DynaPoly_SetBgActor(PlayState* play, DynaCollisionContext* dyna, Actor* acto
|
|||
dyna->bitFlag |= DYNAPOLY_INVALIDATE_LOOKUP;
|
||||
|
||||
dyna->bgActorFlags[bgId] &= ~BGACTOR_1;
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("DynaPolyInfo_setActor():index %d\n", bgId);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("DynaPolyInfo_setActor():index %d\n", bgId);
|
||||
PRINTF(VT_RST);
|
||||
return bgId;
|
||||
}
|
||||
|
||||
|
@ -2779,25 +2779,24 @@ void DynaPoly_EnableCeilingCollision(PlayState* play, DynaCollisionContext* dyna
|
|||
void DynaPoly_DeleteBgActor(PlayState* play, DynaCollisionContext* dyna, s32 bgId) {
|
||||
DynaPolyActor* actor;
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("DynaPolyInfo_delReserve():index %d\n", bgId);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("DynaPolyInfo_delReserve():index %d\n", bgId);
|
||||
PRINTF(VT_RST);
|
||||
if (!DynaPoly_IsBgIdBgActor(bgId)) {
|
||||
|
||||
if (bgId == -1) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "The index that should have been deleted(? ) was(== -1), processing aborted."
|
||||
osSyncPrintf(
|
||||
"DynaPolyInfo_delReserve():削除されているはずの(?)\nインデックス(== -1)のため,処理を中止します。\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("DynaPolyInfo_delReserve():削除されているはずの(?)\nインデックス(== -1)のため,処理を中止します。\n");
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
} else {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Unable to deallocate index / index unallocated, processing aborted."
|
||||
osSyncPrintf("DynaPolyInfo_delReserve():"
|
||||
"確保していない/出来なかったインデックスの解放のため、処理を中止します。index == %d\n",
|
||||
bgId);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("DynaPolyInfo_delReserve():"
|
||||
"確保していない/出来なかったインデックスの解放のため、処理を中止します。index == %d\n",
|
||||
bgId);
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -2853,17 +2852,17 @@ void DynaPoly_AddBgActorToLookup(PlayState* play, DynaCollisionContext* dyna, s3
|
|||
}
|
||||
|
||||
if (!(dyna->polyListMax >= *polyStartIndex + pbgdata->numPolygons)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "do not use if %d exceeds %d"
|
||||
osSyncPrintf("DynaPolyInfo_expandSRT():polygon over %dが%dを越えるとダメ\n",
|
||||
*polyStartIndex + pbgdata->numPolygons, dyna->polyListMax);
|
||||
PRINTF("DynaPolyInfo_expandSRT():polygon over %dが%dを越えるとダメ\n", *polyStartIndex + pbgdata->numPolygons,
|
||||
dyna->polyListMax);
|
||||
}
|
||||
|
||||
if (!(dyna->vtxListMax >= *vtxStartIndex + pbgdata->numVertices)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "do not use if %d exceeds %d"
|
||||
osSyncPrintf("DynaPolyInfo_expandSRT():vertex over %dが%dを越えるとダメ\n",
|
||||
*vtxStartIndex + pbgdata->numVertices, dyna->vtxListMax);
|
||||
PRINTF("DynaPolyInfo_expandSRT():vertex over %dが%dを越えるとダメ\n", *vtxStartIndex + pbgdata->numVertices,
|
||||
dyna->vtxListMax);
|
||||
}
|
||||
|
||||
ASSERT(dyna->polyListMax >= *polyStartIndex + pbgdata->numPolygons,
|
||||
|
@ -3039,9 +3038,9 @@ void DynaPoly_UpdateContext(PlayState* play, DynaCollisionContext* dyna) {
|
|||
for (i = 0; i < BG_ACTOR_MAX; i++) {
|
||||
if (dyna->bgActorFlags[i] & BGACTOR_1) {
|
||||
// Initialize BgActor
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("DynaPolyInfo_setup():削除 index=%d\n", i);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("DynaPolyInfo_setup():削除 index=%d\n", i);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
dyna->bgActorFlags[i] = 0;
|
||||
BgActor_Initialize(play, &dyna->bgActors[i]);
|
||||
|
@ -3049,9 +3048,9 @@ void DynaPoly_UpdateContext(PlayState* play, DynaCollisionContext* dyna) {
|
|||
}
|
||||
if (dyna->bgActors[i].actor != NULL && dyna->bgActors[i].actor->update == NULL) {
|
||||
// Delete BgActor
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("DynaPolyInfo_setup():削除 index=%d\n", i);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("DynaPolyInfo_setup():削除 index=%d\n", i);
|
||||
PRINTF(VT_RST);
|
||||
actor = DynaPoly_GetActor(&play->colCtx, i);
|
||||
if (actor == NULL) {
|
||||
return;
|
||||
|
|
|
@ -440,7 +440,7 @@ f32 Camera_GetFloorYLayer(Camera* camera, Vec3f* norm, Vec3f* pos, s32* bgId) {
|
|||
}
|
||||
}
|
||||
if (i == 0) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: foward check: too many layer!\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: foward check: too many layer!\n" VT_RST);
|
||||
}
|
||||
return floorY;
|
||||
}
|
||||
|
@ -723,7 +723,7 @@ void Camera_CopyDataToRegs(Camera* camera, s16 mode) {
|
|||
s32 i;
|
||||
|
||||
if (PREG(82)) {
|
||||
osSyncPrintf("camera: res: stat (%d/%d/%d)\n", camera->camId, camera->setting, mode);
|
||||
PRINTF("camera: res: stat (%d/%d/%d)\n", camera->camId, camera->setting, mode);
|
||||
}
|
||||
|
||||
values = sCameraSettings[camera->setting].cameraModes[mode].values;
|
||||
|
@ -732,7 +732,7 @@ void Camera_CopyDataToRegs(Camera* camera, s16 mode) {
|
|||
valueP = &values[i];
|
||||
PREG(valueP->dataType) = valueP->val;
|
||||
if (PREG(82)) {
|
||||
osSyncPrintf("camera: res: PREG(%02d) = %d\n", valueP->dataType, valueP->val);
|
||||
PRINTF("camera: res: PREG(%02d) = %d\n", valueP->dataType, valueP->val);
|
||||
}
|
||||
}
|
||||
camera->animState = 0;
|
||||
|
@ -747,7 +747,7 @@ s32 Camera_CopyPREGToModeValues(Camera* camera) {
|
|||
valueP = &values[i];
|
||||
valueP->val = R_CAM_DATA(valueP->dataType);
|
||||
if (PREG(82)) {
|
||||
osSyncPrintf("camera: res: %d = PREG(%02d)\n", valueP->val, valueP->dataType);
|
||||
PRINTF("camera: res: %d = PREG(%02d)\n", valueP->val, valueP->dataType);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
@ -798,8 +798,7 @@ Vec3f Camera_BGCheckCorner(Vec3f* linePointA, Vec3f* linePointB, CamColChk* poin
|
|||
Vec3f closestPoint;
|
||||
|
||||
if (!func_800427B4(pointAColChk->poly, pointBColChk->poly, linePointA, linePointB, &closestPoint)) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: corner check no cross point %x %x\n" VT_RST, pointAColChk,
|
||||
pointBColChk);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: corner check no cross point %x %x\n" VT_RST, pointAColChk, pointBColChk);
|
||||
return pointAColChk->pos;
|
||||
}
|
||||
|
||||
|
@ -1131,8 +1130,8 @@ s32 Camera_CalcAtForLockOn(Camera* camera, VecGeo* eyeAtDir, Vec3f* targetPos, f
|
|||
lookFromOffset = OLib_VecGeoToVec3f(&playerToTargetDir);
|
||||
|
||||
if (PREG(89)) {
|
||||
osSyncPrintf("%f (%f %f %f) %f\n", playerToTargetDir.r / distance, lookFromOffset.x, lookFromOffset.y,
|
||||
lookFromOffset.z, camera->atLERPStepScale);
|
||||
PRINTF("%f (%f %f %f) %f\n", playerToTargetDir.r / distance, lookFromOffset.x, lookFromOffset.y,
|
||||
lookFromOffset.z, camera->atLERPStepScale);
|
||||
}
|
||||
|
||||
playerToAtOffsetTarget.x += lookFromOffset.x;
|
||||
|
@ -2414,7 +2413,7 @@ s32 Camera_Jump2(Camera* camera) {
|
|||
rwData->yawTarget = atToEyeNextDir.yaw;
|
||||
rwData->initYawDiff = 0;
|
||||
if (rwData->floorY == BGCHECK_Y_MIN) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: climb: no floor \n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: climb: no floor \n" VT_RST);
|
||||
rwData->onFloor = -1;
|
||||
rwData->floorY = playerPosRot->pos.y - 1000.0f;
|
||||
} else if (playerPosRot->pos.y - rwData->floorY < playerHeight) {
|
||||
|
@ -2853,8 +2852,7 @@ s32 Camera_Battle1(Camera* camera) {
|
|||
atToEyeNextDir = OLib_Vec3fDiffToVecGeo(at, eyeNext);
|
||||
if (camera->target == NULL || camera->target->update == NULL) {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(
|
||||
VT_COL(YELLOW, BLACK) "camera: warning: battle: target is not valid, change parallel\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: battle: target is not valid, change parallel\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
Camera_RequestMode(camera, CAM_MODE_Z_PARALLEL);
|
||||
|
@ -2869,9 +2867,9 @@ s32 Camera_Battle1(Camera* camera) {
|
|||
rwData->target = camera->target;
|
||||
camera->animState++;
|
||||
if (rwData->target->id > 0) {
|
||||
osSyncPrintf("camera: battle: target actor name " VT_FGCOL(BLUE) "%d" VT_RST "\n", rwData->target->id);
|
||||
PRINTF("camera: battle: target actor name " VT_FGCOL(BLUE) "%d" VT_RST "\n", rwData->target->id);
|
||||
} else {
|
||||
osSyncPrintf("camera: battle: target actor name " VT_COL(RED, WHITE) "%d" VT_RST "\n", rwData->target->id);
|
||||
PRINTF("camera: battle: target actor name " VT_COL(RED, WHITE) "%d" VT_RST "\n", rwData->target->id);
|
||||
camera->target = NULL;
|
||||
Camera_RequestMode(camera, CAM_MODE_Z_PARALLEL);
|
||||
return true;
|
||||
|
@ -2904,8 +2902,8 @@ s32 Camera_Battle1(Camera* camera) {
|
|||
}
|
||||
camera->targetPosRot = Actor_GetFocus(camera->target);
|
||||
if (rwData->target != camera->target) {
|
||||
osSyncPrintf("camera: battle: change target %d -> " VT_FGCOL(BLUE) "%d" VT_RST "\n", rwData->target->id,
|
||||
camera->target->id);
|
||||
PRINTF("camera: battle: change target %d -> " VT_FGCOL(BLUE) "%d" VT_RST "\n", rwData->target->id,
|
||||
camera->target->id);
|
||||
camera->animState = 0;
|
||||
return true;
|
||||
}
|
||||
|
@ -3139,8 +3137,7 @@ s32 Camera_KeepOn1(Camera* camera) {
|
|||
playerHeight = Player_GetHeight(camera->player);
|
||||
if ((camera->target == NULL) || (camera->target->update == NULL)) {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(
|
||||
VT_COL(YELLOW, BLACK) "camera: warning: keepon: target is not valid, change parallel\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: keepon: target is not valid, change parallel\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
Camera_RequestMode(camera, CAM_MODE_Z_PARALLEL);
|
||||
|
@ -3379,7 +3376,7 @@ s32 Camera_KeepOn3(Camera* camera) {
|
|||
playerHeight = Player_GetHeight(camera->player);
|
||||
if (camera->target == NULL || camera->target->update == NULL) {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: warning: talk: target is not valid, change parallel\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: talk: target is not valid, change parallel\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
Camera_RequestMode(camera, CAM_MODE_Z_PARALLEL);
|
||||
|
@ -3488,7 +3485,7 @@ s32 Camera_KeepOn3(Camera* camera) {
|
|||
i++;
|
||||
}
|
||||
}
|
||||
osSyncPrintf("camera: talk: BG&collision check %d time(s)\n", i);
|
||||
PRINTF("camera: talk: BG&collision check %d time(s)\n", i);
|
||||
camera->stateFlags &= ~(CAM_STATE_CHECK_BG | CAM_STATE_EXTERNAL_FINISHED);
|
||||
pad = ((rwData->animTimer + 1) * rwData->animTimer) >> 1;
|
||||
rwData->eyeToAtTargetYaw = (f32)(s16)(atToEyeAdj.yaw - atToEyeNextDir.yaw) / pad;
|
||||
|
@ -3577,8 +3574,7 @@ s32 Camera_KeepOn4(Camera* camera) {
|
|||
}
|
||||
|
||||
if (rwData->unk_14 != *temp_s0) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: item: item type changed %d -> %d\n" VT_RST, rwData->unk_14,
|
||||
*temp_s0);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: item: item type changed %d -> %d\n" VT_RST, rwData->unk_14, *temp_s0);
|
||||
camera->animState = 20;
|
||||
camera->stateFlags |= CAM_STATE_LOCK_MODE;
|
||||
camera->stateFlags &= ~(CAM_STATE_CHECK_WATER | CAM_STATE_CHECK_BG);
|
||||
|
@ -3601,7 +3597,7 @@ s32 Camera_KeepOn4(Camera* camera) {
|
|||
roData->interfaceField = GET_NEXT_RO_DATA(values);
|
||||
roData->unk_14 = GET_NEXT_SCALED_RO_DATA(values);
|
||||
roData->unk_1E = GET_NEXT_RO_DATA(values);
|
||||
osSyncPrintf("camera: item: type %d\n", *temp_s0);
|
||||
PRINTF("camera: item: type %d\n", *temp_s0);
|
||||
switch (*temp_s0) {
|
||||
case 1:
|
||||
roData->unk_00 = playerHeight * -0.6f * yNormal;
|
||||
|
@ -3789,7 +3785,7 @@ s32 Camera_KeepOn4(Camera* camera) {
|
|||
spB8.pitch = D_8011D3CC[i] + spA2;
|
||||
D_8015BD70 = Camera_AddVecGeoToVec3f(&D_8015BD50, &spB8);
|
||||
}
|
||||
osSyncPrintf("camera: item: BG&collision check %d time(s)\n", i);
|
||||
PRINTF("camera: item: BG&collision check %d time(s)\n", i);
|
||||
}
|
||||
rwData->unk_04 = (s16)(spB8.pitch - spA8.pitch) / (f32)rwData->unk_10;
|
||||
rwData->unk_00 = (s16)(spB8.yaw - spA8.yaw) / (f32)rwData->unk_10;
|
||||
|
@ -3895,8 +3891,7 @@ s32 Camera_KeepOn0(Camera* camera) {
|
|||
|
||||
if (camera->target == NULL || camera->target->update == NULL) {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(
|
||||
VT_COL(YELLOW, BLACK) "camera: warning: talk: target is not valid, change normal camera\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: talk: target is not valid, change normal camera\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
Camera_RequestMode(camera, CAM_MODE_NORMAL);
|
||||
|
@ -4130,7 +4125,7 @@ s32 Camera_Fixed3(Camera* camera) {
|
|||
}
|
||||
|
||||
if (bgCamFuncData->roomImageOverrideBgCamIndex != rwData->roomImageOverrideBgCamIndex) {
|
||||
osSyncPrintf("camera: position change %d \n", rwData->roomImageOverrideBgCamIndex);
|
||||
PRINTF("camera: position change %d \n", rwData->roomImageOverrideBgCamIndex);
|
||||
rwData->roomImageOverrideBgCamIndex = bgCamFuncData->roomImageOverrideBgCamIndex;
|
||||
rwData->updDirTimer = 5;
|
||||
}
|
||||
|
@ -4552,7 +4547,7 @@ s32 Camera_Data0(Camera* camera) {
|
|||
}
|
||||
|
||||
s32 Camera_Data1(Camera* camera) {
|
||||
osSyncPrintf("chau!chau!\n");
|
||||
PRINTF("chau!chau!\n");
|
||||
return Camera_Normal1(camera);
|
||||
}
|
||||
|
||||
|
@ -5262,9 +5257,9 @@ s32 Camera_Unique9(Camera* camera) {
|
|||
if ((camera->player->stateFlags1 & PLAYER_STATE1_27) &&
|
||||
(player->currentBoots != PLAYER_BOOTS_IRON)) {
|
||||
Player_SetCsAction(camera->play, camera->target, PLAYER_CSACTION_8);
|
||||
osSyncPrintf("camera: demo: player demo set WAIT\n");
|
||||
PRINTF("camera: demo: player demo set WAIT\n");
|
||||
} else {
|
||||
osSyncPrintf("camera: demo: player demo set %d\n", rwData->curKeyFrame->initField);
|
||||
PRINTF("camera: demo: player demo set %d\n", rwData->curKeyFrame->initField);
|
||||
Player_SetCsAction(camera->play, camera->target, rwData->curKeyFrame->initField);
|
||||
}
|
||||
}
|
||||
|
@ -5314,7 +5309,7 @@ s32 Camera_Unique9(Camera* camera) {
|
|||
rwData->atTarget = Camera_AddVecGeoToVec3f(&targethead.pos, &scratchGeo);
|
||||
} else {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
}
|
||||
|
||||
camera->target = NULL;
|
||||
|
@ -5353,7 +5348,7 @@ s32 Camera_Unique9(Camera* camera) {
|
|||
rwData->atTarget = Camera_AddVecGeoToVec3f(&atFocusPosRot.pos, &scratchGeo);
|
||||
} else {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
}
|
||||
rwData->atTarget = *at;
|
||||
}
|
||||
|
@ -5403,7 +5398,7 @@ s32 Camera_Unique9(Camera* camera) {
|
|||
rwData->eyeTarget = Camera_AddVecGeoToVec3f(&eyeLookAtPos, &scratchGeo);
|
||||
} else {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
rwData->eyeTarget = *eyeNext;
|
||||
|
@ -5444,7 +5439,7 @@ s32 Camera_Unique9(Camera* camera) {
|
|||
rwData->eyeTarget = Camera_AddVecGeoToVec3f(&eyeFocusPosRot.pos, &scratchGeo);
|
||||
} else {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: demo C: actor is not valid\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
rwData->eyeTarget = *eyeNext;
|
||||
|
@ -5676,18 +5671,18 @@ s32 Camera_Unique9(Camera* camera) {
|
|||
void Camera_DebugPrintSplineArray(char* name, s16 length, CutsceneCameraPoint cameraPoints[]) {
|
||||
s32 i;
|
||||
|
||||
osSyncPrintf("static SplinedatZ %s[] = {\n", name);
|
||||
PRINTF("static SplinedatZ %s[] = {\n", name);
|
||||
for (i = 0; i < length; i++) {
|
||||
osSyncPrintf(" /* key frame %2d */ {\n", i);
|
||||
osSyncPrintf(" /* code */ %d,\n", cameraPoints[i].continueFlag);
|
||||
osSyncPrintf(" /* z */ %d,\n", cameraPoints[i].cameraRoll);
|
||||
osSyncPrintf(" /* T */ %d,\n", cameraPoints[i].nextPointFrame);
|
||||
osSyncPrintf(" /* zoom */ %f,\n", cameraPoints[i].viewAngle);
|
||||
osSyncPrintf(" /* pos */ { %d, %d, %d }\n", cameraPoints[i].pos.x, cameraPoints[i].pos.y,
|
||||
cameraPoints[i].pos.z);
|
||||
osSyncPrintf(" },\n");
|
||||
PRINTF(" /* key frame %2d */ {\n", i);
|
||||
PRINTF(" /* code */ %d,\n", cameraPoints[i].continueFlag);
|
||||
PRINTF(" /* z */ %d,\n", cameraPoints[i].cameraRoll);
|
||||
PRINTF(" /* T */ %d,\n", cameraPoints[i].nextPointFrame);
|
||||
PRINTF(" /* zoom */ %f,\n", cameraPoints[i].viewAngle);
|
||||
PRINTF(" /* pos */ { %d, %d, %d }\n", cameraPoints[i].pos.x, cameraPoints[i].pos.y,
|
||||
cameraPoints[i].pos.z);
|
||||
PRINTF(" },\n");
|
||||
}
|
||||
osSyncPrintf("};\n\n");
|
||||
PRINTF("};\n\n");
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -5750,8 +5745,8 @@ s32 Camera_Demo1(Camera* camera) {
|
|||
rwData->curFrame = 0.0f;
|
||||
camera->animState++;
|
||||
// "absolute" : "relative"
|
||||
osSyncPrintf(VT_SGR("1") "%06u:" VT_RST " camera: spline demo: start %s \n", camera->play->state.frames,
|
||||
*relativeToPlayer == 0 ? "絶対" : "相対");
|
||||
PRINTF(VT_SGR("1") "%06u:" VT_RST " camera: spline demo: start %s \n", camera->play->state.frames,
|
||||
*relativeToPlayer == 0 ? "絶対" : "相対");
|
||||
|
||||
if (PREG(93)) {
|
||||
Camera_DebugPrintSplineArray("CENTER", 5, csAtPoints);
|
||||
|
@ -5772,7 +5767,7 @@ s32 Camera_Demo1(Camera* camera) {
|
|||
Camera_RotateAroundPoint(&curPlayerPosRot, &csEyeUpdate, eyeNext);
|
||||
Camera_RotateAroundPoint(&curPlayerPosRot, &csAtUpdate, at);
|
||||
} else {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera: spline demo: owner dead\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera: spline demo: owner dead\n" VT_RST);
|
||||
}
|
||||
} else {
|
||||
// simply copy the interpolated values to the eye and at
|
||||
|
@ -6041,7 +6036,7 @@ s32 Camera_Demo5(Camera* camera) {
|
|||
|
||||
if ((camera->target == NULL) || (camera->target->update == NULL)) {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: warning: attention: target is not valid, stop!\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: attention: target is not valid, stop!\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
return true;
|
||||
|
@ -6150,7 +6145,7 @@ s32 Camera_Demo5(Camera* camera) {
|
|||
D_8011D954[0].timerInit = camera->timer - 5;
|
||||
sp4A = 0;
|
||||
if (!func_800C0D34(camera->play, camera->target, &sp4A)) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: attention demo: this door is dummy door!\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: attention demo: this door is dummy door!\n" VT_RST);
|
||||
if (ABS(playerTargetGeo.yaw - camera->target->shape.rot.y) >= 0x4000) {
|
||||
sp4A = camera->target->shape.rot.y;
|
||||
} else {
|
||||
|
@ -6518,7 +6513,7 @@ s32 Camera_Special0(Camera* camera) {
|
|||
|
||||
if ((camera->target == NULL) || (camera->target->update == NULL)) {
|
||||
if (camera->target == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: warning: circle: target is not valid, stop!\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: warning: circle: target is not valid, stop!\n" VT_RST);
|
||||
}
|
||||
camera->target = NULL;
|
||||
return true;
|
||||
|
@ -7020,20 +7015,20 @@ Camera* Camera_Create(View* view, CollisionContext* colCtx, PlayState* play) {
|
|||
Camera* newCamera = ZELDA_ARENA_MALLOC(sizeof(*newCamera), "../z_camera.c", 9370);
|
||||
|
||||
if (newCamera != NULL) {
|
||||
osSyncPrintf(VT_FGCOL(BLUE) "camera: create --- allocate %d byte" VT_RST "\n", sizeof(*newCamera) * 4);
|
||||
PRINTF(VT_FGCOL(BLUE) "camera: create --- allocate %d byte" VT_RST "\n", sizeof(*newCamera) * 4);
|
||||
Camera_Init(newCamera, view, colCtx, play);
|
||||
} else {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera: create: not enough memory\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera: create: not enough memory\n" VT_RST);
|
||||
}
|
||||
return newCamera;
|
||||
}
|
||||
|
||||
void Camera_Destroy(Camera* camera) {
|
||||
if (camera != NULL) {
|
||||
osSyncPrintf(VT_FGCOL(BLUE) "camera: destroy ---" VT_RST "\n");
|
||||
PRINTF(VT_FGCOL(BLUE) "camera: destroy ---" VT_RST "\n");
|
||||
ZELDA_ARENA_FREE(camera, "../z_camera.c", 9391);
|
||||
} else {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: destroy: already cleared\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: destroy: already cleared\n" VT_RST);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -7112,7 +7107,7 @@ void Camera_Init(Camera* camera, View* view, CollisionContext* colCtx, PlayState
|
|||
sCameraInterfaceField = CAM_INTERFACE_FIELD(CAM_LETTERBOX_IGNORE, CAM_HUD_VISIBILITY_IGNORE, 0);
|
||||
sDbgModeIdx = -1;
|
||||
D_8011D3F0 = 3;
|
||||
osSyncPrintf(VT_FGCOL(BLUE) "camera: initialize --- " VT_RST " UID %d\n", camera->uid);
|
||||
PRINTF(VT_FGCOL(BLUE) "camera: initialize --- " VT_RST " UID %d\n", camera->uid);
|
||||
}
|
||||
|
||||
void func_80057FC4(Camera* camera) {
|
||||
|
@ -7126,19 +7121,19 @@ void func_80057FC4(Camera* camera) {
|
|||
camera->prevSetting = camera->setting = CAM_SET_DUNGEON0;
|
||||
break;
|
||||
case ROOM_BEHAVIOR_TYPE1_0:
|
||||
osSyncPrintf("camera: room type: default set field\n");
|
||||
PRINTF("camera: room type: default set field\n");
|
||||
Camera_ChangeDoorCam(camera, NULL, -99, 0, 0, 18, 10);
|
||||
camera->prevSetting = camera->setting = CAM_SET_NORMAL0;
|
||||
break;
|
||||
default:
|
||||
osSyncPrintf("camera: room type: default set etc (%d)\n", camera->play->roomCtx.curRoom.behaviorType1);
|
||||
PRINTF("camera: room type: default set etc (%d)\n", camera->play->roomCtx.curRoom.behaviorType1);
|
||||
Camera_ChangeDoorCam(camera, NULL, -99, 0, 0, 18, 10);
|
||||
camera->prevSetting = camera->setting = CAM_SET_NORMAL0;
|
||||
camera->stateFlags |= CAM_STATE_CHECK_BG;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
osSyncPrintf("camera: room type: prerender\n");
|
||||
PRINTF("camera: room type: prerender\n");
|
||||
camera->prevSetting = camera->setting = CAM_SET_FREE0;
|
||||
camera->stateFlags &= ~CAM_STATE_CHECK_BG;
|
||||
}
|
||||
|
@ -7208,7 +7203,7 @@ void Camera_InitDataUsingPlayer(Camera* camera, Player* player) {
|
|||
camera->atLERPStepScale = 1.0f;
|
||||
Camera_CopyDataToRegs(camera, camera->mode);
|
||||
Camera_QRegInit();
|
||||
osSyncPrintf(VT_FGCOL(BLUE) "camera: personalize ---" VT_RST "\n");
|
||||
PRINTF(VT_FGCOL(BLUE) "camera: personalize ---" VT_RST "\n");
|
||||
|
||||
if (camera->camId == CAM_ID_MAIN) {
|
||||
Camera_UpdateWater(camera);
|
||||
|
@ -7221,12 +7216,12 @@ s16 Camera_ChangeStatus(Camera* camera, s16 status) {
|
|||
s32 i;
|
||||
|
||||
if (PREG(82)) {
|
||||
osSyncPrintf("camera: change camera status: cond %c%c\n", status == CAM_STAT_ACTIVE ? 'o' : 'x',
|
||||
camera->status != CAM_STAT_ACTIVE ? 'o' : 'x');
|
||||
PRINTF("camera: change camera status: cond %c%c\n", status == CAM_STAT_ACTIVE ? 'o' : 'x',
|
||||
camera->status != CAM_STAT_ACTIVE ? 'o' : 'x');
|
||||
}
|
||||
|
||||
if (PREG(82)) {
|
||||
osSyncPrintf("camera: res: stat (%d/%d/%d)\n", camera->camId, camera->setting, camera->mode);
|
||||
PRINTF("camera: res: stat (%d/%d/%d)\n", camera->camId, camera->setting, camera->mode);
|
||||
}
|
||||
|
||||
if (status == CAM_STAT_ACTIVE && camera->status != CAM_STAT_ACTIVE) {
|
||||
|
@ -7235,7 +7230,7 @@ s16 Camera_ChangeStatus(Camera* camera, s16 status) {
|
|||
valueP = &values[i];
|
||||
R_CAM_DATA(valueP->dataType) = valueP->val;
|
||||
if (PREG(82)) {
|
||||
osSyncPrintf("camera: change camera status: PREG(%02d) = %d\n", valueP->dataType, valueP->val);
|
||||
PRINTF("camera: change camera status: PREG(%02d) = %d\n", valueP->dataType, valueP->val);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -7382,7 +7377,7 @@ s32 Camera_UpdateWater(Camera* camera) {
|
|||
}
|
||||
} else if (camera->stateFlags & CAM_STATE_PLAYER_IN_WATER) {
|
||||
// player is leaving a water box.
|
||||
osSyncPrintf("camera: water: off\n");
|
||||
PRINTF("camera: water: off\n");
|
||||
camera->stateFlags &= ~CAM_STATE_PLAYER_IN_WATER;
|
||||
prevBgId = camera->bgId;
|
||||
camera->bgId = BGCHECK_SCENE;
|
||||
|
@ -7401,7 +7396,7 @@ s32 Camera_UpdateWater(Camera* camera) {
|
|||
camera->waterYPos = waterY;
|
||||
if (!(camera->stateFlags & CAM_STATE_CAMERA_IN_WATER)) {
|
||||
camera->stateFlags |= CAM_STATE_CAMERA_IN_WATER;
|
||||
osSyncPrintf("kankyo changed water, sound on\n");
|
||||
PRINTF("kankyo changed water, sound on\n");
|
||||
Environment_EnableUnderwaterLights(camera->play, waterLightsIndex);
|
||||
camera->waterDistortionTimer = 80;
|
||||
}
|
||||
|
@ -7436,7 +7431,7 @@ s32 Camera_UpdateWater(Camera* camera) {
|
|||
} else {
|
||||
if (camera->stateFlags & CAM_STATE_CAMERA_IN_WATER) {
|
||||
camera->stateFlags &= ~CAM_STATE_CAMERA_IN_WATER;
|
||||
osSyncPrintf("kankyo changed water off, sound off\n");
|
||||
PRINTF("kankyo changed water off, sound off\n");
|
||||
Environment_DisableUnderwaterLights(camera->play);
|
||||
if (*waterQuakeIndex != 0) {
|
||||
Quake_RemoveRequest(*waterQuakeIndex);
|
||||
|
@ -7463,11 +7458,11 @@ s32 Camera_DbgChangeMode(Camera* camera) {
|
|||
|
||||
if (!gDebugCamEnabled && camera->play->activeCamId == CAM_ID_MAIN) {
|
||||
if (CHECK_BTN_ALL(D_8015BD7C->state.input[2].press.button, BTN_CUP)) {
|
||||
osSyncPrintf("attention sound URGENCY\n");
|
||||
PRINTF("attention sound URGENCY\n");
|
||||
Sfx_PlaySfxCentered(NA_SE_SY_ATTENTION_URGENCY);
|
||||
}
|
||||
if (CHECK_BTN_ALL(D_8015BD7C->state.input[2].press.button, BTN_CDOWN)) {
|
||||
osSyncPrintf("attention sound NORMAL\n");
|
||||
PRINTF("attention sound NORMAL\n");
|
||||
Sfx_PlaySfxCentered(NA_SE_SY_ATTENTION_ON);
|
||||
}
|
||||
|
||||
|
@ -7480,7 +7475,7 @@ s32 Camera_DbgChangeMode(Camera* camera) {
|
|||
if (changeDir != 0) {
|
||||
sDbgModeIdx = (sDbgModeIdx + changeDir) % 6;
|
||||
if (Camera_RequestSetting(camera, D_8011DAFC[sDbgModeIdx]) > 0) {
|
||||
osSyncPrintf("camera: force change SET to %s!\n", sCameraSettingNames[D_8011DAFC[sDbgModeIdx]]);
|
||||
PRINTF("camera: force change SET to %s!\n", sCameraSettingNames[D_8011DAFC[sDbgModeIdx]]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -7592,12 +7587,12 @@ Vec3s Camera_Update(Camera* camera) {
|
|||
player = camera->play->cameraPtrs[CAM_ID_MAIN]->player;
|
||||
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: in %x\n", camera);
|
||||
PRINTF("camera: in %x\n", camera);
|
||||
}
|
||||
|
||||
if (camera->status == CAM_STAT_CUT) {
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: cut out %x\n", camera);
|
||||
PRINTF("camera: cut out %x\n", camera);
|
||||
}
|
||||
return camera->inputDir;
|
||||
}
|
||||
|
@ -7672,7 +7667,7 @@ Vec3s Camera_Update(Camera* camera) {
|
|||
|
||||
if (camera->status == CAM_STAT_WAIT) {
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: wait out %x\n", camera);
|
||||
PRINTF("camera: wait out %x\n", camera);
|
||||
}
|
||||
return camera->inputDir;
|
||||
}
|
||||
|
@ -7682,8 +7677,8 @@ Vec3s Camera_Update(Camera* camera) {
|
|||
camera->stateFlags |= CAM_STATE_CAM_FUNC_FINISH;
|
||||
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: engine (%d %d %d) %04x \n", camera->setting, camera->mode,
|
||||
sCameraSettings[camera->setting].cameraModes[camera->mode].funcIdx, camera->stateFlags);
|
||||
PRINTF("camera: engine (%d %d %d) %04x \n", camera->setting, camera->mode,
|
||||
sCameraSettings[camera->setting].cameraModes[camera->mode].funcIdx, camera->stateFlags);
|
||||
}
|
||||
|
||||
if (sOOBTimer < 200) {
|
||||
|
@ -7713,14 +7708,14 @@ Vec3s Camera_Update(Camera* camera) {
|
|||
}
|
||||
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: shrink_and_bitem %x(%d)\n", sCameraInterfaceField, camera->play->transitionMode);
|
||||
PRINTF("camera: shrink_and_bitem %x(%d)\n", sCameraInterfaceField, camera->play->transitionMode);
|
||||
}
|
||||
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: engine (%s(%d) %s(%d) %s(%d)) ok!\n", &sCameraSettingNames[camera->setting],
|
||||
camera->setting, &sCameraModeNames[camera->mode], camera->mode,
|
||||
&sCameraFunctionNames[sCameraSettings[camera->setting].cameraModes[camera->mode].funcIdx],
|
||||
sCameraSettings[camera->setting].cameraModes[camera->mode].funcIdx);
|
||||
PRINTF("camera: engine (%s(%d) %s(%d) %s(%d)) ok!\n", &sCameraSettingNames[camera->setting], camera->setting,
|
||||
&sCameraModeNames[camera->mode], camera->mode,
|
||||
&sCameraFunctionNames[sCameraSettings[camera->setting].cameraModes[camera->mode].funcIdx],
|
||||
sCameraSettings[camera->setting].cameraModes[camera->mode].funcIdx);
|
||||
}
|
||||
|
||||
// enable/disable debug cam
|
||||
|
@ -7739,7 +7734,7 @@ Vec3s Camera_Update(Camera* camera) {
|
|||
DebugCamera_Update(&D_8015BD80, camera);
|
||||
View_LookAt(&camera->play->view, &D_8015BD80.eye, &D_8015BD80.at, &D_8015BD80.unk_1C);
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: debug out\n");
|
||||
PRINTF("camera: debug out\n");
|
||||
}
|
||||
return D_8015BD80.sub.unk_104A;
|
||||
}
|
||||
|
@ -7804,10 +7799,10 @@ Vec3s Camera_Update(Camera* camera) {
|
|||
}
|
||||
|
||||
if (PREG(81)) {
|
||||
osSyncPrintf("dir (%d) %d(%f) %d(%f) 0(0) \n", sUpdateCameraDirection, camera->inputDir.x,
|
||||
CAM_BINANG_TO_DEG(camera->inputDir.x), camera->inputDir.y, CAM_BINANG_TO_DEG(camera->inputDir.y));
|
||||
osSyncPrintf("real (%d) %d(%f) %d(%f) 0(0) \n", sUpdateCameraDirection, camera->camDir.x,
|
||||
CAM_BINANG_TO_DEG(camera->camDir.x), camera->camDir.y, CAM_BINANG_TO_DEG(camera->camDir.y));
|
||||
PRINTF("dir (%d) %d(%f) %d(%f) 0(0) \n", sUpdateCameraDirection, camera->inputDir.x,
|
||||
CAM_BINANG_TO_DEG(camera->inputDir.x), camera->inputDir.y, CAM_BINANG_TO_DEG(camera->inputDir.y));
|
||||
PRINTF("real (%d) %d(%f) %d(%f) 0(0) \n", sUpdateCameraDirection, camera->camDir.x,
|
||||
CAM_BINANG_TO_DEG(camera->camDir.x), camera->camDir.y, CAM_BINANG_TO_DEG(camera->camDir.y));
|
||||
}
|
||||
|
||||
if (camera->timer != -1 && CHECK_BTN_ALL(D_8015BD7C->state.input[0].press.button, BTN_DRIGHT)) {
|
||||
|
@ -7815,14 +7810,13 @@ Vec3s Camera_Update(Camera* camera) {
|
|||
}
|
||||
|
||||
if (R_DEBUG_CAM_UPDATE) {
|
||||
osSyncPrintf("camera: out (%f %f %f) (%f %f %f)\n", camera->at.x, camera->at.y, camera->at.z, camera->eye.x,
|
||||
camera->eye.y, camera->eye.z);
|
||||
osSyncPrintf("camera: dir (%f %d(%f) %d(%f)) (%f)\n", eyeAtAngle.r, eyeAtAngle.pitch,
|
||||
CAM_BINANG_TO_DEG(eyeAtAngle.pitch), eyeAtAngle.yaw, CAM_BINANG_TO_DEG(eyeAtAngle.yaw),
|
||||
camera->fov);
|
||||
PRINTF("camera: out (%f %f %f) (%f %f %f)\n", camera->at.x, camera->at.y, camera->at.z, camera->eye.x,
|
||||
camera->eye.y, camera->eye.z);
|
||||
PRINTF("camera: dir (%f %d(%f) %d(%f)) (%f)\n", eyeAtAngle.r, eyeAtAngle.pitch,
|
||||
CAM_BINANG_TO_DEG(eyeAtAngle.pitch), eyeAtAngle.yaw, CAM_BINANG_TO_DEG(eyeAtAngle.yaw), camera->fov);
|
||||
if (camera->player != NULL) {
|
||||
osSyncPrintf("camera: foot(%f %f %f) dist (%f)\n", curPlayerPosRot.pos.x, curPlayerPosRot.pos.y,
|
||||
curPlayerPosRot.pos.z, camera->dist);
|
||||
PRINTF("camera: foot(%f %f %f) dist (%f)\n", curPlayerPosRot.pos.x, curPlayerPosRot.pos.y,
|
||||
curPlayerPosRot.pos.z, camera->dist);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -7845,7 +7839,7 @@ void Camera_Finish(Camera* camera) {
|
|||
|
||||
if (player->csAction != PLAYER_CSACTION_NONE) {
|
||||
Player_SetCsActionWithHaltedActors(camera->play, &player->actor, PLAYER_CSACTION_7);
|
||||
osSyncPrintf("camera: player demo end!!\n");
|
||||
PRINTF("camera: player demo end!!\n");
|
||||
}
|
||||
|
||||
mainCam->stateFlags |= CAM_STATE_EXTERNAL_FINISHED;
|
||||
|
@ -7888,7 +7882,7 @@ s32 Camera_RequestModeImpl(Camera* camera, s16 requestedMode, u8 forceModeChange
|
|||
static s32 sModeRequestFlags = 0;
|
||||
|
||||
if (QREG(89)) {
|
||||
osSyncPrintf("+=+(%d)+=+ recive request -> %s\n", camera->play->state.frames, sCameraModeNames[requestedMode]);
|
||||
PRINTF("+=+(%d)+=+ recive request -> %s\n", camera->play->state.frames, sCameraModeNames[requestedMode]);
|
||||
}
|
||||
|
||||
if ((camera->stateFlags & CAM_STATE_LOCK_MODE) && !forceModeChange) {
|
||||
|
@ -7898,13 +7892,13 @@ s32 Camera_RequestModeImpl(Camera* camera, s16 requestedMode, u8 forceModeChange
|
|||
|
||||
if (!((sCameraSettings[camera->setting].unk_00 & 0x3FFFFFFF) & (1 << requestedMode))) {
|
||||
if (requestedMode == CAM_MODE_FIRST_PERSON) {
|
||||
osSyncPrintf("camera: error sound\n");
|
||||
PRINTF("camera: error sound\n");
|
||||
Sfx_PlaySfxCentered(NA_SE_SY_ERROR);
|
||||
}
|
||||
|
||||
if (camera->mode != CAM_MODE_NORMAL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "camera: change camera mode: force NORMAL: %s %s refused\n" VT_RST,
|
||||
sCameraSettingNames[camera->setting], sCameraModeNames[requestedMode]);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "camera: change camera mode: force NORMAL: %s %s refused\n" VT_RST,
|
||||
sCameraSettingNames[camera->setting], sCameraModeNames[requestedMode]);
|
||||
camera->mode = CAM_MODE_NORMAL;
|
||||
Camera_CopyDataToRegs(camera, camera->mode);
|
||||
Camera_SetNewModeStateFlags(camera);
|
||||
|
@ -8050,8 +8044,7 @@ s32 Camera_RequestMode(Camera* camera, s16 mode) {
|
|||
|
||||
s32 Camera_CheckValidMode(Camera* camera, s16 mode) {
|
||||
if (QREG(89) != 0) {
|
||||
osSyncPrintf("+=+=+=+ recive asking -> %s (%s)\n", sCameraModeNames[mode],
|
||||
sCameraSettingNames[camera->setting]);
|
||||
PRINTF("+=+=+=+ recive asking -> %s (%s)\n", sCameraModeNames[mode], sCameraSettingNames[camera->setting]);
|
||||
}
|
||||
if (!(sCameraSettings[camera->setting].validModes & (1 << mode))) {
|
||||
return 0;
|
||||
|
@ -8080,7 +8073,7 @@ s16 Camera_RequestSettingImpl(Camera* camera, s16 requestedSetting, s16 flags) {
|
|||
}
|
||||
|
||||
if ((requestedSetting == CAM_SET_NONE) || (requestedSetting >= CAM_SET_MAX)) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera: error: illegal camera set (%d) !!!!\n" VT_RST, requestedSetting);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera: error: illegal camera set (%d) !!!!\n" VT_RST, requestedSetting);
|
||||
return -99;
|
||||
}
|
||||
|
||||
|
@ -8122,8 +8115,8 @@ s16 Camera_RequestSettingImpl(Camera* camera, s16 requestedSetting, s16 flags) {
|
|||
Camera_CopyDataToRegs(camera, camera->mode);
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_SGR("1") "%06u:" VT_RST " camera: change camera[%d] set %s\n", camera->play->state.frames,
|
||||
camera->camId, sCameraSettingNames[camera->setting]);
|
||||
PRINTF(VT_SGR("1") "%06u:" VT_RST " camera: change camera[%d] set %s\n", camera->play->state.frames, camera->camId,
|
||||
sCameraSettingNames[camera->setting]);
|
||||
|
||||
return requestedSetting;
|
||||
}
|
||||
|
@ -8154,8 +8147,8 @@ s32 Camera_RequestBgCam(Camera* camera, s32 requestedBgCamIndex) {
|
|||
} else if (settingChangeSuccessful < -1) {
|
||||
//! @bug: `settingChangeSuccessful` is a bool and is likely checking the wrong value. This can never pass.
|
||||
// The actual return of Camera_RequestSettingImpl or bgCamIndex would make more sense.
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera: error: illegal camera ID (%d) !! (%d|%d|%d)\n" VT_RST,
|
||||
requestedBgCamIndex, camera->camId, BGCHECK_SCENE, requestedCamSetting);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera: error: illegal camera ID (%d) !! (%d|%d|%d)\n" VT_RST,
|
||||
requestedBgCamIndex, camera->camId, BGCHECK_SCENE, requestedCamSetting);
|
||||
}
|
||||
return 0x80000000 | requestedBgCamIndex;
|
||||
}
|
||||
|
@ -8336,7 +8329,7 @@ s32 Camera_ChangeDoorCam(Camera* camera, Actor* doorActor, s16 bgCamIndex, f32 a
|
|||
|
||||
if (bgCamIndex == -1) {
|
||||
Camera_RequestSetting(camera, CAM_SET_DOORC);
|
||||
osSyncPrintf(".... change default door camera (set %d)\n", CAM_SET_DOORC);
|
||||
PRINTF(".... change default door camera (set %d)\n", CAM_SET_DOORC);
|
||||
} else {
|
||||
s32 setting = Camera_GetBgCamSetting(camera, bgCamIndex);
|
||||
|
||||
|
@ -8347,7 +8340,7 @@ s32 Camera_ChangeDoorCam(Camera* camera, Actor* doorActor, s16 bgCamIndex, f32 a
|
|||
camera->behaviorFlags |= CAM_BEHAVIOR_BG_SUCCESS;
|
||||
}
|
||||
|
||||
osSyncPrintf("....change door camera ID %d (set %d)\n", camera->bgCamIndex, camera->setting);
|
||||
PRINTF("....change door camera ID %d (set %d)\n", camera->bgCamIndex, camera->setting);
|
||||
}
|
||||
|
||||
Camera_CopyDataToRegs(camera, camera->mode);
|
||||
|
@ -8409,7 +8402,7 @@ void Camera_SetCameraData(Camera* camera, s16 setDataFlags, void* data0, void* d
|
|||
}
|
||||
|
||||
if (setDataFlags & 0x10) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera: setCameraData: last argument not alive!\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera: setCameraData: last argument not alive!\n" VT_RST);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -811,7 +811,7 @@ static DamageTable sDamageTablePresets[] = {
|
|||
// Gets the pointer to one of the 23 preset damage tables. Returns NULL if index is out of range.
|
||||
DamageTable* DamageTable_Get(s32 index) {
|
||||
if (!(0 <= index && index < ARRAY_COUNT(sDamageTablePresets))) {
|
||||
osSyncPrintf("CollisionBtlTbl_get():インデックスオーバー\n"); // "Index over"
|
||||
PRINTF("CollisionBtlTbl_get():インデックスオーバー\n"); // "Index over"
|
||||
return NULL;
|
||||
}
|
||||
return &sDamageTablePresets[index];
|
||||
|
|
|
@ -340,9 +340,9 @@ s32 Collider_SetJntSphToActor(PlayState* play, ColliderJntSph* dest, ColliderJnt
|
|||
|
||||
if (dest->elements == NULL) {
|
||||
dest->count = 0;
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("ClObjJntSph_set():zelda_malloc()出来ません。\n"); // "Can not."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("ClObjJntSph_set():zelda_malloc()出来ません。\n"); // "Can not."
|
||||
PRINTF(VT_RST);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -368,9 +368,9 @@ s32 Collider_SetJntSphAllocType1(PlayState* play, ColliderJntSph* dest, Actor* a
|
|||
|
||||
if (dest->elements == NULL) {
|
||||
dest->count = 0;
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("ClObjJntSph_set3():zelda_malloc_出来ません。\n"); // "Can not."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("ClObjJntSph_set3():zelda_malloc_出来ません。\n"); // "Can not."
|
||||
PRINTF(VT_RST);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -396,9 +396,9 @@ s32 Collider_SetJntSphAlloc(PlayState* play, ColliderJntSph* dest, Actor* actor,
|
|||
|
||||
if (dest->elements == NULL) {
|
||||
dest->count = 0;
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("ClObjJntSph_set5():zelda_malloc出来ません\n"); // "Can not."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("ClObjJntSph_set5():zelda_malloc出来ません\n"); // "Can not."
|
||||
PRINTF(VT_RST);
|
||||
return false;
|
||||
}
|
||||
for (destElem = dest->elements, srcElem = src->elements; destElem < dest->elements + dest->count;
|
||||
|
@ -702,9 +702,9 @@ s32 Collider_SetTrisAllocType1(PlayState* play, ColliderTris* dest, Actor* actor
|
|||
dest->elements = ZELDA_ARENA_MALLOC(dest->count * sizeof(ColliderTrisElement), "../z_collision_check.c", 2156);
|
||||
if (dest->elements == NULL) {
|
||||
dest->count = 0;
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("ClObjTris_set3():zelda_malloc()出来ません\n"); // "Can not."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("ClObjTris_set3():zelda_malloc()出来ません\n"); // "Can not."
|
||||
PRINTF(VT_RST);
|
||||
return false;
|
||||
}
|
||||
for (destElem = dest->elements, srcElem = src->elements; destElem < dest->elements + dest->count;
|
||||
|
@ -728,9 +728,9 @@ s32 Collider_SetTrisAlloc(PlayState* play, ColliderTris* dest, Actor* actor, Col
|
|||
dest->elements = ZELDA_ARENA_MALLOC(dest->count * sizeof(ColliderTrisElement), "../z_collision_check.c", 2207);
|
||||
|
||||
if (dest->elements == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("ClObjTris_set5():zelda_malloc出来ません\n"); // "Can not."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("ClObjTris_set5():zelda_malloc出来ません\n"); // "Can not."
|
||||
PRINTF(VT_RST);
|
||||
dest->count = 0;
|
||||
return false;
|
||||
}
|
||||
|
@ -1155,7 +1155,7 @@ s32 CollisionCheck_SetAT(PlayState* play, CollisionCheckContext* colChkCtx, Coll
|
|||
}
|
||||
if (colChkCtx->colATCount >= COLLISION_CHECK_AT_MAX) {
|
||||
// "Index exceeded and cannot add more"
|
||||
osSyncPrintf("CollisionCheck_setAT():インデックスがオーバーして追加不能\n");
|
||||
PRINTF("CollisionCheck_setAT():インデックスがオーバーして追加不能\n");
|
||||
return -1;
|
||||
}
|
||||
if (colChkCtx->sacFlags & SAC_ENABLE) {
|
||||
|
@ -1183,14 +1183,14 @@ s32 CollisionCheck_SetAT_SAC(PlayState* play, CollisionCheckContext* colChkCtx,
|
|||
if (colChkCtx->sacFlags & SAC_ENABLE) {
|
||||
if (!(index < colChkCtx->colATCount)) {
|
||||
// "You are trying to register a location that is larger than the total number of data."
|
||||
osSyncPrintf("CollisionCheck_setAT_SAC():全データ数より大きいところに登録しようとしている。\n");
|
||||
PRINTF("CollisionCheck_setAT_SAC():全データ数より大きいところに登録しようとしている。\n");
|
||||
return -1;
|
||||
}
|
||||
colChkCtx->colAT[index] = collider;
|
||||
} else {
|
||||
if (!(colChkCtx->colATCount < COLLISION_CHECK_AT_MAX)) {
|
||||
// "Index exceeded and cannot add more"
|
||||
osSyncPrintf("CollisionCheck_setAT():インデックスがオーバーして追加不能\n");
|
||||
PRINTF("CollisionCheck_setAT():インデックスがオーバーして追加不能\n");
|
||||
return -1;
|
||||
}
|
||||
index = colChkCtx->colATCount;
|
||||
|
@ -1223,7 +1223,7 @@ s32 CollisionCheck_SetAC(PlayState* play, CollisionCheckContext* colChkCtx, Coll
|
|||
}
|
||||
if (colChkCtx->colACCount >= COLLISION_CHECK_AC_MAX) {
|
||||
// "Index exceeded and cannot add more"
|
||||
osSyncPrintf("CollisionCheck_setAC():インデックスがオーバして追加不能\n");
|
||||
PRINTF("CollisionCheck_setAC():インデックスがオーバして追加不能\n");
|
||||
return -1;
|
||||
}
|
||||
if (colChkCtx->sacFlags & SAC_ENABLE) {
|
||||
|
@ -1251,14 +1251,14 @@ s32 CollisionCheck_SetAC_SAC(PlayState* play, CollisionCheckContext* colChkCtx,
|
|||
if (colChkCtx->sacFlags & SAC_ENABLE) {
|
||||
if (!(index < colChkCtx->colACCount)) {
|
||||
// "You are trying to register a location that is larger than the total number of data."
|
||||
osSyncPrintf("CollisionCheck_setAC_SAC():全データ数より大きいところに登録しようとしている。\n");
|
||||
PRINTF("CollisionCheck_setAC_SAC():全データ数より大きいところに登録しようとしている。\n");
|
||||
return -1;
|
||||
}
|
||||
colChkCtx->colAC[index] = collider;
|
||||
} else {
|
||||
if (!(colChkCtx->colACCount < COLLISION_CHECK_AC_MAX)) {
|
||||
// "Index exceeded and cannot add more"
|
||||
osSyncPrintf("CollisionCheck_setAC():インデックスがオーバして追加不能\n");
|
||||
PRINTF("CollisionCheck_setAC():インデックスがオーバして追加不能\n");
|
||||
return -1;
|
||||
}
|
||||
index = colChkCtx->colACCount;
|
||||
|
@ -1293,7 +1293,7 @@ s32 CollisionCheck_SetOC(PlayState* play, CollisionCheckContext* colChkCtx, Coll
|
|||
}
|
||||
if (colChkCtx->colOCCount >= COLLISION_CHECK_OC_MAX) {
|
||||
// "Index exceeded and cannot add more"
|
||||
osSyncPrintf("CollisionCheck_setOC():インデックスがオーバして追加不能\n");
|
||||
PRINTF("CollisionCheck_setOC():インデックスがオーバして追加不能\n");
|
||||
return -1;
|
||||
}
|
||||
if (colChkCtx->sacFlags & SAC_ENABLE) {
|
||||
|
@ -1321,7 +1321,7 @@ s32 CollisionCheck_SetOC_SAC(PlayState* play, CollisionCheckContext* colChkCtx,
|
|||
if (colChkCtx->sacFlags & SAC_ENABLE) {
|
||||
if (!(index < colChkCtx->colOCCount)) {
|
||||
// "You are trying to register a location that is larger than the total number of data."
|
||||
osSyncPrintf("CollisionCheck_setOC_SAC():全データ数より大きいところに登録しようとしている。\n");
|
||||
PRINTF("CollisionCheck_setOC_SAC():全データ数より大きいところに登録しようとしている。\n");
|
||||
return -1;
|
||||
}
|
||||
//! @bug Should be colOC
|
||||
|
@ -1329,7 +1329,7 @@ s32 CollisionCheck_SetOC_SAC(PlayState* play, CollisionCheckContext* colChkCtx,
|
|||
} else {
|
||||
if (!(colChkCtx->colOCCount < COLLISION_CHECK_OC_MAX)) {
|
||||
// "Index exceeded and cannot add more"
|
||||
osSyncPrintf("CollisionCheck_setOC():インデックスがオーバして追加不能\n");
|
||||
PRINTF("CollisionCheck_setOC():インデックスがオーバして追加不能\n");
|
||||
return -1;
|
||||
}
|
||||
index = colChkCtx->colOCCount;
|
||||
|
@ -1351,7 +1351,7 @@ s32 CollisionCheck_SetOCLine(PlayState* play, CollisionCheckContext* colChkCtx,
|
|||
Collider_ResetLineOC(play, collider);
|
||||
if (!(colChkCtx->colLineCount < COLLISION_CHECK_OC_LINE_MAX)) {
|
||||
// "Index exceeded and cannot add more"
|
||||
osSyncPrintf("CollisionCheck_setOCLine():インデックスがオーバして追加不能\n");
|
||||
PRINTF("CollisionCheck_setOCLine():インデックスがオーバして追加不能\n");
|
||||
return -1;
|
||||
}
|
||||
index = colChkCtx->colLineCount;
|
||||
|
@ -2959,7 +2959,7 @@ void CollisionCheck_OC(PlayState* play, CollisionCheckContext* colChkCtx) {
|
|||
vsFunc = sOCVsFuncs[(*leftColP)->shape][(*rightColP)->shape];
|
||||
if (vsFunc == NULL) {
|
||||
// "Not compatible"
|
||||
osSyncPrintf("CollisionCheck_OC():未対応 %d, %d\n", (*leftColP)->shape, (*rightColP)->shape);
|
||||
PRINTF("CollisionCheck_OC():未対応 %d, %d\n", (*leftColP)->shape, (*rightColP)->shape);
|
||||
continue;
|
||||
}
|
||||
vsFunc(play, colChkCtx, *leftColP, *rightColP);
|
||||
|
@ -3220,7 +3220,7 @@ s32 CollisionCheck_LineOC(PlayState* play, CollisionCheckContext* colChkCtx, Vec
|
|||
lineCheck = sOCLineCheckFuncs[(*col)->shape];
|
||||
if (lineCheck == NULL) {
|
||||
// "type %d not supported"
|
||||
osSyncPrintf("CollisionCheck_generalLineOcCheck():未対応 %dタイプ\n", (*col)->shape);
|
||||
PRINTF("CollisionCheck_generalLineOcCheck():未対応 %dタイプ\n", (*col)->shape);
|
||||
} else {
|
||||
result = lineCheck(play, colChkCtx, (*col), a, b);
|
||||
if (result) {
|
||||
|
|
|
@ -32,11 +32,11 @@ void Interface_Init(PlayState* play) {
|
|||
parameterSize = (uintptr_t)_parameter_staticSegmentRomEnd - (uintptr_t)_parameter_staticSegmentRomStart;
|
||||
|
||||
// "Permanent PARAMETER Segment = %x"
|
||||
osSyncPrintf("常駐PARAMETERセグメント=%x\n", parameterSize);
|
||||
PRINTF("常駐PARAMETERセグメント=%x\n", parameterSize);
|
||||
|
||||
interfaceCtx->parameterSegment = GAME_STATE_ALLOC(&play->state, parameterSize, "../z_construct.c", 159);
|
||||
|
||||
osSyncPrintf("parameter->parameterSegment=%x\n", interfaceCtx->parameterSegment);
|
||||
PRINTF("parameter->parameterSegment=%x\n", interfaceCtx->parameterSegment);
|
||||
|
||||
ASSERT(interfaceCtx->parameterSegment != NULL, "parameter->parameterSegment != NULL", "../z_construct.c", 161);
|
||||
DMA_REQUEST_SYNC(interfaceCtx->parameterSegment, (uintptr_t)_parameter_staticSegmentRomStart, parameterSize,
|
||||
|
@ -44,8 +44,8 @@ void Interface_Init(PlayState* play) {
|
|||
|
||||
interfaceCtx->doActionSegment = GAME_STATE_ALLOC(&play->state, 3 * DO_ACTION_TEX_SIZE, "../z_construct.c", 166);
|
||||
|
||||
osSyncPrintf("DOアクション テクスチャ初期=%x\n", 3 * DO_ACTION_TEX_SIZE); // "DO Action Texture Initialization"
|
||||
osSyncPrintf("parameter->do_actionSegment=%x\n", interfaceCtx->doActionSegment);
|
||||
PRINTF("DOアクション テクスチャ初期=%x\n", 3 * DO_ACTION_TEX_SIZE); // "DO Action Texture Initialization"
|
||||
PRINTF("parameter->do_actionSegment=%x\n", interfaceCtx->doActionSegment);
|
||||
|
||||
ASSERT(interfaceCtx->doActionSegment != NULL, "parameter->do_actionSegment != NULL", "../z_construct.c", 169);
|
||||
|
||||
|
@ -75,14 +75,14 @@ void Interface_Init(PlayState* play) {
|
|||
interfaceCtx->iconItemSegment = GAME_STATE_ALLOC(&play->state, ICON_ITEM_SEGMENT_SIZE, "../z_construct.c", 190);
|
||||
|
||||
// "Icon Item Texture Initialization = %x"
|
||||
osSyncPrintf("アイコンアイテム テクスチャ初期=%x\n", ICON_ITEM_SEGMENT_SIZE);
|
||||
osSyncPrintf("parameter->icon_itemSegment=%x\n", interfaceCtx->iconItemSegment);
|
||||
PRINTF("アイコンアイテム テクスチャ初期=%x\n", ICON_ITEM_SEGMENT_SIZE);
|
||||
PRINTF("parameter->icon_itemSegment=%x\n", interfaceCtx->iconItemSegment);
|
||||
|
||||
ASSERT(interfaceCtx->iconItemSegment != NULL, "parameter->icon_itemSegment != NULL", "../z_construct.c", 193);
|
||||
|
||||
osSyncPrintf("Register_Item[%x, %x, %x, %x]\n", gSaveContext.save.info.equips.buttonItems[0],
|
||||
gSaveContext.save.info.equips.buttonItems[1], gSaveContext.save.info.equips.buttonItems[2],
|
||||
gSaveContext.save.info.equips.buttonItems[3]);
|
||||
PRINTF("Register_Item[%x, %x, %x, %x]\n", gSaveContext.save.info.equips.buttonItems[0],
|
||||
gSaveContext.save.info.equips.buttonItems[1], gSaveContext.save.info.equips.buttonItems[2],
|
||||
gSaveContext.save.info.equips.buttonItems[3]);
|
||||
|
||||
if (gSaveContext.save.info.equips.buttonItems[0] < 0xF0) {
|
||||
DMA_REQUEST_SYNC(interfaceCtx->iconItemSegment + (0 * ITEM_ICON_SIZE),
|
||||
|
@ -114,13 +114,13 @@ void Interface_Init(PlayState* play) {
|
|||
"../z_construct.c", 219);
|
||||
}
|
||||
|
||||
osSyncPrintf("EVENT=%d\n", ((void)0, gSaveContext.timerState));
|
||||
PRINTF("EVENT=%d\n", ((void)0, gSaveContext.timerState));
|
||||
|
||||
if ((gSaveContext.timerState == TIMER_STATE_ENV_HAZARD_TICK) ||
|
||||
(gSaveContext.timerState == TIMER_STATE_DOWN_TICK) ||
|
||||
(gSaveContext.subTimerState == SUBTIMER_STATE_DOWN_TICK) ||
|
||||
(gSaveContext.subTimerState == SUBTIMER_STATE_UP_TICK)) {
|
||||
osSyncPrintf("restart_flag=%d\n", ((void)0, gSaveContext.respawnFlag));
|
||||
PRINTF("restart_flag=%d\n", ((void)0, gSaveContext.respawnFlag));
|
||||
|
||||
if ((gSaveContext.respawnFlag == -1) || (gSaveContext.respawnFlag == 1)) {
|
||||
if (gSaveContext.timerState == TIMER_STATE_ENV_HAZARD_TICK) {
|
||||
|
@ -149,10 +149,10 @@ void Interface_Init(PlayState* play) {
|
|||
if ((gSaveContext.timerState >= TIMER_STATE_UP_INIT) && (gSaveContext.timerState <= TIMER_STATE_UP_FREEZE)) {
|
||||
gSaveContext.timerState = TIMER_STATE_OFF;
|
||||
// "Timer Stop!!!!!!!!!!!!!!!!!!!!!!"
|
||||
osSyncPrintf("タイマー停止!!!!!!!!!!!!!!!!!!!!! = %d\n", gSaveContext.timerState);
|
||||
PRINTF("タイマー停止!!!!!!!!!!!!!!!!!!!!! = %d\n", gSaveContext.timerState);
|
||||
}
|
||||
|
||||
osSyncPrintf("PARAMETER領域=%x\n", parameterSize + 0x5300); // "Parameter Area = %x"
|
||||
PRINTF("PARAMETER領域=%x\n", parameterSize + 0x5300); // "Parameter Area = %x"
|
||||
|
||||
Health_InitMeter(play);
|
||||
Map_Init(play);
|
||||
|
@ -192,9 +192,9 @@ void Message_Init(PlayState* play) {
|
|||
|
||||
msgCtx->textboxSegment = GAME_STATE_ALLOC(&play->state, TEXTBOX_SEGMENT_SIZE, "../z_construct.c", 349);
|
||||
|
||||
osSyncPrintf("message->fukidashiSegment=%x\n", msgCtx->textboxSegment);
|
||||
PRINTF("message->fukidashiSegment=%x\n", msgCtx->textboxSegment);
|
||||
|
||||
osSyncPrintf("吹き出しgame_alloc=%x\n", TEXTBOX_SEGMENT_SIZE); // "Textbox game_alloc=%x"
|
||||
PRINTF("吹き出しgame_alloc=%x\n", TEXTBOX_SEGMENT_SIZE); // "Textbox game_alloc=%x"
|
||||
ASSERT(msgCtx->textboxSegment != NULL, "message->fukidashiSegment != NULL", "../z_construct.c", 352);
|
||||
|
||||
Font_LoadOrderedFont(&play->msgCtx.font);
|
||||
|
|
|
@ -193,7 +193,7 @@ void Cutscene_UpdateScripted(PlayState* play, CutsceneContext* csCtx) {
|
|||
}
|
||||
|
||||
if ((gSaveContext.cutsceneTrigger != 0) && (csCtx->state == CS_STATE_IDLE)) {
|
||||
osSyncPrintf("\nデモ開始要求 発令!"); // "Cutscene start request announcement!"
|
||||
PRINTF("\nデモ開始要求 発令!"); // "Cutscene start request announcement!"
|
||||
gSaveContext.save.cutsceneIndex = 0xFFFD;
|
||||
gSaveContext.cutsceneTrigger = 1;
|
||||
}
|
||||
|
@ -568,7 +568,7 @@ void CutsceneCmd_Destination(PlayState* play, CutsceneContext* csCtx, CsCmdDesti
|
|||
Audio_SetCutsceneFlag(0);
|
||||
gSaveContext.cutsceneTransitionControl = 1;
|
||||
|
||||
osSyncPrintf("\n分岐先指定!!=[%d]番", cmd->destination); // "Future fork designation=No. [%d]"
|
||||
PRINTF("\n分岐先指定!!=[%d]番", cmd->destination); // "Future fork designation=No. [%d]"
|
||||
|
||||
// `forceRisingButtonAlphas` has a secondary purpose, which is to signal to the title screen actor
|
||||
// that it should display immediately. This occurs when a title screen cutscene that is not the main
|
||||
|
@ -2238,7 +2238,7 @@ void CutsceneHandler_StopScript(PlayState* play, CutsceneContext* csCtx) {
|
|||
csCtx->actorCues[i] = NULL;
|
||||
}
|
||||
|
||||
osSyncPrintf("\n\n\n\n\nやっぱりここかいな"); // "Right here, huh"
|
||||
PRINTF("\n\n\n\n\nやっぱりここかいな"); // "Right here, huh"
|
||||
|
||||
gSaveContext.save.cutsceneIndex = 0;
|
||||
gSaveContext.gameMode = GAMEMODE_NORMAL;
|
||||
|
@ -2363,7 +2363,7 @@ void Cutscene_HandleEntranceTriggers(PlayState* play) {
|
|||
}
|
||||
|
||||
void Cutscene_HandleConditionalTriggers(PlayState* play) {
|
||||
osSyncPrintf("\ngame_info.mode=[%d] restart_flag", ((void)0, gSaveContext.respawnFlag));
|
||||
PRINTF("\ngame_info.mode=[%d] restart_flag", ((void)0, gSaveContext.respawnFlag));
|
||||
|
||||
if ((gSaveContext.gameMode == GAMEMODE_NORMAL) && (gSaveContext.respawnFlag <= 0) &&
|
||||
(gSaveContext.save.cutsceneIndex < 0xFFF0)) {
|
||||
|
|
|
@ -19,7 +19,7 @@ void EffectBlure_AddVertex(EffectBlure* this, Vec3f* p1, Vec3f* p2) {
|
|||
numElements = this->numElements;
|
||||
if (numElements >= 16) {
|
||||
// "Blure vertex addition processing: Table over %d"
|
||||
osSyncPrintf("ブラ─頂点追加処理:テーブルオーバー %d\n", numElements);
|
||||
PRINTF("ブラ─頂点追加処理:テーブルオーバー %d\n", numElements);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -77,7 +77,7 @@ void EffectBlure_AddSpace(EffectBlure* this) {
|
|||
numElements = this->numElements;
|
||||
if (numElements >= 16) {
|
||||
// "Blure space addition processing: Table over %d"
|
||||
osSyncPrintf("ブラ─空白追加処理:テーブルオーバー %d\n", numElements);
|
||||
PRINTF("ブラ─空白追加処理:テーブルオーバー %d\n", numElements);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -396,7 +396,7 @@ void EffectBlure_DrawElemNoInterpolation(EffectBlure* this, EffectBlureElement*
|
|||
vtx = GRAPH_ALLOC(gfxCtx, sizeof(Vtx[4]));
|
||||
if (vtx == NULL) {
|
||||
// "Vertices cannot be secured."
|
||||
osSyncPrintf("z_eff_blure.c::SQ_NoInterpolate_disp() 頂点確保できず。\n");
|
||||
PRINTF("z_eff_blure.c::SQ_NoInterpolate_disp() 頂点確保できず。\n");
|
||||
} else {
|
||||
vtx[0].v = baseVtx;
|
||||
vtx[1].v = baseVtx;
|
||||
|
@ -557,7 +557,7 @@ void EffectBlure_DrawElemHermiteInterpolation(EffectBlure* this, EffectBlureElem
|
|||
vtx = GRAPH_ALLOC(gfxCtx, sizeof(Vtx[16]));
|
||||
if (vtx == NULL) {
|
||||
// "Vertices cannot be secured."
|
||||
osSyncPrintf("z_eff_blure.c::SQ_HermiteInterpolate_disp() 頂点確保できず。\n");
|
||||
PRINTF("z_eff_blure.c::SQ_HermiteInterpolate_disp() 頂点確保できず。\n");
|
||||
} else {
|
||||
Math_Vec3f_Diff(&sp1CC, &sp138, &sp158);
|
||||
Math_Vec3f_Scale(&sp158, 10.0f);
|
||||
|
@ -800,7 +800,7 @@ void EffectBlure_DrawSimpleVertices(GraphicsContext* gfxCtx, EffectBlure* this,
|
|||
mtx = SkinMatrix_MtxFToNewMtx(gfxCtx, &sp94);
|
||||
if (mtx == NULL) {
|
||||
// "Forced termination because a matrix cannot be taken"
|
||||
osSyncPrintf("EffectBlureInfo2_disp_makeDisplayList()マトリックス取れないので,強制終了\n");
|
||||
PRINTF("EffectBlureInfo2_disp_makeDisplayList()マトリックス取れないので,強制終了\n");
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -852,7 +852,7 @@ void EffectBlure_DrawSimple(EffectBlure* this2, GraphicsContext* gfxCtx) {
|
|||
vtx = GRAPH_ALLOC(gfxCtx, vtxCount * sizeof(Vtx));
|
||||
if (vtx == NULL) {
|
||||
// "Vertices cannot be secured. Forced termination"
|
||||
osSyncPrintf("ブラ─表示:頂点確保できず。強制終了\n");
|
||||
PRINTF("ブラ─表示:頂点確保できず。強制終了\n");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -946,7 +946,7 @@ void EffectBlure_Draw(void* thisx, GraphicsContext* gfxCtx) {
|
|||
vtx = GRAPH_ALLOC(gfxCtx, sizeof(Vtx[32]));
|
||||
if (vtx == NULL) {
|
||||
// "Blure display: Vertex table could not be secured"
|
||||
osSyncPrintf("ブラ─表示:頂点テーブル確保できず\n");
|
||||
PRINTF("ブラ─表示:頂点テーブル確保できず\n");
|
||||
} else {
|
||||
j = 0;
|
||||
for (i = 0; i < this->numElements; i++) {
|
||||
|
|
|
@ -18,9 +18,9 @@ void EffectShieldParticle_Init(void* thisx, void* initParamsx) {
|
|||
if ((this != NULL) && (initParams != NULL)) {
|
||||
this->numElements = initParams->numElements;
|
||||
if (this->numElements > ARRAY_COUNT(this->elements)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("EffectShieldParticle_ct():パーティクル数がオーバしてます。\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("EffectShieldParticle_ct():パーティクル数がオーバしてます。\n");
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ void EffectSpark_Init(void* thisx, void* initParamsx) {
|
|||
|
||||
if ((this != NULL) && (initParams != NULL)) {
|
||||
if ((initParams->uDiv == 0) || (initParams->vDiv == 0)) {
|
||||
osSyncPrintf("spark():u_div,v_div 0では困る。\n"); // "u_div,v_div 0 is not good."
|
||||
PRINTF("spark():u_div,v_div 0では困る。\n"); // "u_div,v_div 0 is not good."
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -56,7 +56,7 @@ void EffectSpark_Init(void* thisx, void* initParamsx) {
|
|||
|
||||
this->numElements = (this->uDiv * this->vDiv) + 2;
|
||||
if (this->numElements > ARRAY_COUNT(this->elements)) {
|
||||
osSyncPrintf("table_sizeオーバー\n"); // "over table_size"
|
||||
PRINTF("table_sizeオーバー\n"); // "over table_size"
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -103,7 +103,7 @@ s32 EffectSpark_Update(void* thisx) {
|
|||
s32 i;
|
||||
|
||||
if (this == NULL) {
|
||||
osSyncPrintf("EffectSparkInfo_proc():Spark Pointer is NULL\n");
|
||||
PRINTF("EffectSparkInfo_proc():Spark Pointer is NULL\n");
|
||||
}
|
||||
|
||||
for (i = 0; i < this->numElements; i++) {
|
||||
|
@ -174,7 +174,7 @@ void EffectSpark_Draw(void* thisx, GraphicsContext* gfxCtx) {
|
|||
vertices = GRAPH_ALLOC(gfxCtx, this->numElements * sizeof(Vtx[4]));
|
||||
if (vertices == NULL) {
|
||||
// "Memory Allocation Failure graph_malloc"
|
||||
osSyncPrintf("EffectSparkInfo_disp():メモリー確保失敗 graph_malloc\n");
|
||||
PRINTF("EffectSparkInfo_disp():メモリー確保失敗 graph_malloc\n");
|
||||
goto end;
|
||||
}
|
||||
|
||||
|
|
|
@ -145,8 +145,8 @@ void Effect_Add(PlayState* play, s32* pIndex, s32 type, u8 arg3, u8 arg4, void*
|
|||
|
||||
if (!slotFound) {
|
||||
// "EffectAdd(): I cannot secure it. Be careful. Type %d"
|
||||
osSyncPrintf("EffectAdd():確保できません。注意してください。Type%d\n", type);
|
||||
osSyncPrintf("エフェクト追加せずに終了します。\n"); // "Exit without adding the effect."
|
||||
PRINTF("EffectAdd():確保できません。注意してください。Type%d\n", type);
|
||||
PRINTF("エフェクト追加せずに終了します。\n"); // "Exit without adding the effect."
|
||||
} else {
|
||||
sEffectInfoTable[type].init(effect, initParams);
|
||||
status->unk_02 = arg3;
|
||||
|
@ -238,7 +238,7 @@ void Effect_Delete(PlayState* play, s32 index) {
|
|||
void Effect_DeleteAll(PlayState* play) {
|
||||
s32 i;
|
||||
|
||||
osSyncPrintf("エフェクト総て解放\n"); // "All effect release"
|
||||
PRINTF("エフェクト総て解放\n"); // "All effect release"
|
||||
|
||||
for (i = 0; i < SPARK_COUNT; i++) {
|
||||
sEffectContext.sparks[i].status.active = false;
|
||||
|
@ -255,5 +255,5 @@ void Effect_DeleteAll(PlayState* play) {
|
|||
sEffectInfoTable[EFFECT_SHIELD_PARTICLE].destroy(&sEffectContext.shieldParticles[i].effect);
|
||||
}
|
||||
|
||||
osSyncPrintf("エフェクト総て解放 終了\n"); // "All effects release End"
|
||||
PRINTF("エフェクト総て解放 終了\n"); // "All effects release End"
|
||||
}
|
||||
|
|
|
@ -10,9 +10,8 @@ void EffectSs_InitInfo(PlayState* play, s32 tableSize) {
|
|||
|
||||
for (i = 0; i < ARRAY_COUNT(gEffectSsOverlayTable); i++) {
|
||||
overlay = &gEffectSsOverlayTable[i];
|
||||
osSyncPrintf("effect index %3d:size=%6dbyte romsize=%6dbyte\n", i,
|
||||
(uintptr_t)overlay->vramEnd - (uintptr_t)overlay->vramStart,
|
||||
overlay->vromEnd - overlay->vromStart);
|
||||
PRINTF("effect index %3d:size=%6dbyte romsize=%6dbyte\n", i,
|
||||
(uintptr_t)overlay->vramEnd - (uintptr_t)overlay->vramStart, overlay->vromEnd - overlay->vromStart);
|
||||
}
|
||||
|
||||
sEffectSsInfo.table =
|
||||
|
@ -186,32 +185,32 @@ void EffectSs_Spawn(PlayState* play, s32 type, s32 priority, void* initParams) {
|
|||
|
||||
if (overlayEntry->vramStart == NULL) {
|
||||
// "Not an overlay"
|
||||
osSyncPrintf("EffectSoftSprite2_makeEffect():オーバーレイではありません。\n");
|
||||
PRINTF("EffectSoftSprite2_makeEffect():オーバーレイではありません。\n");
|
||||
initInfo = overlayEntry->initInfo;
|
||||
} else {
|
||||
if (overlayEntry->loadedRamAddr == NULL) {
|
||||
overlayEntry->loadedRamAddr = ZELDA_ARENA_MALLOC_R(overlaySize, "../z_effect_soft_sprite.c", 585);
|
||||
|
||||
if (overlayEntry->loadedRamAddr == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "The memory of %d byte cannot be secured. Therefore, the program cannot be loaded.
|
||||
// What a dangerous situation! Naturally, effects will not produced either."
|
||||
osSyncPrintf("EffectSoftSprite2_makeEffect():zelda_malloc_r()により,%"
|
||||
"dbyteのメモリ確保ができま\nせん。そのため、プログラムのロードも\n出来ません。ただいま危険"
|
||||
"な状態です!\nもちろん,エフェクトも出ません。\n",
|
||||
overlaySize);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("EffectSoftSprite2_makeEffect():zelda_malloc_r()により,%"
|
||||
"dbyteのメモリ確保ができま\nせん。そのため、プログラムのロードも\n出来ません。ただいま危険"
|
||||
"な状態です!\nもちろん,エフェクトも出ません。\n",
|
||||
overlaySize);
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
|
||||
Overlay_Load(overlayEntry->vromStart, overlayEntry->vromEnd, overlayEntry->vramStart, overlayEntry->vramEnd,
|
||||
overlayEntry->loadedRamAddr);
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("EFFECT SS OVL:SegRom %08x %08x, Seg %08x %08x, RamStart %08x, type: %d\n",
|
||||
overlayEntry->vromStart, overlayEntry->vromEnd, overlayEntry->vramStart, overlayEntry->vramEnd,
|
||||
overlayEntry->loadedRamAddr, type);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("EFFECT SS OVL:SegRom %08x %08x, Seg %08x %08x, RamStart %08x, type: %d\n", overlayEntry->vromStart,
|
||||
overlayEntry->vromEnd, overlayEntry->vramStart, overlayEntry->vramEnd, overlayEntry->loadedRamAddr,
|
||||
type);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
initInfo = (void*)(uintptr_t)((overlayEntry->initInfo != NULL)
|
||||
|
@ -224,9 +223,9 @@ void EffectSs_Spawn(PlayState* play, s32 type, s32 priority, void* initParams) {
|
|||
if (initInfo->init == NULL) {
|
||||
// "Effects have already been loaded, but the constructor is NULL so the addition will not occur.
|
||||
// Please fix this. (Waste of memory) %08x %d"
|
||||
osSyncPrintf("EffectSoftSprite2_makeEffect():すでにエフェクトはロード済みで\nすが,"
|
||||
"コンストラクターがNULLなので追加をやめます。\n直してください。(メモリーの無駄) %08x %d\n",
|
||||
initInfo, type);
|
||||
PRINTF("EffectSoftSprite2_makeEffect():すでにエフェクトはロード済みで\nすが,"
|
||||
"コンストラクターがNULLなので追加をやめます。\n直してください。(メモリーの無駄) %08x %d\n",
|
||||
initInfo, type);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -237,13 +236,13 @@ void EffectSs_Spawn(PlayState* play, s32 type, s32 priority, void* initParams) {
|
|||
sEffectSsInfo.table[index].priority = priority;
|
||||
|
||||
if (initInfo->init(play, index, &sEffectSsInfo.table[index], initParams) == 0) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "Construction failed for some reason. The constructor returned an error.
|
||||
// Ceasing effect addition."
|
||||
osSyncPrintf("EffectSoftSprite2_makeEffect():"
|
||||
"何らかの理由でコンストラクト失敗。コンストラクターがエラーを返しました。エフェクトの追加を中"
|
||||
"止します。\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("EffectSoftSprite2_makeEffect():"
|
||||
"何らかの理由でコンストラクト失敗。コンストラクターがエラーを返しました。エフェクトの追加を中"
|
||||
"止します。\n");
|
||||
PRINTF(VT_RST);
|
||||
EffectSs_Reset(&sEffectSsInfo.table[index]);
|
||||
}
|
||||
}
|
||||
|
@ -303,19 +302,19 @@ void EffectSs_DrawAll(PlayState* play) {
|
|||
if ((sEffectSsInfo.table[i].pos.x > 32000.0f) || (sEffectSsInfo.table[i].pos.x < -32000.0f) ||
|
||||
(sEffectSsInfo.table[i].pos.y > 32000.0f) || (sEffectSsInfo.table[i].pos.y < -32000.0f) ||
|
||||
(sEffectSsInfo.table[i].pos.z > 32000.0f) || (sEffectSsInfo.table[i].pos.z < -32000.0f)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Since the position is outside the area, delete it.
|
||||
// Effect label No. %d: Please respond by the program.
|
||||
// Here is ==> pos (%f, %f, %f) and the label is in z_effect_soft_sprite_dlftbls.decl."
|
||||
osSyncPrintf("EffectSoftSprite2_disp():位置が領域外のため "
|
||||
"削除します。エフェクトラベルNo.%d:プログラムの方で対応をお願いします。ここです ==> "
|
||||
"pos(%f, %f, %f)で、ラベルはz_effect_soft_sprite_dlftbls.declにあります。\n",
|
||||
sEffectSsInfo.table[i].type, sEffectSsInfo.table[i].pos.x, sEffectSsInfo.table[i].pos.y,
|
||||
sEffectSsInfo.table[i].pos.z);
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF("EffectSoftSprite2_disp():位置が領域外のため "
|
||||
"削除します。エフェクトラベルNo.%d:プログラムの方で対応をお願いします。ここです ==> "
|
||||
"pos(%f, %f, %f)で、ラベルはz_effect_soft_sprite_dlftbls.declにあります。\n",
|
||||
sEffectSsInfo.table[i].type, sEffectSsInfo.table[i].pos.x, sEffectSsInfo.table[i].pos.y,
|
||||
sEffectSsInfo.table[i].pos.z);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "If you are using pos for something else, consult me."
|
||||
osSyncPrintf("もし、posを別のことに使っている場合相談に応じます。\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("もし、posを別のことに使っている場合相談に応じます。\n");
|
||||
PRINTF(VT_RST);
|
||||
|
||||
EffectSs_Delete(&sEffectSsInfo.table[i]);
|
||||
} else {
|
||||
|
|
|
@ -128,8 +128,8 @@ void TransitionTile_InitVtxData(TransitionTile* this) {
|
|||
}
|
||||
|
||||
void TransitionTile_Destroy(TransitionTile* this) {
|
||||
osSyncPrintf("fbdemo_cleanup(%08x)\n", this);
|
||||
osSyncPrintf("msleep(100);\n");
|
||||
PRINTF("fbdemo_cleanup(%08x)\n", this);
|
||||
PRINTF("msleep(100);\n");
|
||||
Sleep_Msec(100);
|
||||
|
||||
if (this->vtxData != NULL) {
|
||||
|
@ -151,7 +151,7 @@ void TransitionTile_Destroy(TransitionTile* this) {
|
|||
}
|
||||
|
||||
TransitionTile* TransitionTile_Init(TransitionTile* this, s32 cols, s32 rows) {
|
||||
osSyncPrintf("fbdemo_init(%08x, %d, %d)\n", this, cols, rows);
|
||||
PRINTF("fbdemo_init(%08x, %d, %d)\n", this, cols, rows);
|
||||
bzero(this, sizeof(TransitionTile));
|
||||
this->frame = 0;
|
||||
this->cols = cols;
|
||||
|
@ -162,7 +162,7 @@ TransitionTile* TransitionTile_Init(TransitionTile* this, s32 cols, s32 rows) {
|
|||
this->gfx = SYSTEM_ARENA_MALLOC((this->rows * (1 + this->cols * 9) + 2) * sizeof(Gfx), "../z_fbdemo.c", 198);
|
||||
|
||||
if ((this->vtxData == NULL) || (this->vtxFrame1 == NULL) || (this->vtxFrame2 == NULL) || (this->gfx == NULL)) {
|
||||
osSyncPrintf("fbdemo_init allocation error\n");
|
||||
PRINTF("fbdemo_init allocation error\n");
|
||||
if (this->vtxData != NULL) {
|
||||
SYSTEM_ARENA_FREE(this->vtxData, "../z_fbdemo.c", 202);
|
||||
this->vtxData = NULL;
|
||||
|
|
|
@ -69,7 +69,7 @@ void TransitionFade_Update(void* thisx, s32 updateRate) {
|
|||
}
|
||||
if ((u32)gSaveContext.transFadeDuration == 0) {
|
||||
// "Divide by 0! Zero is included in ZCommonGet fade_speed"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "0除算! ZCommonGet fade_speed に0がはいってる" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "0除算! ZCommonGet fade_speed に0がはいってる" VT_RST);
|
||||
}
|
||||
|
||||
alpha = (255.0f * this->timer) / ((void)0, gSaveContext.transFadeDuration);
|
||||
|
|
|
@ -80,7 +80,7 @@ void TransitionTriforce_Draw(void* thisx, Gfx** gfxP) {
|
|||
modelView = this->modelView[this->frame];
|
||||
scale = this->transPos * 0.625f;
|
||||
this->frame ^= 1;
|
||||
osSyncPrintf("rate=%f tx=%f ty=%f rotate=%f\n", this->transPos, 0.0f, 0.0f, rotation);
|
||||
PRINTF("rate=%f tx=%f ty=%f rotate=%f\n", this->transPos, 0.0f, 0.0f, rotation);
|
||||
guScale(&modelView[0], scale, scale, 1.0f);
|
||||
guRotate(&modelView[1], rotation, 0.0f, 0.0f, 1.0f);
|
||||
guTranslate(&modelView[2], 0.0f, 0.0f, 0.0f);
|
||||
|
|
|
@ -213,7 +213,7 @@ void SkelCurve_DrawLimb(PlayState* play, s32 limbIndex, SkelCurve* skelCurve, Ov
|
|||
}
|
||||
} else {
|
||||
// "FcSkeletonInfo_draw_child (): Not supported"
|
||||
osSyncPrintf("FcSkeletonInfo_draw_child():未対応\n");
|
||||
PRINTF("FcSkeletonInfo_draw_child():未対応\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -76,8 +76,8 @@ void func_8006D0EC(PlayState* play, Player* player) {
|
|||
} else if ((play->sceneId == gSaveContext.save.info.horseData.sceneId) &&
|
||||
(Flags_GetEventChkInf(EVENTCHKINF_EPONA_OBTAINED) || DREG(1) != 0)) {
|
||||
// "Set by existence of horse %d %d %d"
|
||||
osSyncPrintf("馬存在によるセット %d %d %d\n", gSaveContext.save.info.horseData.sceneId,
|
||||
Flags_GetEventChkInf(EVENTCHKINF_EPONA_OBTAINED), DREG(1));
|
||||
PRINTF("馬存在によるセット %d %d %d\n", gSaveContext.save.info.horseData.sceneId,
|
||||
Flags_GetEventChkInf(EVENTCHKINF_EPONA_OBTAINED), DREG(1));
|
||||
|
||||
if (func_8006CFC0(gSaveContext.save.info.horseData.sceneId)) {
|
||||
Actor* horseActor =
|
||||
|
@ -89,10 +89,10 @@ void func_8006D0EC(PlayState* play, Player* player) {
|
|||
horseActor->room = -1;
|
||||
}
|
||||
} else {
|
||||
osSyncPrintf(VT_COL(RED, WHITE));
|
||||
PRINTF(VT_COL(RED, WHITE));
|
||||
// "Horse_SetNormal():%d set spot is no good."
|
||||
osSyncPrintf("Horse_SetNormal():%d セットスポットまずいです。\n", gSaveContext.save.info.horseData.sceneId);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Horse_SetNormal():%d セットスポットまずいです。\n", gSaveContext.save.info.horseData.sceneId);
|
||||
PRINTF(VT_RST);
|
||||
func_8006D074(play);
|
||||
}
|
||||
} else if ((play->sceneId == SCENE_LON_LON_RANCH) && !Flags_GetEventChkInf(EVENTCHKINF_EPONA_OBTAINED) &&
|
||||
|
@ -246,10 +246,10 @@ void func_8006D684(PlayState* play, Player* player) {
|
|||
void func_8006DC68(PlayState* play, Player* player) {
|
||||
if (LINK_IS_ADULT) {
|
||||
if (!func_8006CFC0(gSaveContext.save.info.horseData.sceneId)) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE));
|
||||
PRINTF(VT_COL(RED, WHITE));
|
||||
// "Horse_Set_Check():%d set spot is no good."
|
||||
osSyncPrintf("Horse_Set_Check():%d セットスポットまずいです。\n", gSaveContext.save.info.horseData.sceneId);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Horse_Set_Check():%d セットスポットまずいです。\n", gSaveContext.save.info.horseData.sceneId);
|
||||
PRINTF(VT_RST);
|
||||
func_8006D074(play);
|
||||
}
|
||||
|
||||
|
|
|
@ -135,65 +135,65 @@ void Jpeg_ParseMarkers(u8* ptr, JpegContext* ctx) {
|
|||
}
|
||||
case MARKER_SOI: {
|
||||
// Start of Image
|
||||
osSyncPrintf("MARKER_SOI\n");
|
||||
PRINTF("MARKER_SOI\n");
|
||||
break;
|
||||
}
|
||||
case MARKER_APP0: {
|
||||
// Application marker for JFIF
|
||||
osSyncPrintf("MARKER_APP0 %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
PRINTF("MARKER_APP0 %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
break;
|
||||
}
|
||||
case MARKER_APP1: {
|
||||
// Application marker for EXIF
|
||||
osSyncPrintf("MARKER_APP1 %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
PRINTF("MARKER_APP1 %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
break;
|
||||
}
|
||||
case MARKER_APP2: {
|
||||
osSyncPrintf("MARKER_APP2 %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
PRINTF("MARKER_APP2 %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
break;
|
||||
}
|
||||
case MARKER_DQT: {
|
||||
// Define Quantization Table, stored for later processing
|
||||
osSyncPrintf("MARKER_DQT %d %d %02x\n", ctx->dqtCount, Jpeg_GetUnalignedU16(ptr), ptr[2]);
|
||||
PRINTF("MARKER_DQT %d %d %02x\n", ctx->dqtCount, Jpeg_GetUnalignedU16(ptr), ptr[2]);
|
||||
ctx->dqtPtr[ctx->dqtCount++] = ptr + 2;
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
break;
|
||||
}
|
||||
case MARKER_DHT: {
|
||||
// Define Huffman Table, stored for later processing
|
||||
osSyncPrintf("MARKER_DHT %d %d %02x\n", ctx->dhtCount, Jpeg_GetUnalignedU16(ptr), ptr[2]);
|
||||
PRINTF("MARKER_DHT %d %d %02x\n", ctx->dhtCount, Jpeg_GetUnalignedU16(ptr), ptr[2]);
|
||||
ctx->dhtPtr[ctx->dhtCount++] = ptr + 2;
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
break;
|
||||
}
|
||||
case MARKER_DRI: {
|
||||
// Define Restart Interval
|
||||
osSyncPrintf("MARKER_DRI %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
PRINTF("MARKER_DRI %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
break;
|
||||
}
|
||||
case MARKER_SOF: {
|
||||
// Start of Frame, stores important metadata of the image.
|
||||
// Only used for extracting the sampling factors (ctx->mode).
|
||||
osSyncPrintf("MARKER_SOF %d "
|
||||
"精度%02x " // "accuracy"
|
||||
"垂直%d " // "vertical"
|
||||
"水平%d " // "horizontal"
|
||||
"compo%02x "
|
||||
"(1:Y)%d (H0=2,V0=1(422) or 2(420))%02x (量子化テーブル)%02x "
|
||||
"(2:Cb)%d (H1=1,V1=1)%02x (量子化テーブル)%02x "
|
||||
"(3:Cr)%d (H2=1,V2=1)%02x (量子化テーブル)%02x\n",
|
||||
Jpeg_GetUnalignedU16(ptr),
|
||||
ptr[2], // precision
|
||||
Jpeg_GetUnalignedU16(ptr + 3), // height
|
||||
Jpeg_GetUnalignedU16(ptr + 5), // width
|
||||
ptr[7], // component count (assumed to be 3)
|
||||
ptr[8], ptr[9], ptr[10], // Y component
|
||||
ptr[11], ptr[12], ptr[13], // Cb component
|
||||
ptr[14], ptr[15], ptr[16] // Cr component
|
||||
PRINTF("MARKER_SOF %d "
|
||||
"精度%02x " // "accuracy"
|
||||
"垂直%d " // "vertical"
|
||||
"水平%d " // "horizontal"
|
||||
"compo%02x "
|
||||
"(1:Y)%d (H0=2,V0=1(422) or 2(420))%02x (量子化テーブル)%02x "
|
||||
"(2:Cb)%d (H1=1,V1=1)%02x (量子化テーブル)%02x "
|
||||
"(3:Cr)%d (H2=1,V2=1)%02x (量子化テーブル)%02x\n",
|
||||
Jpeg_GetUnalignedU16(ptr),
|
||||
ptr[2], // precision
|
||||
Jpeg_GetUnalignedU16(ptr + 3), // height
|
||||
Jpeg_GetUnalignedU16(ptr + 5), // width
|
||||
ptr[7], // component count (assumed to be 3)
|
||||
ptr[8], ptr[9], ptr[10], // Y component
|
||||
ptr[11], ptr[12], ptr[13], // Cb component
|
||||
ptr[14], ptr[15], ptr[16] // Cr component
|
||||
);
|
||||
|
||||
if (ptr[9] == 0x21) {
|
||||
|
@ -208,19 +208,19 @@ void Jpeg_ParseMarkers(u8* ptr, JpegContext* ctx) {
|
|||
}
|
||||
case MARKER_SOS: {
|
||||
// Start of Scan marker, indicates the start of the image data.
|
||||
osSyncPrintf("MARKER_SOS %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
PRINTF("MARKER_SOS %d\n", Jpeg_GetUnalignedU16(ptr));
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
ctx->imageData = ptr;
|
||||
break;
|
||||
}
|
||||
case MARKER_EOI: {
|
||||
// End of Image
|
||||
osSyncPrintf("MARKER_EOI\n");
|
||||
PRINTF("MARKER_EOI\n");
|
||||
exit = true;
|
||||
break;
|
||||
}
|
||||
default: {
|
||||
osSyncPrintf("マーカー不明 %02x\n", ptr[-1]); // "Unknown marker"
|
||||
PRINTF("マーカー不明 %02x\n", ptr[-1]); // "Unknown marker"
|
||||
ptr += Jpeg_GetUnalignedU16(ptr);
|
||||
break;
|
||||
}
|
||||
|
@ -257,7 +257,7 @@ s32 Jpeg_Decode(void* data, void* zbuffer, void* work, u32 workSize) {
|
|||
diff = curTime - time;
|
||||
time = curTime;
|
||||
// "Wait for synchronization of fifo buffer"
|
||||
osSyncPrintf("*** fifoバッファの同期待ち time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
PRINTF("*** fifoバッファの同期待ち time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
|
||||
ctx.workBuf = workBuff;
|
||||
Jpeg_ParseMarkers(data, &ctx);
|
||||
|
@ -266,7 +266,7 @@ s32 Jpeg_Decode(void* data, void* zbuffer, void* work, u32 workSize) {
|
|||
diff = curTime - time;
|
||||
time = curTime;
|
||||
// "Check markers for each segment"
|
||||
osSyncPrintf("*** 各セグメントのマーカーのチェック time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
PRINTF("*** 各セグメントのマーカーのチェック time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
|
||||
switch (ctx.dqtCount) {
|
||||
case 1:
|
||||
|
@ -290,26 +290,26 @@ s32 Jpeg_Decode(void* data, void* zbuffer, void* work, u32 workSize) {
|
|||
diff = curTime - time;
|
||||
time = curTime;
|
||||
// "Create quantization table"
|
||||
osSyncPrintf("*** 量子化テーブル作成 time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
PRINTF("*** 量子化テーブル作成 time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
|
||||
switch (ctx.dhtCount) {
|
||||
case 1:
|
||||
if (JpegUtils_ProcessHuffmanTable(ctx.dhtPtr[0], &hTables[0], workBuff->codesLengths, workBuff->codes, 4)) {
|
||||
osSyncPrintf("Error : Cant' make huffman table.\n");
|
||||
PRINTF("Error : Cant' make huffman table.\n");
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
if (JpegUtils_ProcessHuffmanTable(ctx.dhtPtr[0], &hTables[0], workBuff->codesLengths, workBuff->codes, 1)) {
|
||||
osSyncPrintf("Error : Cant' make huffman table.\n");
|
||||
PRINTF("Error : Cant' make huffman table.\n");
|
||||
}
|
||||
if (JpegUtils_ProcessHuffmanTable(ctx.dhtPtr[1], &hTables[1], workBuff->codesLengths, workBuff->codes, 1)) {
|
||||
osSyncPrintf("Error : Cant' make huffman table.\n");
|
||||
PRINTF("Error : Cant' make huffman table.\n");
|
||||
}
|
||||
if (JpegUtils_ProcessHuffmanTable(ctx.dhtPtr[2], &hTables[2], workBuff->codesLengths, workBuff->codes, 1)) {
|
||||
osSyncPrintf("Error : Cant' make huffman table.\n");
|
||||
PRINTF("Error : Cant' make huffman table.\n");
|
||||
}
|
||||
if (JpegUtils_ProcessHuffmanTable(ctx.dhtPtr[3], &hTables[3], workBuff->codesLengths, workBuff->codes, 1)) {
|
||||
osSyncPrintf("Error : Cant' make huffman table.\n");
|
||||
PRINTF("Error : Cant' make huffman table.\n");
|
||||
}
|
||||
break;
|
||||
default:
|
||||
|
@ -320,7 +320,7 @@ s32 Jpeg_Decode(void* data, void* zbuffer, void* work, u32 workSize) {
|
|||
diff = curTime - time;
|
||||
time = curTime;
|
||||
// "Huffman table creation"
|
||||
osSyncPrintf("*** ハフマンテーブル作成 time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
PRINTF("*** ハフマンテーブル作成 time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
|
||||
decoder.imageData = ctx.imageData;
|
||||
decoder.mode = ctx.mode;
|
||||
|
@ -334,9 +334,9 @@ s32 Jpeg_Decode(void* data, void* zbuffer, void* work, u32 workSize) {
|
|||
x = y = 0;
|
||||
for (i = 0; i < 300; i += 4) {
|
||||
if (JpegDecoder_Decode(&decoder, (u16*)workBuff->data, 4, i != 0, &state)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("Error : Can't decode jpeg\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("Error : Can't decode jpeg\n");
|
||||
PRINTF(VT_RST);
|
||||
} else {
|
||||
Jpeg_ScheduleDecoderTask(&ctx);
|
||||
osInvalDCache(&workBuff->data, sizeof(workBuff->data[0]));
|
||||
|
@ -357,7 +357,7 @@ s32 Jpeg_Decode(void* data, void* zbuffer, void* work, u32 workSize) {
|
|||
diff = curTime - time;
|
||||
time = curTime;
|
||||
// "Unfold & draw"
|
||||
osSyncPrintf("*** 展開 & 描画 time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
PRINTF("*** 展開 & 描画 time = %6.3f ms ***\n", OS_CYCLES_TO_USEC(diff) / 1000.0f);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -22,11 +22,11 @@ void KaleidoManager_LoadOvl(KaleidoMgrOverlay* ovl) {
|
|||
ovl->loadedRamAddr = sKaleidoAreaPtr;
|
||||
Overlay_Load(ovl->vromStart, ovl->vromEnd, ovl->vramStart, ovl->vramEnd, ovl->loadedRamAddr);
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("OVL(k):Seg:%08x-%08x Ram:%08x-%08x Off:%08x %s\n", ovl->vramStart, ovl->vramEnd, ovl->loadedRamAddr,
|
||||
(uintptr_t)ovl->loadedRamAddr + (uintptr_t)ovl->vramEnd - (uintptr_t)ovl->vramStart,
|
||||
(uintptr_t)ovl->vramStart - (uintptr_t)ovl->loadedRamAddr, ovl->name);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("OVL(k):Seg:%08x-%08x Ram:%08x-%08x Off:%08x %s\n", ovl->vramStart, ovl->vramEnd, ovl->loadedRamAddr,
|
||||
(uintptr_t)ovl->loadedRamAddr + (uintptr_t)ovl->vramEnd - (uintptr_t)ovl->vramStart,
|
||||
(uintptr_t)ovl->vramStart - (uintptr_t)ovl->loadedRamAddr, ovl->name);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
ovl->offset = (uintptr_t)ovl->loadedRamAddr - (uintptr_t)ovl->vramStart;
|
||||
gKaleidoMgrCurOvl = ovl;
|
||||
|
@ -53,16 +53,16 @@ void KaleidoManager_Init(PlayState* play) {
|
|||
}
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("KaleidoArea の最大サイズは %d バイトを確保します\n", largestSize);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("KaleidoArea の最大サイズは %d バイトを確保します\n", largestSize);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
sKaleidoAreaPtr = GAME_STATE_ALLOC(&play->state, largestSize, "../z_kaleido_manager.c", 150);
|
||||
LogUtils_CheckNullPointer("KaleidoArea_allocp", sKaleidoAreaPtr, "../z_kaleido_manager.c", 151);
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("KaleidoArea %08x - %08x\n", sKaleidoAreaPtr, (uintptr_t)sKaleidoAreaPtr + largestSize);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("KaleidoArea %08x - %08x\n", sKaleidoAreaPtr, (uintptr_t)sKaleidoAreaPtr + largestSize);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
gKaleidoMgrCurOvl = NULL;
|
||||
}
|
||||
|
@ -93,7 +93,7 @@ void* KaleidoManager_GetRamAddr(void* vram) {
|
|||
//! @bug Probably missing iter++ here
|
||||
}
|
||||
|
||||
osSyncPrintf("異常\n"); // "Abnormal"
|
||||
PRINTF("異常\n"); // "Abnormal"
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
|
@ -15,16 +15,16 @@ void KaleidoScopeCall_LoadPlayer(void) {
|
|||
|
||||
if (gKaleidoMgrCurOvl != playerActorOvl) {
|
||||
if (gKaleidoMgrCurOvl != NULL) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("カレイド領域 強制排除\n"); // "Kaleido area forced exclusion"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("カレイド領域 強制排除\n"); // "Kaleido area forced exclusion"
|
||||
PRINTF(VT_RST);
|
||||
|
||||
KaleidoManager_ClearOvl(gKaleidoMgrCurOvl);
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("プレイヤーアクター搬入\n"); // "Player actor import"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("プレイヤーアクター搬入\n"); // "Player actor import"
|
||||
PRINTF(VT_RST);
|
||||
|
||||
KaleidoManager_LoadOvl(playerActorOvl);
|
||||
}
|
||||
|
@ -32,7 +32,7 @@ void KaleidoScopeCall_LoadPlayer(void) {
|
|||
|
||||
void KaleidoScopeCall_Init(PlayState* play) {
|
||||
// "Kaleidoscope replacement construction"
|
||||
osSyncPrintf("カレイド・スコープ入れ替え コンストラクト \n");
|
||||
PRINTF("カレイド・スコープ入れ替え コンストラクト \n");
|
||||
|
||||
sKaleidoScopeUpdateFunc = KaleidoManager_GetRamAddr(KaleidoScope_Update);
|
||||
sKaleidoScopeDrawFunc = KaleidoManager_GetRamAddr(KaleidoScope_Draw);
|
||||
|
@ -47,7 +47,7 @@ void KaleidoScopeCall_Init(PlayState* play) {
|
|||
|
||||
void KaleidoScopeCall_Destroy(PlayState* play) {
|
||||
// "Kaleidoscope replacement destruction"
|
||||
osSyncPrintf("カレイド・スコープ入れ替え デストラクト \n");
|
||||
PRINTF("カレイド・スコープ入れ替え デストラクト \n");
|
||||
|
||||
KaleidoSetup_Destroy(play);
|
||||
}
|
||||
|
@ -74,7 +74,7 @@ void KaleidoScopeCall_Update(PlayState* play) {
|
|||
pauseCtx->unk_1EC = 0;
|
||||
pauseCtx->state = (pauseCtx->state & 0xFFFF) + 1; // PAUSE_STATE_9
|
||||
} else if ((pauseCtx->state == PAUSE_STATE_WAIT_BG_PRERENDER) || (pauseCtx->state == PAUSE_STATE_9)) {
|
||||
osSyncPrintf("PR_KAREIDOSCOPE_MODE=%d\n", R_PAUSE_BG_PRERENDER_STATE);
|
||||
PRINTF("PR_KAREIDOSCOPE_MODE=%d\n", R_PAUSE_BG_PRERENDER_STATE);
|
||||
|
||||
if (R_PAUSE_BG_PRERENDER_STATE >= PAUSE_BG_PRERENDER_READY) {
|
||||
pauseCtx->state++; // PAUSE_STATE_INIT or PAUSE_STATE_10
|
||||
|
@ -82,18 +82,18 @@ void KaleidoScopeCall_Update(PlayState* play) {
|
|||
} else if (pauseCtx->state != PAUSE_STATE_OFF) {
|
||||
if (gKaleidoMgrCurOvl != kaleidoScopeOvl) {
|
||||
if (gKaleidoMgrCurOvl != NULL) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "Kaleido area Player Forced Elimination"
|
||||
osSyncPrintf("カレイド領域 プレイヤー 強制排除\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("カレイド領域 プレイヤー 強制排除\n");
|
||||
PRINTF(VT_RST);
|
||||
|
||||
KaleidoManager_ClearOvl(gKaleidoMgrCurOvl);
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "Kaleido area Kaleidoscope loading"
|
||||
osSyncPrintf("カレイド領域 カレイドスコープ搬入\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("カレイド領域 カレイドスコープ搬入\n");
|
||||
PRINTF(VT_RST);
|
||||
|
||||
KaleidoManager_LoadOvl(kaleidoScopeOvl);
|
||||
}
|
||||
|
@ -102,10 +102,10 @@ void KaleidoScopeCall_Update(PlayState* play) {
|
|||
sKaleidoScopeUpdateFunc(play);
|
||||
|
||||
if (!IS_PAUSED(&play->pauseCtx)) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "Kaleido area Kaleidoscope Emission"
|
||||
osSyncPrintf("カレイド領域 カレイドスコープ排出\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("カレイド領域 カレイドスコープ排出\n");
|
||||
PRINTF(VT_RST);
|
||||
|
||||
KaleidoManager_ClearOvl(kaleidoScopeOvl);
|
||||
KaleidoScopeCall_LoadPlayer();
|
||||
|
|
|
@ -46,8 +46,8 @@ void KaleidoSetup_Update(PlayState* play) {
|
|||
pauseCtx->mode = (u16)(pauseCtx->pageIndex * 2) + 1;
|
||||
pauseCtx->state = PAUSE_STATE_WAIT_LETTERBOX;
|
||||
|
||||
osSyncPrintf("Mode=%d eye.x=%f, eye.z=%f kscp_pos=%d\n", pauseCtx->mode, pauseCtx->eye.x,
|
||||
pauseCtx->eye.z, pauseCtx->pageIndex);
|
||||
PRINTF("Mode=%d eye.x=%f, eye.z=%f kscp_pos=%d\n", pauseCtx->mode, pauseCtx->eye.x, pauseCtx->eye.z,
|
||||
pauseCtx->pageIndex);
|
||||
}
|
||||
|
||||
if (pauseCtx->state == PAUSE_STATE_WAIT_LETTERBOX) {
|
||||
|
|
|
@ -44,12 +44,12 @@ void Font_LoadOrderedFont(Font* font) {
|
|||
|
||||
DMA_REQUEST_SYNC(font->msgBuf, (uintptr_t)_nes_message_data_staticSegmentRomStart + font->msgOffset, len,
|
||||
"../z_kanfont.c", 122);
|
||||
osSyncPrintf("msg_data=%x, msg_data0=%x jj=%x\n", font->msgOffset, font->msgLength, jj = len);
|
||||
PRINTF("msg_data=%x, msg_data0=%x jj=%x\n", font->msgOffset, font->msgLength, jj = len);
|
||||
|
||||
len = jj;
|
||||
for (fontBufIndex = 0, codePointIndex = 0; font->msgBuf[codePointIndex] != MESSAGE_END; codePointIndex++) {
|
||||
if (codePointIndex > len) {
|
||||
osSyncPrintf("ERROR!! エラー!!! error───!!!!\n");
|
||||
PRINTF("ERROR!! エラー!!! error───!!!!\n");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -57,7 +57,7 @@ void Font_LoadOrderedFont(Font* font) {
|
|||
fontBuf = font->fontBuf + fontBufIndex * 8;
|
||||
fontStatic = (uintptr_t)_nes_font_staticSegmentRomStart;
|
||||
|
||||
osSyncPrintf("nes_mes_buf[%d]=%d\n", codePointIndex, font->msgBuf[codePointIndex]);
|
||||
PRINTF("nes_mes_buf[%d]=%d\n", codePointIndex, font->msgBuf[codePointIndex]);
|
||||
|
||||
offset = (font->msgBuf[codePointIndex] - ' ') * FONT_CHAR_TEX_SIZE;
|
||||
DMA_REQUEST_SYNC(fontBuf, fontStatic + offset, FONT_CHAR_TEX_SIZE, "../z_kanfont.c", 134);
|
||||
|
|
|
@ -435,7 +435,7 @@ void Environment_Init(PlayState* play2, EnvironmentContext* envCtx, s32 unused)
|
|||
if (Object_GetSlot(&play->objectCtx, OBJECT_GAMEPLAY_FIELD_KEEP) < 0 && !play->envCtx.sunMoonDisabled) {
|
||||
play->envCtx.sunMoonDisabled = true;
|
||||
// "Sun setting other than field keep! So forced release!"
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "\n\nフィールド常駐以外、太陽設定!よって強制解除!\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "\n\nフィールド常駐以外、太陽設定!よって強制解除!\n" VT_RST);
|
||||
}
|
||||
|
||||
gCustomLensFlareOn = false;
|
||||
|
@ -554,8 +554,8 @@ f32 Environment_LerpWeightAccelDecel(u16 endFrame, u16 startFrame, u16 curFrame,
|
|||
|
||||
if ((startFrameF >= endFrameF) || (accelDurationF + decelDurationF > totalFrames)) {
|
||||
// "The frame relation between end_frame and start_frame is wrong!!!"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "\nend_frameとstart_frameのフレーム関係がおかしい!!!" VT_RST);
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "\nby get_parcent_forAccelBrake!!!!!!!!!" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "\nend_frameとstart_frameのフレーム関係がおかしい!!!" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "\nby get_parcent_forAccelBrake!!!!!!!!!" VT_RST);
|
||||
|
||||
return 0.0f;
|
||||
}
|
||||
|
@ -702,7 +702,7 @@ void Environment_UpdateSkybox(u8 skyboxId, EnvironmentContext* envCtx, SkyboxCon
|
|||
|
||||
if (newSkybox1Index == 0xFF) {
|
||||
// "Environment VR data acquisition failed! Report to Sasaki!"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "\n環境VRデータ取得失敗! ささきまでご報告を!" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "\n環境VRデータ取得失敗! ささきまでご報告を!" VT_RST);
|
||||
}
|
||||
|
||||
if ((envCtx->skybox1Index != newSkybox1Index) && (envCtx->skyboxDmaState == SKYBOX_DMA_INACTIVE)) {
|
||||
|
@ -788,7 +788,7 @@ void Environment_EnableUnderwaterLights(PlayState* play, s32 waterLightsIndex) {
|
|||
if (waterLightsIndex == WATERBOX_LIGHT_INDEX_NONE) {
|
||||
waterLightsIndex = 0;
|
||||
// "Underwater color is not set in the water poly data!"
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "\n水ポリゴンデータに水中カラーが設定されておりません!" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "\n水ポリゴンデータに水中カラーが設定されておりません!" VT_RST);
|
||||
}
|
||||
|
||||
if (play->envCtx.lightMode == LIGHT_MODE_TIME) {
|
||||
|
@ -902,7 +902,7 @@ void Environment_Update(PlayState* play, EnvironmentContext* envCtx, LightContex
|
|||
|
||||
if (((void)0, gSaveContext.nextDayTime) >= 0xFF00 && ((void)0, gSaveContext.nextDayTime) != NEXT_TIME_NONE) {
|
||||
gSaveContext.nextDayTime -= 0x10;
|
||||
osSyncPrintf("\nnext_zelda_time=[%x]", ((void)0, gSaveContext.nextDayTime));
|
||||
PRINTF("\nnext_zelda_time=[%x]", ((void)0, gSaveContext.nextDayTime));
|
||||
|
||||
// nextDayTime is used as both a time of day value and a timer to delay sfx when changing days.
|
||||
// When Sun's Song is played, nextDayTime is set to 0x8001 or 0 for day and night respectively.
|
||||
|
@ -1127,12 +1127,12 @@ void Environment_Update(PlayState* play, EnvironmentContext* envCtx, LightContex
|
|||
if (sTimeBasedLightConfigs[envCtx->changeLightNextConfig][i].nextLightSetting >=
|
||||
envCtx->numLightSettings) {
|
||||
// "The color palette setting seems to be wrong!"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "\nカラーパレットの設定がおかしいようです!" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "\nカラーパレットの設定がおかしいようです!" VT_RST);
|
||||
|
||||
// "Palette setting = [] Last palette number = []"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "\n設定パレット=[%d] 最後パレット番号=[%d]\n" VT_RST,
|
||||
sTimeBasedLightConfigs[envCtx->changeLightNextConfig][i].nextLightSetting,
|
||||
envCtx->numLightSettings - 1);
|
||||
PRINTF(VT_COL(RED, WHITE) "\n設定パレット=[%d] 最後パレット番号=[%d]\n" VT_RST,
|
||||
sTimeBasedLightConfigs[envCtx->changeLightNextConfig][i].nextLightSetting,
|
||||
envCtx->numLightSettings - 1);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -1203,11 +1203,11 @@ void Environment_Update(PlayState* play, EnvironmentContext* envCtx, LightContex
|
|||
|
||||
if (envCtx->lightSetting >= envCtx->numLightSettings) {
|
||||
// "The color palette seems to be wrong!"
|
||||
osSyncPrintf("\n" VT_FGCOL(RED) "カラーパレットがおかしいようです!");
|
||||
PRINTF("\n" VT_FGCOL(RED) "カラーパレットがおかしいようです!");
|
||||
|
||||
// "Palette setting = [] Last palette number = []"
|
||||
osSyncPrintf("\n" VT_FGCOL(YELLOW) "設定パレット=[%d] パレット数=[%d]\n" VT_RST,
|
||||
envCtx->lightSetting, envCtx->numLightSettings);
|
||||
PRINTF("\n" VT_FGCOL(YELLOW) "設定パレット=[%d] パレット数=[%d]\n" VT_RST, envCtx->lightSetting,
|
||||
envCtx->numLightSettings);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -2058,8 +2058,8 @@ void Environment_PlaySceneSequence(PlayState* play) {
|
|||
}
|
||||
} else if (play->sequenceCtx.natureAmbienceId == NATURE_ID_NONE) {
|
||||
// "BGM Configuration"
|
||||
osSyncPrintf("\n\n\nBGM設定game_play->sound_info.BGM=[%d] old_bgm=[%d]\n\n", play->sequenceCtx.seqId,
|
||||
((void)0, gSaveContext.seqId));
|
||||
PRINTF("\n\n\nBGM設定game_play->sound_info.BGM=[%d] old_bgm=[%d]\n\n", play->sequenceCtx.seqId,
|
||||
((void)0, gSaveContext.seqId));
|
||||
if (((void)0, gSaveContext.seqId) != play->sequenceCtx.seqId) {
|
||||
Audio_PlaySceneSequence(play->sequenceCtx.seqId);
|
||||
}
|
||||
|
@ -2086,11 +2086,11 @@ void Environment_PlaySceneSequence(PlayState* play) {
|
|||
}
|
||||
}
|
||||
|
||||
osSyncPrintf("\n-----------------\n", ((void)0, gSaveContext.forcedSeqId));
|
||||
osSyncPrintf("\n 強制BGM=[%d]", ((void)0, gSaveContext.forcedSeqId)); // "Forced BGM"
|
||||
osSyncPrintf("\n BGM=[%d]", play->sequenceCtx.seqId);
|
||||
osSyncPrintf("\n エンブ=[%d]", play->sequenceCtx.natureAmbienceId);
|
||||
osSyncPrintf("\n status=[%d]", play->envCtx.timeSeqState);
|
||||
PRINTF("\n-----------------\n", ((void)0, gSaveContext.forcedSeqId));
|
||||
PRINTF("\n 強制BGM=[%d]", ((void)0, gSaveContext.forcedSeqId)); // "Forced BGM"
|
||||
PRINTF("\n BGM=[%d]", play->sequenceCtx.seqId);
|
||||
PRINTF("\n エンブ=[%d]", play->sequenceCtx.natureAmbienceId);
|
||||
PRINTF("\n status=[%d]", play->envCtx.timeSeqState);
|
||||
|
||||
Audio_SetEnvReverb(play->roomCtx.curRoom.echo);
|
||||
}
|
||||
|
@ -2102,7 +2102,7 @@ void Environment_PlayTimeBasedSequence(PlayState* play) {
|
|||
CHANNEL_IO_PORT_1, 0);
|
||||
|
||||
if (play->envCtx.precipitation[PRECIP_RAIN_MAX] == 0 && play->envCtx.precipitation[PRECIP_SOS_MAX] == 0) {
|
||||
osSyncPrintf("\n\n\nNa_StartMorinigBgm\n\n");
|
||||
PRINTF("\n\n\nNa_StartMorinigBgm\n\n");
|
||||
Audio_PlayMorningSceneSequence(play->sequenceCtx.seqId);
|
||||
}
|
||||
|
||||
|
|
|
@ -380,7 +380,7 @@ void IChain_Apply_Vec3fdiv1000(u8* ptr, InitChainEntry* ichain) {
|
|||
Vec3f* vec = (Vec3f*)(ptr + ichain->offset);
|
||||
f32 val;
|
||||
|
||||
osSyncPrintf("pp=%x data=%f\n", vec, ichain->value / 1000.0f);
|
||||
PRINTF("pp=%x data=%f\n", vec, ichain->value / 1000.0f);
|
||||
val = ichain->value / 1000.0f;
|
||||
|
||||
vec->z = val;
|
||||
|
|
|
@ -11,12 +11,12 @@ void ZeldaArena_CheckPointer(void* ptr, u32 size, const char* name, const char*
|
|||
if (ptr == NULL) {
|
||||
if (gZeldaArenaLogSeverity >= LOG_SEVERITY_ERROR) {
|
||||
// "%s: %u bytes %s failed\n"
|
||||
osSyncPrintf("%s: %u バイトの%sに失敗しました\n", name, size, action);
|
||||
PRINTF("%s: %u バイトの%sに失敗しました\n", name, size, action);
|
||||
__osDisplayArena(&sZeldaArena);
|
||||
}
|
||||
} else if (gZeldaArenaLogSeverity >= LOG_SEVERITY_VERBOSE) {
|
||||
// "%s: %u bytes %s succeeded\n"
|
||||
osSyncPrintf("%s: %u バイトの%sに成功しました\n", name, size, action);
|
||||
PRINTF("%s: %u バイトの%sに成功しました\n", name, size, action);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -82,7 +82,7 @@ void* ZeldaArena_Calloc(u32 num, u32 size) {
|
|||
}
|
||||
|
||||
void ZeldaArena_Display(void) {
|
||||
osSyncPrintf("ゼルダヒープ表示\n"); // "Zelda heap display"
|
||||
PRINTF("ゼルダヒープ表示\n"); // "Zelda heap display"
|
||||
__osDisplayArena(&sZeldaArena);
|
||||
}
|
||||
|
||||
|
|
|
@ -27,11 +27,11 @@ void Map_SetPaletteData(PlayState* play, s16 room) {
|
|||
interfaceCtx->mapPaletteIndex = paletteIndex;
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
// "PALETE Set"
|
||||
osSyncPrintf("PALETEセット 【 i=%x : room=%x 】Room_Inf[%d][4]=%x ( map_palete_no = %d )\n", paletteIndex,
|
||||
room, mapIndex, gSaveContext.save.info.sceneFlags[mapIndex].rooms, interfaceCtx->mapPaletteIndex);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("PALETEセット 【 i=%x : room=%x 】Room_Inf[%d][4]=%x ( map_palete_no = %d )\n", paletteIndex, room,
|
||||
mapIndex, gSaveContext.save.info.sceneFlags[mapIndex].rooms, interfaceCtx->mapPaletteIndex);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
interfaceCtx->mapPalette[paletteIndex * 2] = 2;
|
||||
interfaceCtx->mapPalette[paletteIndex * 2 + 1] = 0xBF;
|
||||
|
@ -126,9 +126,9 @@ void Map_InitData(PlayState* play, s16 room) {
|
|||
extendedMapIndex = 0x17;
|
||||
}
|
||||
}
|
||||
osSyncPrintf(VT_FGCOL(BLUE));
|
||||
osSyncPrintf("KKK=%d\n", extendedMapIndex);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(BLUE));
|
||||
PRINTF("KKK=%d\n", extendedMapIndex);
|
||||
PRINTF(VT_RST);
|
||||
sEntranceIconMapIndex = extendedMapIndex;
|
||||
DMA_REQUEST_SYNC(interfaceCtx->mapSegment,
|
||||
(uintptr_t)_map_grand_staticSegmentRomStart +
|
||||
|
@ -154,11 +154,11 @@ void Map_InitData(PlayState* play, s16 room) {
|
|||
case SCENE_WATER_TEMPLE_BOSS:
|
||||
case SCENE_SPIRIT_TEMPLE_BOSS:
|
||||
case SCENE_SHADOW_TEMPLE_BOSS:
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
// "Deku Tree Dungeon MAP Texture DMA"
|
||||
osSyncPrintf("デクの樹ダンジョンMAP テクスチャDMA(%x) scene_id_offset=%d VREG(30)=%d\n", room,
|
||||
mapIndex, VREG(30));
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("デクの樹ダンジョンMAP テクスチャDMA(%x) scene_id_offset=%d VREG(30)=%d\n", room, mapIndex,
|
||||
VREG(30));
|
||||
PRINTF(VT_RST);
|
||||
DMA_REQUEST_SYNC(play->interfaceCtx.mapSegment,
|
||||
(uintptr_t)_map_i_staticSegmentRomStart +
|
||||
((gMapData->dgnMinimapTexIndexOffset[mapIndex] + room) * MAP_I_TEX_SIZE),
|
||||
|
@ -166,7 +166,7 @@ void Map_InitData(PlayState* play, s16 room) {
|
|||
R_COMPASS_OFFSET_X = gMapData->roomCompassOffsetX[mapIndex][room];
|
||||
R_COMPASS_OFFSET_Y = gMapData->roomCompassOffsetY[mapIndex][room];
|
||||
Map_SetFloorPalettesData(play, VREG(30));
|
||||
osSyncPrintf("MAP 各階ONチェック\n"); // "MAP Individual Floor ON Check"
|
||||
PRINTF("MAP 各階ONチェック\n"); // "MAP Individual Floor ON Check"
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -175,8 +175,8 @@ void Map_InitRoomData(PlayState* play, s16 room) {
|
|||
s32 mapIndex = gSaveContext.mapIndex;
|
||||
InterfaceContext* interfaceCtx = &play->interfaceCtx;
|
||||
|
||||
osSyncPrintf("*******\n*******\nroom_no=%d (%d)(%d)\n*******\n*******\n", room,
|
||||
mapIndex, play->sceneId);
|
||||
PRINTF("*******\n*******\nroom_no=%d (%d)(%d)\n*******\n*******\n", room, mapIndex,
|
||||
play->sceneId);
|
||||
|
||||
if (room >= 0) {
|
||||
switch (play->sceneId) {
|
||||
|
@ -199,13 +199,13 @@ void Map_InitRoomData(PlayState* play, s16 room) {
|
|||
case SCENE_SPIRIT_TEMPLE_BOSS:
|
||||
case SCENE_SHADOW_TEMPLE_BOSS:
|
||||
gSaveContext.save.info.sceneFlags[mapIndex].rooms |= gBitFlags[room];
|
||||
osSyncPrintf("ROOM_INF=%d\n", gSaveContext.save.info.sceneFlags[mapIndex].rooms);
|
||||
PRINTF("ROOM_INF=%d\n", gSaveContext.save.info.sceneFlags[mapIndex].rooms);
|
||||
interfaceCtx->mapRoomNum = room;
|
||||
interfaceCtx->unk_25A = mapIndex;
|
||||
Map_SetPaletteData(play, room);
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("部屋部屋=%d\n", room); // "Room Room = %d"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("部屋部屋=%d\n", room); // "Room Room = %d"
|
||||
PRINTF(VT_RST);
|
||||
Map_InitData(play, room);
|
||||
break;
|
||||
}
|
||||
|
@ -234,8 +234,8 @@ void Map_Init(PlayState* play) {
|
|||
|
||||
interfaceCtx->mapSegment = GAME_STATE_ALLOC(&play->state, 0x1000, "../z_map_exp.c", 457);
|
||||
// "MAP texture initialization scene_data_ID=%d mapSegment=%x"
|
||||
osSyncPrintf("\n\n\nMAP テクスチャ初期化 scene_data_ID=%d\nmapSegment=%x\n\n", play->sceneId,
|
||||
interfaceCtx->mapSegment, play);
|
||||
PRINTF("\n\n\nMAP テクスチャ初期化 scene_data_ID=%d\nmapSegment=%x\n\n", play->sceneId,
|
||||
interfaceCtx->mapSegment, play);
|
||||
ASSERT(interfaceCtx->mapSegment != NULL, "parameter->mapSegment != NULL", "../z_map_exp.c", 459);
|
||||
|
||||
switch (play->sceneId) {
|
||||
|
@ -404,7 +404,7 @@ void Minimap_Draw(PlayState* play) {
|
|||
}
|
||||
|
||||
if (CHECK_BTN_ALL(play->state.input[0].press.button, BTN_L) && !Play_InCsMode(play)) {
|
||||
osSyncPrintf("Game_play_demo_mode_check=%d\n", Play_InCsMode(play));
|
||||
PRINTF("Game_play_demo_mode_check=%d\n", Play_InCsMode(play));
|
||||
// clang-format off
|
||||
if (!R_MINIMAP_DISABLED) { Audio_PlaySfxGeneral(NA_SE_SY_CAMERA_ZOOM_UP, &gSfxDefaultPos, 4,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultFreqAndVolScale,
|
||||
|
@ -556,8 +556,8 @@ void Map_Update(PlayState* play) {
|
|||
|
||||
if (interfaceCtx->mapRoomNum != sLastRoomNum) {
|
||||
// "Current floor = %d Current room = %x Number of rooms = %d"
|
||||
osSyncPrintf("現在階=%d 現在部屋=%x 部屋数=%d\n", floor, interfaceCtx->mapRoomNum,
|
||||
gMapData->switchEntryCount[mapIndex]);
|
||||
PRINTF("現在階=%d 現在部屋=%x 部屋数=%d\n", floor, interfaceCtx->mapRoomNum,
|
||||
gMapData->switchEntryCount[mapIndex]);
|
||||
sLastRoomNum = interfaceCtx->mapRoomNum;
|
||||
}
|
||||
|
||||
|
@ -565,10 +565,10 @@ void Map_Update(PlayState* play) {
|
|||
if ((interfaceCtx->mapRoomNum == gMapData->switchFromRoom[mapIndex][i]) &&
|
||||
(floor == gMapData->switchFromFloor[mapIndex][i])) {
|
||||
interfaceCtx->mapRoomNum = gMapData->switchToRoom[mapIndex][i];
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
// "Layer switching = %x"
|
||||
osSyncPrintf("階層切替=%x\n", interfaceCtx->mapRoomNum);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("階層切替=%x\n", interfaceCtx->mapRoomNum);
|
||||
PRINTF(VT_RST);
|
||||
Map_InitData(play, interfaceCtx->mapRoomNum);
|
||||
gSaveContext.sunsSongState = SUNSSONG_INACTIVE;
|
||||
Map_SavePlayerInitialInfo(play);
|
||||
|
|
|
@ -89,8 +89,8 @@ void MapMark_DrawForDungeon(PlayState* play) {
|
|||
|
||||
if ((gMapData != NULL) && (play->interfaceCtx.mapRoomNum >= gMapData->dgnMinimapCount[dungeon])) {
|
||||
// "Room number exceeded, yikes %d/%d MapMarkDraw processing interrupted"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "部屋番号がオーバーしてるで,ヤバイで %d/%d \nMapMarkDraw の処理を中断します\n",
|
||||
VT_RST, play->interfaceCtx.mapRoomNum, gMapData->dgnMinimapCount[dungeon]);
|
||||
PRINTF(VT_COL(RED, WHITE) "部屋番号がオーバーしてるで,ヤバイで %d/%d \nMapMarkDraw の処理を中断します\n",
|
||||
VT_RST, play->interfaceCtx.mapRoomNum, gMapData->dgnMinimapCount[dungeon]);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -310,9 +310,9 @@ void Message_FindMessage(PlayState* play, u16 textId) {
|
|||
font->msgOffset = foundSeg - seg;
|
||||
font->msgLength = nextSeg - foundSeg;
|
||||
// "Message found!!!"
|
||||
osSyncPrintf(" メッセージが,見つかった!!! = %x "
|
||||
"(data=%x) (data0=%x) (data1=%x) (data2=%x) (data3=%x)\n",
|
||||
textId, font->msgOffset, font->msgLength, foundSeg, seg, nextSeg);
|
||||
PRINTF(" メッセージが,見つかった!!! = %x "
|
||||
"(data=%x) (data0=%x) (data1=%x) (data2=%x) (data3=%x)\n",
|
||||
textId, font->msgOffset, font->msgLength, foundSeg, seg, nextSeg);
|
||||
return;
|
||||
}
|
||||
messageTableEntry++;
|
||||
|
@ -333,9 +333,9 @@ void Message_FindMessage(PlayState* play, u16 textId) {
|
|||
font->msgOffset = foundSeg - seg;
|
||||
font->msgLength = nextSeg - foundSeg;
|
||||
// "Message found!!!"
|
||||
osSyncPrintf(" メッセージが,見つかった!!! = %x "
|
||||
"(data=%x) (data0=%x) (data1=%x) (data2=%x) (data3=%x)\n",
|
||||
textId, font->msgOffset, font->msgLength, foundSeg, seg, nextSeg);
|
||||
PRINTF(" メッセージが,見つかった!!! = %x "
|
||||
"(data=%x) (data0=%x) (data1=%x) (data2=%x) (data3=%x)\n",
|
||||
textId, font->msgOffset, font->msgLength, foundSeg, seg, nextSeg);
|
||||
return;
|
||||
}
|
||||
messageTableEntry++;
|
||||
|
@ -343,7 +343,7 @@ void Message_FindMessage(PlayState* play, u16 textId) {
|
|||
}
|
||||
}
|
||||
// "Message not found!!!"
|
||||
osSyncPrintf(" メッセージが,見つからなかった!!! = %x\n", textId);
|
||||
PRINTF(" メッセージが,見つからなかった!!! = %x\n", textId);
|
||||
font = &play->msgCtx.font;
|
||||
messageTableEntry = sNesMessageEntryTablePtr;
|
||||
|
||||
|
@ -383,8 +383,8 @@ void Message_FindCreditsMessage(PlayState* play, u16 textId) {
|
|||
font->msgOffset = foundSeg - seg;
|
||||
font->msgLength = nextSeg - foundSeg;
|
||||
// "Message found!!!"
|
||||
osSyncPrintf(" メッセージが,見つかった!!! = %x (data=%x) (data0=%x) (data1=%x) (data2=%x) (data3=%x)\n",
|
||||
textId, font->msgOffset, font->msgLength, foundSeg, seg, nextSeg);
|
||||
PRINTF(" メッセージが,見つかった!!! = %x (data=%x) (data0=%x) (data1=%x) (data2=%x) (data3=%x)\n",
|
||||
textId, font->msgOffset, font->msgLength, foundSeg, seg, nextSeg);
|
||||
return;
|
||||
}
|
||||
messageTableEntry++;
|
||||
|
@ -785,10 +785,10 @@ void Message_HandleOcarina(PlayState* play) {
|
|||
if (msgCtx->ocarinaAction == OCARINA_ACTION_SCARECROW_LONG_RECORDING) {
|
||||
msgCtx->msgMode = MSGMODE_SCARECROW_LONG_RECORDING_START;
|
||||
// "Recording Start / Recording Start / Recording Start / Recording Start -> "
|
||||
osSyncPrintf("録音開始 録音開始 録音開始 録音開始 -> ");
|
||||
PRINTF("録音開始 録音開始 録音開始 録音開始 -> ");
|
||||
} else if (msgCtx->ocarinaAction == OCARINA_ACTION_SCARECROW_LONG_PLAYBACK) {
|
||||
// "Recording Playback / Recording Playback / Recording Playback / Recording Playback -> "
|
||||
osSyncPrintf("録音再生 録音再生 録音再生 録音再生 -> ");
|
||||
PRINTF("録音再生 録音再生 録音再生 録音再生 -> ");
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetPlaybackStaff();
|
||||
|
@ -801,10 +801,10 @@ void Message_HandleOcarina(PlayState* play) {
|
|||
} else if (msgCtx->ocarinaAction == OCARINA_ACTION_SCARECROW_SPAWN_RECORDING) {
|
||||
msgCtx->msgMode = MSGMODE_SCARECROW_SPAWN_RECORDING_START;
|
||||
// "8 Note Recording Start / 8 Note Recording Start / 8 Note Recording Start -> "
|
||||
osSyncPrintf("8音録音開始 8音録音開始 8音録音開始 -> ");
|
||||
PRINTF("8音録音開始 8音録音開始 8音録音開始 -> ");
|
||||
} else if (msgCtx->ocarinaAction == OCARINA_ACTION_SCARECROW_SPAWN_PLAYBACK) {
|
||||
// "8 Note Playback / 8 Note Playback / 8 Note Playback -> "
|
||||
osSyncPrintf("8音再生 8音再生 8音再生 -> ");
|
||||
PRINTF("8音再生 8音再生 8音再生 -> ");
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetPlaybackStaff();
|
||||
|
@ -817,28 +817,28 @@ void Message_HandleOcarina(PlayState* play) {
|
|||
} else if (msgCtx->ocarinaAction == OCARINA_ACTION_MEMORY_GAME) {
|
||||
msgCtx->msgMode = MSGMODE_MEMORY_GAME_START;
|
||||
// "Musical Round Start / Musical Round Start / Musical Round Start / Musical Round Start -> "
|
||||
osSyncPrintf("輪唱開始 輪唱開始 輪唱開始 輪唱開始 -> ");
|
||||
PRINTF("輪唱開始 輪唱開始 輪唱開始 輪唱開始 -> ");
|
||||
} else if (msgCtx->ocarinaAction == OCARINA_ACTION_FROGS) {
|
||||
msgCtx->msgMode = MSGMODE_FROGS_START;
|
||||
// "Frog Chorus / Frog Chorus -> "
|
||||
osSyncPrintf("カエルの合唱 カエルの合唱 -> ");
|
||||
PRINTF("カエルの合唱 カエルの合唱 -> ");
|
||||
} else {
|
||||
// "Ocarina(%d)"
|
||||
osSyncPrintf("オカリナ(%d) ", msgCtx->ocarinaAction);
|
||||
PRINTF("オカリナ(%d) ", msgCtx->ocarinaAction);
|
||||
if (msgCtx->ocarinaAction == OCARINA_ACTION_UNK_0 || msgCtx->ocarinaAction == OCARINA_ACTION_FREE_PLAY ||
|
||||
msgCtx->ocarinaAction >= OCARINA_ACTION_CHECK_SARIA) {
|
||||
msgCtx->msgMode = MSGMODE_OCARINA_STARTING;
|
||||
osSyncPrintf("000000000000 -> ");
|
||||
PRINTF("000000000000 -> ");
|
||||
} else if (msgCtx->ocarinaAction >= OCARINA_ACTION_TEACH_MINUET &&
|
||||
msgCtx->ocarinaAction <= OCARINA_ACTION_TEACH_STORMS) {
|
||||
msgCtx->msgMode = MSGMODE_SONG_DEMONSTRATION_STARTING;
|
||||
osSyncPrintf("111111111111 -> ");
|
||||
PRINTF("111111111111 -> ");
|
||||
} else {
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYBACK_STARTING;
|
||||
osSyncPrintf("222222222222 -> ");
|
||||
PRINTF("222222222222 -> ");
|
||||
}
|
||||
}
|
||||
osSyncPrintf("msg_mode=%d\n", msgCtx->msgMode);
|
||||
PRINTF("msg_mode=%d\n", msgCtx->msgMode);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -968,11 +968,11 @@ void Message_DrawText(PlayState* play, Gfx** gfxP) {
|
|||
msgCtx->msgMode = MSGMODE_TEXT_DONE;
|
||||
msgCtx->textboxEndType = TEXTBOX_ENDTYPE_FADING;
|
||||
// "Timer"
|
||||
osSyncPrintf("タイマー (%x) (%x)", msgCtx->msgBufDecoded[i + 1], msgCtx->msgBufDecoded[i + 2]);
|
||||
PRINTF("タイマー (%x) (%x)", msgCtx->msgBufDecoded[i + 1], msgCtx->msgBufDecoded[i + 2]);
|
||||
msgCtx->stateTimer = msgCtx->msgBufDecoded[++i] << 8;
|
||||
msgCtx->stateTimer |= msgCtx->msgBufDecoded[++i];
|
||||
// "Total wct"
|
||||
osSyncPrintf("合計wct=%x(%d)\n", msgCtx->stateTimer, msgCtx->stateTimer);
|
||||
PRINTF("合計wct=%x(%d)\n", msgCtx->stateTimer, msgCtx->stateTimer);
|
||||
}
|
||||
*gfxP = gfx;
|
||||
return;
|
||||
|
@ -980,7 +980,7 @@ void Message_DrawText(PlayState* play, Gfx** gfxP) {
|
|||
if (msgCtx->msgMode == MSGMODE_TEXT_DISPLAYING && !sMessageHasSetSfx) {
|
||||
sMessageHasSetSfx = true;
|
||||
// "Sound (SE)"
|
||||
osSyncPrintf("サウンド(SE)\n");
|
||||
PRINTF("サウンド(SE)\n");
|
||||
sfxHi = msgCtx->msgBufDecoded[i + 1] << 8;
|
||||
Audio_PlaySfxGeneral(sfxHi | msgCtx->msgBufDecoded[i + 2], &gSfxDefaultPos, 4,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
|
@ -1164,7 +1164,7 @@ void Message_LoadItemIcon(PlayState* play, u16 itemId, s16 y) {
|
|||
DMA_REQUEST_SYNC(msgCtx->textboxSegment + MESSAGE_STATIC_TEX_SIZE, GET_ITEM_ICON_VROM(itemId), ITEM_ICON_SIZE,
|
||||
"../z_message_PAL.c", 1473);
|
||||
// "Item 32-0"
|
||||
osSyncPrintf("アイテム32-0\n");
|
||||
PRINTF("アイテム32-0\n");
|
||||
} else {
|
||||
R_TEXTBOX_ICON_XPOS = R_TEXT_INIT_XPOS - sIconItem24XOffsets[gSaveContext.language];
|
||||
R_TEXTBOX_ICON_YPOS = y + ((44 - QUEST_ICON_HEIGHT) / 2);
|
||||
|
@ -1172,7 +1172,7 @@ void Message_LoadItemIcon(PlayState* play, u16 itemId, s16 y) {
|
|||
DMA_REQUEST_SYNC(msgCtx->textboxSegment + MESSAGE_STATIC_TEX_SIZE, GET_QUEST_ICON_VROM(itemId), QUEST_ICON_SIZE,
|
||||
"../z_message_PAL.c", 1482);
|
||||
// "Item 24"
|
||||
osSyncPrintf("アイテム24=%d (%d) {%d}\n", itemId, itemId - ITEM_KOKIRI_EMERALD, 84);
|
||||
PRINTF("アイテム24=%d (%d) {%d}\n", itemId, itemId - ITEM_KOKIRI_EMERALD, 84);
|
||||
}
|
||||
msgCtx->msgBufPos++;
|
||||
msgCtx->choiceNum = 1;
|
||||
|
@ -1206,7 +1206,7 @@ void Message_Decode(PlayState* play) {
|
|||
msgCtx->msgMode = MSGMODE_TEXT_DISPLAYING;
|
||||
msgCtx->textDrawPos = 1;
|
||||
R_TEXT_INIT_YPOS = R_TEXTBOX_Y + 8;
|
||||
osSyncPrintf("JJ=%d\n", numLines);
|
||||
PRINTF("JJ=%d\n", numLines);
|
||||
if (msgCtx->textBoxType != TEXTBOX_TYPE_NONE_BOTTOM) {
|
||||
if (numLines == 0) {
|
||||
R_TEXT_INIT_YPOS = (u16)(R_TEXTBOX_Y + 26);
|
||||
|
@ -1217,8 +1217,8 @@ void Message_Decode(PlayState* play) {
|
|||
}
|
||||
}
|
||||
if (curChar2 == MESSAGE_TEXTID) {
|
||||
osSyncPrintf("NZ_NEXTMSG=%x, %x, %x\n", font->msgBuf[msgCtx->msgBufPos],
|
||||
font->msgBuf[msgCtx->msgBufPos + 1], font->msgBuf[msgCtx->msgBufPos + 2]);
|
||||
PRINTF("NZ_NEXTMSG=%x, %x, %x\n", font->msgBuf[msgCtx->msgBufPos], font->msgBuf[msgCtx->msgBufPos + 1],
|
||||
font->msgBuf[msgCtx->msgBufPos + 2]);
|
||||
curChar = msgCtx->msgBufDecoded[++decodedBufPos] = font->msgBuf[msgCtx->msgBufPos + 1];
|
||||
msgCtx->msgBufDecoded[++decodedBufPos] = font->msgBuf[msgCtx->msgBufPos + 2];
|
||||
value = curChar << 8;
|
||||
|
@ -1242,7 +1242,7 @@ void Message_Decode(PlayState* play) {
|
|||
}
|
||||
}
|
||||
// "Name"
|
||||
osSyncPrintf("\n名前 = ");
|
||||
PRINTF("\n名前 = ");
|
||||
for (i = 0; i < playerNameLen; i++) {
|
||||
curChar2 = gSaveContext.save.info.playerData.playerName[i];
|
||||
if (curChar2 == 0x3E) {
|
||||
|
@ -1265,7 +1265,7 @@ void Message_Decode(PlayState* play) {
|
|||
Font_LoadChar(font, curChar2 - ' ', charTexIdx);
|
||||
charTexIdx += FONT_CHAR_TEX_SIZE;
|
||||
}
|
||||
osSyncPrintf("%x ", curChar2);
|
||||
PRINTF("%x ", curChar2);
|
||||
msgCtx->msgBufDecoded[decodedBufPos] = curChar2;
|
||||
decodedBufPos++;
|
||||
}
|
||||
|
@ -1274,7 +1274,7 @@ void Message_Decode(PlayState* play) {
|
|||
// Convert the values of the appropriate timer to digits and add the
|
||||
// digits to the decoded buffer in place of the control character.
|
||||
// "EVENT timer"
|
||||
osSyncPrintf("\nEVENTタイマー = ");
|
||||
PRINTF("\nEVENTタイマー = ");
|
||||
digits[0] = digits[1] = digits[2] = 0;
|
||||
if (curChar == MESSAGE_RACE_TIME) {
|
||||
digits[3] = gSaveContext.timerSeconds;
|
||||
|
@ -1315,7 +1315,7 @@ void Message_Decode(PlayState* play) {
|
|||
// Convert the values of the current minigame score to digits and
|
||||
// add the digits to the decoded buffer in place of the control character.
|
||||
// "Yabusame score"
|
||||
osSyncPrintf("\n流鏑馬スコア = %d\n", gSaveContext.minigameScore);
|
||||
PRINTF("\n流鏑馬スコア = %d\n", gSaveContext.minigameScore);
|
||||
digits[0] = digits[1] = digits[2] = 0;
|
||||
digits[3] = gSaveContext.minigameScore;
|
||||
|
||||
|
@ -1349,7 +1349,7 @@ void Message_Decode(PlayState* play) {
|
|||
// Convert the current number of collected gold skulltula tokens to digits and
|
||||
// add the digits to the decoded buffer in place of the control character.
|
||||
// "Total number of gold stars"
|
||||
osSyncPrintf("\n金スタ合計数 = %d", gSaveContext.save.info.inventory.gsTokens);
|
||||
PRINTF("\n金スタ合計数 = %d", gSaveContext.save.info.inventory.gsTokens);
|
||||
digits[0] = digits[1] = 0;
|
||||
digits[2] = gSaveContext.save.info.inventory.gsTokens;
|
||||
|
||||
|
@ -1371,14 +1371,14 @@ void Message_Decode(PlayState* play) {
|
|||
Font_LoadChar(font, digits[i] + '0' - ' ', charTexIdx);
|
||||
msgCtx->msgBufDecoded[decodedBufPos] = digits[i] + '0';
|
||||
charTexIdx += FONT_CHAR_TEX_SIZE;
|
||||
osSyncPrintf("%x(%x) ", digits[i] + '0' - ' ', digits[i]);
|
||||
PRINTF("%x(%x) ", digits[i] + '0' - ' ', digits[i]);
|
||||
decodedBufPos++;
|
||||
}
|
||||
}
|
||||
decodedBufPos--;
|
||||
} else if (curChar == MESSAGE_FISH_INFO) {
|
||||
// "Fishing hole fish size"
|
||||
osSyncPrintf("\n釣り堀魚サイズ = ");
|
||||
PRINTF("\n釣り堀魚サイズ = ");
|
||||
digits[0] = 0;
|
||||
digits[1] = gSaveContext.minigameScore;
|
||||
|
||||
|
@ -1392,7 +1392,7 @@ void Message_Decode(PlayState* play) {
|
|||
Font_LoadChar(font, digits[i] + '0' - ' ', charTexIdx);
|
||||
msgCtx->msgBufDecoded[decodedBufPos] = digits[i] + '0';
|
||||
charTexIdx += FONT_CHAR_TEX_SIZE;
|
||||
osSyncPrintf("%x(%x) ", digits[i] + '0' - ' ', digits[i]);
|
||||
PRINTF("%x(%x) ", digits[i] + '0' - ' ', digits[i]);
|
||||
decodedBufPos++;
|
||||
}
|
||||
}
|
||||
|
@ -1400,17 +1400,17 @@ void Message_Decode(PlayState* play) {
|
|||
} else if (curChar == MESSAGE_HIGHSCORE) {
|
||||
value = HIGH_SCORE((u8)font->msgBuf[++msgCtx->msgBufPos]);
|
||||
// "Highscore"
|
||||
osSyncPrintf("ランキング=%d\n", font->msgBuf[msgCtx->msgBufPos]);
|
||||
PRINTF("ランキング=%d\n", font->msgBuf[msgCtx->msgBufPos]);
|
||||
if ((font->msgBuf[msgCtx->msgBufPos] & 0xFF) == 2) {
|
||||
if (LINK_AGE_IN_YEARS == YEARS_CHILD) {
|
||||
value &= 0x7F;
|
||||
} else {
|
||||
osSyncPrintf("HI_SCORE( kanfont->mbuff.nes_mes_buf[message->rdp] & 0xff000000 ) = %x\n",
|
||||
HIGH_SCORE(font->msgBufWide[msgCtx->msgBufPos] & 0xFF000000));
|
||||
PRINTF("HI_SCORE( kanfont->mbuff.nes_mes_buf[message->rdp] & 0xff000000 ) = %x\n",
|
||||
HIGH_SCORE(font->msgBufWide[msgCtx->msgBufPos] & 0xFF000000));
|
||||
value = ((HIGH_SCORE((u8)font->msgBuf[msgCtx->msgBufPos]) & 0xFF000000) >> 0x18) & 0x7F;
|
||||
}
|
||||
value = SQ((f32)value) * 0.0036f + 0.5f;
|
||||
osSyncPrintf("score=%d\n", value);
|
||||
PRINTF("score=%d\n", value);
|
||||
}
|
||||
switch (font->msgBuf[msgCtx->msgBufPos] & 0xFF) {
|
||||
case HS_HBA:
|
||||
|
@ -1487,7 +1487,7 @@ void Message_Decode(PlayState* play) {
|
|||
}
|
||||
} else if (curChar == MESSAGE_TIME) {
|
||||
// "Zelda time"
|
||||
osSyncPrintf("\nゼルダ時間 = ");
|
||||
PRINTF("\nゼルダ時間 = ");
|
||||
digits[0] = 0;
|
||||
timeInSeconds = gSaveContext.save.dayTime * (24.0f * 60.0f / 0x10000);
|
||||
|
||||
|
@ -1518,8 +1518,7 @@ void Message_Decode(PlayState* play) {
|
|||
decodedBufPos--;
|
||||
} else if (curChar == MESSAGE_ITEM_ICON) {
|
||||
msgCtx->msgBufDecoded[++decodedBufPos] = font->msgBuf[msgCtx->msgBufPos + 1];
|
||||
osSyncPrintf("ITEM_NO=(%d) (%d)\n", msgCtx->msgBufDecoded[decodedBufPos],
|
||||
font->msgBuf[msgCtx->msgBufPos + 1]);
|
||||
PRINTF("ITEM_NO=(%d) (%d)\n", msgCtx->msgBufDecoded[decodedBufPos], font->msgBuf[msgCtx->msgBufPos + 1]);
|
||||
Message_LoadItemIcon(play, font->msgBuf[msgCtx->msgBufPos + 1], R_TEXTBOX_Y + 10);
|
||||
} else if (curChar == MESSAGE_BACKGROUND) {
|
||||
msgCtx->textboxBackgroundIdx = font->msgBuf[msgCtx->msgBufPos + 1] * 2;
|
||||
|
@ -1548,11 +1547,11 @@ void Message_Decode(PlayState* play) {
|
|||
curChar != MESSAGE_PERSISTENT && curChar != MESSAGE_UNSKIPPABLE) {
|
||||
if (curChar == MESSAGE_FADE) {
|
||||
sTextFade = true;
|
||||
osSyncPrintf("NZ_TIMER_END (key_off_flag=%d)\n", sTextFade);
|
||||
PRINTF("NZ_TIMER_END (key_off_flag=%d)\n", sTextFade);
|
||||
msgCtx->msgBufDecoded[++decodedBufPos] = font->msgBuf[++msgCtx->msgBufPos];
|
||||
} else if (curChar == MESSAGE_FADE2) {
|
||||
sTextFade = true;
|
||||
osSyncPrintf("NZ_BGM (key_off_flag=%d)\n", sTextFade);
|
||||
PRINTF("NZ_BGM (key_off_flag=%d)\n", sTextFade);
|
||||
msgCtx->msgBufDecoded[++decodedBufPos] = font->msgBuf[++msgCtx->msgBufPos];
|
||||
msgCtx->msgBufDecoded[++decodedBufPos] = font->msgBuf[++msgCtx->msgBufPos];
|
||||
} else if (curChar == MESSAGE_SHIFT || curChar == MESSAGE_TEXT_SPEED) {
|
||||
|
@ -1620,9 +1619,9 @@ void Message_OpenText(PlayState* play, u16 textId) {
|
|||
msgCtx->textId = textId;
|
||||
|
||||
if (textId == 0x2030) { // Talking to Ingo as adult in Lon Lon Ranch for the first time before freeing Epona
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("???????????????? z_message.c ??????????????????\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("???????????????? z_message.c ??????????????????\n");
|
||||
PRINTF(VT_RST);
|
||||
gSaveContext.eventInf[0] = gSaveContext.eventInf[1] = gSaveContext.eventInf[2] = gSaveContext.eventInf[3] = 0;
|
||||
}
|
||||
|
||||
|
@ -1654,7 +1653,7 @@ void Message_OpenText(PlayState* play, u16 textId) {
|
|||
msgCtx->textBoxPos = msgCtx->textBoxProperties & 0xF;
|
||||
textBoxType = msgCtx->textBoxType;
|
||||
// "Text Box Type"
|
||||
osSyncPrintf("吹き出し種類=%d\n", msgCtx->textBoxType);
|
||||
PRINTF("吹き出し種類=%d\n", msgCtx->textBoxType);
|
||||
if (textBoxType < TEXTBOX_TYPE_NONE_BOTTOM) {
|
||||
DMA_REQUEST_SYNC(msgCtx->textboxSegment,
|
||||
(uintptr_t)_message_staticSegmentRomStart +
|
||||
|
@ -1693,10 +1692,10 @@ void Message_OpenText(PlayState* play, u16 textId) {
|
|||
void Message_StartTextbox(PlayState* play, u16 textId, Actor* actor) {
|
||||
MessageContext* msgCtx = &play->msgCtx;
|
||||
|
||||
osSyncPrintf(VT_FGCOL(BLUE));
|
||||
PRINTF(VT_FGCOL(BLUE));
|
||||
// "Message"
|
||||
osSyncPrintf("めっせーじ=%x(%d)\n", textId, actor);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("めっせーじ=%x(%d)\n", textId, actor);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
msgCtx->ocarinaAction = 0xFFFF;
|
||||
Message_OpenText(play, textId);
|
||||
|
@ -1710,10 +1709,10 @@ void Message_StartTextbox(PlayState* play, u16 textId, Actor* actor) {
|
|||
void Message_ContinueTextbox(PlayState* play, u16 textId) {
|
||||
MessageContext* msgCtx = &play->msgCtx;
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "Message"
|
||||
osSyncPrintf("めっせーじ=%x message->msg_data\n", textId, msgCtx->msgLength);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("めっせーじ=%x message->msg_data\n", textId, msgCtx->msgLength);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
msgCtx->msgLength = 0;
|
||||
Message_OpenText(play, textId);
|
||||
|
@ -1753,19 +1752,19 @@ void Message_StartOcarinaImpl(PlayState* play, u16 ocarinaActionId) {
|
|||
s16 noStopDoAction;
|
||||
s32 k;
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
|
||||
for (i = sOcarinaSongBitFlags = 0; i <= (QUEST_SONG_STORMS - QUEST_SONG_MINUET); i++) {
|
||||
if (CHECK_QUEST_ITEM(QUEST_SONG_MINUET + i)) {
|
||||
osSyncPrintf("ocarina_check_bit[%d]=%x\n", i, sOcarinaSongFlagsMap[i]);
|
||||
PRINTF("ocarina_check_bit[%d]=%x\n", i, sOcarinaSongFlagsMap[i]);
|
||||
sOcarinaSongBitFlags |= sOcarinaSongFlagsMap[i];
|
||||
}
|
||||
}
|
||||
if (gSaveContext.save.info.scarecrowSpawnSongSet) {
|
||||
sOcarinaSongBitFlags |= (1 << OCARINA_SONG_SCARECROW_SPAWN);
|
||||
}
|
||||
osSyncPrintf("ocarina_bit = %x\n", sOcarinaSongBitFlags);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("ocarina_bit = %x\n", sOcarinaSongBitFlags);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
sHasSunsSong = CHECK_QUEST_ITEM(QUEST_SONG_SUN);
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetRecordingStaff();
|
||||
|
@ -1775,7 +1774,7 @@ void Message_StartOcarinaImpl(PlayState* play, u16 ocarinaActionId) {
|
|||
sLastPlayedSong = msgCtx->unk_E3F2 = msgCtx->lastOcarinaButtonIndex = 0xFF;
|
||||
|
||||
// "Ocarina Number"
|
||||
osSyncPrintf(VT_FGCOL(RED) "☆☆☆☆☆ オカリナ番号=%d(%d) ☆☆☆☆☆\n" VT_RST, ocarinaActionId, 2);
|
||||
PRINTF(VT_FGCOL(RED) "☆☆☆☆☆ オカリナ番号=%d(%d) ☆☆☆☆☆\n" VT_RST, ocarinaActionId, 2);
|
||||
noStopDoAction = false;
|
||||
if (ocarinaActionId >= 0x893) {
|
||||
Message_OpenText(play, ocarinaActionId); // You played the [song name]
|
||||
|
@ -1785,7 +1784,7 @@ void Message_StartOcarinaImpl(PlayState* play, u16 ocarinaActionId) {
|
|||
Message_OpenText(play, 0x86D); // Play using [A] and [C].
|
||||
textId = ocarinaActionId + 0x86E;
|
||||
} else if (ocarinaActionId == OCARINA_ACTION_FREE_PLAY || ocarinaActionId >= OCARINA_ACTION_CHECK_SARIA) {
|
||||
osSyncPrintf("ocarina_set 000000000000000000 = %d\n", ocarinaActionId);
|
||||
PRINTF("ocarina_set 000000000000000000 = %d\n", ocarinaActionId);
|
||||
msgCtx->ocarinaAction = ocarinaActionId;
|
||||
if (ocarinaActionId >= OCARINA_ACTION_CHECK_SARIA && ocarinaActionId <= OCARINA_ACTION_CHECK_STORMS) {
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_TRE_BOX_APPEAR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
|
@ -1802,18 +1801,18 @@ void Message_StartOcarinaImpl(PlayState* play, u16 ocarinaActionId) {
|
|||
msgCtx->ocarinaAction = ocarinaActionId;
|
||||
noStopDoAction = true;
|
||||
if (ocarinaActionId >= OCARINA_ACTION_PLAYBACK_MINUET) {
|
||||
osSyncPrintf("222222222\n");
|
||||
PRINTF("222222222\n");
|
||||
Message_OpenText(play, 0x86D); // Play using [A] and [C].
|
||||
textId = ocarinaActionId + 0x86E;
|
||||
} else {
|
||||
osSyncPrintf("333333333\n");
|
||||
PRINTF("333333333\n");
|
||||
textId = ocarinaActionId + 0x86E;
|
||||
Message_OpenText(play, textId); // Play using [A] and [C]; [B] to Stop.
|
||||
}
|
||||
}
|
||||
msgCtx->talkActor = NULL;
|
||||
// "Ocarina Mode"
|
||||
osSyncPrintf("オカリナモード = %d (%x)\n", msgCtx->ocarinaAction, textId);
|
||||
PRINTF("オカリナモード = %d (%x)\n", msgCtx->ocarinaAction, textId);
|
||||
msgCtx->textDelayTimer = 0;
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_00;
|
||||
R_TEXTBOX_X = 34;
|
||||
|
@ -1837,7 +1836,7 @@ void Message_StartOcarinaImpl(PlayState* play, u16 ocarinaActionId) {
|
|||
gSaveContext.hudVisibilityMode = noStopDoAction;
|
||||
}
|
||||
// "Music Performance Start"
|
||||
osSyncPrintf("演奏開始\n");
|
||||
PRINTF("演奏開始\n");
|
||||
if (ocarinaActionId == OCARINA_ACTION_FREE_PLAY || ocarinaActionId == OCARINA_ACTION_CHECK_NOWARP) {
|
||||
msgCtx->msgMode = MSGMODE_OCARINA_STARTING;
|
||||
msgCtx->textBoxType = 0x63;
|
||||
|
@ -1850,7 +1849,7 @@ void Message_StartOcarinaImpl(PlayState* play, u16 ocarinaActionId) {
|
|||
msgCtx->msgMode = MSGMODE_MEMORY_GAME_START;
|
||||
} else if (ocarinaActionId == OCARINA_ACTION_SCARECROW_LONG_PLAYBACK) {
|
||||
// "?????Recording Playback / Recording Playback / Recording Playback / Recording Playback -> "
|
||||
osSyncPrintf("?????録音再生 録音再生 録音再生 録音再生 -> ");
|
||||
PRINTF("?????録音再生 録音再生 録音再生 録音再生 -> ");
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetPlaybackStaff();
|
||||
|
@ -2074,11 +2073,11 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
AudioOcarina_Start(sOcarinaSongBitFlags + 0xC000);
|
||||
} else {
|
||||
// "On Stage Performance"
|
||||
osSyncPrintf("台上演奏\n");
|
||||
PRINTF("台上演奏\n");
|
||||
AudioOcarina_Start(sOcarinaSongBitFlags);
|
||||
}
|
||||
} else {
|
||||
osSyncPrintf("Na_StartOcarinaSinglePlayCheck2( message->ocarina_no );\n");
|
||||
PRINTF("Na_StartOcarinaSinglePlayCheck2( message->ocarina_no );\n");
|
||||
AudioOcarina_Start((1 << msgCtx->ocarinaAction) + 0x8000);
|
||||
}
|
||||
msgCtx->msgMode = MSGMODE_OCARINA_PLAYING;
|
||||
|
@ -2088,7 +2087,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
} else {
|
||||
AudioOcarina_Start((1 << (msgCtx->ocarinaAction - OCARINA_ACTION_PLAYBACK_MINUET)) + 0x8000);
|
||||
// "Performance Check"
|
||||
osSyncPrintf("演奏チェック=%d\n", msgCtx->ocarinaAction - OCARINA_ACTION_PLAYBACK_MINUET);
|
||||
PRINTF("演奏チェック=%d\n", msgCtx->ocarinaAction - OCARINA_ACTION_PLAYBACK_MINUET);
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYBACK;
|
||||
}
|
||||
if (msgCtx->ocarinaAction != OCARINA_ACTION_FREE_PLAY &&
|
||||
|
@ -2099,7 +2098,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
case MSGMODE_OCARINA_PLAYING:
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetPlayingStaff();
|
||||
if (msgCtx->ocarinaStaff->pos) {
|
||||
osSyncPrintf("locate=%d onpu_pt=%d\n", msgCtx->ocarinaStaff->pos, sOcarinaButtonIndexBufPos);
|
||||
PRINTF("locate=%d onpu_pt=%d\n", msgCtx->ocarinaStaff->pos, sOcarinaButtonIndexBufPos);
|
||||
if (msgCtx->ocarinaStaff->pos == 1 && sOcarinaButtonIndexBufPos == 8) {
|
||||
sOcarinaButtonIndexBufPos = 0;
|
||||
}
|
||||
|
@ -2127,7 +2126,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
msgCtx->msgMode = MSGMODE_OCARINA_STARTING;
|
||||
} else {
|
||||
// "Ocarina_Flog Correct Example Performance"
|
||||
osSyncPrintf("Ocarina_Flog 正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
PRINTF("Ocarina_Flog 正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
Message_ContinueTextbox(play, 0x86F); // Ocarina
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYED;
|
||||
msgCtx->textBoxType = TEXTBOX_TYPE_OCARINA;
|
||||
|
@ -2147,7 +2146,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
msgCtx->msgMode = MSGMODE_OCARINA_FAIL;
|
||||
} else {
|
||||
// "Ocarina_Flog Correct Example Performance"
|
||||
osSyncPrintf("Ocarina_Flog 正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
PRINTF("Ocarina_Flog 正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
Message_ContinueTextbox(play, 0x86F); // Ocarina
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYED;
|
||||
msgCtx->textBoxType = TEXTBOX_TYPE_OCARINA;
|
||||
|
@ -2159,7 +2158,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
}
|
||||
} else if (msgCtx->ocarinaAction == OCARINA_ACTION_FREE_PLAY) {
|
||||
// "Ocarina_Free Correct Example Performance"
|
||||
osSyncPrintf("Ocarina_Free 正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
PRINTF("Ocarina_Free 正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
Message_ContinueTextbox(play, 0x86F); // Ocarina
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYED;
|
||||
msgCtx->textBoxType = TEXTBOX_TYPE_OCARINA;
|
||||
|
@ -2313,7 +2312,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_OFF);
|
||||
if (msgCtx->msgMode == MSGMODE_OCARINA_CORRECT_PLAYBACK) {
|
||||
// "Correct Example Performance"
|
||||
osSyncPrintf("正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
PRINTF("正解模範演奏=%x\n", msgCtx->lastPlayedSong);
|
||||
Message_ContinueTextbox(play, 0x86F); // Ocarina
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYED;
|
||||
msgCtx->textBoxType = TEXTBOX_TYPE_OCARINA;
|
||||
|
@ -2345,7 +2344,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
R_OCARINA_BUTTONS_YPOS_OFFSET = 1;
|
||||
if (msgCtx->msgMode == MSGMODE_SONG_PLAYBACK_FAIL) {
|
||||
// "kokokokokoko"
|
||||
osSyncPrintf("ここここここ\n");
|
||||
PRINTF("ここここここ\n");
|
||||
Message_ContinueTextbox(play, 0x88B); // red X background
|
||||
Message_Decode(play);
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYBACK_NOTES_DROP;
|
||||
|
@ -2353,7 +2352,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
msgCtx->msgMode = MSGMODE_OCARINA_NOTES_DROP;
|
||||
}
|
||||
// "Cancel"
|
||||
osSyncPrintf("キャンセル\n");
|
||||
PRINTF("キャンセル\n");
|
||||
}
|
||||
break;
|
||||
case MSGMODE_OCARINA_NOTES_DROP:
|
||||
|
@ -2379,11 +2378,11 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
msgCtx->stateTimer--;
|
||||
if (msgCtx->stateTimer == 0) {
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_OFF);
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("Na_StopOcarinaMode();\n");
|
||||
osSyncPrintf("Na_StopOcarinaMode();\n");
|
||||
osSyncPrintf("Na_StopOcarinaMode();\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("Na_StopOcarinaMode();\n");
|
||||
PRINTF("Na_StopOcarinaMode();\n");
|
||||
PRINTF("Na_StopOcarinaMode();\n");
|
||||
PRINTF(VT_RST);
|
||||
Message_Decode(play);
|
||||
msgCtx->msgMode = MSGMODE_SETUP_DISPLAY_SONG_PLAYED;
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetPlayingStaff();
|
||||
|
@ -2421,7 +2420,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
msgCtx->stateTimer--;
|
||||
if (msgCtx->stateTimer == 0) {
|
||||
// "ocarina_no=%d Song Chosen=%d"
|
||||
osSyncPrintf("ocarina_no=%d 選曲=%d\n", msgCtx->ocarinaAction, 0x16);
|
||||
PRINTF("ocarina_no=%d 選曲=%d\n", msgCtx->ocarinaAction, 0x16);
|
||||
if (msgCtx->ocarinaAction < OCARINA_ACTION_TEACH_SARIA) {
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_HARP);
|
||||
} else if (msgCtx->ocarinaAction == OCARINA_ACTION_TEACH_EPONA) {
|
||||
|
@ -2434,7 +2433,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
}
|
||||
// "Example Performance"
|
||||
osSyncPrintf("模範演奏=%x\n", msgCtx->ocarinaAction - OCARINA_ACTION_TEACH_MINUET);
|
||||
PRINTF("模範演奏=%x\n", msgCtx->ocarinaAction - OCARINA_ACTION_TEACH_MINUET);
|
||||
AudioOcarina_SetPlaybackSong(msgCtx->ocarinaAction - OCARINA_ACTION_TEACH_MINUET + 1, 2);
|
||||
sOcarinaButtonIndexBufPos = 0;
|
||||
msgCtx->msgMode = MSGMODE_SONG_DEMONSTRATION;
|
||||
|
@ -2483,35 +2482,35 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
if (msgCtx->lastPlayedSong == OCARINA_SONG_EPONAS) {
|
||||
R_EPONAS_SONG_PLAYED = true;
|
||||
}
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("☆☆☆ocarina=%d message->ocarina_no=%d ", msgCtx->lastPlayedSong,
|
||||
msgCtx->ocarinaAction);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("☆☆☆ocarina=%d message->ocarina_no=%d ", msgCtx->lastPlayedSong,
|
||||
msgCtx->ocarinaAction);
|
||||
if (msgCtx->ocarinaAction == OCARINA_ACTION_FREE_PLAY_DONE) {
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_01;
|
||||
if (msgCtx->lastPlayedSong == OCARINA_SONG_SCARECROW_SPAWN) {
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_0B;
|
||||
}
|
||||
} else if (msgCtx->ocarinaAction >= OCARINA_ACTION_CHECK_MINUET) {
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("Ocarina_PC_Wind=%d(%d) ☆☆☆ ", OCARINA_ACTION_CHECK_MINUET,
|
||||
msgCtx->ocarinaAction - OCARINA_ACTION_CHECK_MINUET);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("Ocarina_PC_Wind=%d(%d) ☆☆☆ ", OCARINA_ACTION_CHECK_MINUET,
|
||||
msgCtx->ocarinaAction - OCARINA_ACTION_CHECK_MINUET);
|
||||
if (msgCtx->lastPlayedSong == (msgCtx->ocarinaAction - OCARINA_ACTION_CHECK_MINUET)) {
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_03;
|
||||
} else {
|
||||
play->msgCtx.ocarinaMode = msgCtx->lastPlayedSong - 1;
|
||||
}
|
||||
} else {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("Ocarina_C_Wind=%d(%d) ☆☆☆ ", OCARINA_ACTION_PLAYBACK_MINUET,
|
||||
msgCtx->ocarinaAction - OCARINA_ACTION_PLAYBACK_MINUET);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("Ocarina_C_Wind=%d(%d) ☆☆☆ ", OCARINA_ACTION_PLAYBACK_MINUET,
|
||||
msgCtx->ocarinaAction - OCARINA_ACTION_PLAYBACK_MINUET);
|
||||
if (msgCtx->lastPlayedSong == (msgCtx->ocarinaAction - OCARINA_ACTION_PLAYBACK_MINUET)) {
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_03;
|
||||
} else {
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_04;
|
||||
}
|
||||
}
|
||||
osSyncPrintf(VT_RST);
|
||||
osSyncPrintf("→ OCARINA_MODE=%d\n", play->msgCtx.ocarinaMode);
|
||||
PRINTF(VT_RST);
|
||||
PRINTF("→ OCARINA_MODE=%d\n", play->msgCtx.ocarinaMode);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
@ -2524,8 +2523,8 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
} else {
|
||||
msgCtx->msgMode = MSGMODE_SONG_DEMONSTRATION_DONE;
|
||||
}
|
||||
osSyncPrintf("onpu_buff[%d]=%x\n", msgCtx->ocarinaStaff->pos,
|
||||
sOcarinaButtonIndexBuf[msgCtx->ocarinaStaff->pos]);
|
||||
PRINTF("onpu_buff[%d]=%x\n", msgCtx->ocarinaStaff->pos,
|
||||
sOcarinaButtonIndexBuf[msgCtx->ocarinaStaff->pos]);
|
||||
} else {
|
||||
if (sOcarinaButtonIndexBufPos != 0 && msgCtx->ocarinaStaff->pos == 1) {
|
||||
sOcarinaButtonIndexBufPos = 0;
|
||||
|
@ -2551,15 +2550,15 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
sOcarinaButtonIndexBufPos++;
|
||||
}
|
||||
if (msgCtx->ocarinaStaff->state < OCARINA_SONG_MEMORY_GAME) {
|
||||
osSyncPrintf("M_OCARINA20 : ocarina_no=%x status=%x\n", msgCtx->ocarinaAction,
|
||||
msgCtx->ocarinaStaff->state);
|
||||
PRINTF("M_OCARINA20 : ocarina_no=%x status=%x\n", msgCtx->ocarinaAction,
|
||||
msgCtx->ocarinaStaff->state);
|
||||
msgCtx->lastPlayedSong = msgCtx->ocarinaStaff->state;
|
||||
msgCtx->msgMode = MSGMODE_SONG_PLAYBACK_SUCCESS;
|
||||
Item_Give(play, ITEM_SONG_MINUET + gOcarinaSongItemMap[msgCtx->ocarinaStaff->state]);
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
// "z_message.c Song Acquired"
|
||||
osSyncPrintf("z_message.c 取得メロディ=%d\n", ITEM_SONG_MINUET + msgCtx->ocarinaStaff->state);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("z_message.c 取得メロディ=%d\n", ITEM_SONG_MINUET + msgCtx->ocarinaStaff->state);
|
||||
PRINTF(VT_RST);
|
||||
msgCtx->stateTimer = 20;
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_TRE_BOX_APPEAR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
|
@ -2579,7 +2578,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
break;
|
||||
case MSGMODE_SCARECROW_LONG_RECORDING_START:
|
||||
// "Scarecrow Recording Initialization"
|
||||
osSyncPrintf("案山子録音 初期化\n");
|
||||
PRINTF("案山子録音 初期化\n");
|
||||
AudioOcarina_SetRecordingState(OCARINA_RECORD_SCARECROW_LONG);
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_DEFAULT);
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetRecordingStaff();
|
||||
|
@ -2591,7 +2590,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
break;
|
||||
case MSGMODE_SCARECROW_LONG_RECORDING_ONGOING:
|
||||
msgCtx->ocarinaStaff = AudioOcarina_GetRecordingStaff();
|
||||
osSyncPrintf("\nonpu_pt=%d, locate=%d", sOcarinaButtonIndexBufPos, msgCtx->ocarinaStaff->pos);
|
||||
PRINTF("\nonpu_pt=%d, locate=%d", sOcarinaButtonIndexBufPos, msgCtx->ocarinaStaff->pos);
|
||||
if (((u32)msgCtx->ocarinaStaff->pos != 0) &&
|
||||
(sOcarinaButtonIndexBufPos == msgCtx->ocarinaStaff->pos - 1)) {
|
||||
if (sOcarinaButtonIndexBufLen >= 8) {
|
||||
|
@ -2601,8 +2600,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
sOcarinaButtonIndexBufLen--;
|
||||
}
|
||||
// "Button Entered"
|
||||
osSyncPrintf(" 入力ボタン【%d】=%d", sOcarinaButtonIndexBufLen,
|
||||
msgCtx->ocarinaStaff->buttonIndex);
|
||||
PRINTF(" 入力ボタン【%d】=%d", sOcarinaButtonIndexBufLen, msgCtx->ocarinaStaff->buttonIndex);
|
||||
msgCtx->lastOcarinaButtonIndex = sOcarinaButtonIndexBuf[sOcarinaButtonIndexBufLen] =
|
||||
msgCtx->ocarinaStaff->buttonIndex;
|
||||
sOcarinaButtonIndexBufLen++;
|
||||
|
@ -2616,28 +2614,27 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
CHECK_BTN_ALL(play->state.input[0].press.button, BTN_B)) {
|
||||
if (sOcarinaButtonIndexBufLen != 0) {
|
||||
// "Recording complete!!!!!!!!!"
|
||||
osSyncPrintf("録音終了!!!!!!!!! message->info->status=%d \n",
|
||||
msgCtx->ocarinaStaff->state);
|
||||
PRINTF("録音終了!!!!!!!!! message->info->status=%d \n", msgCtx->ocarinaStaff->state);
|
||||
gSaveContext.save.info.scarecrowLongSongSet = true;
|
||||
}
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_OCARINA_ERROR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
osSyncPrintf("aaaaaaaaaaaaaa\n");
|
||||
PRINTF("aaaaaaaaaaaaaa\n");
|
||||
AudioOcarina_SetRecordingState(OCARINA_RECORD_OFF);
|
||||
msgCtx->stateTimer = 10;
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_04;
|
||||
Message_CloseTextbox(play);
|
||||
// "Recording complete!!!!!!!!!Recording Complete"
|
||||
osSyncPrintf("録音終了!!!!!!!!!録音終了\n");
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
PRINTF("録音終了!!!!!!!!!録音終了\n");
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("\n====================================================================\n");
|
||||
MemCpy(gSaveContext.save.info.scarecrowLongSong, gScarecrowLongSongPtr,
|
||||
sizeof(gSaveContext.save.info.scarecrowLongSong));
|
||||
for (i = 0; i < ARRAY_COUNT(gSaveContext.save.info.scarecrowLongSong); i++) {
|
||||
osSyncPrintf("%d, ", gSaveContext.save.info.scarecrowLongSong[i]);
|
||||
PRINTF("%d, ", gSaveContext.save.info.scarecrowLongSong[i]);
|
||||
}
|
||||
osSyncPrintf(VT_RST);
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
PRINTF(VT_RST);
|
||||
PRINTF("\n====================================================================\n");
|
||||
}
|
||||
Message_DrawText(play, &gfx);
|
||||
break;
|
||||
|
@ -2660,10 +2657,10 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
sOcarinaButtonIndexBufLen = sOcarinaButtonIndexBufPos = 0;
|
||||
}
|
||||
}
|
||||
osSyncPrintf("status=%d (%d)\n", msgCtx->ocarinaStaff->state, 0);
|
||||
PRINTF("status=%d (%d)\n", msgCtx->ocarinaStaff->state, 0);
|
||||
if (msgCtx->stateTimer == 0) {
|
||||
if (msgCtx->ocarinaStaff->state == 0) {
|
||||
osSyncPrintf("bbbbbbbbbbb\n");
|
||||
PRINTF("bbbbbbbbbbb\n");
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_OFF);
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_0F;
|
||||
Message_CloseTextbox(play);
|
||||
|
@ -2689,25 +2686,25 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
}
|
||||
if (msgCtx->ocarinaStaff->state == OCARINA_RECORD_OFF) {
|
||||
// "8 Note Recording OK!"
|
||||
osSyncPrintf("8音録音OK!\n");
|
||||
PRINTF("8音録音OK!\n");
|
||||
msgCtx->stateTimer = 20;
|
||||
gSaveContext.save.info.scarecrowSpawnSongSet = true;
|
||||
msgCtx->msgMode = MSGMODE_SCARECROW_SPAWN_RECORDING_DONE;
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_TRE_BOX_APPEAR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("\n====================================================================\n");
|
||||
MemCpy(gSaveContext.save.info.scarecrowSpawnSong, gScarecrowSpawnSongPtr,
|
||||
sizeof(gSaveContext.save.info.scarecrowSpawnSong));
|
||||
for (i = 0; i < ARRAY_COUNT(gSaveContext.save.info.scarecrowSpawnSong); i++) {
|
||||
osSyncPrintf("%d, ", gSaveContext.save.info.scarecrowSpawnSong[i]);
|
||||
PRINTF("%d, ", gSaveContext.save.info.scarecrowSpawnSong[i]);
|
||||
}
|
||||
osSyncPrintf(VT_RST);
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
PRINTF(VT_RST);
|
||||
PRINTF("\n====================================================================\n");
|
||||
} else if (msgCtx->ocarinaStaff->state == OCARINA_RECORD_REJECTED ||
|
||||
CHECK_BTN_ALL(play->state.input[0].press.button, BTN_B)) {
|
||||
// "Played an existing song!!!"
|
||||
osSyncPrintf("すでに存在する曲吹いた!!! \n");
|
||||
PRINTF("すでに存在する曲吹いた!!! \n");
|
||||
AudioOcarina_SetRecordingState(OCARINA_RECORD_OFF);
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_OCARINA_ERROR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
|
@ -2717,7 +2714,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
Message_DrawText(play, &gfx);
|
||||
break;
|
||||
case MSGMODE_SCARECROW_SPAWN_RECORDING_FAILED:
|
||||
osSyncPrintf("cccccccccccc\n");
|
||||
PRINTF("cccccccccccc\n");
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_OFF);
|
||||
Message_StartTextbox(play, 0x40AD, NULL); // Bonooru doesn't remember your song
|
||||
play->msgCtx.ocarinaMode = OCARINA_MODE_04;
|
||||
|
@ -2781,7 +2778,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
}
|
||||
if (msgCtx->ocarinaStaff->state == 0xFF) {
|
||||
// "Musical round failed!!!!!!!!!"
|
||||
osSyncPrintf("輪唱失敗!!!!!!!!!\n");
|
||||
PRINTF("輪唱失敗!!!!!!!!!\n");
|
||||
AudioOcarina_SetInstrument(OCARINA_INSTRUMENT_OFF);
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_OCARINA_ERROR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
|
@ -2789,7 +2786,7 @@ void Message_DrawMain(PlayState* play, Gfx** p) {
|
|||
play->msgCtx.ocarinaMode = OCARINA_MODE_03;
|
||||
} else if (msgCtx->ocarinaStaff->state == OCARINA_SONG_MEMORY_GAME) {
|
||||
// "Musical round succeeded!!!!!!!!!"
|
||||
osSyncPrintf("輪唱成功!!!!!!!!!\n");
|
||||
PRINTF("輪唱成功!!!!!!!!!\n");
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_GET_ITEM, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
msgCtx->msgMode = MSGMODE_MEMORY_GAME_ROUND_SUCCESS;
|
||||
|
@ -3068,7 +3065,7 @@ void Message_Update(PlayState* play) {
|
|||
|
||||
if (BREG(0) != 0) {
|
||||
if (CHECK_BTN_ALL(input->press.button, BTN_DDOWN) && CHECK_BTN_ALL(input->cur.button, BTN_L)) {
|
||||
osSyncPrintf("msgno=%d\n", D_80153D78);
|
||||
PRINTF("msgno=%d\n", D_80153D78);
|
||||
Message_StartTextbox(play, R_MESSAGE_DEBUGGER_TEXTID, NULL);
|
||||
D_80153D78 = (D_80153D78 + 1) % 10;
|
||||
}
|
||||
|
@ -3079,7 +3076,7 @@ void Message_Update(PlayState* play) {
|
|||
while (entry->textId != 0xFFFD) {
|
||||
if (entry->textId == R_MESSAGE_DEBUGGER_TEXTID) {
|
||||
// "The message was found! !! !!"
|
||||
osSyncPrintf(" メッセージが,見つかった!!! = %x\n", R_MESSAGE_DEBUGGER_TEXTID);
|
||||
PRINTF(" メッセージが,見つかった!!! = %x\n", R_MESSAGE_DEBUGGER_TEXTID);
|
||||
Message_StartTextbox(play, R_MESSAGE_DEBUGGER_TEXTID, NULL);
|
||||
R_MESSAGE_DEBUGGER_TEXTID++;
|
||||
R_MESSAGE_DEBUGGER_SELECT = 0;
|
||||
|
@ -3122,8 +3119,8 @@ void Message_Update(PlayState* play) {
|
|||
} else {
|
||||
averageY = ((actorFocusScreenPosY - playerFocusScreenPosY) / 2) + playerFocusScreenPosY;
|
||||
}
|
||||
osSyncPrintf("dxpos=%d dypos=%d dypos1 dypos2=%d\n", focusScreenPosX, averageY,
|
||||
playerFocusScreenPosY, actorFocusScreenPosY);
|
||||
PRINTF("dxpos=%d dypos=%d dypos1 dypos2=%d\n", focusScreenPosX, averageY, playerFocusScreenPosY,
|
||||
actorFocusScreenPosY);
|
||||
} else {
|
||||
R_TEXTBOX_X = R_TEXTBOX_X_TARGET;
|
||||
R_TEXTBOX_Y = R_TEXTBOX_Y_TARGET;
|
||||
|
@ -3166,7 +3163,7 @@ void Message_Update(PlayState* play) {
|
|||
R_TEXT_CHOICE_YPOS(0) = R_TEXTBOX_Y_TARGET + 20;
|
||||
R_TEXT_CHOICE_YPOS(1) = R_TEXTBOX_Y_TARGET + 32;
|
||||
R_TEXT_CHOICE_YPOS(2) = R_TEXTBOX_Y_TARGET + 44;
|
||||
osSyncPrintf("message->msg_disp_type=%x\n", msgCtx->textBoxProperties & 0xF0);
|
||||
PRINTF("message->msg_disp_type=%x\n", msgCtx->textBoxProperties & 0xF0);
|
||||
if (msgCtx->textBoxType == TEXTBOX_TYPE_NONE_BOTTOM ||
|
||||
msgCtx->textBoxType == TEXTBOX_TYPE_NONE_NO_SHADOW) {
|
||||
msgCtx->msgMode = MSGMODE_TEXT_STARTING;
|
||||
|
@ -3245,15 +3242,15 @@ void Message_Update(PlayState* play) {
|
|||
msgCtx->textboxEndType != TEXTBOX_ENDTYPE_EVENT && YREG(31) == 0) {
|
||||
if (msgCtx->textboxEndType == TEXTBOX_ENDTYPE_2_CHOICE && play->msgCtx.ocarinaMode == OCARINA_MODE_01) {
|
||||
if (Message_ShouldAdvance(play)) {
|
||||
osSyncPrintf("OCARINA_MODE=%d -> ", play->msgCtx.ocarinaMode);
|
||||
PRINTF("OCARINA_MODE=%d -> ", play->msgCtx.ocarinaMode);
|
||||
play->msgCtx.ocarinaMode = (msgCtx->choiceIndex == 0) ? OCARINA_MODE_02 : OCARINA_MODE_04;
|
||||
osSyncPrintf("InRaceSeq=%d(%d) OCARINA_MODE=%d --> ", GET_EVENTINF_HORSES_STATE(), 1,
|
||||
play->msgCtx.ocarinaMode);
|
||||
PRINTF("InRaceSeq=%d(%d) OCARINA_MODE=%d --> ", GET_EVENTINF_HORSES_STATE(), 1,
|
||||
play->msgCtx.ocarinaMode);
|
||||
Message_CloseTextbox(play);
|
||||
osSyncPrintf("OCARINA_MODE=%d\n", play->msgCtx.ocarinaMode);
|
||||
PRINTF("OCARINA_MODE=%d\n", play->msgCtx.ocarinaMode);
|
||||
}
|
||||
} else if (Message_ShouldAdvanceSilent(play)) {
|
||||
osSyncPrintf("select=%d\n", msgCtx->textboxEndType);
|
||||
PRINTF("select=%d\n", msgCtx->textboxEndType);
|
||||
if (msgCtx->textboxEndType == TEXTBOX_ENDTYPE_HAS_NEXT) {
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_MESSAGE_PASS, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
|
@ -3281,13 +3278,13 @@ void Message_Update(PlayState* play) {
|
|||
gSaveContext.prevHudVisibilityMode = HUD_VISIBILITY_ALL;
|
||||
}
|
||||
if (play->csCtx.state == 0) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("day_time=%x active_camera=%d ", gSaveContext.save.cutsceneIndex, play->activeCamId);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("day_time=%x active_camera=%d ", gSaveContext.save.cutsceneIndex, play->activeCamId);
|
||||
|
||||
if (msgCtx->textId != 0x2061 && msgCtx->textId != 0x2025 && msgCtx->textId != 0x208C &&
|
||||
((msgCtx->textId < 0x88D || msgCtx->textId >= 0x893) || msgCtx->choiceIndex != 0) &&
|
||||
(msgCtx->textId != 0x3055 && gSaveContext.save.cutsceneIndex < 0xFFF0)) {
|
||||
osSyncPrintf("=== day_time=%x ", ((void)0, gSaveContext.save.cutsceneIndex));
|
||||
PRINTF("=== day_time=%x ", ((void)0, gSaveContext.save.cutsceneIndex));
|
||||
if (play->activeCamId == CAM_ID_MAIN) {
|
||||
if (gSaveContext.prevHudVisibilityMode == HUD_VISIBILITY_NO_CHANGE ||
|
||||
gSaveContext.prevHudVisibilityMode == HUD_VISIBILITY_NOTHING ||
|
||||
|
@ -3299,7 +3296,7 @@ void Message_Update(PlayState* play) {
|
|||
}
|
||||
}
|
||||
}
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
msgCtx->msgLength = 0;
|
||||
msgCtx->msgMode = MSGMODE_NONE;
|
||||
interfaceCtx->unk_1FA = interfaceCtx->unk_1FC = 0;
|
||||
|
@ -3334,7 +3331,7 @@ void Message_Update(PlayState* play) {
|
|||
}
|
||||
}
|
||||
sLastPlayedSong = 0xFF;
|
||||
osSyncPrintf("OCARINA_MODE=%d chk_ocarina_no=%d\n", play->msgCtx.ocarinaMode, msgCtx->unk_E3F2);
|
||||
PRINTF("OCARINA_MODE=%d chk_ocarina_no=%d\n", play->msgCtx.ocarinaMode, msgCtx->unk_E3F2);
|
||||
break;
|
||||
case MSGMODE_PAUSED:
|
||||
break;
|
||||
|
|
|
@ -65,7 +65,7 @@ void Moji_DrawChar(GraphicsContext* gfxCtx, char c) {
|
|||
OPEN_DISPS(gfxCtx, "../z_moji.c", 86);
|
||||
|
||||
if ((uintptr_t)gMojiFontTLUTs & 0xF) {
|
||||
osSyncPrintf("moji_tlut --> %X\n", gMojiFontTLUTs);
|
||||
PRINTF("moji_tlut --> %X\n", gMojiFontTLUTs);
|
||||
}
|
||||
|
||||
if (sCurTLUTIndex != GET_CHAR_TLUT_INDEX(c)) {
|
||||
|
@ -91,7 +91,7 @@ void Moji_DrawString(GraphicsContext* gfxCtx, const char* str) {
|
|||
OPEN_DISPS(gfxCtx, "../z_moji.c", 137);
|
||||
|
||||
if ((uintptr_t)gMojiFontTex & 0xF) {
|
||||
osSyncPrintf("font_ff --> %X\n", gMojiFontTex);
|
||||
PRINTF("font_ff --> %X\n", gMojiFontTex);
|
||||
}
|
||||
|
||||
gDPPipeSync(POLY_OPA_DISP++);
|
||||
|
|
|
@ -258,8 +258,7 @@ s32 OnePointCutscene_SetInfo(PlayState* play, s16 subCamId, s16 csId, Actor* act
|
|||
D_801211D4[0].atTargetInit.y = actor->focus.pos.y - 5.0f;
|
||||
D_801211D4[0].atTargetInit.z = actor->focus.pos.z;
|
||||
spC0 = ((EnSw*)actor)->unk_364;
|
||||
osSyncPrintf("%s(%d): xyz_t: %s (%f %f %f)\n", "../z_onepointdemo.c", 1671, "&cp", spC0.x, spC0.y,
|
||||
spC0.z);
|
||||
PRINTF("%s(%d): xyz_t: %s (%f %f %f)\n", "../z_onepointdemo.c", 1671, "&cp", spC0.x, spC0.y, spC0.z);
|
||||
D_801211D4[0].eyeTargetInit.x = (actor->focus.pos.x + (120.0f * spC0.x)) - (Rand_ZeroOne() * 20.0f);
|
||||
D_801211D4[0].eyeTargetInit.y = actor->focus.pos.y + (120.0f * spC0.y) + 20.0f;
|
||||
D_801211D4[0].eyeTargetInit.z = (actor->focus.pos.z + (120.0f * spC0.z)) - (Rand_ZeroOne() * 20.0f);
|
||||
|
@ -1192,7 +1191,7 @@ s32 OnePointCutscene_SetInfo(PlayState* play, s16 subCamId, s16 csId, Actor* act
|
|||
break;
|
||||
|
||||
default:
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "onepointdemo camera: demo number not found !! (%d)\n" VT_RST, csId);
|
||||
PRINTF(VT_COL(RED, WHITE) "onepointdemo camera: demo number not found !! (%d)\n" VT_RST, csId);
|
||||
break;
|
||||
}
|
||||
return 0;
|
||||
|
@ -1250,7 +1249,7 @@ s16 OnePointCutscene_Init(PlayState* play, s16 csId, s16 timer, Actor* actor, s1
|
|||
}
|
||||
subCamId = Play_CreateSubCamera(play);
|
||||
if (subCamId == CAM_ID_NONE) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "onepoint demo: error: too many cameras ... give up! type=%d\n" VT_RST, csId);
|
||||
PRINTF(VT_COL(RED, WHITE) "onepoint demo: error: too many cameras ... give up! type=%d\n" VT_RST, csId);
|
||||
return CAM_ID_NONE;
|
||||
}
|
||||
|
||||
|
@ -1294,8 +1293,8 @@ s16 OnePointCutscene_Init(PlayState* play, s16 csId, s16 timer, Actor* actor, s1
|
|||
s16 thisCsId = play->cameraPtrs[subCamId]->csId;
|
||||
|
||||
if ((nextCsId / 100) < (thisCsId / 100)) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "onepointdemo camera[%d]: killed 'coz low priority (%d < %d)\n" VT_RST,
|
||||
vNextCamId, nextCsId, thisCsId);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "onepointdemo camera[%d]: killed 'coz low priority (%d < %d)\n" VT_RST,
|
||||
vNextCamId, nextCsId, thisCsId);
|
||||
if (play->cameraPtrs[vNextCamId]->csId != 5010) {
|
||||
if ((vNextCamId = OnePointCutscene_RemoveCamera(play, vNextCamId)) != CAM_ID_NONE) {
|
||||
Play_ChangeCameraStatus(play, vNextCamId, CAM_STAT_ACTIVE);
|
||||
|
@ -1320,8 +1319,8 @@ s16 OnePointCutscene_EndCutscene(PlayState* play, s16 subCamId) {
|
|||
subCamId = play->activeCamId;
|
||||
}
|
||||
if (play->cameraPtrs[subCamId] != NULL) {
|
||||
osSyncPrintf("onepointdemo camera[%d]: delete timer=%d next=%d\n", subCamId, play->cameraPtrs[subCamId]->timer,
|
||||
play->cameraPtrs[subCamId]->parentCamId);
|
||||
PRINTF("onepointdemo camera[%d]: delete timer=%d next=%d\n", subCamId, play->cameraPtrs[subCamId]->timer,
|
||||
play->cameraPtrs[subCamId]->parentCamId);
|
||||
if (play->cameraPtrs[subCamId]->csId == 5010) {
|
||||
play->cameraPtrs[subCamId]->timer = 5;
|
||||
} else {
|
||||
|
@ -1346,14 +1345,14 @@ s32 OnePointCutscene_Attention(PlayState* play, Actor* actor) {
|
|||
s32 timer;
|
||||
|
||||
if (sDisableAttention) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "actor attention demo camera: canceled by other camera\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "actor attention demo camera: canceled by other camera\n" VT_RST);
|
||||
return CAM_ID_NONE;
|
||||
}
|
||||
sUnused = -1;
|
||||
|
||||
parentCam = play->cameraPtrs[CAM_ID_MAIN];
|
||||
if (parentCam->mode == CAM_MODE_FOLLOW_BOOMERANG) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "actor attention demo camera: change mode BOOKEEPON -> NORMAL\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "actor attention demo camera: change mode BOOKEEPON -> NORMAL\n" VT_RST);
|
||||
Camera_RequestMode(parentCam, CAM_MODE_NORMAL);
|
||||
}
|
||||
|
||||
|
@ -1401,23 +1400,23 @@ s32 OnePointCutscene_Attention(PlayState* play, Actor* actor) {
|
|||
case ACTORCAT_MISC:
|
||||
case ACTORCAT_BOSS:
|
||||
default:
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "actor attention demo camera: %d: unkown part of actor %d\n" VT_RST,
|
||||
play->state.frames, actor->category);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "actor attention demo camera: %d: unkown part of actor %d\n" VT_RST,
|
||||
play->state.frames, actor->category);
|
||||
timer = 30;
|
||||
break;
|
||||
}
|
||||
osSyncPrintf(VT_FGCOL(CYAN) "%06u:" VT_RST " actor attention demo camera: request %d ", play->state.frames,
|
||||
actor->category);
|
||||
PRINTF(VT_FGCOL(CYAN) "%06u:" VT_RST " actor attention demo camera: request %d ", play->state.frames,
|
||||
actor->category);
|
||||
|
||||
// If the previous attention cutscene has an actor in the same category, skip this actor.
|
||||
if (actor->category == vLastHigherCat) {
|
||||
osSyncPrintf("→ " VT_FGCOL(MAGENTA) "×" VT_RST " (%d)\n", actor->id);
|
||||
PRINTF("→ " VT_FGCOL(MAGENTA) "×" VT_RST " (%d)\n", actor->id);
|
||||
return CAM_ID_NONE;
|
||||
}
|
||||
osSyncPrintf("→ " VT_FGCOL(BLUE) "○" VT_RST " (%d)\n", actor->id);
|
||||
PRINTF("→ " VT_FGCOL(BLUE) "○" VT_RST " (%d)\n", actor->id);
|
||||
vSubCamId = OnePointCutscene_Init(play, 5010, timer, actor, vParentCamId);
|
||||
if (vSubCamId == CAM_ID_NONE) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "actor attention demo: give up! \n" VT_RST, actor->id);
|
||||
PRINTF(VT_COL(RED, WHITE) "actor attention demo: give up! \n" VT_RST, actor->id);
|
||||
return CAM_ID_NONE;
|
||||
} else {
|
||||
s32* data = (s32*)&play->cameraPtrs[vSubCamId]->data1;
|
||||
|
|
|
@ -166,8 +166,7 @@ static Gfx sSetupDL_80125A60[] = {
|
|||
// original name: "alpha_change"
|
||||
void Interface_ChangeHudVisibilityMode(u16 hudVisibilityMode) {
|
||||
if (hudVisibilityMode != gSaveContext.hudVisibilityMode) {
|
||||
osSyncPrintf("ALPHAーTYPE=%d LAST_TIME_TYPE=%d\n", hudVisibilityMode,
|
||||
gSaveContext.prevHudVisibilityMode);
|
||||
PRINTF("ALPHAーTYPE=%d LAST_TIME_TYPE=%d\n", hudVisibilityMode, gSaveContext.prevHudVisibilityMode);
|
||||
gSaveContext.hudVisibilityMode = gSaveContext.nextHudVisibilityMode = hudVisibilityMode;
|
||||
gSaveContext.hudVisibilityModeTimer = 1;
|
||||
}
|
||||
|
@ -272,7 +271,7 @@ void Interface_UpdateHudAlphas(PlayState* play, s16 dimmingAlpha) {
|
|||
case HUD_VISIBILITY_NOTHING:
|
||||
case HUD_VISIBILITY_NOTHING_ALT:
|
||||
case HUD_VISIBILITY_B:
|
||||
osSyncPrintf("a_alpha=%d, c_alpha=%d → ", interfaceCtx->aAlpha, interfaceCtx->cLeftAlpha);
|
||||
PRINTF("a_alpha=%d, c_alpha=%d → ", interfaceCtx->aAlpha, interfaceCtx->cLeftAlpha);
|
||||
|
||||
if (gSaveContext.nextHudVisibilityMode == HUD_VISIBILITY_B) {
|
||||
if (interfaceCtx->bAlpha != 255) {
|
||||
|
@ -312,7 +311,7 @@ void Interface_UpdateHudAlphas(PlayState* play, s16 dimmingAlpha) {
|
|||
interfaceCtx->minimapAlpha = dimmingAlpha;
|
||||
}
|
||||
|
||||
osSyncPrintf("a_alpha=%d, c_alpha=%d\n", interfaceCtx->aAlpha, interfaceCtx->cLeftAlpha);
|
||||
PRINTF("a_alpha=%d, c_alpha=%d\n", interfaceCtx->aAlpha, interfaceCtx->cLeftAlpha);
|
||||
|
||||
break;
|
||||
|
||||
|
@ -996,7 +995,7 @@ void func_80083108(PlayState* play) {
|
|||
}
|
||||
|
||||
gSaveContext.buttonStatus[i] = BTN_DISABLED;
|
||||
osSyncPrintf("***(i=%d)*** ", i);
|
||||
PRINTF("***(i=%d)*** ", i);
|
||||
}
|
||||
}
|
||||
} else if (interfaceCtx->restrictions.farores == 0) {
|
||||
|
@ -1088,9 +1087,9 @@ void func_80083108(PlayState* play) {
|
|||
gSaveContext.hudVisibilityMode = HUD_VISIBILITY_NO_CHANGE;
|
||||
if ((play->transitionTrigger == TRANS_TRIGGER_OFF) && (play->transitionMode == TRANS_MODE_OFF)) {
|
||||
Interface_ChangeHudVisibilityMode(HUD_VISIBILITY_ALL);
|
||||
osSyncPrintf("???????? alpha_change( 50 ); ?????\n");
|
||||
PRINTF("???????? alpha_change( 50 ); ?????\n");
|
||||
} else {
|
||||
osSyncPrintf("game_play->fade_direction || game_play->fbdemo_wipe_modem");
|
||||
PRINTF("game_play->fade_direction || game_play->fbdemo_wipe_modem");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1110,7 +1109,7 @@ void Interface_SetSceneRestrictions(PlayState* play) {
|
|||
i = 0;
|
||||
|
||||
// "Data settings related to button display scene_data_ID=%d\n"
|
||||
osSyncPrintf("ボタン表示関係データ設定 scene_data_ID=%d\n", play->sceneId);
|
||||
PRINTF("ボタン表示関係データ設定 scene_data_ID=%d\n", play->sceneId);
|
||||
|
||||
do {
|
||||
sceneId = (u8)play->sceneId;
|
||||
|
@ -1128,19 +1127,19 @@ void Interface_SetSceneRestrictions(PlayState* play) {
|
|||
interfaceCtx->restrictions.dinsNayrus = (sRestrictionFlags[i].flags3 & 0x0C) >> 2;
|
||||
interfaceCtx->restrictions.all = (sRestrictionFlags[i].flags3 & 0x03) >> 0;
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("parameter->button_status = %x,%x,%x\n", sRestrictionFlags[i].flags1,
|
||||
sRestrictionFlags[i].flags2, sRestrictionFlags[i].flags3);
|
||||
osSyncPrintf("h_gage=%d, b_button=%d, a_button=%d, c_bottle=%d\n", interfaceCtx->restrictions.hGauge,
|
||||
interfaceCtx->restrictions.bButton, interfaceCtx->restrictions.aButton,
|
||||
interfaceCtx->restrictions.bottles);
|
||||
osSyncPrintf("c_warasibe=%d, c_hook=%d, c_ocarina=%d, c_warp=%d\n", interfaceCtx->restrictions.tradeItems,
|
||||
interfaceCtx->restrictions.hookshot, interfaceCtx->restrictions.ocarina,
|
||||
interfaceCtx->restrictions.warpSongs);
|
||||
osSyncPrintf("c_sunmoon=%d, m_wind=%d, m_magic=%d, another=%d\n", interfaceCtx->restrictions.sunsSong,
|
||||
interfaceCtx->restrictions.farores, interfaceCtx->restrictions.dinsNayrus,
|
||||
interfaceCtx->restrictions.all);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("parameter->button_status = %x,%x,%x\n", sRestrictionFlags[i].flags1, sRestrictionFlags[i].flags2,
|
||||
sRestrictionFlags[i].flags3);
|
||||
PRINTF("h_gage=%d, b_button=%d, a_button=%d, c_bottle=%d\n", interfaceCtx->restrictions.hGauge,
|
||||
interfaceCtx->restrictions.bButton, interfaceCtx->restrictions.aButton,
|
||||
interfaceCtx->restrictions.bottles);
|
||||
PRINTF("c_warasibe=%d, c_hook=%d, c_ocarina=%d, c_warp=%d\n", interfaceCtx->restrictions.tradeItems,
|
||||
interfaceCtx->restrictions.hookshot, interfaceCtx->restrictions.ocarina,
|
||||
interfaceCtx->restrictions.warpSongs);
|
||||
PRINTF("c_sunmoon=%d, m_wind=%d, m_magic=%d, another=%d\n", interfaceCtx->restrictions.sunsSong,
|
||||
interfaceCtx->restrictions.farores, interfaceCtx->restrictions.dinsNayrus,
|
||||
interfaceCtx->restrictions.all);
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
i++;
|
||||
|
@ -1225,7 +1224,7 @@ void Inventory_SwapAgeEquipment(void) {
|
|||
(gSaveContext.save.info.equips.buttonItems[i] <= ITEM_BOTTLE_POE)) ||
|
||||
((gSaveContext.save.info.equips.buttonItems[i] >= ITEM_WEIRD_EGG) &&
|
||||
(gSaveContext.save.info.equips.buttonItems[i] <= ITEM_CLAIM_CHECK))) {
|
||||
osSyncPrintf("Register_Item_Pt(%d)=%d\n", i, gSaveContext.save.info.equips.cButtonSlots[i - 1]);
|
||||
PRINTF("Register_Item_Pt(%d)=%d\n", i, gSaveContext.save.info.equips.cButtonSlots[i - 1]);
|
||||
gSaveContext.save.info.equips.buttonItems[i] =
|
||||
gSaveContext.save.info.inventory.items[gSaveContext.save.info.equips.cButtonSlots[i - 1]];
|
||||
}
|
||||
|
@ -1259,7 +1258,7 @@ void Inventory_SwapAgeEquipment(void) {
|
|||
(gSaveContext.save.info.equips.buttonItems[i] <= ITEM_BOTTLE_POE)) ||
|
||||
((gSaveContext.save.info.equips.buttonItems[i] >= ITEM_WEIRD_EGG) &&
|
||||
(gSaveContext.save.info.equips.buttonItems[i] <= ITEM_CLAIM_CHECK))) {
|
||||
osSyncPrintf("Register_Item_Pt(%d)=%d\n", i, gSaveContext.save.info.equips.cButtonSlots[i - 1]);
|
||||
PRINTF("Register_Item_Pt(%d)=%d\n", i, gSaveContext.save.info.equips.cButtonSlots[i - 1]);
|
||||
gSaveContext.save.info.equips.buttonItems[i] =
|
||||
gSaveContext.save.info.inventory.items[gSaveContext.save.info.equips.cButtonSlots[i - 1]];
|
||||
}
|
||||
|
@ -1369,16 +1368,16 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
slot = SLOT(sExtraItemBases[item - ITEM_DEKU_STICKS_5]);
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("item_get_setting=%d pt=%d z=%x\n", item, slot, gSaveContext.save.info.inventory.items[slot]);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("item_get_setting=%d pt=%d z=%x\n", item, slot, gSaveContext.save.info.inventory.items[slot]);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if ((item >= ITEM_MEDALLION_FOREST) && (item <= ITEM_MEDALLION_LIGHT)) {
|
||||
gSaveContext.save.info.inventory.questItems |= gBitFlags[item - ITEM_MEDALLION_FOREST + QUEST_MEDALLION_FOREST];
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("封印 = %x\n", gSaveContext.save.info.inventory.questItems); // "Seals = %x"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("封印 = %x\n", gSaveContext.save.info.inventory.questItems); // "Seals = %x"
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if (item == ITEM_MEDALLION_WATER) {
|
||||
func_8006D0AC(play);
|
||||
|
@ -1388,39 +1387,39 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
} else if ((item >= ITEM_SONG_MINUET) && (item <= ITEM_SONG_STORMS)) {
|
||||
gSaveContext.save.info.inventory.questItems |= gBitFlags[item - ITEM_SONG_MINUET + QUEST_SONG_MINUET];
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("楽譜 = %x\n", gSaveContext.save.info.inventory.questItems); // "Musical scores = %x"
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("楽譜 = %x\n", gSaveContext.save.info.inventory.questItems); // "Musical scores = %x"
|
||||
// "Musical scores = %x (%x) (%x)"
|
||||
osSyncPrintf("楽譜 = %x (%x) (%x)\n", gSaveContext.save.info.inventory.questItems,
|
||||
gBitFlags[item - ITEM_SONG_MINUET + QUEST_SONG_MINUET], gBitFlags[item - ITEM_SONG_MINUET]);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("楽譜 = %x (%x) (%x)\n", gSaveContext.save.info.inventory.questItems,
|
||||
gBitFlags[item - ITEM_SONG_MINUET + QUEST_SONG_MINUET], gBitFlags[item - ITEM_SONG_MINUET]);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
return ITEM_NONE;
|
||||
} else if ((item >= ITEM_KOKIRI_EMERALD) && (item <= ITEM_ZORA_SAPPHIRE)) {
|
||||
gSaveContext.save.info.inventory.questItems |= gBitFlags[item - ITEM_KOKIRI_EMERALD + QUEST_KOKIRI_EMERALD];
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("精霊石 = %x\n", gSaveContext.save.info.inventory.questItems); // "Spiritual Stones = %x"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("精霊石 = %x\n", gSaveContext.save.info.inventory.questItems); // "Spiritual Stones = %x"
|
||||
PRINTF(VT_RST);
|
||||
|
||||
return ITEM_NONE;
|
||||
} else if ((item == ITEM_STONE_OF_AGONY) || (item == ITEM_GERUDOS_CARD)) {
|
||||
gSaveContext.save.info.inventory.questItems |= gBitFlags[item - ITEM_STONE_OF_AGONY + QUEST_STONE_OF_AGONY];
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("アイテム = %x\n", gSaveContext.save.info.inventory.questItems); // "Items = %x"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("アイテム = %x\n", gSaveContext.save.info.inventory.questItems); // "Items = %x"
|
||||
PRINTF(VT_RST);
|
||||
|
||||
return ITEM_NONE;
|
||||
} else if (item == ITEM_SKULL_TOKEN) {
|
||||
gSaveContext.save.info.inventory.questItems |= gBitFlags[item - ITEM_SKULL_TOKEN + QUEST_SKULL_TOKEN];
|
||||
gSaveContext.save.info.inventory.gsTokens++;
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
// "N Coins = %x(%d)"
|
||||
osSyncPrintf("Nコイン = %x(%d)\n", gSaveContext.save.info.inventory.questItems,
|
||||
gSaveContext.save.info.inventory.gsTokens);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Nコイン = %x(%d)\n", gSaveContext.save.info.inventory.questItems,
|
||||
gSaveContext.save.info.inventory.gsTokens);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
return ITEM_NONE;
|
||||
} else if ((item >= ITEM_SWORD_KOKIRI) && (item <= ITEM_SWORD_BIGGORON)) {
|
||||
|
@ -1610,8 +1609,8 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
Inventory_ChangeUpgrade(UPG_DEKU_NUTS, 1);
|
||||
AMMO(ITEM_DEKU_NUT) += sAmmoRefillCounts[item - ITEM_DEKU_NUTS_5];
|
||||
// "Deku Nuts %d(%d)=%d BS_count=%d"
|
||||
osSyncPrintf("デクの実 %d(%d)=%d BS_count=%d\n", item, ITEM_DEKU_NUTS_5, item - ITEM_DEKU_NUTS_5,
|
||||
sAmmoRefillCounts[item - ITEM_DEKU_NUTS_5]);
|
||||
PRINTF("デクの実 %d(%d)=%d BS_count=%d\n", item, ITEM_DEKU_NUTS_5, item - ITEM_DEKU_NUTS_5,
|
||||
sAmmoRefillCounts[item - ITEM_DEKU_NUTS_5]);
|
||||
} else {
|
||||
AMMO(ITEM_DEKU_NUT) += sAmmoRefillCounts[item - ITEM_DEKU_NUTS_5];
|
||||
if (AMMO(ITEM_DEKU_NUT) > CUR_CAPACITY(UPG_DEKU_NUTS)) {
|
||||
|
@ -1621,7 +1620,7 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
item = ITEM_DEKU_NUT;
|
||||
} else if (item == ITEM_BOMB) {
|
||||
// "Bomb Bomb Bomb Bomb Bomb Bomb Bomb"
|
||||
osSyncPrintf(" 爆弾 爆弾 爆弾 爆弾 爆弾 爆弾 爆弾 \n");
|
||||
PRINTF(" 爆弾 爆弾 爆弾 爆弾 爆弾 爆弾 爆弾 \n");
|
||||
if ((AMMO(ITEM_BOMB) += 1) > CUR_CAPACITY(UPG_BOMB_BAG)) {
|
||||
AMMO(ITEM_BOMB) = CUR_CAPACITY(UPG_BOMB_BAG);
|
||||
}
|
||||
|
@ -1662,7 +1661,7 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
AMMO(ITEM_BOW) = CUR_CAPACITY(UPG_QUIVER);
|
||||
}
|
||||
|
||||
osSyncPrintf("%d本 Item_MaxGet=%d\n", AMMO(ITEM_BOW), CUR_CAPACITY(UPG_QUIVER));
|
||||
PRINTF("%d本 Item_MaxGet=%d\n", AMMO(ITEM_BOW), CUR_CAPACITY(UPG_QUIVER));
|
||||
|
||||
return ITEM_BOW;
|
||||
} else if (item == ITEM_SLINGSHOT) {
|
||||
|
@ -1726,7 +1725,7 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
gSaveContext.save.info.playerData.health += 0x10;
|
||||
return ITEM_NONE;
|
||||
} else if (item == ITEM_RECOVERY_HEART) {
|
||||
osSyncPrintf("回復ハート回復ハート回復ハート\n"); // "Recovery Heart"
|
||||
PRINTF("回復ハート回復ハート回復ハート\n"); // "Recovery Heart"
|
||||
Health_ChangeBy(play, 0x10);
|
||||
return item;
|
||||
} else if (item == ITEM_MAGIC_JAR_SMALL) {
|
||||
|
@ -1785,10 +1784,9 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
for (i = 0; i < 4; i++) {
|
||||
if (gSaveContext.save.info.inventory.items[temp + i] == ITEM_BOTTLE_EMPTY) {
|
||||
// "Item_Pt(1)=%d Item_Pt(2)=%d Item_Pt(3)=%d Empty Bottle=%d Content=%d"
|
||||
osSyncPrintf("Item_Pt(1)=%d Item_Pt(2)=%d Item_Pt(3)=%d 空瓶=%d 中味=%d\n",
|
||||
gSaveContext.save.info.equips.cButtonSlots[0],
|
||||
gSaveContext.save.info.equips.cButtonSlots[1],
|
||||
gSaveContext.save.info.equips.cButtonSlots[2], temp + i, item);
|
||||
PRINTF("Item_Pt(1)=%d Item_Pt(2)=%d Item_Pt(3)=%d 空瓶=%d 中味=%d\n",
|
||||
gSaveContext.save.info.equips.cButtonSlots[0], gSaveContext.save.info.equips.cButtonSlots[1],
|
||||
gSaveContext.save.info.equips.cButtonSlots[2], temp + i, item);
|
||||
|
||||
if ((temp + i) == gSaveContext.save.info.equips.cButtonSlots[0]) {
|
||||
gSaveContext.save.info.equips.buttonItems[1] = item;
|
||||
|
@ -1842,7 +1840,7 @@ u8 Item_Give(PlayState* play, u8 item) {
|
|||
}
|
||||
|
||||
temp = gSaveContext.save.info.inventory.items[slot];
|
||||
osSyncPrintf("Item_Register(%d)=%d %d\n", slot, item, temp);
|
||||
PRINTF("Item_Register(%d)=%d %d\n", slot, item, temp);
|
||||
INV_CONTENT(item) = item;
|
||||
|
||||
return temp;
|
||||
|
@ -1857,9 +1855,9 @@ u8 Item_CheckObtainability(u8 item) {
|
|||
slot = SLOT(sExtraItemBases[item - ITEM_DEKU_STICKS_5]);
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("item_get_non_setting=%d pt=%d z=%x\n", item, slot, gSaveContext.save.info.inventory.items[slot]);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("item_get_non_setting=%d pt=%d z=%x\n", item, slot, gSaveContext.save.info.inventory.items[slot]);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if ((item >= ITEM_MEDALLION_FOREST) && (item <= ITEM_MEDALLION_LIGHT)) {
|
||||
return ITEM_NONE;
|
||||
|
@ -1937,7 +1935,7 @@ u8 Item_CheckObtainability(u8 item) {
|
|||
return ITEM_RECOVERY_HEART;
|
||||
} else if ((item == ITEM_MAGIC_JAR_SMALL) || (item == ITEM_MAGIC_JAR_BIG)) {
|
||||
// "Magic Pot Get_Inf_Table( 25, 0x0100)=%d"
|
||||
osSyncPrintf("魔法の壷 Get_Inf_Table( 25, 0x0100)=%d\n", GET_INFTABLE(INFTABLE_198));
|
||||
PRINTF("魔法の壷 Get_Inf_Table( 25, 0x0100)=%d\n", GET_INFTABLE(INFTABLE_198));
|
||||
if (!GET_INFTABLE(INFTABLE_198)) {
|
||||
return ITEM_NONE;
|
||||
} else {
|
||||
|
@ -1984,7 +1982,7 @@ void Inventory_DeleteItem(u16 item, u16 invSlot) {
|
|||
|
||||
gSaveContext.save.info.inventory.items[invSlot] = ITEM_NONE;
|
||||
|
||||
osSyncPrintf("\nItem_Register(%d)\n", invSlot, gSaveContext.save.info.inventory.items[invSlot]);
|
||||
PRINTF("\nItem_Register(%d)\n", invSlot, gSaveContext.save.info.inventory.items[invSlot]);
|
||||
|
||||
for (i = 1; i < 4; i++) {
|
||||
if (gSaveContext.save.info.equips.buttonItems[i] == item) {
|
||||
|
@ -2000,7 +1998,7 @@ s32 Inventory_ReplaceItem(PlayState* play, u16 oldItem, u16 newItem) {
|
|||
for (i = 0; i < ARRAY_COUNT(gSaveContext.save.info.inventory.items); i++) {
|
||||
if (gSaveContext.save.info.inventory.items[i] == oldItem) {
|
||||
gSaveContext.save.info.inventory.items[i] = newItem;
|
||||
osSyncPrintf("アイテム消去(%d)\n", i); // "Item Purge (%d)"
|
||||
PRINTF("アイテム消去(%d)\n", i); // "Item Purge (%d)"
|
||||
for (i = 1; i < 4; i++) {
|
||||
if (gSaveContext.save.info.equips.buttonItems[i] == oldItem) {
|
||||
gSaveContext.save.info.equips.buttonItems[i] = newItem;
|
||||
|
@ -2048,9 +2046,9 @@ s32 Inventory_HasSpecificBottle(u8 bottleItem) {
|
|||
}
|
||||
|
||||
void Inventory_UpdateBottleItem(PlayState* play, u8 item, u8 button) {
|
||||
osSyncPrintf("item_no=%x, c_no=%x, Pt=%x Item_Register=%x\n", item, button,
|
||||
gSaveContext.save.info.equips.cButtonSlots[button - 1],
|
||||
gSaveContext.save.info.inventory.items[gSaveContext.save.info.equips.cButtonSlots[button - 1]]);
|
||||
PRINTF("item_no=%x, c_no=%x, Pt=%x Item_Register=%x\n", item, button,
|
||||
gSaveContext.save.info.equips.cButtonSlots[button - 1],
|
||||
gSaveContext.save.info.inventory.items[gSaveContext.save.info.equips.cButtonSlots[button - 1]]);
|
||||
|
||||
// Special case to only empty half of a Lon Lon Milk Bottle
|
||||
if ((gSaveContext.save.info.inventory.items[gSaveContext.save.info.equips.cButtonSlots[button - 1]] ==
|
||||
|
@ -2084,7 +2082,7 @@ s32 Inventory_ConsumeFairy(PlayState* play) {
|
|||
break;
|
||||
}
|
||||
}
|
||||
osSyncPrintf("妖精使用=%d\n", bottleSlot); // "Fairy Usage=%d"
|
||||
PRINTF("妖精使用=%d\n", bottleSlot); // "Fairy Usage=%d"
|
||||
gSaveContext.save.info.inventory.items[bottleSlot + i] = ITEM_BOTTLE_EMPTY;
|
||||
return true;
|
||||
}
|
||||
|
@ -2199,15 +2197,15 @@ s32 Health_ChangeBy(PlayState* play, s16 amount) {
|
|||
u16 healthLevel;
|
||||
|
||||
// "***** Fluctuation=%d (now=%d, max=%d) ***"
|
||||
osSyncPrintf("***** 増減=%d (now=%d, max=%d) ***", amount, gSaveContext.save.info.playerData.health,
|
||||
gSaveContext.save.info.playerData.healthCapacity);
|
||||
PRINTF("***** 増減=%d (now=%d, max=%d) ***", amount, gSaveContext.save.info.playerData.health,
|
||||
gSaveContext.save.info.playerData.healthCapacity);
|
||||
|
||||
// clang-format off
|
||||
if (amount > 0) { Audio_PlaySfxGeneral(NA_SE_SY_HP_RECOVER, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
} else if (gSaveContext.save.info.playerData.isDoubleDefenseAcquired && (amount < 0)) {
|
||||
amount >>= 1;
|
||||
osSyncPrintf("ハート減少半分!!=%d\n", amount); // "Heart decrease halved!!=%d"
|
||||
PRINTF("ハート減少半分!!=%d\n", amount); // "Heart decrease halved!!=%d"
|
||||
}
|
||||
// clang-format on
|
||||
|
||||
|
@ -2231,7 +2229,7 @@ s32 Health_ChangeBy(PlayState* play, s16 amount) {
|
|||
}
|
||||
|
||||
// "Life=%d *** %d ******"
|
||||
osSyncPrintf(" ライフ=%d *** %d ******\n", gSaveContext.save.info.playerData.health, healthLevel);
|
||||
PRINTF(" ライフ=%d *** %d ******\n", gSaveContext.save.info.playerData.health, healthLevel);
|
||||
|
||||
if (gSaveContext.save.info.playerData.health <= 0) {
|
||||
gSaveContext.save.info.playerData.health = 0;
|
||||
|
@ -2251,7 +2249,7 @@ void Rupees_ChangeBy(s16 rupeeChange) {
|
|||
|
||||
void Inventory_ChangeAmmo(s16 item, s16 ammoChange) {
|
||||
// "Item = (%d) Amount = (%d + %d)"
|
||||
osSyncPrintf("アイテム = (%d) 数 = (%d + %d) ", item, AMMO(item), ammoChange);
|
||||
PRINTF("アイテム = (%d) 数 = (%d + %d) ", item, AMMO(item), ammoChange);
|
||||
|
||||
if (item == ITEM_DEKU_STICK) {
|
||||
AMMO(ITEM_DEKU_STICK) += ammoChange;
|
||||
|
@ -2305,7 +2303,7 @@ void Inventory_ChangeAmmo(s16 item, s16 ammoChange) {
|
|||
AMMO(ITEM_MAGIC_BEAN) += ammoChange;
|
||||
}
|
||||
|
||||
osSyncPrintf("合計 = (%d)\n", AMMO(item)); // "Total = (%d)"
|
||||
PRINTF("合計 = (%d)\n", AMMO(item)); // "Total = (%d)"
|
||||
}
|
||||
|
||||
void Magic_Fill(PlayState* play) {
|
||||
|
@ -2482,8 +2480,7 @@ void Magic_Update(PlayState* play) {
|
|||
}
|
||||
|
||||
// "Storage MAGIC_NOW=%d (%d)"
|
||||
osSyncPrintf("蓄電 MAGIC_NOW=%d (%d)\n", gSaveContext.save.info.playerData.magic,
|
||||
gSaveContext.magicFillTarget);
|
||||
PRINTF("蓄電 MAGIC_NOW=%d (%d)\n", gSaveContext.save.info.playerData.magic, gSaveContext.magicFillTarget);
|
||||
|
||||
if (gSaveContext.save.info.playerData.magic >= gSaveContext.magicFillTarget) {
|
||||
gSaveContext.save.info.playerData.magic = gSaveContext.magicFillTarget;
|
||||
|
@ -3504,7 +3501,7 @@ void Interface_Draw(PlayState* play) {
|
|||
gSaveContext.eventInf[EVENTINF_HORSES_INDEX] &=
|
||||
(u16) ~(EVENTINF_HORSES_STATE_MASK | EVENTINF_HORSES_HORSETYPE_MASK | EVENTINF_HORSES_05_MASK |
|
||||
EVENTINF_HORSES_06_MASK | EVENTINF_HORSES_0F_MASK);
|
||||
osSyncPrintf("EVENT_INF=%x\n", gSaveContext.eventInf[EVENTINF_HORSES_INDEX]);
|
||||
PRINTF("EVENT_INF=%x\n", gSaveContext.eventInf[EVENTINF_HORSES_INDEX]);
|
||||
play->nextEntranceIndex = spoilingItemEntrances[svar1];
|
||||
INV_CONTENT(gSpoilingItemReverts[svar1]) = gSpoilingItemReverts[svar1];
|
||||
|
||||
|
@ -3753,9 +3750,9 @@ void Interface_Draw(PlayState* play) {
|
|||
|
||||
case SUBTIMER_STATE_DOWN_MOVE:
|
||||
case SUBTIMER_STATE_UP_MOVE:
|
||||
osSyncPrintf("event_xp[1]=%d, event_yp[1]=%d TOTAL_EVENT_TM=%d\n",
|
||||
((void)0, gSaveContext.timerX[TIMER_ID_SUB]),
|
||||
((void)0, gSaveContext.timerY[TIMER_ID_SUB]), gSaveContext.subTimerSeconds);
|
||||
PRINTF("event_xp[1]=%d, event_yp[1]=%d TOTAL_EVENT_TM=%d\n",
|
||||
((void)0, gSaveContext.timerX[TIMER_ID_SUB]),
|
||||
((void)0, gSaveContext.timerY[TIMER_ID_SUB]), gSaveContext.subTimerSeconds);
|
||||
svar1 = (gSaveContext.timerX[TIMER_ID_SUB] - 26) / sSubTimerStateTimer;
|
||||
gSaveContext.timerX[TIMER_ID_SUB] -= svar1;
|
||||
if (gSaveContext.save.info.playerData.healthCapacity > 0xA0) {
|
||||
|
@ -3802,7 +3799,7 @@ void Interface_Draw(PlayState* play) {
|
|||
sSubTimerNextSecondTimer = 20;
|
||||
if (gSaveContext.subTimerState == SUBTIMER_STATE_DOWN_TICK) {
|
||||
gSaveContext.subTimerSeconds--;
|
||||
osSyncPrintf("TOTAL_EVENT_TM=%d\n", gSaveContext.subTimerSeconds);
|
||||
PRINTF("TOTAL_EVENT_TM=%d\n", gSaveContext.subTimerSeconds);
|
||||
|
||||
if (gSaveContext.subTimerSeconds <= 0) {
|
||||
// Out of time
|
||||
|
@ -3965,13 +3962,13 @@ void Interface_Update(PlayState* play) {
|
|||
|
||||
if (CHECK_BTN_ALL(debugInput->press.button, BTN_DLEFT)) {
|
||||
gSaveContext.language = LANGUAGE_ENG;
|
||||
osSyncPrintf("J_N=%x J_N=%x\n", gSaveContext.language, &gSaveContext.language);
|
||||
PRINTF("J_N=%x J_N=%x\n", gSaveContext.language, &gSaveContext.language);
|
||||
} else if (CHECK_BTN_ALL(debugInput->press.button, BTN_DUP)) {
|
||||
gSaveContext.language = LANGUAGE_GER;
|
||||
osSyncPrintf("J_N=%x J_N=%x\n", gSaveContext.language, &gSaveContext.language);
|
||||
PRINTF("J_N=%x J_N=%x\n", gSaveContext.language, &gSaveContext.language);
|
||||
} else if (CHECK_BTN_ALL(debugInput->press.button, BTN_DRIGHT)) {
|
||||
gSaveContext.language = LANGUAGE_FRA;
|
||||
osSyncPrintf("J_N=%x J_N=%x\n", gSaveContext.language, &gSaveContext.language);
|
||||
PRINTF("J_N=%x J_N=%x\n", gSaveContext.language, &gSaveContext.language);
|
||||
}
|
||||
|
||||
if (!IS_PAUSED(&play->pauseCtx)) {
|
||||
|
@ -4025,7 +4022,7 @@ void Interface_Update(PlayState* play) {
|
|||
risingAlpha = 255;
|
||||
}
|
||||
|
||||
osSyncPrintf("case 50 : alpha=%d alpha1=%d\n", dimmingAlpha, risingAlpha);
|
||||
PRINTF("case 50 : alpha=%d alpha1=%d\n", dimmingAlpha, risingAlpha);
|
||||
|
||||
Interface_RaiseButtonAlphas(play, risingAlpha);
|
||||
|
||||
|
@ -4100,13 +4097,13 @@ void Interface_Update(PlayState* play) {
|
|||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
}
|
||||
|
||||
osSyncPrintf("now_life=%d max_life=%d\n", gSaveContext.save.info.playerData.health,
|
||||
gSaveContext.save.info.playerData.healthCapacity);
|
||||
PRINTF("now_life=%d max_life=%d\n", gSaveContext.save.info.playerData.health,
|
||||
gSaveContext.save.info.playerData.healthCapacity);
|
||||
|
||||
if (gSaveContext.save.info.playerData.health >= gSaveContext.save.info.playerData.healthCapacity) {
|
||||
gSaveContext.save.info.playerData.health = gSaveContext.save.info.playerData.healthCapacity;
|
||||
osSyncPrintf("S_Private.now_life=%d S_Private.max_life=%d\n", gSaveContext.save.info.playerData.health,
|
||||
gSaveContext.save.info.playerData.healthCapacity);
|
||||
PRINTF("S_Private.now_life=%d S_Private.max_life=%d\n", gSaveContext.save.info.playerData.health,
|
||||
gSaveContext.save.info.playerData.healthCapacity);
|
||||
gSaveContext.healthAccumulator = 0;
|
||||
}
|
||||
}
|
||||
|
@ -4141,7 +4138,7 @@ void Interface_Update(PlayState* play) {
|
|||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
} else {
|
||||
// "Rupee Amount MAX = %d"
|
||||
osSyncPrintf("ルピー数MAX = %d\n", CUR_CAPACITY(UPG_WALLET));
|
||||
PRINTF("ルピー数MAX = %d\n", CUR_CAPACITY(UPG_WALLET));
|
||||
gSaveContext.save.info.playerData.rupees = CUR_CAPACITY(UPG_WALLET);
|
||||
gSaveContext.rupeeAccumulator = 0;
|
||||
}
|
||||
|
@ -4220,13 +4217,13 @@ void Interface_Update(PlayState* play) {
|
|||
if (gSaveContext.save.info.playerData.isMagicAcquired && (gSaveContext.save.info.playerData.magicLevel == 0)) {
|
||||
gSaveContext.save.info.playerData.magicLevel = gSaveContext.save.info.playerData.isDoubleMagicAcquired + 1;
|
||||
gSaveContext.magicState = MAGIC_STATE_STEP_CAPACITY;
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("魔法スター─────ト!!!!!!!!!\n"); // "Magic Start!!!!!!!!!"
|
||||
osSyncPrintf("MAGIC_MAX=%d\n", gSaveContext.save.info.playerData.magicLevel);
|
||||
osSyncPrintf("MAGIC_NOW=%d\n", gSaveContext.save.info.playerData.magic);
|
||||
osSyncPrintf("Z_MAGIC_NOW_NOW=%d\n", gSaveContext.magicFillTarget);
|
||||
osSyncPrintf("Z_MAGIC_NOW_MAX=%d\n", gSaveContext.magicCapacity);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("魔法スター─────ト!!!!!!!!!\n"); // "Magic Start!!!!!!!!!"
|
||||
PRINTF("MAGIC_MAX=%d\n", gSaveContext.save.info.playerData.magicLevel);
|
||||
PRINTF("MAGIC_NOW=%d\n", gSaveContext.save.info.playerData.magic);
|
||||
PRINTF("Z_MAGIC_NOW_NOW=%d\n", gSaveContext.magicFillTarget);
|
||||
PRINTF("Z_MAGIC_NOW_MAX=%d\n", gSaveContext.magicCapacity);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
Magic_Update(play);
|
||||
|
|
|
@ -57,7 +57,7 @@ s32 Play_CheckViewpoint(PlayState* this, s16 viewpoint) {
|
|||
* to toggle the camera into a "browsing item selection" setting.
|
||||
*/
|
||||
void Play_SetShopBrowsingViewpoint(PlayState* this) {
|
||||
osSyncPrintf("Game_play_shop_pr_vr_switch_set()\n");
|
||||
PRINTF("Game_play_shop_pr_vr_switch_set()\n");
|
||||
|
||||
if (R_SCENE_CAM_TYPE == SCENE_CAM_TYPE_FIXED_SHOP_VIEWPOINT) {
|
||||
this->viewpoint = VIEWPOINT_PIVOT;
|
||||
|
@ -325,15 +325,15 @@ void Play_Init(GameState* thisx) {
|
|||
this, gEntranceTable[((void)0, gSaveContext.save.entranceIndex) + ((void)0, gSaveContext.sceneLayer)].sceneId,
|
||||
gEntranceTable[((void)0, gSaveContext.save.entranceIndex) + ((void)0, gSaveContext.sceneLayer)].spawn);
|
||||
|
||||
osSyncPrintf("\nSCENE_NO=%d COUNTER=%d\n", ((void)0, gSaveContext.save.entranceIndex), gSaveContext.sceneLayer);
|
||||
PRINTF("\nSCENE_NO=%d COUNTER=%d\n", ((void)0, gSaveContext.save.entranceIndex), gSaveContext.sceneLayer);
|
||||
|
||||
// When entering Gerudo Valley in the credits, trigger the GC emulator to play the ending movie.
|
||||
// The emulator constantly checks whether PC is 0x81000000, so this works even though it's not a valid address.
|
||||
if ((gEntranceTable[((void)0, gSaveContext.save.entranceIndex)].sceneId == SCENE_GERUDO_VALLEY) &&
|
||||
gSaveContext.sceneLayer == 6) {
|
||||
osSyncPrintf("エンディングはじまるよー\n"); // "The ending starts"
|
||||
PRINTF("エンディングはじまるよー\n"); // "The ending starts"
|
||||
((void (*)(void))0x81000000)();
|
||||
osSyncPrintf("出戻り?\n"); // "Return?"
|
||||
PRINTF("出戻り?\n"); // "Return?"
|
||||
}
|
||||
|
||||
Cutscene_HandleEntranceTriggers(this);
|
||||
|
@ -395,14 +395,13 @@ void Play_Init(GameState* thisx) {
|
|||
gVisMonoColor.a = 0;
|
||||
CutsceneFlags_UnsetAll(this);
|
||||
|
||||
osSyncPrintf("ZELDA ALLOC SIZE=%x\n", THA_GetRemaining(&this->state.tha));
|
||||
PRINTF("ZELDA ALLOC SIZE=%x\n", THA_GetRemaining(&this->state.tha));
|
||||
zAllocSize = THA_GetRemaining(&this->state.tha);
|
||||
zAlloc = (uintptr_t)GAME_STATE_ALLOC(&this->state, zAllocSize, "../z_play.c", 2918);
|
||||
zAllocAligned = (zAlloc + 8) & ~0xF;
|
||||
ZeldaArena_Init((void*)zAllocAligned, zAllocSize - (zAllocAligned - zAlloc));
|
||||
// "Zelda Heap"
|
||||
osSyncPrintf("ゼルダヒープ %08x-%08x\n", zAllocAligned,
|
||||
(u8*)zAllocAligned + zAllocSize - (s32)(zAllocAligned - zAlloc));
|
||||
PRINTF("ゼルダヒープ %08x-%08x\n", zAllocAligned, (u8*)zAllocAligned + zAllocSize - (s32)(zAllocAligned - zAlloc));
|
||||
|
||||
Fault_AddClient(&D_801614B8, ZeldaArena_Display, NULL, NULL);
|
||||
Actor_InitContext(this, &this->actorCtx, this->playerEntry);
|
||||
|
@ -417,7 +416,7 @@ void Play_Init(GameState* thisx) {
|
|||
|
||||
playerStartBgCamIndex = player->actor.params & 0xFF;
|
||||
if (playerStartBgCamIndex != 0xFF) {
|
||||
osSyncPrintf("player has start camera ID (" VT_FGCOL(BLUE) "%d" VT_RST ")\n", playerStartBgCamIndex);
|
||||
PRINTF("player has start camera ID (" VT_FGCOL(BLUE) "%d" VT_RST ")\n", playerStartBgCamIndex);
|
||||
Camera_RequestBgCam(&this->mainCamera, playerStartBgCamIndex);
|
||||
}
|
||||
|
||||
|
@ -439,7 +438,7 @@ void Play_Init(GameState* thisx) {
|
|||
|
||||
if (R_USE_DEBUG_CUTSCENE) {
|
||||
gDebugCutsceneScript = sDebugCutsceneScriptBuf;
|
||||
osSyncPrintf("\nkawauso_data=[%x]", gDebugCutsceneScript);
|
||||
PRINTF("\nkawauso_data=[%x]", gDebugCutsceneScript);
|
||||
|
||||
// This hardcoded ROM address extends past the end of the ROM file.
|
||||
// Presumably the ROM was larger at a previous point in development when this debug feature was used.
|
||||
|
@ -463,17 +462,17 @@ void Play_Update(PlayState* this) {
|
|||
|
||||
if ((R_HREG_MODE == HREG_MODE_PRINT_OBJECT_TABLE) && (R_PRINT_OBJECT_TABLE_TRIGGER < 0)) {
|
||||
R_PRINT_OBJECT_TABLE_TRIGGER = 0;
|
||||
osSyncPrintf("object_exchange_rom_address %u\n", gObjectTableSize);
|
||||
osSyncPrintf("RomStart RomEnd Size\n");
|
||||
PRINTF("object_exchange_rom_address %u\n", gObjectTableSize);
|
||||
PRINTF("RomStart RomEnd Size\n");
|
||||
|
||||
for (i = 0; i < gObjectTableSize; i++) {
|
||||
s32 size = gObjectTable[i].vromEnd - gObjectTable[i].vromStart;
|
||||
|
||||
osSyncPrintf("%08x-%08x %08x(%8.3fKB)\n", gObjectTable[i].vromStart, gObjectTable[i].vromEnd, size,
|
||||
size / 1024.0f);
|
||||
PRINTF("%08x-%08x %08x(%8.3fKB)\n", gObjectTable[i].vromStart, gObjectTable[i].vromEnd, size,
|
||||
size / 1024.0f);
|
||||
}
|
||||
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
}
|
||||
|
||||
// HREG(81) was very likely intended to be HREG(80), which would make more sense given how the
|
||||
|
@ -497,7 +496,7 @@ void Play_Update(PlayState* this) {
|
|||
switch (gTransitionTileState) {
|
||||
case TRANS_TILE_PROCESS:
|
||||
if (TransitionTile_Init(&sTransitionTile, 10, 7) == NULL) {
|
||||
osSyncPrintf("fbdemo_init呼出し失敗!\n"); // "fbdemo_init call failed!"
|
||||
PRINTF("fbdemo_init呼出し失敗!\n"); // "fbdemo_init call failed!"
|
||||
gTransitionTileState = TRANS_TILE_OFF;
|
||||
} else {
|
||||
sTransitionTile.zBuffer = (u16*)gZBuffer;
|
||||
|
@ -531,10 +530,10 @@ void Play_Update(PlayState* this) {
|
|||
if (!(gEntranceTable[this->nextEntranceIndex + sceneLayer].field &
|
||||
ENTRANCE_INFO_CONTINUE_BGM_FLAG)) {
|
||||
// "Sound initialized. 111"
|
||||
osSyncPrintf("\n\n\nサウンドイニシャル来ました。111");
|
||||
PRINTF("\n\n\nサウンドイニシャル来ました。111");
|
||||
if ((this->transitionType < TRANS_TYPE_MAX) && !Environment_IsForcedSequenceDisabled()) {
|
||||
// "Sound initialized. 222"
|
||||
osSyncPrintf("\n\n\nサウンドイニシャル来ました。222");
|
||||
PRINTF("\n\n\nサウンドイニシャル来ました。222");
|
||||
func_800F6964(0x14);
|
||||
gSaveContext.seqId = (u8)NA_BGM_DISABLED;
|
||||
gSaveContext.natureAmbienceId = NATURE_ID_DISABLED;
|
||||
|
@ -868,7 +867,7 @@ void Play_Update(PlayState* this) {
|
|||
Rumble_SetUpdateEnabled(true);
|
||||
|
||||
if (this->actorCtx.freezeFlashTimer && (this->actorCtx.freezeFlashTimer-- < 5)) {
|
||||
osSyncPrintf("FINISH=%d\n", this->actorCtx.freezeFlashTimer);
|
||||
PRINTF("FINISH=%d\n", this->actorCtx.freezeFlashTimer);
|
||||
|
||||
if ((this->actorCtx.freezeFlashTimer > 0) && ((this->actorCtx.freezeFlashTimer % 2) != 0)) {
|
||||
this->envCtx.fillScreen = true;
|
||||
|
@ -930,10 +929,10 @@ void Play_Update(PlayState* this) {
|
|||
if (CHECK_BTN_ALL(input[0].press.button, BTN_CUP)) {
|
||||
if (IS_PAUSED(&this->pauseCtx)) {
|
||||
// "Changing viewpoint is prohibited due to the kaleidoscope"
|
||||
osSyncPrintf(VT_FGCOL(CYAN) "カレイドスコープ中につき視点変更を禁止しております\n" VT_RST);
|
||||
PRINTF(VT_FGCOL(CYAN) "カレイドスコープ中につき視点変更を禁止しております\n" VT_RST);
|
||||
} else if (Player_InCsMode(this)) {
|
||||
// "Changing viewpoint is prohibited during the cutscene"
|
||||
osSyncPrintf(VT_FGCOL(CYAN) "デモ中につき視点変更を禁止しております\n" VT_RST);
|
||||
PRINTF(VT_FGCOL(CYAN) "デモ中につき視点変更を禁止しております\n" VT_RST);
|
||||
} else if (R_SCENE_CAM_TYPE == SCENE_CAM_TYPE_FIXED_SHOP_VIEWPOINT) {
|
||||
Audio_PlaySfxGeneral(NA_SE_SY_ERROR, &gSfxDefaultPos, 4, &gSfxDefaultFreqAndVolScale,
|
||||
&gSfxDefaultFreqAndVolScale, &gSfxDefaultReverb);
|
||||
|
@ -1455,7 +1454,7 @@ void Play_SpawnScene(PlayState* this, s32 sceneId, s32 spawn) {
|
|||
this->sceneId = sceneId;
|
||||
this->sceneDrawConfig = scene->drawConfig;
|
||||
|
||||
osSyncPrintf("\nSCENE SIZE %fK\n", (scene->sceneFile.vromEnd - scene->sceneFile.vromStart) / 1024.0f);
|
||||
PRINTF("\nSCENE SIZE %fK\n", (scene->sceneFile.vromEnd - scene->sceneFile.vromStart) / 1024.0f);
|
||||
|
||||
this->sceneSegment = Play_LoadFile(this, &scene->sceneFile);
|
||||
scene->unk_13 = 0;
|
||||
|
@ -1467,7 +1466,7 @@ void Play_SpawnScene(PlayState* this, s32 sceneId, s32 spawn) {
|
|||
|
||||
size = func_80096FE8(this, &this->roomCtx);
|
||||
|
||||
osSyncPrintf("ROOM SIZE=%fK\n", size / 1024.0f);
|
||||
PRINTF("ROOM SIZE=%fK\n", size / 1024.0f);
|
||||
}
|
||||
|
||||
void Play_GetScreenPos(PlayState* this, Vec3f* src, Vec3f* dest) {
|
||||
|
@ -1493,13 +1492,13 @@ s16 Play_CreateSubCamera(PlayState* this) {
|
|||
}
|
||||
|
||||
if (camId == NUM_CAMS) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera control: error: fulled sub camera system area\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera control: error: fulled sub camera system area\n" VT_RST);
|
||||
return CAM_ID_NONE;
|
||||
}
|
||||
|
||||
osSyncPrintf("camera control: " VT_BGCOL(CYAN) " " VT_COL(WHITE, BLUE) " create new sub camera [%d] " VT_BGCOL(
|
||||
CYAN) " " VT_RST "\n",
|
||||
camId);
|
||||
PRINTF("camera control: " VT_BGCOL(CYAN) " " VT_COL(WHITE, BLUE) " create new sub camera [%d] " VT_BGCOL(
|
||||
CYAN) " " VT_RST "\n",
|
||||
camId);
|
||||
|
||||
this->cameraPtrs[camId] = &this->subCameras[camId - CAM_ID_SUB_FIRST];
|
||||
Camera_Init(this->cameraPtrs[camId], &this->view, &this->colCtx, this);
|
||||
|
@ -1526,17 +1525,17 @@ void Play_ClearCamera(PlayState* this, s16 camId) {
|
|||
s16 camIdx = (camId == CAM_ID_NONE) ? this->activeCamId : camId;
|
||||
|
||||
if (camIdx == CAM_ID_MAIN) {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera control: error: never clear camera !!\n" VT_RST);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera control: error: never clear camera !!\n" VT_RST);
|
||||
}
|
||||
|
||||
if (this->cameraPtrs[camIdx] != NULL) {
|
||||
Camera_ChangeStatus(this->cameraPtrs[camIdx], CAM_STAT_UNK100);
|
||||
this->cameraPtrs[camIdx] = NULL;
|
||||
osSyncPrintf("camera control: " VT_BGCOL(CYAN) " " VT_COL(WHITE, BLUE) " clear sub camera [%d] " VT_BGCOL(
|
||||
CYAN) " " VT_RST "\n",
|
||||
camIdx);
|
||||
PRINTF("camera control: " VT_BGCOL(CYAN) " " VT_COL(WHITE, BLUE) " clear sub camera [%d] " VT_BGCOL(
|
||||
CYAN) " " VT_RST "\n",
|
||||
camIdx);
|
||||
} else {
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "camera control: error: camera No.%d already cleared\n" VT_RST, camIdx);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera control: error: camera No.%d already cleared\n" VT_RST, camIdx);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1665,9 +1664,8 @@ void Play_ReturnToMainCam(PlayState* this, s16 camId, s16 duration) {
|
|||
|
||||
for (subCamId = CAM_ID_SUB_FIRST; subCamId < NUM_CAMS; subCamId++) {
|
||||
if (this->cameraPtrs[subCamId] != NULL) {
|
||||
osSyncPrintf(
|
||||
VT_COL(RED, WHITE) "camera control: error: return to main, other camera left. %d cleared!!\n" VT_RST,
|
||||
subCamId);
|
||||
PRINTF(VT_COL(RED, WHITE) "camera control: error: return to main, other camera left. %d cleared!!\n" VT_RST,
|
||||
subCamId);
|
||||
Play_ClearCamera(this, subCamId);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,12 +8,12 @@ void func_80092320(PreNMIState* this) {
|
|||
}
|
||||
|
||||
void PreNMI_Update(PreNMIState* this) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "prenmi_move\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "prenmi_move\n" VT_RST);
|
||||
|
||||
// Strings existing only in rodata
|
||||
if (0) {
|
||||
osSyncPrintf("../z_prenmi.c");
|
||||
osSyncPrintf("(int)volume = %d\n");
|
||||
PRINTF("../z_prenmi.c");
|
||||
PRINTF("(int)volume = %d\n");
|
||||
}
|
||||
|
||||
if (this->timer == 0) {
|
||||
|
@ -28,7 +28,7 @@ void PreNMI_Update(PreNMIState* this) {
|
|||
void PreNMI_Draw(PreNMIState* this) {
|
||||
GraphicsContext* gfxCtx = this->state.gfxCtx;
|
||||
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "prenmi_draw\n" VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "prenmi_draw\n" VT_RST);
|
||||
|
||||
OPEN_DISPS(gfxCtx, "../z_prenmi.c", 96);
|
||||
|
||||
|
|
|
@ -160,7 +160,7 @@ s16 Quake_GetFreeIndex(void) {
|
|||
}
|
||||
|
||||
if (timerMin != 0x20000) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "quake: too many request %d is changed new one !!\n" VT_RST, index);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "quake: too many request %d is changed new one !!\n" VT_RST, index);
|
||||
}
|
||||
|
||||
return index;
|
||||
|
@ -437,7 +437,7 @@ s16 Quake_Update(Camera* camera, ShakeInfo* camShake) {
|
|||
}
|
||||
|
||||
if (play->cameraPtrs[req->camId] == NULL) {
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK) "quake: stopped! 'coz camera [%d] killed!!\n" VT_RST, req->camId);
|
||||
PRINTF(VT_COL(YELLOW, BLACK) "quake: stopped! 'coz camera [%d] killed!!\n" VT_RST, req->camId);
|
||||
Quake_Remove(req);
|
||||
continue;
|
||||
}
|
||||
|
|
|
@ -262,25 +262,25 @@ s32 Room_DecodeJpeg(void* data) {
|
|||
OSTime time;
|
||||
|
||||
if (*(u32*)data == JPEG_MARKER) {
|
||||
osSyncPrintf("JPEGデータを展開します\n"); // "Expanding jpeg data"
|
||||
osSyncPrintf("JPEGデータアドレス %08x\n", data); // "Jpeg data address %08x"
|
||||
PRINTF("JPEGデータを展開します\n"); // "Expanding jpeg data"
|
||||
PRINTF("JPEGデータアドレス %08x\n", data); // "Jpeg data address %08x"
|
||||
// "Work buffer address (Z buffer) %08x"
|
||||
osSyncPrintf("ワークバッファアドレス(Zバッファ)%08x\n", gZBuffer);
|
||||
PRINTF("ワークバッファアドレス(Zバッファ)%08x\n", gZBuffer);
|
||||
|
||||
time = osGetTime();
|
||||
if (!Jpeg_Decode(data, gZBuffer, gGfxSPTaskOutputBuffer, sizeof(gGfxSPTaskOutputBuffer))) {
|
||||
time = osGetTime() - time;
|
||||
|
||||
// "Success... I think. time = %6.3f ms"
|
||||
osSyncPrintf("成功…だと思う。 time = %6.3f ms \n", OS_CYCLES_TO_USEC(time) / 1000.0f);
|
||||
PRINTF("成功…だと思う。 time = %6.3f ms \n", OS_CYCLES_TO_USEC(time) / 1000.0f);
|
||||
// "Writing back to original address from work buffer."
|
||||
osSyncPrintf("ワークバッファから元のアドレスに書き戻します。\n");
|
||||
PRINTF("ワークバッファから元のアドレスに書き戻します。\n");
|
||||
// "If the original buffer size isn't at least 150kB, it will be out of control."
|
||||
osSyncPrintf("元のバッファのサイズが150キロバイト無いと暴走するでしょう。\n");
|
||||
PRINTF("元のバッファのサイズが150キロバイト無いと暴走するでしょう。\n");
|
||||
|
||||
bcopy(gZBuffer, data, sizeof(u16[SCREEN_HEIGHT][SCREEN_WIDTH]));
|
||||
} else {
|
||||
osSyncPrintf("失敗!なんで〜\n"); // "Failure! Why is it 〜"
|
||||
PRINTF("失敗!なんで〜\n"); // "Failure! Why is it 〜"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -438,7 +438,7 @@ RoomShapeImageMultiBgEntry* Room_GetImageMultiBgEntry(RoomShapeImageMulti* roomS
|
|||
}
|
||||
|
||||
// "z_room.c: Data consistent with camera id does not exist camid=%d"
|
||||
osSyncPrintf(VT_COL(RED, WHITE) "z_room.c:カメラIDに一致するデータが存在しません camid=%d\n" VT_RST, bgCamIndex);
|
||||
PRINTF(VT_COL(RED, WHITE) "z_room.c:カメラIDに一致するデータが存在しません camid=%d\n" VT_RST, bgCamIndex);
|
||||
LogUtils_HungupThread("../z_room.c", 726);
|
||||
|
||||
return NULL;
|
||||
|
@ -540,7 +540,7 @@ u32 func_80096FE8(PlayState* play, RoomContext* roomCtx) {
|
|||
|
||||
for (i = 0; i < play->numRooms; i++) {
|
||||
roomSize = roomList[i].vromEnd - roomList[i].vromStart;
|
||||
osSyncPrintf("ROOM%d size=%d\n", i, roomSize);
|
||||
PRINTF("ROOM%d size=%d\n", i, roomSize);
|
||||
if (maxRoomSize < roomSize) {
|
||||
maxRoomSize = roomSize;
|
||||
}
|
||||
|
@ -559,8 +559,8 @@ u32 func_80096FE8(PlayState* play, RoomContext* roomCtx) {
|
|||
backRoomSize = (backRoom < 0) ? 0 : roomList[backRoom].vromEnd - roomList[backRoom].vromStart;
|
||||
cumulRoomSize = (frontRoom != backRoom) ? frontRoomSize + backRoomSize : frontRoomSize;
|
||||
|
||||
osSyncPrintf("DOOR%d=<%d> ROOM1=<%d, %d> ROOM2=<%d, %d>\n", j, cumulRoomSize, frontRoom, frontRoomSize,
|
||||
backRoom, backRoomSize);
|
||||
PRINTF("DOOR%d=<%d> ROOM1=<%d, %d> ROOM2=<%d, %d>\n", j, cumulRoomSize, frontRoom, frontRoomSize, backRoom,
|
||||
backRoomSize);
|
||||
if (maxRoomSize < cumulRoomSize) {
|
||||
maxRoomSize = cumulRoomSize;
|
||||
}
|
||||
|
@ -568,16 +568,16 @@ u32 func_80096FE8(PlayState* play, RoomContext* roomCtx) {
|
|||
}
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
// "Room buffer size=%08x(%5.1fK)"
|
||||
osSyncPrintf("部屋バッファサイズ=%08x(%5.1fK)\n", maxRoomSize, maxRoomSize / 1024.0f);
|
||||
PRINTF("部屋バッファサイズ=%08x(%5.1fK)\n", maxRoomSize, maxRoomSize / 1024.0f);
|
||||
roomCtx->bufPtrs[0] = GAME_STATE_ALLOC(&play->state, maxRoomSize, "../z_room.c", 946);
|
||||
// "Room buffer initial pointer=%08x"
|
||||
osSyncPrintf("部屋バッファ開始ポインタ=%08x\n", roomCtx->bufPtrs[0]);
|
||||
PRINTF("部屋バッファ開始ポインタ=%08x\n", roomCtx->bufPtrs[0]);
|
||||
roomCtx->bufPtrs[1] = (void*)((uintptr_t)roomCtx->bufPtrs[0] + maxRoomSize);
|
||||
// "Room buffer end pointer=%08x"
|
||||
osSyncPrintf("部屋バッファ終了ポインタ=%08x\n", roomCtx->bufPtrs[1]);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("部屋バッファ終了ポインタ=%08x\n", roomCtx->bufPtrs[1]);
|
||||
PRINTF(VT_RST);
|
||||
roomCtx->unk_30 = 0;
|
||||
roomCtx->status = 0;
|
||||
|
||||
|
|
|
@ -21,11 +21,10 @@ s32 Object_SpawnPersistent(ObjectContext* objectCtx, s16 objectId) {
|
|||
objectCtx->slots[objectCtx->numEntries].id = objectId;
|
||||
size = gObjectTable[objectId].vromEnd - gObjectTable[objectId].vromStart;
|
||||
|
||||
osSyncPrintf("OBJECT[%d] SIZE %fK SEG=%x\n", objectId, size / 1024.0f,
|
||||
objectCtx->slots[objectCtx->numEntries].segment);
|
||||
PRINTF("OBJECT[%d] SIZE %fK SEG=%x\n", objectId, size / 1024.0f, objectCtx->slots[objectCtx->numEntries].segment);
|
||||
|
||||
osSyncPrintf("num=%d adrs=%x end=%x\n", objectCtx->numEntries,
|
||||
(uintptr_t)objectCtx->slots[objectCtx->numEntries].segment + size, objectCtx->spaceEnd);
|
||||
PRINTF("num=%d adrs=%x end=%x\n", objectCtx->numEntries,
|
||||
(uintptr_t)objectCtx->slots[objectCtx->numEntries].segment + size, objectCtx->spaceEnd);
|
||||
|
||||
ASSERT(((objectCtx->numEntries < ARRAY_COUNT(objectCtx->slots)) &&
|
||||
(((uintptr_t)objectCtx->slots[objectCtx->numEntries].segment + size) < (uintptr_t)objectCtx->spaceEnd)),
|
||||
|
@ -76,10 +75,10 @@ void Object_InitContext(PlayState* play, ObjectContext* objectCtx) {
|
|||
objectCtx->slots[i].id = OBJECT_INVALID;
|
||||
}
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
// "Object exchange bank data %8.3fKB"
|
||||
osSyncPrintf("オブジェクト入れ替えバンク情報 %8.3fKB\n", spaceSize / 1024.0f);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("オブジェクト入れ替えバンク情報 %8.3fKB\n", spaceSize / 1024.0f);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
objectCtx->spaceStart = objectCtx->slots[0].segment =
|
||||
GAME_STATE_ALLOC(&play->state, spaceSize, "../z_scene.c", 219);
|
||||
|
@ -102,7 +101,7 @@ void Object_UpdateEntries(ObjectContext* objectCtx) {
|
|||
objectFile = &gObjectTable[-entry->id];
|
||||
size = objectFile->vromEnd - objectFile->vromStart;
|
||||
|
||||
osSyncPrintf("OBJECT EXCHANGE BANK-%2d SIZE %8.3fK SEG=%08x\n", i, size / 1024.0f, entry->segment);
|
||||
PRINTF("OBJECT EXCHANGE BANK-%2d SIZE %8.3fK SEG=%08x\n", i, size / 1024.0f, entry->segment);
|
||||
|
||||
DMA_REQUEST_ASYNC(&entry->dmaRequest, entry->segment, objectFile->vromStart, size, 0, &entry->loadQueue,
|
||||
NULL, "../z_scene.c", 266);
|
||||
|
@ -142,10 +141,9 @@ void func_800981B8(ObjectContext* objectCtx) {
|
|||
for (i = 0; i < objectCtx->numEntries; i++) {
|
||||
id = objectCtx->slots[i].id;
|
||||
size = gObjectTable[id].vromEnd - gObjectTable[id].vromStart;
|
||||
osSyncPrintf("OBJECT[%d] SIZE %fK SEG=%x\n", objectCtx->slots[i].id, size / 1024.0f,
|
||||
objectCtx->slots[i].segment);
|
||||
osSyncPrintf("num=%d adrs=%x end=%x\n", objectCtx->numEntries, (uintptr_t)objectCtx->slots[i].segment + size,
|
||||
objectCtx->spaceEnd);
|
||||
PRINTF("OBJECT[%d] SIZE %fK SEG=%x\n", objectCtx->slots[i].id, size / 1024.0f, objectCtx->slots[i].segment);
|
||||
PRINTF("num=%d adrs=%x end=%x\n", objectCtx->numEntries, (uintptr_t)objectCtx->slots[i].segment + size,
|
||||
objectCtx->spaceEnd);
|
||||
DMA_REQUEST_SYNC(objectCtx->slots[i].segment, gObjectTable[id].vromStart, size, "../z_scene.c", 342);
|
||||
}
|
||||
}
|
||||
|
@ -160,14 +158,14 @@ void* func_800982FC(ObjectContext* objectCtx, s32 slot, s16 objectId) {
|
|||
entry->dmaRequest.vromAddr = 0;
|
||||
|
||||
size = objectFile->vromEnd - objectFile->vromStart;
|
||||
osSyncPrintf("OBJECT EXCHANGE NO=%2d BANK=%3d SIZE=%8.3fK\n", slot, objectId, size / 1024.0f);
|
||||
PRINTF("OBJECT EXCHANGE NO=%2d BANK=%3d SIZE=%8.3fK\n", slot, objectId, size / 1024.0f);
|
||||
|
||||
nextPtr = (void*)ALIGN16((uintptr_t)entry->segment + size);
|
||||
|
||||
ASSERT(nextPtr < objectCtx->spaceEnd, "nextptr < this->endSegment", "../z_scene.c", 381);
|
||||
|
||||
// "Object exchange free size=%08x"
|
||||
osSyncPrintf("オブジェクト入れ替え空きサイズ=%08x\n", (uintptr_t)objectCtx->spaceEnd - (uintptr_t)nextPtr);
|
||||
PRINTF("オブジェクト入れ替え空きサイズ=%08x\n", (uintptr_t)objectCtx->spaceEnd - (uintptr_t)nextPtr);
|
||||
|
||||
return nextPtr;
|
||||
}
|
||||
|
@ -177,8 +175,8 @@ s32 Scene_ExecuteCommands(PlayState* play, SceneCmd* sceneCmd) {
|
|||
|
||||
while (true) {
|
||||
cmdCode = sceneCmd->base.code;
|
||||
osSyncPrintf("*** Scene_Word = { code=%d, data1=%02x, data2=%04x } ***\n", cmdCode, sceneCmd->base.data1,
|
||||
sceneCmd->base.data2);
|
||||
PRINTF("*** Scene_Word = { code=%d, data1=%02x, data2=%04x } ***\n", cmdCode, sceneCmd->base.data1,
|
||||
sceneCmd->base.data2);
|
||||
|
||||
if (cmdCode == SCENE_CMD_ID_END) {
|
||||
break;
|
||||
|
@ -187,9 +185,9 @@ s32 Scene_ExecuteCommands(PlayState* play, SceneCmd* sceneCmd) {
|
|||
if (cmdCode < ARRAY_COUNT(gSceneCmdHandlers)) {
|
||||
gSceneCmdHandlers[cmdCode](play, sceneCmd);
|
||||
} else {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("code の値が異常です\n"); // "code variable is abnormal"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("code の値が異常です\n"); // "code variable is abnormal"
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
sceneCmd++;
|
||||
}
|
||||
|
@ -425,9 +423,9 @@ void Scene_CommandAlternateHeaderList(PlayState* play, SceneCmd* cmd) {
|
|||
s32 pad;
|
||||
SceneCmd* altHeader;
|
||||
|
||||
osSyncPrintf("\n[ZU]sceneset age =[%X]", ((void)0, gSaveContext.save.linkAge));
|
||||
osSyncPrintf("\n[ZU]sceneset time =[%X]", ((void)0, gSaveContext.save.cutsceneIndex));
|
||||
osSyncPrintf("\n[ZU]sceneset counter=[%X]", ((void)0, gSaveContext.sceneLayer));
|
||||
PRINTF("\n[ZU]sceneset age =[%X]", ((void)0, gSaveContext.save.linkAge));
|
||||
PRINTF("\n[ZU]sceneset time =[%X]", ((void)0, gSaveContext.save.cutsceneIndex));
|
||||
PRINTF("\n[ZU]sceneset counter=[%X]", ((void)0, gSaveContext.sceneLayer));
|
||||
|
||||
if (gSaveContext.sceneLayer != 0) {
|
||||
altHeader = ((SceneCmd**)SEGMENTED_TO_VIRTUAL(cmd->altHeaders.data))[gSaveContext.sceneLayer - 1];
|
||||
|
@ -439,7 +437,7 @@ void Scene_CommandAlternateHeaderList(PlayState* play, SceneCmd* cmd) {
|
|||
(cmd + 1)->base.code = SCENE_CMD_ID_END;
|
||||
} else {
|
||||
// "Coughh! There is no specified dataaaaa!"
|
||||
osSyncPrintf("\nげぼはっ! 指定されたデータがないでええっす!");
|
||||
PRINTF("\nげぼはっ! 指定されたデータがないでええっす!");
|
||||
|
||||
if (gSaveContext.sceneLayer == SCENE_LAYER_ADULT_NIGHT) {
|
||||
// Due to the condition above, this is equivalent to accessing altHeaders[SCENE_LAYER_ADULT_DAY - 1]
|
||||
|
@ -448,7 +446,7 @@ void Scene_CommandAlternateHeaderList(PlayState* play, SceneCmd* cmd) {
|
|||
.data))[(gSaveContext.sceneLayer - SCENE_LAYER_ADULT_NIGHT) + SCENE_LAYER_ADULT_DAY - 1];
|
||||
|
||||
// "Using adult day data there!"
|
||||
osSyncPrintf("\nそこで、大人の昼データを使用するでええっす!!");
|
||||
PRINTF("\nそこで、大人の昼データを使用するでええっす!!");
|
||||
|
||||
if (altHeader != NULL) {
|
||||
Scene_ExecuteCommands(play, SEGMENTED_TO_VIRTUAL(altHeader));
|
||||
|
@ -460,7 +458,7 @@ void Scene_CommandAlternateHeaderList(PlayState* play, SceneCmd* cmd) {
|
|||
}
|
||||
|
||||
void Scene_CommandCutsceneData(PlayState* play, SceneCmd* cmd) {
|
||||
osSyncPrintf("\ngame_play->demo_play.data=[%x]", play->csCtx.script);
|
||||
PRINTF("\ngame_play->demo_play.data=[%x]", play->csCtx.script);
|
||||
play->csCtx.script = SEGMENTED_TO_VIRTUAL(cmd->cutsceneData.data);
|
||||
}
|
||||
|
||||
|
@ -479,8 +477,8 @@ void Scene_CommandMiscSettings(PlayState* play, SceneCmd* cmd) {
|
|||
((play->sceneId >= SCENE_MARKET_ENTRANCE_DAY) && (play->sceneId <= SCENE_TEMPLE_OF_TIME_EXTERIOR_RUINS))) {
|
||||
if (gSaveContext.save.cutsceneIndex < 0xFFF0) {
|
||||
gSaveContext.save.info.worldMapAreaData |= gBitFlags[gSaveContext.worldMapArea];
|
||||
osSyncPrintf("000 area_arrival=%x (%d)\n", gSaveContext.save.info.worldMapAreaData,
|
||||
gSaveContext.worldMapArea);
|
||||
PRINTF("000 area_arrival=%x (%d)\n", gSaveContext.save.info.worldMapAreaData,
|
||||
gSaveContext.worldMapArea);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -76,9 +76,9 @@ void SkelAnime_DrawLod(PlayState* play, void** skeleton, Vec3s* jointTable, Over
|
|||
Vec3s rot;
|
||||
|
||||
if (skeleton == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("Si2_Lod_draw():skelがNULLです。\n"); // "skel is NULL."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("Si2_Lod_draw():skelがNULLです。\n"); // "skel is NULL."
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -188,9 +188,9 @@ void SkelAnime_DrawFlexLod(PlayState* play, void** skeleton, Vec3s* jointTable,
|
|||
Mtx* mtx = GRAPH_ALLOC(play->state.gfxCtx, dListCount * sizeof(Mtx));
|
||||
|
||||
if (skeleton == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("Si2_Lod_draw_SV():skelがNULLです。\n"); // "skel is NULL."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("Si2_Lod_draw_SV():skelがNULLです。\n"); // "skel is NULL."
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -293,9 +293,9 @@ void SkelAnime_DrawOpa(PlayState* play, void** skeleton, Vec3s* jointTable, Over
|
|||
Vec3s rot;
|
||||
|
||||
if (skeleton == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("Si2_draw():skelがNULLです。\n"); // "skel is NULL."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("Si2_draw():skelがNULLです。\n"); // "skel is NULL."
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -405,9 +405,9 @@ void SkelAnime_DrawFlexOpa(PlayState* play, void** skeleton, Vec3s* jointTable,
|
|||
Mtx* mtx = GRAPH_ALLOC(play->state.gfxCtx, dListCount * sizeof(Mtx));
|
||||
|
||||
if (skeleton == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("Si2_draw_SV():skelがNULLです。\n"); // "skel is NULL."
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("Si2_draw_SV():skelがNULLです。\n"); // "skel is NULL."
|
||||
PRINTF(VT_RST);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -556,10 +556,10 @@ Gfx* SkelAnime_Draw(PlayState* play, void** skeleton, Vec3s* jointTable, Overrid
|
|||
Vec3s rot;
|
||||
|
||||
if (skeleton == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "skel is NULL. Returns NULL."
|
||||
osSyncPrintf("Si2_draw2():skelがNULLです。NULLを返します。\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Si2_draw2():skelがNULLです。NULLを返します。\n");
|
||||
PRINTF(VT_RST);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@ -665,10 +665,10 @@ Gfx* SkelAnime_DrawFlex(PlayState* play, void** skeleton, Vec3s* jointTable, s32
|
|||
Mtx* mtx = GRAPH_ALLOC(play->state.gfxCtx, dListCount * sizeof(*mtx));
|
||||
|
||||
if (skeleton == NULL) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "skel is NULL. Returns NULL."
|
||||
osSyncPrintf("Si2_draw2_SV():skelがNULLです。NULLを返します。\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Si2_draw2_SV():skelがNULLです。NULLを返します。\n");
|
||||
PRINTF(VT_RST);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
@ -1077,10 +1077,10 @@ void SkelAnime_InitLink(PlayState* play, SkelAnime* skelAnime, FlexSkeletonHeade
|
|||
}
|
||||
|
||||
if ((skelAnime->jointTable == NULL) || (skelAnime->morphTable == NULL)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Memory allocation error"
|
||||
osSyncPrintf("Skeleton_Info_Rom_SV_ct メモリアロケーションエラー\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Skeleton_Info_Rom_SV_ct メモリアロケーションエラー\n");
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
LinkAnimation_Change(play, skelAnime, animation, 1.0f, 0.0f, 0.0f, ANIMMODE_LOOP, 0.0f);
|
||||
|
@ -1392,9 +1392,9 @@ SkelAnime_Init(PlayState* play, SkelAnime* skelAnime, SkeletonHeader* skeletonHe
|
|||
skelAnime->morphTable = morphTable;
|
||||
}
|
||||
if ((skelAnime->jointTable == NULL) || (skelAnime->morphTable == NULL)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
osSyncPrintf("Skeleton_Info2_ct メモリアロケーションエラー\n"); // "Memory allocation error"
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
PRINTF("Skeleton_Info2_ct メモリアロケーションエラー\n"); // "Memory allocation error"
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
if (animation != NULL) {
|
||||
|
@ -1426,10 +1426,10 @@ SkelAnime_InitFlex(PlayState* play, SkelAnime* skelAnime, FlexSkeletonHeader* sk
|
|||
skelAnime->morphTable = morphTable;
|
||||
}
|
||||
if ((skelAnime->jointTable == NULL) || (skelAnime->morphTable == NULL)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Memory allocation error"
|
||||
osSyncPrintf("Skeleton_Info_Rom_SV_ct メモリアロケーションエラー\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Skeleton_Info_Rom_SV_ct メモリアロケーションエラー\n");
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
if (animation != NULL) {
|
||||
|
@ -1452,10 +1452,10 @@ SkelAnime_InitSkin(PlayState* play, SkelAnime* skelAnime, SkeletonHeader* skelet
|
|||
skelAnime->morphTable =
|
||||
ZELDA_ARENA_MALLOC(skelAnime->limbCount * sizeof(*skelAnime->morphTable), "../z_skelanime.c", 3121);
|
||||
if ((skelAnime->jointTable == NULL) || (skelAnime->morphTable == NULL)) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Memory allocation error"
|
||||
osSyncPrintf("Skeleton_Info2_skin2_ct メモリアロケーションエラー\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("Skeleton_Info2_skin2_ct メモリアロケーションエラー\n");
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
if (animation != NULL) {
|
||||
|
@ -1840,13 +1840,13 @@ void SkelAnime_Free(SkelAnime* skelAnime, PlayState* play) {
|
|||
if (skelAnime->jointTable != NULL) {
|
||||
ZELDA_ARENA_FREE(skelAnime->jointTable, "../z_skelanime.c", 3729);
|
||||
} else {
|
||||
osSyncPrintf("now_joint あきまへん!!\n"); // "now_joint is freed! !"
|
||||
PRINTF("now_joint あきまへん!!\n"); // "now_joint is freed! !"
|
||||
}
|
||||
|
||||
if (skelAnime->morphTable != NULL) {
|
||||
ZELDA_ARENA_FREE(skelAnime->morphTable, "../z_skelanime.c", 3731);
|
||||
} else {
|
||||
osSyncPrintf("morf_joint あきまへん!!\n"); // "morf_joint is freed !!"
|
||||
PRINTF("morf_joint あきまへん!!\n"); // "morf_joint is freed !!"
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -254,9 +254,9 @@ s32 SkinMatrix_Invert(MtxF* src, MtxF* dest) {
|
|||
// Reaching row = 4 means the column is either all 0 or a duplicate column.
|
||||
// Therefore src is a singular matrix (0 determinant).
|
||||
|
||||
osSyncPrintf(VT_COL(YELLOW, BLACK));
|
||||
osSyncPrintf("Skin_Matrix_InverseMatrix():逆行列つくれません\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_COL(YELLOW, BLACK));
|
||||
PRINTF("Skin_Matrix_InverseMatrix():逆行列つくれません\n");
|
||||
PRINTF(VT_RST);
|
||||
return 2;
|
||||
}
|
||||
|
||||
|
@ -596,7 +596,7 @@ Mtx* SkinMatrix_MtxFToNewMtx(GraphicsContext* gfxCtx, MtxF* src) {
|
|||
Mtx* mtx = GRAPH_ALLOC(gfxCtx, sizeof(Mtx));
|
||||
|
||||
if (mtx == NULL) {
|
||||
osSyncPrintf("Skin_Matrix_to_Mtx_new() 確保失敗:NULLを返して終了\n", mtx);
|
||||
PRINTF("Skin_Matrix_to_Mtx_new() 確保失敗:NULLを返して終了\n", mtx);
|
||||
return NULL;
|
||||
}
|
||||
SkinMatrix_MtxFToMtx(src, mtx);
|
||||
|
|
|
@ -345,15 +345,15 @@ void Sram_OpenSave(SramContext* sramCtx) {
|
|||
u16 j;
|
||||
u8* ptr;
|
||||
|
||||
osSyncPrintf("個人File作成\n"); // "Create personal file"
|
||||
PRINTF("個人File作成\n"); // "Create personal file"
|
||||
i = gSramSlotOffsets[gSaveContext.fileNum];
|
||||
osSyncPrintf("ぽいんと=%x(%d)\n", i, gSaveContext.fileNum); // "Point="
|
||||
PRINTF("ぽいんと=%x(%d)\n", i, gSaveContext.fileNum); // "Point="
|
||||
|
||||
MemCpy(&gSaveContext, sramCtx->readBuff + i, sizeof(Save));
|
||||
|
||||
osSyncPrintf(VT_FGCOL(YELLOW));
|
||||
osSyncPrintf("SCENE_DATA_ID = %d SceneNo = %d\n", gSaveContext.save.info.playerData.savedSceneId,
|
||||
((void)0, gSaveContext.save.entranceIndex));
|
||||
PRINTF(VT_FGCOL(YELLOW));
|
||||
PRINTF("SCENE_DATA_ID = %d SceneNo = %d\n", gSaveContext.save.info.playerData.savedSceneId,
|
||||
((void)0, gSaveContext.save.entranceIndex));
|
||||
|
||||
switch (gSaveContext.save.info.playerData.savedSceneId) {
|
||||
case SCENE_DEKU_TREE:
|
||||
|
@ -423,43 +423,43 @@ void Sram_OpenSave(SramContext* sramCtx) {
|
|||
break;
|
||||
}
|
||||
|
||||
osSyncPrintf("scene_no = %d\n", gSaveContext.save.entranceIndex);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("scene_no = %d\n", gSaveContext.save.entranceIndex);
|
||||
PRINTF(VT_RST);
|
||||
|
||||
if (gSaveContext.save.info.playerData.health < 0x30) {
|
||||
gSaveContext.save.info.playerData.health = 0x30;
|
||||
}
|
||||
|
||||
if (gSaveContext.save.info.scarecrowLongSongSet) {
|
||||
osSyncPrintf(VT_FGCOL(BLUE));
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
PRINTF(VT_FGCOL(BLUE));
|
||||
PRINTF("\n====================================================================\n");
|
||||
|
||||
MemCpy(gScarecrowLongSongPtr, gSaveContext.save.info.scarecrowLongSong,
|
||||
sizeof(gSaveContext.save.info.scarecrowLongSong));
|
||||
|
||||
ptr = (u8*)gScarecrowLongSongPtr;
|
||||
for (i = 0; i < ARRAY_COUNT(gSaveContext.save.info.scarecrowLongSong); i++, ptr++) {
|
||||
osSyncPrintf("%d, ", *ptr);
|
||||
PRINTF("%d, ", *ptr);
|
||||
}
|
||||
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("\n====================================================================\n");
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
if (gSaveContext.save.info.scarecrowSpawnSongSet) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("\n====================================================================\n");
|
||||
|
||||
MemCpy(gScarecrowSpawnSongPtr, gSaveContext.save.info.scarecrowSpawnSong,
|
||||
sizeof(gSaveContext.save.info.scarecrowSpawnSong));
|
||||
|
||||
ptr = gScarecrowSpawnSongPtr;
|
||||
for (i = 0; i < ARRAY_COUNT(gSaveContext.save.info.scarecrowSpawnSong); i++, ptr++) {
|
||||
osSyncPrintf("%d, ", *ptr);
|
||||
PRINTF("%d, ", *ptr);
|
||||
}
|
||||
|
||||
osSyncPrintf("\n====================================================================\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("\n====================================================================\n");
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
// if zelda cutscene has been watched but lullaby was not obtained, restore cutscene and take away letter
|
||||
|
@ -566,7 +566,7 @@ void Sram_VerifyAndLoadAllSaves(FileSelectState* fileSelect, SramContext* sramCt
|
|||
u16* ptr;
|
||||
u16 dayTime;
|
||||
|
||||
osSyncPrintf("SRAM START─LOAD\n");
|
||||
PRINTF("SRAM START─LOAD\n");
|
||||
bzero(sramCtx->readBuff, SRAM_SIZE);
|
||||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000), sramCtx->readBuff, SRAM_SIZE, OS_READ);
|
||||
|
||||
|
@ -574,41 +574,41 @@ void Sram_VerifyAndLoadAllSaves(FileSelectState* fileSelect, SramContext* sramCt
|
|||
|
||||
for (slotNum = 0; slotNum < 3; slotNum++) {
|
||||
offset = gSramSlotOffsets[slotNum];
|
||||
osSyncPrintf("ぽいんと=%x(%d) SAVE_MAX=%d\n", offset, gSaveContext.fileNum, sizeof(Save));
|
||||
PRINTF("ぽいんと=%x(%d) SAVE_MAX=%d\n", offset, gSaveContext.fileNum, sizeof(Save));
|
||||
MemCpy(&gSaveContext, sramCtx->readBuff + offset, sizeof(Save));
|
||||
|
||||
oldChecksum = gSaveContext.save.info.checksum;
|
||||
gSaveContext.save.info.checksum = 0;
|
||||
ptr = (u16*)&gSaveContext;
|
||||
osSyncPrintf("\n============= S(%d) =============\n", slotNum);
|
||||
PRINTF("\n============= S(%d) =============\n", slotNum);
|
||||
|
||||
for (i = newChecksum = j = 0; i < CHECKSUM_SIZE; i++, offset += 2) {
|
||||
newChecksum += *ptr++;
|
||||
}
|
||||
|
||||
// "SAVE checksum calculation"
|
||||
osSyncPrintf("\nSAVEチェックサム計算 j=%x mmm=%x ", newChecksum, oldChecksum);
|
||||
PRINTF("\nSAVEチェックサム計算 j=%x mmm=%x ", newChecksum, oldChecksum);
|
||||
|
||||
if (newChecksum != oldChecksum) {
|
||||
// checksum didnt match, try backup save
|
||||
osSyncPrintf("ERROR!!! = %x(%d)\n", gSramSlotOffsets[slotNum], slotNum);
|
||||
PRINTF("ERROR!!! = %x(%d)\n", gSramSlotOffsets[slotNum], slotNum);
|
||||
offset = gSramSlotOffsets[slotNum + 3];
|
||||
MemCpy(&gSaveContext, sramCtx->readBuff + offset, sizeof(Save));
|
||||
|
||||
oldChecksum = gSaveContext.save.info.checksum;
|
||||
gSaveContext.save.info.checksum = 0;
|
||||
ptr = (u16*)&gSaveContext;
|
||||
osSyncPrintf("================= BACK─UP ========================\n");
|
||||
PRINTF("================= BACK─UP ========================\n");
|
||||
|
||||
for (i = newChecksum = j = 0; i < CHECKSUM_SIZE; i++, offset += 2) {
|
||||
newChecksum += *ptr++;
|
||||
}
|
||||
// "(B) SAVE checksum calculation"
|
||||
osSyncPrintf("\n(B)SAVEチェックサム計算 j=%x mmm=%x ", newChecksum, oldChecksum);
|
||||
PRINTF("\n(B)SAVEチェックサム計算 j=%x mmm=%x ", newChecksum, oldChecksum);
|
||||
|
||||
if (newChecksum != oldChecksum) {
|
||||
// backup save didnt work, make new save
|
||||
osSyncPrintf("ERROR!!! = %x(%d+3)\n", gSramSlotOffsets[slotNum + 3], slotNum);
|
||||
PRINTF("ERROR!!! = %x(%d+3)\n", gSramSlotOffsets[slotNum + 3], slotNum);
|
||||
bzero(&gSaveContext.save.entranceIndex, sizeof(s32));
|
||||
bzero(&gSaveContext.save.linkAge, sizeof(s32));
|
||||
bzero(&gSaveContext.save.cutsceneIndex, sizeof(s32));
|
||||
|
@ -626,47 +626,46 @@ void Sram_VerifyAndLoadAllSaves(FileSelectState* fileSelect, SramContext* sramCt
|
|||
gSaveContext.save.info.playerData.newf[3] = 'D';
|
||||
gSaveContext.save.info.playerData.newf[4] = 'A';
|
||||
gSaveContext.save.info.playerData.newf[5] = 'Z';
|
||||
osSyncPrintf("newf=%x,%x,%x,%x,%x,%x\n", gSaveContext.save.info.playerData.newf[0],
|
||||
gSaveContext.save.info.playerData.newf[1], gSaveContext.save.info.playerData.newf[2],
|
||||
gSaveContext.save.info.playerData.newf[3], gSaveContext.save.info.playerData.newf[4],
|
||||
gSaveContext.save.info.playerData.newf[5]);
|
||||
PRINTF("newf=%x,%x,%x,%x,%x,%x\n", gSaveContext.save.info.playerData.newf[0],
|
||||
gSaveContext.save.info.playerData.newf[1], gSaveContext.save.info.playerData.newf[2],
|
||||
gSaveContext.save.info.playerData.newf[3], gSaveContext.save.info.playerData.newf[4],
|
||||
gSaveContext.save.info.playerData.newf[5]);
|
||||
} else {
|
||||
Sram_InitNewSave();
|
||||
}
|
||||
|
||||
ptr = (u16*)&gSaveContext;
|
||||
osSyncPrintf("\n--------------------------------------------------------------\n");
|
||||
PRINTF("\n--------------------------------------------------------------\n");
|
||||
|
||||
for (i = newChecksum = j = 0; i < CHECKSUM_SIZE; i++) {
|
||||
osSyncPrintf("%x ", *ptr);
|
||||
PRINTF("%x ", *ptr);
|
||||
if (++j == 0x20) {
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
j = 0;
|
||||
}
|
||||
newChecksum += *ptr++;
|
||||
}
|
||||
|
||||
gSaveContext.save.info.checksum = newChecksum;
|
||||
osSyncPrintf("\nCheck_Sum=%x(%x)\n", gSaveContext.save.info.checksum, newChecksum);
|
||||
PRINTF("\nCheck_Sum=%x(%x)\n", gSaveContext.save.info.checksum, newChecksum);
|
||||
|
||||
i = gSramSlotOffsets[slotNum + 3];
|
||||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000) + i, &gSaveContext, SLOT_SIZE, OS_WRITE);
|
||||
|
||||
osSyncPrintf("????#%x,%x,%x,%x,%x,%x\n", gSaveContext.save.info.playerData.newf[0],
|
||||
gSaveContext.save.info.playerData.newf[1], gSaveContext.save.info.playerData.newf[2],
|
||||
gSaveContext.save.info.playerData.newf[3], gSaveContext.save.info.playerData.newf[4],
|
||||
gSaveContext.save.info.playerData.newf[5]);
|
||||
osSyncPrintf("\nぽいんと=%x(%d+3) check_sum=%x(%x)\n", i, slotNum, gSaveContext.save.info.checksum,
|
||||
newChecksum);
|
||||
PRINTF("????#%x,%x,%x,%x,%x,%x\n", gSaveContext.save.info.playerData.newf[0],
|
||||
gSaveContext.save.info.playerData.newf[1], gSaveContext.save.info.playerData.newf[2],
|
||||
gSaveContext.save.info.playerData.newf[3], gSaveContext.save.info.playerData.newf[4],
|
||||
gSaveContext.save.info.playerData.newf[5]);
|
||||
PRINTF("\nぽいんと=%x(%d+3) check_sum=%x(%x)\n", i, slotNum, gSaveContext.save.info.checksum,
|
||||
newChecksum);
|
||||
}
|
||||
|
||||
i = gSramSlotOffsets[slotNum];
|
||||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000) + i, &gSaveContext, SLOT_SIZE, OS_WRITE);
|
||||
|
||||
osSyncPrintf("ぽいんと=%x(%d) check_sum=%x(%x)\n", i, slotNum, gSaveContext.save.info.checksum,
|
||||
newChecksum);
|
||||
PRINTF("ぽいんと=%x(%d) check_sum=%x(%x)\n", i, slotNum, gSaveContext.save.info.checksum, newChecksum);
|
||||
} else {
|
||||
osSyncPrintf("\nSAVEデータ OK!!!!\n"); // "SAVE data OK! ! ! !"
|
||||
PRINTF("\nSAVEデータ OK!!!!\n"); // "SAVE data OK! ! ! !"
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -674,8 +673,8 @@ void Sram_VerifyAndLoadAllSaves(FileSelectState* fileSelect, SramContext* sramCt
|
|||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000), sramCtx->readBuff, SRAM_SIZE, OS_READ);
|
||||
gSaveContext.save.dayTime = dayTime;
|
||||
|
||||
osSyncPrintf("SAVECT=%x, NAME=%x, LIFE=%x, ITEM=%x, 64DD=%x, HEART=%x\n", DEATHS, NAME, HEALTH_CAP, QUEST, N64DD,
|
||||
DEFENSE);
|
||||
PRINTF("SAVECT=%x, NAME=%x, LIFE=%x, ITEM=%x, 64DD=%x, HEART=%x\n", DEATHS, NAME, HEALTH_CAP, QUEST, N64DD,
|
||||
DEFENSE);
|
||||
|
||||
MemCpy(&fileSelect->deaths[0], sramCtx->readBuff + SLOT_OFFSET(0) + DEATHS, sizeof(fileSelect->deaths[0]));
|
||||
MemCpy(&fileSelect->deaths[1], sramCtx->readBuff + SLOT_OFFSET(1) + DEATHS, sizeof(fileSelect->deaths[0]));
|
||||
|
@ -708,10 +707,9 @@ void Sram_VerifyAndLoadAllSaves(FileSelectState* fileSelect, SramContext* sramCt
|
|||
MemCpy(&fileSelect->health[1], sramCtx->readBuff + SLOT_OFFSET(1) + HEALTH, sizeof(fileSelect->health[0]));
|
||||
MemCpy(&fileSelect->health[2], sramCtx->readBuff + SLOT_OFFSET(2) + HEALTH, sizeof(fileSelect->health[0]));
|
||||
|
||||
osSyncPrintf("f_64dd=%d, %d, %d\n", fileSelect->n64ddFlags[0], fileSelect->n64ddFlags[1],
|
||||
fileSelect->n64ddFlags[2]);
|
||||
osSyncPrintf("heart_status=%d, %d, %d\n", fileSelect->defense[0], fileSelect->defense[1], fileSelect->defense[2]);
|
||||
osSyncPrintf("now_life=%d, %d, %d\n", fileSelect->health[0], fileSelect->health[1], fileSelect->health[2]);
|
||||
PRINTF("f_64dd=%d, %d, %d\n", fileSelect->n64ddFlags[0], fileSelect->n64ddFlags[1], fileSelect->n64ddFlags[2]);
|
||||
PRINTF("heart_status=%d, %d, %d\n", fileSelect->defense[0], fileSelect->defense[1], fileSelect->defense[2]);
|
||||
PRINTF("now_life=%d, %d, %d\n", fileSelect->health[0], fileSelect->health[1], fileSelect->health[2]);
|
||||
}
|
||||
|
||||
void Sram_InitSave(FileSelectState* fileSelect, SramContext* sramCtx) {
|
||||
|
@ -747,42 +745,42 @@ void Sram_InitSave(FileSelectState* fileSelect, SramContext* sramCtx) {
|
|||
gSaveContext.save.info.playerData.newf[5] = 'Z';
|
||||
|
||||
gSaveContext.save.info.playerData.n64ddFlag = fileSelect->n64ddFlag;
|
||||
osSyncPrintf("64DDフラグ=%d\n", fileSelect->n64ddFlag);
|
||||
osSyncPrintf("newf=%x,%x,%x,%x,%x,%x\n", gSaveContext.save.info.playerData.newf[0],
|
||||
gSaveContext.save.info.playerData.newf[1], gSaveContext.save.info.playerData.newf[2],
|
||||
gSaveContext.save.info.playerData.newf[3], gSaveContext.save.info.playerData.newf[4],
|
||||
gSaveContext.save.info.playerData.newf[5]);
|
||||
osSyncPrintf("\n$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$\n");
|
||||
PRINTF("64DDフラグ=%d\n", fileSelect->n64ddFlag);
|
||||
PRINTF("newf=%x,%x,%x,%x,%x,%x\n", gSaveContext.save.info.playerData.newf[0],
|
||||
gSaveContext.save.info.playerData.newf[1], gSaveContext.save.info.playerData.newf[2],
|
||||
gSaveContext.save.info.playerData.newf[3], gSaveContext.save.info.playerData.newf[4],
|
||||
gSaveContext.save.info.playerData.newf[5]);
|
||||
PRINTF("\n$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$\n");
|
||||
|
||||
ptr = (u16*)&gSaveContext;
|
||||
j = 0;
|
||||
checksum = 0;
|
||||
|
||||
for (offset = 0; offset < CHECKSUM_SIZE; offset++) {
|
||||
osSyncPrintf("%x ", *ptr);
|
||||
PRINTF("%x ", *ptr);
|
||||
checksum += *ptr++;
|
||||
if (++j == 0x20) {
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
j = 0;
|
||||
}
|
||||
}
|
||||
|
||||
gSaveContext.save.info.checksum = checksum;
|
||||
osSyncPrintf("\nチェックサム=%x\n", gSaveContext.save.info.checksum); // "Checksum = %x"
|
||||
PRINTF("\nチェックサム=%x\n", gSaveContext.save.info.checksum); // "Checksum = %x"
|
||||
|
||||
offset = gSramSlotOffsets[gSaveContext.fileNum];
|
||||
osSyncPrintf("I=%x no=%d\n", offset, gSaveContext.fileNum);
|
||||
PRINTF("I=%x no=%d\n", offset, gSaveContext.fileNum);
|
||||
MemCpy(sramCtx->readBuff + offset, &gSaveContext, sizeof(Save));
|
||||
|
||||
offset = gSramSlotOffsets[gSaveContext.fileNum + 3];
|
||||
osSyncPrintf("I=%x no=%d\n", offset, gSaveContext.fileNum + 3);
|
||||
PRINTF("I=%x no=%d\n", offset, gSaveContext.fileNum + 3);
|
||||
MemCpy(sramCtx->readBuff + offset, &gSaveContext, sizeof(Save));
|
||||
|
||||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000), sramCtx->readBuff, SRAM_SIZE, OS_WRITE);
|
||||
|
||||
osSyncPrintf("SAVE終了\n"); // "SAVE end"
|
||||
osSyncPrintf("z_common_data.file_no = %d\n", gSaveContext.fileNum);
|
||||
osSyncPrintf("SAVECT=%x, NAME=%x, LIFE=%x, ITEM=%x, SAVE_64DD=%x\n", DEATHS, NAME, HEALTH_CAP, QUEST, N64DD);
|
||||
PRINTF("SAVE終了\n"); // "SAVE end"
|
||||
PRINTF("z_common_data.file_no = %d\n", gSaveContext.fileNum);
|
||||
PRINTF("SAVECT=%x, NAME=%x, LIFE=%x, ITEM=%x, SAVE_64DD=%x\n", DEATHS, NAME, HEALTH_CAP, QUEST, N64DD);
|
||||
|
||||
j = gSramSlotOffsets[gSaveContext.fileNum];
|
||||
|
||||
|
@ -798,9 +796,9 @@ void Sram_InitSave(FileSelectState* fileSelect, SramContext* sramCtx) {
|
|||
MemCpy(&fileSelect->defense[gSaveContext.fileNum], sramCtx->readBuff + j + DEFENSE, sizeof(fileSelect->defense[0]));
|
||||
MemCpy(&fileSelect->health[gSaveContext.fileNum], sramCtx->readBuff + j + HEALTH, sizeof(fileSelect->health[0]));
|
||||
|
||||
osSyncPrintf("f_64dd[%d]=%d\n", gSaveContext.fileNum, fileSelect->n64ddFlags[gSaveContext.fileNum]);
|
||||
osSyncPrintf("heart_status[%d]=%d\n", gSaveContext.fileNum, fileSelect->defense[gSaveContext.fileNum]);
|
||||
osSyncPrintf("now_life[%d]=%d\n", gSaveContext.fileNum, fileSelect->health[gSaveContext.fileNum]);
|
||||
PRINTF("f_64dd[%d]=%d\n", gSaveContext.fileNum, fileSelect->n64ddFlags[gSaveContext.fileNum]);
|
||||
PRINTF("heart_status[%d]=%d\n", gSaveContext.fileNum, fileSelect->defense[gSaveContext.fileNum]);
|
||||
PRINTF("now_life[%d]=%d\n", gSaveContext.fileNum, fileSelect->health[gSaveContext.fileNum]);
|
||||
}
|
||||
|
||||
void Sram_EraseSave(FileSelectState* fileSelect, SramContext* sramCtx) {
|
||||
|
@ -819,15 +817,15 @@ void Sram_EraseSave(FileSelectState* fileSelect, SramContext* sramCtx) {
|
|||
MemCpy(sramCtx->readBuff + offset, &gSaveContext, sizeof(Save));
|
||||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000) + offset, &gSaveContext, SLOT_SIZE, OS_WRITE);
|
||||
|
||||
osSyncPrintf("CLEAR終了\n");
|
||||
PRINTF("CLEAR終了\n");
|
||||
}
|
||||
|
||||
void Sram_CopySave(FileSelectState* fileSelect, SramContext* sramCtx) {
|
||||
s32 offset;
|
||||
|
||||
osSyncPrintf("READ=%d(%x) COPY=%d(%x)\n", fileSelect->selectedFileIndex,
|
||||
gSramSlotOffsets[fileSelect->selectedFileIndex], fileSelect->copyDestFileIndex,
|
||||
gSramSlotOffsets[fileSelect->copyDestFileIndex]);
|
||||
PRINTF("READ=%d(%x) COPY=%d(%x)\n", fileSelect->selectedFileIndex,
|
||||
gSramSlotOffsets[fileSelect->selectedFileIndex], fileSelect->copyDestFileIndex,
|
||||
gSramSlotOffsets[fileSelect->copyDestFileIndex]);
|
||||
|
||||
offset = gSramSlotOffsets[fileSelect->selectedFileIndex];
|
||||
MemCpy(&gSaveContext, sramCtx->readBuff + offset, sizeof(Save));
|
||||
|
@ -857,9 +855,9 @@ void Sram_CopySave(FileSelectState* fileSelect, SramContext* sramCtx) {
|
|||
MemCpy(&fileSelect->health[fileSelect->copyDestFileIndex], (sramCtx->readBuff + offset) + HEALTH,
|
||||
sizeof(fileSelect->health[0]));
|
||||
|
||||
osSyncPrintf("f_64dd[%d]=%d\n", gSaveContext.fileNum, fileSelect->n64ddFlags[gSaveContext.fileNum]);
|
||||
osSyncPrintf("heart_status[%d]=%d\n", gSaveContext.fileNum, fileSelect->defense[gSaveContext.fileNum]);
|
||||
osSyncPrintf("COPY終了\n"); // "Copy end"
|
||||
PRINTF("f_64dd[%d]=%d\n", gSaveContext.fileNum, fileSelect->n64ddFlags[gSaveContext.fileNum]);
|
||||
PRINTF("heart_status[%d]=%d\n", gSaveContext.fileNum, fileSelect->defense[gSaveContext.fileNum]);
|
||||
PRINTF("COPY終了\n"); // "Copy end"
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -872,12 +870,12 @@ void Sram_WriteSramHeader(SramContext* sramCtx) {
|
|||
void Sram_InitSram(GameState* gameState, SramContext* sramCtx) {
|
||||
u16 i;
|
||||
|
||||
osSyncPrintf("sram_initialize( Game *game, Sram *sram )\n");
|
||||
PRINTF("sram_initialize( Game *game, Sram *sram )\n");
|
||||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000), sramCtx->readBuff, SRAM_SIZE, OS_READ);
|
||||
|
||||
for (i = 0; i < ARRAY_COUNTU(sZeldaMagic) - 3; i++) {
|
||||
if (sZeldaMagic[i + SRAM_HEADER_MAGIC] != sramCtx->readBuff[i + SRAM_HEADER_MAGIC]) {
|
||||
osSyncPrintf("SRAM破壊!!!!!!\n"); // "SRAM destruction! ! ! ! ! !"
|
||||
PRINTF("SRAM破壊!!!!!!\n"); // "SRAM destruction! ! ! ! ! !"
|
||||
gSaveContext.language = sramCtx->readBuff[SRAM_HEADER_LANGUAGE];
|
||||
MemCpy(sramCtx->readBuff, sZeldaMagic, sizeof(sZeldaMagic));
|
||||
sramCtx->readBuff[SRAM_HEADER_LANGUAGE] = gSaveContext.language;
|
||||
|
@ -901,16 +899,16 @@ void Sram_InitSram(GameState* gameState, SramContext* sramCtx) {
|
|||
sramCtx->readBuff[i] = i;
|
||||
}
|
||||
SsSram_ReadWrite(OS_K1_TO_PHYSICAL(0xA8000000), sramCtx->readBuff, SRAM_SIZE, OS_WRITE);
|
||||
osSyncPrintf("SRAM破壊!!!!!!\n"); // "SRAM destruction! ! ! ! ! !"
|
||||
PRINTF("SRAM破壊!!!!!!\n"); // "SRAM destruction! ! ! ! ! !"
|
||||
}
|
||||
|
||||
// "GOOD! GOOD! Size = %d + %d = %d"
|
||||
osSyncPrintf("GOOD!GOOD! サイズ=%d + %d = %d\n", sizeof(SaveInfo), 4, sizeof(SaveInfo) + 4);
|
||||
osSyncPrintf(VT_FGCOL(BLUE));
|
||||
osSyncPrintf("Na_SetSoundOutputMode = %d\n", gSaveContext.audioSetting);
|
||||
osSyncPrintf("Na_SetSoundOutputMode = %d\n", gSaveContext.audioSetting);
|
||||
osSyncPrintf("Na_SetSoundOutputMode = %d\n", gSaveContext.audioSetting);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("GOOD!GOOD! サイズ=%d + %d = %d\n", sizeof(SaveInfo), 4, sizeof(SaveInfo) + 4);
|
||||
PRINTF(VT_FGCOL(BLUE));
|
||||
PRINTF("Na_SetSoundOutputMode = %d\n", gSaveContext.audioSetting);
|
||||
PRINTF("Na_SetSoundOutputMode = %d\n", gSaveContext.audioSetting);
|
||||
PRINTF("Na_SetSoundOutputMode = %d\n", gSaveContext.audioSetting);
|
||||
PRINTF(VT_RST);
|
||||
func_800F6700(gSaveContext.audioSetting);
|
||||
}
|
||||
|
||||
|
|
|
@ -50,7 +50,7 @@ void SsSram_Dma(void* dramAddr, size_t size, s32 direction) {
|
|||
}
|
||||
|
||||
void SsSram_ReadWrite(u32 addr, void* dramAddr, size_t size, s32 direction) {
|
||||
osSyncPrintf("ssSRAMReadWrite:%08x %08x %08x %d\n", addr, dramAddr, size, direction);
|
||||
PRINTF("ssSRAMReadWrite:%08x %08x %08x %d\n", addr, dramAddr, size, direction);
|
||||
SsSram_Init(addr, DEVICE_TYPE_SRAM, PI_DOMAIN2, 5, 0xD, 2, 0xC, 0);
|
||||
SsSram_Dma(dramAddr, size, direction);
|
||||
}
|
||||
|
|
|
@ -56,7 +56,7 @@ void View_Init(View* view, GraphicsContext* gfxCtx) {
|
|||
|
||||
if (sLogOnNextViewInit) {
|
||||
if (sLogOnNextViewInit == false) {}
|
||||
osSyncPrintf("\nview: initialize ---\n");
|
||||
PRINTF("\nview: initialize ---\n");
|
||||
sLogOnNextViewInit = false;
|
||||
}
|
||||
|
||||
|
@ -329,15 +329,15 @@ s32 View_ApplyPerspective(View* view) {
|
|||
s32 i;
|
||||
MtxF mf;
|
||||
|
||||
osSyncPrintf("fovy %f near %f far %f scale %f aspect %f normal %08x\n", view->fovy, view->zNear, view->zFar,
|
||||
view->scale, aspect, view->normal);
|
||||
PRINTF("fovy %f near %f far %f scale %f aspect %f normal %08x\n", view->fovy, view->zNear, view->zFar,
|
||||
view->scale, aspect, view->normal);
|
||||
|
||||
Matrix_MtxToMtxF(projection, &mf);
|
||||
osSyncPrintf("projection\n");
|
||||
PRINTF("projection\n");
|
||||
for (i = 0; i < 4; i++) {
|
||||
osSyncPrintf("\t%f\t%f\t%f\t%f\n", mf.mf[i][0], mf.mf[i][1], mf.mf[i][2], mf.mf[i][3]);
|
||||
PRINTF("\t%f\t%f\t%f\t%f\n", mf.mf[i][0], mf.mf[i][1], mf.mf[i][2], mf.mf[i][3]);
|
||||
}
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
}
|
||||
|
||||
view->projection = *projection;
|
||||
|
@ -372,11 +372,11 @@ s32 View_ApplyPerspective(View* view) {
|
|||
MtxF mf;
|
||||
|
||||
Matrix_MtxToMtxF(view->viewingPtr, &mf);
|
||||
osSyncPrintf("viewing\n");
|
||||
PRINTF("viewing\n");
|
||||
for (i = 0; i < 4; i++) {
|
||||
osSyncPrintf("\t%f\t%f\t%f\t%f\n", mf.mf[i][0], mf.mf[i][1], mf.mf[i][2], mf.mf[i][3]);
|
||||
PRINTF("\t%f\t%f\t%f\t%f\n", mf.mf[i][0], mf.mf[i][1], mf.mf[i][2], mf.mf[i][3]);
|
||||
}
|
||||
osSyncPrintf("\n");
|
||||
PRINTF("\n");
|
||||
}
|
||||
|
||||
gSPMatrix(POLY_OPA_DISP++, viewing, G_MTX_NOPUSH | G_MTX_MUL | G_MTX_PROJECTION);
|
||||
|
@ -632,10 +632,10 @@ s32 View_ErrorCheckEyePosition(f32 eyeX, f32 eyeY, f32 eyeZ) {
|
|||
}
|
||||
|
||||
if (error != 0) {
|
||||
osSyncPrintf(VT_FGCOL(RED));
|
||||
PRINTF(VT_FGCOL(RED));
|
||||
// "Is too large"
|
||||
osSyncPrintf("eye が大きすぎます eye=[%8.3f %8.3f %8.3f] error=%d\n", eyeX, eyeY, eyeZ, error);
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF("eye が大きすぎます eye=[%8.3f %8.3f %8.3f] error=%d\n", eyeX, eyeY, eyeZ, error);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
return error;
|
||||
|
|
|
@ -187,15 +187,15 @@ void ViMode_Save(ViMode* viMode) {
|
|||
|
||||
switch (SREG(59)) {
|
||||
case 1:
|
||||
osSyncPrintf("osViModePalLan1\n");
|
||||
PRINTF("osViModePalLan1\n");
|
||||
ViMode_LogPrint(&osViModePalLan1);
|
||||
break;
|
||||
case 2:
|
||||
osSyncPrintf("osViModeFpalLan1\n");
|
||||
PRINTF("osViModeFpalLan1\n");
|
||||
ViMode_LogPrint(&osViModeFpalLan1);
|
||||
break;
|
||||
default:
|
||||
osSyncPrintf("Custom\n");
|
||||
PRINTF("Custom\n");
|
||||
ViMode_LogPrint(&viMode->customViMode);
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -582,7 +582,7 @@ void Skybox_Setup(PlayState* play, SkyboxContext* skyboxCtx, s16 skyboxId) {
|
|||
|
||||
start = (uintptr_t)_vr_RUVR_pal_staticSegmentRomStart;
|
||||
size = (uintptr_t)_vr_RUVR_pal_staticSegmentRomEnd - start;
|
||||
osSyncPrintf("SIZE = %d\n", size);
|
||||
PRINTF("SIZE = %d\n", size);
|
||||
|
||||
skyboxCtx->palettes = GAME_STATE_ALLOC(&play->state, size, "../z_vr_box.c", 1188);
|
||||
ASSERT(skyboxCtx->palettes != NULL, "vr_box->vr_box_staticSegment[2] != NULL", "../z_vr_box.c", 1189);
|
||||
|
@ -664,7 +664,7 @@ void Skybox_Setup(PlayState* play, SkyboxContext* skyboxCtx, s16 skyboxId) {
|
|||
|
||||
start = (uintptr_t)_vr_MNVR_pal_staticSegmentRomStart;
|
||||
size = (uintptr_t)_vr_MNVR_pal_staticSegmentRomEnd - start;
|
||||
osSyncPrintf("SIZE = %d\n", size);
|
||||
PRINTF("SIZE = %d\n", size);
|
||||
|
||||
skyboxCtx->palettes = GAME_STATE_ALLOC(&play->state, size, "../z_vr_box.c", 1277);
|
||||
ASSERT(skyboxCtx->palettes != NULL, "vr_box->vr_box_staticSegment[2] != NULL", "../z_vr_box.c", 1278);
|
||||
|
@ -997,14 +997,14 @@ void Skybox_Init(GameState* state, SkyboxContext* skyboxCtx, s16 skyboxId) {
|
|||
|
||||
// DMA required assets based on skybox id
|
||||
Skybox_Setup(play, skyboxCtx, skyboxId);
|
||||
osSyncPrintf("\n\n\n********************\n\n\n"
|
||||
"TYPE=%d"
|
||||
"\n\n\n********************\n\n\n",
|
||||
skyboxId);
|
||||
PRINTF("\n\n\n********************\n\n\n"
|
||||
"TYPE=%d"
|
||||
"\n\n\n********************\n\n\n",
|
||||
skyboxId);
|
||||
|
||||
// Precompute vertices and display lists for drawing the skybox
|
||||
if (skyboxId != SKYBOX_NONE) {
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
|
||||
if (skyboxCtx->drawType != SKYBOX_DRAW_128) {
|
||||
skyboxCtx->dListBuf = GAME_STATE_ALLOC(state, 8 * 150 * sizeof(Gfx), "../z_vr_box.c", 1636);
|
||||
|
@ -1030,6 +1030,6 @@ void Skybox_Init(GameState* state, SkyboxContext* skyboxCtx, s16 skyboxId) {
|
|||
Skybox_Calculate128(skyboxCtx, 5); // compute 5 faces, excludes the bottom face
|
||||
}
|
||||
}
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -95,7 +95,7 @@ s32 BgBdanObjects_GetProperty(BgBdanObjects* this, s32 arg1) {
|
|||
case JABU_OBJECTS_GET_PROP_CAM_SETTING_DUNGEON1:
|
||||
return this->cameraSetting == CAM_SET_DUNGEON1;
|
||||
default:
|
||||
osSyncPrintf("Bg_Bdan_Objects_Get_Contact_Ru1\nそんな受信モードは無い%d!!!!!!!!\n");
|
||||
PRINTF("Bg_Bdan_Objects_Get_Contact_Ru1\nそんな受信モードは無い%d!!!!!!!!\n");
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
@ -112,7 +112,7 @@ void BgBdanObjects_SetProperty(BgBdanObjects* this, s32 arg1) {
|
|||
SET_INFTABLE(INFTABLE_146);
|
||||
break;
|
||||
default:
|
||||
osSyncPrintf("Bg_Bdan_Objects_Set_Contact_Ru1\nそんな送信モードは無い%d!!!!!!!!\n");
|
||||
PRINTF("Bg_Bdan_Objects_Set_Contact_Ru1\nそんな送信モードは無い%d!!!!!!!!\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -98,8 +98,8 @@ void BgBdanSwitch_InitDynaPoly(BgBdanSwitch* this, PlayState* play, CollisionHea
|
|||
CollisionHeader_GetVirtual(collision, &colHeader);
|
||||
this->dyna.bgId = DynaPoly_SetBgActor(play, &play->colCtx.dyna, &this->dyna.actor, colHeader);
|
||||
if (this->dyna.bgId == BG_ACTOR_MAX) {
|
||||
osSyncPrintf("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("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);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -192,12 +192,11 @@ void BgBdanSwitch_Init(Actor* thisx, PlayState* play) {
|
|||
}
|
||||
break;
|
||||
default:
|
||||
osSyncPrintf("不正な ARG_DATA(arg_data 0x%04x)(%s %d)\n", this->dyna.actor.params, "../z_bg_bdan_switch.c",
|
||||
454);
|
||||
PRINTF("不正な 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;
|
||||
}
|
||||
osSyncPrintf("(巨大魚ダンジョン 専用スイッチ)(arg_data 0x%04x)\n", this->dyna.actor.params);
|
||||
PRINTF("(巨大魚ダンジョン 専用スイッチ)(arg_data 0x%04x)\n", this->dyna.actor.params);
|
||||
}
|
||||
|
||||
void BgBdanSwitch_Destroy(Actor* thisx, PlayState* play) {
|
||||
|
|
|
@ -42,8 +42,8 @@ void BgBomGuard_Init(Actor* thisx, PlayState* play) {
|
|||
CollisionHeader_GetVirtual(&gBowlingDefaultCol, &colHeader);
|
||||
this->dyna.bgId = DynaPoly_SetBgActor(play, &play->colCtx.dyna, thisx, colHeader);
|
||||
|
||||
osSyncPrintf("\n\n");
|
||||
osSyncPrintf(VT_FGCOL(GREEN) " ☆☆☆☆☆ 透明ガード出現 ☆☆☆☆☆ \n" VT_RST);
|
||||
PRINTF("\n\n");
|
||||
PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ 透明ガード出現 ☆☆☆☆☆ \n" VT_RST);
|
||||
|
||||
thisx->scale.x = 1.0f;
|
||||
thisx->scale.y = 1.0f;
|
||||
|
|
|
@ -92,8 +92,8 @@ void BgBombwall_InitDynapoly(BgBombwall* this, PlayState* play) {
|
|||
|
||||
if (this->dyna.bgId == BG_ACTOR_MAX) {
|
||||
// "Warning : move BG login failed"
|
||||
osSyncPrintf("Warning : move BG 登録失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_bombwall.c", 243,
|
||||
this->dyna.actor.params);
|
||||
PRINTF("Warning : move BG 登録失敗(%s %d)(arg_data 0x%04x)\n", "../z_bg_bombwall.c", 243,
|
||||
this->dyna.actor.params);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -149,8 +149,8 @@ void BgBombwall_Init(Actor* thisx, PlayState* play) {
|
|||
func_8086ED50(this, play);
|
||||
}
|
||||
|
||||
osSyncPrintf("(field keep 汎用爆弾壁)(arg_data 0x%04x)(angY %d)\n", this->dyna.actor.params,
|
||||
this->dyna.actor.shape.rot.y);
|
||||
PRINTF("(field keep 汎用爆弾壁)(arg_data 0x%04x)(angY %d)\n", this->dyna.actor.params,
|
||||
this->dyna.actor.shape.rot.y);
|
||||
}
|
||||
|
||||
void BgBombwall_DestroyCollision(BgBombwall* this, PlayState* play) {
|
||||
|
|
|
@ -61,8 +61,8 @@ 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;
|
||||
osSyncPrintf("\n\n");
|
||||
osSyncPrintf(VT_FGCOL(GREEN) " ☆☆☆☆☆ ボーリングおじゃま壁発生 ☆☆☆☆☆ %d\n" VT_RST, this->dyna.actor.params);
|
||||
PRINTF("\n\n");
|
||||
PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ ボーリングおじゃま壁発生 ☆☆☆☆☆ %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;
|
||||
}
|
||||
|
@ -83,7 +83,7 @@ void BgBowlWall_SpawnBullseyes(BgBowlWall* this, PlayState* play) {
|
|||
if (type != 0) {
|
||||
type += (s16)Rand_ZeroFloat(2.99f);
|
||||
this->dyna.actor.shape.rot.z = this->dyna.actor.world.rot.z = sTargetRot[type];
|
||||
osSyncPrintf("\n\n");
|
||||
PRINTF("\n\n");
|
||||
}
|
||||
this->bullseyeCenter.x = sBullseyeOffset[type].x + this->dyna.actor.world.pos.x;
|
||||
this->bullseyeCenter.y = sBullseyeOffset[type].y + this->dyna.actor.world.pos.y;
|
||||
|
|
|
@ -96,7 +96,7 @@ void BgDdanKd_CheckForExplosions(BgDdanKd* this, PlayState* play) {
|
|||
|
||||
explosive = Actor_GetCollidedExplosive(play, &this->collider.base);
|
||||
if (explosive != NULL) {
|
||||
osSyncPrintf("dam %d\n", this->dyna.actor.colChkInfo.damage);
|
||||
PRINTF("dam %d\n", this->dyna.actor.colChkInfo.damage);
|
||||
explosive->params = 2;
|
||||
}
|
||||
|
||||
|
|
|
@ -82,12 +82,12 @@ void BgDyYoseizo_Init(Actor* thisx, PlayState* play2) {
|
|||
|
||||
if (play->sceneId == SCENE_GREAT_FAIRYS_FOUNTAIN_MAGIC) {
|
||||
// "Great Fairy Fountain"
|
||||
osSyncPrintf(VT_FGCOL(GREEN) "☆☆☆☆☆ 大妖精の泉 ☆☆☆☆☆ %d\n" VT_RST, play->spawn);
|
||||
PRINTF(VT_FGCOL(GREEN) "☆☆☆☆☆ 大妖精の泉 ☆☆☆☆☆ %d\n" VT_RST, play->spawn);
|
||||
SkelAnime_InitFlex(play, &this->skelAnime, &gGreatFairySkel, &gGreatFairySittingTransitionAnim,
|
||||
this->jointTable, this->morphTable, 28);
|
||||
} else {
|
||||
// "Stone/Jewel Fairy Fountain"
|
||||
osSyncPrintf(VT_FGCOL(GREEN) "☆☆☆☆☆ 石妖精の泉 ☆☆☆☆☆ %d\n" VT_RST, play->spawn);
|
||||
PRINTF(VT_FGCOL(GREEN) "☆☆☆☆☆ 石妖精の泉 ☆☆☆☆☆ %d\n" VT_RST, play->spawn);
|
||||
SkelAnime_InitFlex(play, &this->skelAnime, &gGreatFairySkel, &gGreatFairyLayingDownTransitionAnim,
|
||||
this->jointTable, this->morphTable, 28);
|
||||
}
|
||||
|
@ -201,7 +201,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) {
|
|||
|
||||
Player_SetCsActionWithHaltedActors(play, &this->actor, PLAYER_CSACTION_1);
|
||||
// "Mode"
|
||||
osSyncPrintf(VT_FGCOL(YELLOW) "☆☆☆☆☆ もうど ☆☆☆☆☆ %d\n" VT_RST, play->msgCtx.ocarinaMode);
|
||||
PRINTF(VT_FGCOL(YELLOW) "☆☆☆☆☆ もうど ☆☆☆☆☆ %d\n" VT_RST, play->msgCtx.ocarinaMode);
|
||||
givingReward = false;
|
||||
|
||||
if (play->sceneId != SCENE_GREAT_FAIRYS_FOUNTAIN_MAGIC) {
|
||||
|
@ -227,7 +227,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) {
|
|||
case FAIRY_UPGRADE_MAGIC:
|
||||
if (!gSaveContext.save.info.playerData.isMagicAcquired || BREG(2)) {
|
||||
// "Spin Attack speed UP"
|
||||
osSyncPrintf(VT_FGCOL(GREEN) " ☆☆☆☆☆ 回転切り速度UP ☆☆☆☆☆ \n" VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ 回転切り速度UP ☆☆☆☆☆ \n" VT_RST);
|
||||
this->givingSpell = true;
|
||||
givingReward = true;
|
||||
}
|
||||
|
@ -235,7 +235,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) {
|
|||
case FAIRY_UPGRADE_DOUBLE_MAGIC:
|
||||
if (!gSaveContext.save.info.playerData.isDoubleMagicAcquired) {
|
||||
// "Magic Meter doubled"
|
||||
osSyncPrintf(VT_FGCOL(YELLOW) " ☆☆☆☆☆ 魔法ゲージメーター倍増 ☆☆☆☆☆ \n" VT_RST);
|
||||
PRINTF(VT_FGCOL(YELLOW) " ☆☆☆☆☆ 魔法ゲージメーター倍増 ☆☆☆☆☆ \n" VT_RST);
|
||||
this->givingSpell = true;
|
||||
givingReward = true;
|
||||
}
|
||||
|
@ -243,7 +243,7 @@ void BgDyYoseizo_ChooseType(BgDyYoseizo* this, PlayState* play) {
|
|||
case FAIRY_UPGRADE_DOUBLE_DEFENSE:
|
||||
if (!gSaveContext.save.info.playerData.isDoubleDefenseAcquired) {
|
||||
// "Damage halved"
|
||||
osSyncPrintf(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ ダメージ半減 ☆☆☆☆☆ \n" VT_RST);
|
||||
PRINTF(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ ダメージ半減 ☆☆☆☆☆ \n" VT_RST);
|
||||
this->givingSpell = true;
|
||||
givingReward = true;
|
||||
}
|
||||
|
|
|
@ -89,9 +89,9 @@ void BgGanonOtyuka_Destroy(Actor* thisx, PlayState* play2) {
|
|||
|
||||
DynaPoly_DeleteBgActor(play, &play->colCtx.dyna, this->dyna.bgId);
|
||||
|
||||
osSyncPrintf(VT_FGCOL(GREEN));
|
||||
osSyncPrintf("WHY !!!!!!!!!!!!!!!!\n");
|
||||
osSyncPrintf(VT_RST);
|
||||
PRINTF(VT_FGCOL(GREEN));
|
||||
PRINTF("WHY !!!!!!!!!!!!!!!!\n");
|
||||
PRINTF(VT_RST);
|
||||
}
|
||||
|
||||
void BgGanonOtyuka_WaitToFall(BgGanonOtyuka* this, PlayState* play) {
|
||||
|
@ -105,7 +105,7 @@ void BgGanonOtyuka_WaitToFall(BgGanonOtyuka* this, PlayState* play) {
|
|||
s16 i;
|
||||
|
||||
if (this->isFalling || ((play->actorCtx.unk_02 != 0) && (this->dyna.actor.xyzDistToPlayerSq < SQ(70.0f)))) {
|
||||
osSyncPrintf("OTC O 1\n");
|
||||
PRINTF("OTC O 1\n");
|
||||
|
||||
for (i = 0; i < ARRAY_COUNT(D_80876A68); i++) {
|
||||
prop = play->actorCtx.actorLists[ACTORCAT_PROP].head;
|
||||
|
@ -130,7 +130,7 @@ void BgGanonOtyuka_WaitToFall(BgGanonOtyuka* this, PlayState* play) {
|
|||
}
|
||||
}
|
||||
|
||||
osSyncPrintf("OTC O 2\n");
|
||||
PRINTF("OTC O 2\n");
|
||||
|
||||
for (i = 0; i < ARRAY_COUNT(D_80876A68); i++) {
|
||||
center.x = this->dyna.actor.world.pos.x + D_80876A68[i].x;
|
||||
|
@ -141,7 +141,7 @@ void BgGanonOtyuka_WaitToFall(BgGanonOtyuka* this, PlayState* play) {
|
|||
}
|
||||
}
|
||||
|
||||
osSyncPrintf("OTC O 3\n");
|
||||
PRINTF("OTC O 3\n");
|
||||
|
||||
this->actionFunc = BgGanonOtyuka_Fall;
|
||||
this->isFalling = true;
|
||||
|
@ -164,7 +164,7 @@ void BgGanonOtyuka_Fall(BgGanonOtyuka* this, PlayState* play) {
|
|||
Vec3f velocity;
|
||||
Vec3f accel;
|
||||
|
||||
osSyncPrintf("MODE DOWN\n");
|
||||
PRINTF("MODE DOWN\n");
|
||||
if (this->flashState == FLASH_GROW) {
|
||||
Math_ApproachF(&this->flashPrimColorB, 170.0f, 1.0f, 8.5f);
|
||||
Math_ApproachF(&this->flashEnvColorR, 120.0f, 1.0f, 13.5f);
|
||||
|
@ -227,7 +227,7 @@ void BgGanonOtyuka_Fall(BgGanonOtyuka* this, PlayState* play) {
|
|||
Math_ApproachF(&this->dyna.actor.world.pos.y, -1000.0f, 1.0f, this->dyna.actor.speed);
|
||||
Math_ApproachF(&this->dyna.actor.speed, 100.0f, 1.0f, 0.1f);
|
||||
}
|
||||
osSyncPrintf("MODE DOWN END\n");
|
||||
PRINTF("MODE DOWN END\n");
|
||||
}
|
||||
|
||||
void BgGanonOtyuka_DoNothing(Actor* thisx, PlayState* play) {
|
||||
|
|
|
@ -50,8 +50,8 @@ void BgGateShutter_Init(Actor* thisx, PlayState* play) {
|
|||
thisx->scale.x = 1.0f;
|
||||
thisx->scale.y = 1.0f;
|
||||
thisx->scale.z = 1.0f;
|
||||
osSyncPrintf("\n\n");
|
||||
osSyncPrintf(VT_FGCOL(GREEN) " ☆☆☆☆☆ 柵でたなぁ ☆☆☆☆☆ \n" VT_RST);
|
||||
PRINTF("\n\n");
|
||||
PRINTF(VT_FGCOL(GREEN) " ☆☆☆☆☆ 柵でたなぁ ☆☆☆☆☆ \n" VT_RST);
|
||||
this->actionFunc = func_8087828C;
|
||||
}
|
||||
|
||||
|
|
|
@ -93,7 +93,7 @@ void BgHakaShip_WaitForSong(BgHakaShip* this, PlayState* play) {
|
|||
if (this->counter == 0) {
|
||||
this->counter = 130;
|
||||
this->actionFunc = BgHakaShip_CutsceneStationary;
|
||||
osSyncPrintf("シーン 外輪船 ... アァクション!!\n");
|
||||
PRINTF("シーン 外輪船 ... アァクション!!\n");
|
||||
OnePointCutscene_Init(play, 3390, 999, &this->dyna.actor, CAM_ID_MAIN);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -146,7 +146,7 @@ void BgHeavyBlock_Init(Actor* thisx, PlayState* play) {
|
|||
break;
|
||||
}
|
||||
// "Largest Block Save Bit %x"
|
||||
osSyncPrintf(VT_FGCOL(CYAN) " 最大 ブロック セーブビット %x\n" VT_RST, thisx->params);
|
||||
PRINTF(VT_FGCOL(CYAN) " 最大 ブロック セーブビット %x\n" VT_RST, thisx->params);
|
||||
}
|
||||
|
||||
void BgHeavyBlock_Destroy(Actor* thisx, PlayState* play) {
|
||||
|
|
|
@ -70,13 +70,13 @@ void BgHidanCurtain_Init(Actor* thisx, PlayState* play) {
|
|||
BgHidanCurtain* this = (BgHidanCurtain*)thisx;
|
||||
BgHidanCurtainParams* hcParams;
|
||||
|
||||
osSyncPrintf("Curtain (arg_data 0x%04x)\n", this->actor.params);
|
||||
PRINTF("Curtain (arg_data 0x%04x)\n", this->actor.params);
|
||||
Actor_SetFocus(&this->actor, 20.0f);
|
||||
this->type = (thisx->params >> 0xC) & 0xF;
|
||||
if (this->type > 6) {
|
||||
// "Type is not set"
|
||||
osSyncPrintf("Error : object のタイプが設定されていない(%s %d)(arg_data 0x%04x)\n", "../z_bg_hidan_curtain.c",
|
||||
352, this->actor.params);
|
||||
PRINTF("Error : object のタイプが設定されていない(%s %d)(arg_data 0x%04x)\n", "../z_bg_hidan_curtain.c", 352,
|
||||
this->actor.params);
|
||||
Actor_Kill(&this->actor);
|
||||
return;
|
||||
}
|
||||
|
@ -88,8 +88,8 @@ void BgHidanCurtain_Init(Actor* thisx, PlayState* play) {
|
|||
|
||||
if ((this->actor.params < 0) || (this->actor.params > 0x3F)) {
|
||||
// "Save bit is not set"
|
||||
osSyncPrintf("Warning : object のセーブビットが設定されていない(%s %d)(arg_data 0x%04x)\n",
|
||||
"../z_bg_hidan_curtain.c", 373, this->actor.params);
|
||||
PRINTF("Warning : object のセーブビットが設定されていない(%s %d)(arg_data 0x%04x)\n", "../z_bg_hidan_curtain.c",
|
||||
373, this->actor.params);
|
||||
}
|
||||
Actor_SetScale(&this->actor, hcParams->scale);
|
||||
Collider_InitCylinder(play, &this->collider);
|
||||
|
|
|
@ -180,13 +180,13 @@ void BgHidanHamstep_Init(Actor* thisx, PlayState* play) {
|
|||
|
||||
if ((this->dyna.actor.params & 0xFF) == 0) {
|
||||
// "Fire Temple Object [Hammer Step] appears"
|
||||
osSyncPrintf("◯◯◯炎の神殿オブジェクト【ハンマーステップ】出現\n");
|
||||
PRINTF("◯◯◯炎の神殿オブジェクト【ハンマーステップ】出現\n");
|
||||
if (BgHidanHamstep_SpawnChildren(this, play) == 0) {
|
||||
step = this;
|
||||
|
||||
// "[Hammer Step] I can't create a step!"
|
||||
osSyncPrintf("【ハンマーステップ】 足場産れない!!\n");
|
||||
osSyncPrintf("%s %d\n", "../z_bg_hidan_hamstep.c", 425);
|
||||
PRINTF("【ハンマーステップ】 足場産れない!!\n");
|
||||
PRINTF("%s %d\n", "../z_bg_hidan_hamstep.c", 425);
|
||||
|
||||
while (step != NULL) {
|
||||
Actor_Kill(&step->dyna.actor);
|
||||
|
@ -316,7 +316,7 @@ void func_80888860(BgHidanHamstep* this, PlayState* play) {
|
|||
Actor_PlaySfx(&this->dyna.actor, NA_SE_EV_BLOCK_BOUND);
|
||||
Rumble_Request(this->dyna.actor.xyzDistToPlayerSq, 255, 20, 150);
|
||||
func_80888638(this, play);
|
||||
osSyncPrintf("A(%d)\n", this->dyna.actor.params);
|
||||
PRINTF("A(%d)\n", this->dyna.actor.params);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -349,8 +349,8 @@ void func_80888A58(BgHidanHamstep* this, PlayState* play) {
|
|||
|
||||
if (((this->dyna.actor.params & 0xFF) <= 0) || ((this->dyna.actor.params & 0xFF) >= 6)) {
|
||||
// "[Hammer Step] arg_data strange (arg_data = %d)"
|
||||
osSyncPrintf("【ハンマーステップ】 arg_data おかしい (arg_data = %d)", this->dyna.actor.params);
|
||||
osSyncPrintf("%s %d\n", "../z_bg_hidan_hamstep.c", 696);
|
||||
PRINTF("【ハンマーステップ】 arg_data おかしい (arg_data = %d)", this->dyna.actor.params);
|
||||
PRINTF("%s %d\n", "../z_bg_hidan_hamstep.c", 696);
|
||||
}
|
||||
|
||||
if (((this->dyna.actor.world.pos.y - this->dyna.actor.home.pos.y) <=
|
||||
|
@ -381,7 +381,7 @@ void func_80888A58(BgHidanHamstep* this, PlayState* play) {
|
|||
Sfx_PlaySfxCentered(NA_SE_SY_CORRECT_CHIME);
|
||||
}
|
||||
|
||||
osSyncPrintf("B(%d)\n", this->dyna.actor.params);
|
||||
PRINTF("B(%d)\n", this->dyna.actor.params);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -69,12 +69,12 @@ void BgHidanKousi_Init(Actor* thisx, PlayState* play) {
|
|||
|
||||
DynaPolyActor_Init(&this->dyna, 0);
|
||||
Actor_SetFocus(thisx, 50.0f);
|
||||
osSyncPrintf("◯◯◯炎の神殿オブジェクト【格子(arg_data : %0x)】出現 (%d %d)\n", thisx->params, thisx->params & 0xFF,
|
||||
((s32)thisx->params >> 8) & 0xFF);
|
||||
PRINTF("◯◯◯炎の神殿オブジェクト【格子(arg_data : %0x)】出現 (%d %d)\n", thisx->params, thisx->params & 0xFF,
|
||||
((s32)thisx->params >> 8) & 0xFF);
|
||||
|
||||
Actor_ProcessInitChain(thisx, sInitChain);
|
||||
if (((thisx->params & 0xFF) < 0) || ((thisx->params & 0xFF) >= 3)) {
|
||||
osSyncPrintf("arg_data おかしい 【格子】\n");
|
||||
PRINTF("arg_data おかしい 【格子】\n");
|
||||
}
|
||||
|
||||
CollisionHeader_GetVirtual(sMetalFencesCollisions[thisx->params & 0xFF], &colHeader);
|
||||
|
|
|
@ -118,8 +118,8 @@ void BgHidanKowarerukabe_Init(Actor* thisx, PlayState* play) {
|
|||
if (((this->dyna.actor.params & 0xFF) < CRACKED_STONE_FLOOR) ||
|
||||
((this->dyna.actor.params & 0xFF) > LARGE_BOMBABLE_WALL)) {
|
||||
// "Error: Fire Temple Breakable Walls. arg_data I can't determine the (%s %d)(arg_data 0x%04x)"
|
||||
osSyncPrintf("Error : 炎の神殿 壊れる壁 の arg_data が判別出来ない(%s %d)(arg_data 0x%04x)\n",
|
||||
"../z_bg_hidan_kowarerukabe.c", 254, this->dyna.actor.params);
|
||||
PRINTF("Error : 炎の神殿 壊れる壁 の arg_data が判別出来ない(%s %d)(arg_data 0x%04x)\n",
|
||||
"../z_bg_hidan_kowarerukabe.c", 254, this->dyna.actor.params);
|
||||
Actor_Kill(&this->dyna.actor);
|
||||
return;
|
||||
}
|
||||
|
@ -134,7 +134,7 @@ void BgHidanKowarerukabe_Init(Actor* thisx, PlayState* play) {
|
|||
BgHidanKowarerukabe_InitColliderSphere(this, play);
|
||||
BgHidanKowarerukabe_OffsetActorYPos(this);
|
||||
// "(fire walls, floors, destroyed by bombs)(arg_data 0x%04x)"
|
||||
osSyncPrintf("(hidan 爆弾で壊れる 壁 床)(arg_data 0x%04x)\n", this->dyna.actor.params);
|
||||
PRINTF("(hidan 爆弾で壊れる 壁 床)(arg_data 0x%04x)\n", this->dyna.actor.params);
|
||||
}
|
||||
|
||||
void BgHidanKowarerukabe_Destroy(Actor* thisx, PlayState* play) {
|
||||
|
|
|
@ -123,8 +123,8 @@ void BgIceShelter_InitDynaPoly(BgIceShelter* this, PlayState* play, CollisionHea
|
|||
|
||||
if (this->dyna.bgId == BG_ACTOR_MAX) {
|
||||
// "Warning : move BG registration failed"
|
||||
osSyncPrintf("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("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);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -186,7 +186,7 @@ void BgIceShelter_Init(Actor* thisx, PlayState* play) {
|
|||
|
||||
BgIceShelter_SetupIdle(this);
|
||||
|
||||
osSyncPrintf("(ice shelter)(arg_data 0x%04x)\n", this->dyna.actor.params);
|
||||
PRINTF("(ice shelter)(arg_data 0x%04x)\n", this->dyna.actor.params);
|
||||
}
|
||||
|
||||
void BgIceShelter_Destroy(Actor* thisx, PlayState* play) {
|
||||
|
|
|
@ -77,8 +77,8 @@ void BgJya1flift_InitDynapoly(BgJya1flift* this, PlayState* play, CollisionHeade
|
|||
|
||||
if (this->dyna.bgId == BG_ACTOR_MAX) {
|
||||
// "Warning : move BG login failed"
|
||||
osSyncPrintf("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("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);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -93,7 +93,7 @@ void BgJya1flift_InitCollision(Actor* thisx, PlayState* play) {
|
|||
void BgJya1flift_Init(Actor* thisx, PlayState* play) {
|
||||
BgJya1flift* this = (BgJya1flift*)thisx;
|
||||
// "1 F lift"
|
||||
osSyncPrintf("(1Fリフト)(flag %d)(room %d)\n", sIsSpawned, play->roomCtx.curRoom.num);
|
||||
PRINTF("(1Fリフト)(flag %d)(room %d)\n", sIsSpawned, play->roomCtx.curRoom.num);
|
||||
this->hasInitialized = false;
|
||||
if (sIsSpawned) {
|
||||
Actor_Kill(thisx);
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue