mirror of
https://github.com/zeldaret/oot.git
synced 2024-12-27 23:36:22 +00:00
Run formatter (#1139)
This commit is contained in:
parent
8926b08582
commit
ed0daabf98
9 changed files with 33 additions and 33 deletions
|
@ -24,7 +24,6 @@ void bootproc(void) {
|
|||
Locale_Init();
|
||||
|
||||
StackCheck_Init(&sIdleThreadInfo, sIdleThreadStack, STACK_TOP(sIdleThreadStack), 0, 256, "idle");
|
||||
osCreateThread(&sIdleThread, 1, Idle_ThreadEntry, NULL, STACK_TOP(sIdleThreadStack),
|
||||
Z_PRIORITY_MAIN);
|
||||
osCreateThread(&sIdleThread, 1, Idle_ThreadEntry, NULL, STACK_TOP(sIdleThreadStack), Z_PRIORITY_MAIN);
|
||||
osStartThread(&sIdleThread);
|
||||
}
|
||||
|
|
|
@ -1265,8 +1265,7 @@ void Fault_Init(void) {
|
|||
gFaultMgr.faultHandlerEnabled = true;
|
||||
osCreateMesgQueue(&sFaultInstance->queue, &sFaultInstance->msg, 1);
|
||||
StackCheck_Init(&sFaultThreadInfo, &sFaultStack, STACK_TOP(sFaultStack), 0, 0x100, "fault");
|
||||
osCreateThread(&sFaultInstance->thread, 2, Fault_ThreadEntry, 0, STACK_TOP(sFaultStack),
|
||||
OS_PRIORITY_APPMAX);
|
||||
osCreateThread(&sFaultInstance->thread, 2, Fault_ThreadEntry, 0, STACK_TOP(sFaultStack), OS_PRIORITY_APPMAX);
|
||||
osStartThread(&sFaultInstance->thread);
|
||||
}
|
||||
|
||||
|
|
|
@ -470,7 +470,8 @@ void func_8002C7BC(TargetContext* targetCtx, Player* player, Actor* actorArg, Gl
|
|||
|
||||
if ((actorArg != NULL) && (targetCtx->unk_4B == 0)) {
|
||||
Actor_ProjectPos(globalCtx, &actorArg->focus.pos, &projectedFocusPos, &cappedInvWDest);
|
||||
if (((projectedFocusPos.z <= 0.0f) || (1.0f <= fabsf(projectedFocusPos.x * cappedInvWDest))) || (1.0f <= fabsf(projectedFocusPos.y * cappedInvWDest))) {
|
||||
if (((projectedFocusPos.z <= 0.0f) || (1.0f <= fabsf(projectedFocusPos.x * cappedInvWDest))) ||
|
||||
(1.0f <= fabsf(projectedFocusPos.y * cappedInvWDest))) {
|
||||
actorArg = NULL;
|
||||
}
|
||||
}
|
||||
|
@ -728,23 +729,23 @@ void TitleCard_Draw(GlobalContext* globalCtx, TitleCardContext* titleCtx) {
|
|||
gDPSetPrimColor(OVERLAY_DISP++, 0, 0, (u8)titleCtx->intensity, (u8)titleCtx->intensity, (u8)titleCtx->intensity,
|
||||
(u8)titleCtx->alpha);
|
||||
|
||||
gDPLoadTextureBlock(OVERLAY_DISP++, (s32)titleCtx->texture + textureLanguageOffset, G_IM_FMT_IA, G_IM_SIZ_8b, width, height, 0,
|
||||
G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOMASK, G_TX_NOLOD,
|
||||
G_TX_NOLOD);
|
||||
gDPLoadTextureBlock(OVERLAY_DISP++, (s32)titleCtx->texture + textureLanguageOffset, G_IM_FMT_IA, G_IM_SIZ_8b,
|
||||
width, height, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK,
|
||||
G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD);
|
||||
|
||||
gSPTextureRectangle(OVERLAY_DISP++, titleX, titleY, ((doubleWidth * 2) + titleX) - 4, titleY + (height * 4) - 1, G_TX_RENDERTILE,
|
||||
0, 0, 1 << 10, 1 << 10);
|
||||
gSPTextureRectangle(OVERLAY_DISP++, titleX, titleY, ((doubleWidth * 2) + titleX) - 4, titleY + (height * 4) - 1,
|
||||
G_TX_RENDERTILE, 0, 0, 1 << 10, 1 << 10);
|
||||
|
||||
height = titleCtx->height - height;
|
||||
|
||||
// If texture is bigger than 0x1000, display the rest
|
||||
if (height > 0) {
|
||||
gDPLoadTextureBlock(OVERLAY_DISP++, (s32)titleCtx->texture + textureLanguageOffset + 0x1000, G_IM_FMT_IA, G_IM_SIZ_8b, width,
|
||||
height, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMASK, G_TX_NOMASK,
|
||||
G_TX_NOLOD, G_TX_NOLOD);
|
||||
gDPLoadTextureBlock(OVERLAY_DISP++, (s32)titleCtx->texture + textureLanguageOffset + 0x1000, G_IM_FMT_IA,
|
||||
G_IM_SIZ_8b, width, height, 0, G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP,
|
||||
G_TX_NOMASK, G_TX_NOMASK, G_TX_NOLOD, G_TX_NOLOD);
|
||||
|
||||
gSPTextureRectangle(OVERLAY_DISP++, titleX, titleSecondY, ((doubleWidth * 2) + titleX) - 4, titleSecondY + (height * 4) - 1,
|
||||
G_TX_RENDERTILE, 0, 0, 1 << 10, 1 << 10);
|
||||
gSPTextureRectangle(OVERLAY_DISP++, titleX, titleSecondY, ((doubleWidth * 2) + titleX) - 4,
|
||||
titleSecondY + (height * 4) - 1, G_TX_RENDERTILE, 0, 0, 1 << 10, 1 << 10);
|
||||
}
|
||||
|
||||
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 2880);
|
||||
|
|
|
@ -452,8 +452,10 @@ void HealthMeter_Draw(GlobalContext* globalCtx) {
|
|||
heartTexCoordPerPixel *= 1 << 10;
|
||||
halfHeartLength = 8.0f;
|
||||
halfHeartLength *= 0.68f;
|
||||
gSPTextureRectangle(OVERLAY_DISP++, (s32)((heartCenterX - halfHeartLength) * 4), (s32)((heartCenterY - halfHeartLength) * 4),
|
||||
(s32)((heartCenterX + halfHeartLength) * 4), (s32)((heartCenterY + halfHeartLength) * 4), G_TX_RENDERTILE, 0, 0,
|
||||
gSPTextureRectangle(OVERLAY_DISP++, (s32)((heartCenterX - halfHeartLength) * 4),
|
||||
(s32)((heartCenterY - halfHeartLength) * 4),
|
||||
(s32)((heartCenterX + halfHeartLength) * 4),
|
||||
(s32)((heartCenterY + halfHeartLength) * 4), G_TX_RENDERTILE, 0, 0,
|
||||
(s32)heartTexCoordPerPixel, (s32)heartTexCoordPerPixel);
|
||||
} else {
|
||||
if ((ddHeartCountMinusOne < 0) || (heartIndex > ddHeartCountMinusOne)) {
|
||||
|
@ -474,8 +476,9 @@ void HealthMeter_Draw(GlobalContext* globalCtx) {
|
|||
|
||||
{
|
||||
Mtx* matrix = Graph_Alloc(gfxCtx, sizeof(Mtx));
|
||||
Matrix_SetTranslateScaleMtx2(matrix, 1.0f - (0.32f * beatingHeartPulsingSize), 1.0f - (0.32f * beatingHeartPulsingSize), 1.0f - (0.32f * beatingHeartPulsingSize),
|
||||
-130.0f + offsetX, 94.5f - offsetY, 0.0f);
|
||||
Matrix_SetTranslateScaleMtx2(
|
||||
matrix, 1.0f - (0.32f * beatingHeartPulsingSize), 1.0f - (0.32f * beatingHeartPulsingSize),
|
||||
1.0f - (0.32f * beatingHeartPulsingSize), -130.0f + offsetX, 94.5f - offsetY, 0.0f);
|
||||
gSPMatrix(OVERLAY_DISP++, matrix, G_MTX_MODELVIEW | G_MTX_LOAD);
|
||||
gSPVertex(OVERLAY_DISP++, beatingHeartVtx, 4, 0);
|
||||
gSP1Quadrangle(OVERLAY_DISP++, 0, 2, 3, 1, 0);
|
||||
|
|
|
@ -63,10 +63,10 @@ void MapMark_Init(GlobalContext* globalCtx) {
|
|||
Overlay_Load(overlay->vromStart, overlay->vromEnd, overlay->vramStart, overlay->vramEnd, overlay->loadedRamAddr);
|
||||
|
||||
sLoadedMarkDataTable = gMapMarkDataTable;
|
||||
sLoadedMarkDataTable = (void*)(u32)((overlay->vramTable != NULL)
|
||||
? (void*)((u32)overlay->vramTable -
|
||||
(s32)((u32)overlay->vramStart - (u32)overlay->loadedRamAddr))
|
||||
: NULL);
|
||||
sLoadedMarkDataTable = (void*)(u32)(
|
||||
(overlay->vramTable != NULL)
|
||||
? (void*)((u32)overlay->vramTable - (s32)((u32)overlay->vramStart - (u32)overlay->loadedRamAddr))
|
||||
: NULL);
|
||||
}
|
||||
|
||||
void MapMark_ClearPointers(GlobalContext* globalCtx) {
|
||||
|
|
|
@ -155,7 +155,8 @@ void EnHeishi2_Init(Actor* thisx, GlobalContext* globalCtx) {
|
|||
// "Identification Completed!"
|
||||
osSyncPrintf(VT_FGCOL(YELLOW) " ☆☆☆☆☆ 識別完了! ☆☆☆☆☆ %d\n" VT_RST, this->type);
|
||||
// "Message completed!"
|
||||
osSyncPrintf(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ メッセージ完了! ☆☆☆☆☆ %x\n\n" VT_RST, (this->actor.params >> 8) & 0xF);
|
||||
osSyncPrintf(VT_FGCOL(MAGENTA) " ☆☆☆☆☆ メッセージ完了! ☆☆☆☆☆ %x\n\n" VT_RST,
|
||||
(this->actor.params >> 8) & 0xF);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -61,12 +61,8 @@ static s16 sObjectIds[6] = {
|
|||
};
|
||||
|
||||
static FlexSkeletonHeader* sSkeletons[6] = {
|
||||
&object_ahg_Skel_0000F0,
|
||||
&object_boj_Skel_0000F0,
|
||||
&object_boj_Skel_0000F0,
|
||||
&object_boj_Skel_0000F0,
|
||||
&object_boj_Skel_0000F0,
|
||||
&object_boj_Skel_0000F0,
|
||||
&object_ahg_Skel_0000F0, &object_boj_Skel_0000F0, &object_boj_Skel_0000F0,
|
||||
&object_boj_Skel_0000F0, &object_boj_Skel_0000F0, &object_boj_Skel_0000F0,
|
||||
};
|
||||
|
||||
static AnimationHeader* sAnimations[6] = {
|
||||
|
|
|
@ -186,7 +186,8 @@ void func_80B3A3D4(EnWonderTalk2* this, GlobalContext* globalCtx) {
|
|||
if ((this->switchFlag >= 0) && (this->talkMode != 4)) {
|
||||
Flags_SetSwitch(globalCtx, this->switchFlag);
|
||||
// "(Forced) I saved it! All of it!"
|
||||
osSyncPrintf(VT_FGCOL(MAGENTA) "☆☆☆☆☆ (強制)セーブしたよ!おもいっきり! %x\n" VT_RST, this->switchFlag);
|
||||
osSyncPrintf(VT_FGCOL(MAGENTA) "☆☆☆☆☆ (強制)セーブしたよ!おもいっきり! %x\n" VT_RST,
|
||||
this->switchFlag);
|
||||
}
|
||||
|
||||
if (this->talkMode == 4) {
|
||||
|
|
|
@ -344,8 +344,8 @@ s16 ObjOshihiki_GetHighestFloor(ObjOshihiki* this) {
|
|||
for (i = 1; i < ARRAY_COUNT(this->floorHeights); i++) {
|
||||
if (this->floorHeights[i] > this->floorHeights[highestFloor]) {
|
||||
highestFloor = i;
|
||||
} else if ((this->floorBgIds[i] == BGCHECK_SCENE) &&
|
||||
((this->floorHeights[i] - this->floorHeights[highestFloor]) > -0.001f)) {
|
||||
} else if ((this->floorBgIds[i] == BGCHECK_SCENE) &&
|
||||
((this->floorHeights[i] - this->floorHeights[highestFloor]) > -0.001f)) {
|
||||
highestFloor = i;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue