mirror of
https://github.com/zeldaret/oot.git
synced 2024-12-25 22:26:12 +00:00
ovl_Obj_Dekujr OK (#276)
* started dekujr * ovl_Obj_Dekujr OK * cleanup * Made suggested changes
This commit is contained in:
parent
00836ddebc
commit
b39cddd576
15 changed files with 153 additions and 465 deletions
|
@ -1,4 +0,0 @@
|
|||
glabel ObjDekujr_Destroy
|
||||
/* 0010C 80B9252C AFA40000 */ sw $a0, 0x0000($sp)
|
||||
/* 00110 80B92530 03E00008 */ jr $ra
|
||||
/* 00114 80B92534 AFA50004 */ sw $a1, 0x0004($sp)
|
|
@ -1,118 +0,0 @@
|
|||
.rdata
|
||||
glabel D_80B92A40
|
||||
.asciz "../z_obj_dekujr.c"
|
||||
.balign 4
|
||||
|
||||
glabel D_80B92A54
|
||||
.asciz "../z_obj_dekujr.c"
|
||||
.balign 4
|
||||
|
||||
glabel D_80B92A68
|
||||
.asciz "../z_obj_dekujr.c"
|
||||
.balign 4
|
||||
|
||||
glabel D_80B92A7C
|
||||
.asciz "../z_obj_dekujr.c"
|
||||
.balign 4
|
||||
|
||||
.text
|
||||
glabel ObjDekujr_Draw
|
||||
/* 00434 80B92854 27BDFF90 */ addiu $sp, $sp, 0xFF90 ## $sp = FFFFFF90
|
||||
/* 00438 80B92858 AFB10038 */ sw $s1, 0x0038($sp)
|
||||
/* 0043C 80B9285C 00A08825 */ or $s1, $a1, $zero ## $s1 = 00000000
|
||||
/* 00440 80B92860 AFBF003C */ sw $ra, 0x003C($sp)
|
||||
/* 00444 80B92864 AFB00034 */ sw $s0, 0x0034($sp)
|
||||
/* 00448 80B92868 AFA40070 */ sw $a0, 0x0070($sp)
|
||||
/* 0044C 80B9286C 8CA50000 */ lw $a1, 0x0000($a1) ## 00000000
|
||||
/* 00450 80B92870 3C0680B9 */ lui $a2, %hi(D_80B92A40) ## $a2 = 80B90000
|
||||
/* 00454 80B92874 24C62A40 */ addiu $a2, $a2, %lo(D_80B92A40) ## $a2 = 80B92A40
|
||||
/* 00458 80B92878 27A40058 */ addiu $a0, $sp, 0x0058 ## $a0 = FFFFFFE8
|
||||
/* 0045C 80B9287C 24070172 */ addiu $a3, $zero, 0x0172 ## $a3 = 00000172
|
||||
/* 00460 80B92880 0C031AB1 */ jal Graph_OpenDisps
|
||||
/* 00464 80B92884 00A08025 */ or $s0, $a1, $zero ## $s0 = 00000000
|
||||
/* 00468 80B92888 0C024F46 */ jal func_80093D18
|
||||
/* 0046C 80B9288C 8E240000 */ lw $a0, 0x0000($s1) ## 00000000
|
||||
/* 00470 80B92890 0C024F61 */ jal func_80093D84
|
||||
/* 00474 80B92894 8E240000 */ lw $a0, 0x0000($s1) ## 00000000
|
||||
/* 00478 80B92898 8E0202C0 */ lw $v0, 0x02C0($s0) ## 000002C0
|
||||
/* 0047C 80B9289C 3C0FDA38 */ lui $t7, 0xDA38 ## $t7 = DA380000
|
||||
/* 00480 80B928A0 35EF0003 */ ori $t7, $t7, 0x0003 ## $t7 = DA380003
|
||||
/* 00484 80B928A4 244E0008 */ addiu $t6, $v0, 0x0008 ## $t6 = 00000008
|
||||
/* 00488 80B928A8 AE0E02C0 */ sw $t6, 0x02C0($s0) ## 000002C0
|
||||
/* 0048C 80B928AC AC4F0000 */ sw $t7, 0x0000($v0) ## 00000000
|
||||
/* 00490 80B928B0 8E240000 */ lw $a0, 0x0000($s1) ## 00000000
|
||||
/* 00494 80B928B4 3C0580B9 */ lui $a1, %hi(D_80B92A54) ## $a1 = 80B90000
|
||||
/* 00498 80B928B8 24A52A54 */ addiu $a1, $a1, %lo(D_80B92A54) ## $a1 = 80B92A54
|
||||
/* 0049C 80B928BC 2406017B */ addiu $a2, $zero, 0x017B ## $a2 = 0000017B
|
||||
/* 004A0 80B928C0 0C0346A2 */ jal Matrix_NewMtx
|
||||
/* 004A4 80B928C4 AFA20054 */ sw $v0, 0x0054($sp)
|
||||
/* 004A8 80B928C8 8FA30054 */ lw $v1, 0x0054($sp)
|
||||
/* 004AC 80B928CC 3C090600 */ lui $t1, 0x0600 ## $t1 = 06000000
|
||||
/* 004B0 80B928D0 252930D0 */ addiu $t1, $t1, 0x30D0 ## $t1 = 060030D0
|
||||
/* 004B4 80B928D4 AC620004 */ sw $v0, 0x0004($v1) ## 00000004
|
||||
/* 004B8 80B928D8 8E0202C0 */ lw $v0, 0x02C0($s0) ## 000002C0
|
||||
/* 004BC 80B928DC 3C19DE00 */ lui $t9, 0xDE00 ## $t9 = DE000000
|
||||
/* 004C0 80B928E0 3C0BDB06 */ lui $t3, 0xDB06 ## $t3 = DB060000
|
||||
/* 004C4 80B928E4 24580008 */ addiu $t8, $v0, 0x0008 ## $t8 = 00000008
|
||||
/* 004C8 80B928E8 AE1802C0 */ sw $t8, 0x02C0($s0) ## 000002C0
|
||||
/* 004CC 80B928EC AC590000 */ sw $t9, 0x0000($v0) ## 00000000
|
||||
/* 004D0 80B928F0 AC490004 */ sw $t1, 0x0004($v0) ## 00000004
|
||||
/* 004D4 80B928F4 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
|
||||
/* 004D8 80B928F8 8E28009C */ lw $t0, 0x009C($s1) ## 0000009C
|
||||
/* 004DC 80B928FC 356B0020 */ ori $t3, $t3, 0x0020 ## $t3 = DB060020
|
||||
/* 004E0 80B92900 244A0008 */ addiu $t2, $v0, 0x0008 ## $t2 = 00000008
|
||||
/* 004E4 80B92904 AE0A02D0 */ sw $t2, 0x02D0($s0) ## 000002D0
|
||||
/* 004E8 80B92908 AC4B0000 */ sw $t3, 0x0000($v0) ## 00000000
|
||||
/* 004EC 80B9290C 8E240000 */ lw $a0, 0x0000($s1) ## 00000000
|
||||
/* 004F0 80B92910 24180020 */ addiu $t8, $zero, 0x0020 ## $t8 = 00000020
|
||||
/* 004F4 80B92914 240C0020 */ addiu $t4, $zero, 0x0020 ## $t4 = 00000020
|
||||
/* 004F8 80B92918 240D0020 */ addiu $t5, $zero, 0x0020 ## $t5 = 00000020
|
||||
/* 004FC 80B9291C 240E0001 */ addiu $t6, $zero, 0x0001 ## $t6 = 00000001
|
||||
/* 00500 80B92920 240F0020 */ addiu $t7, $zero, 0x0020 ## $t7 = 00000020
|
||||
/* 00504 80B92924 3106007F */ andi $a2, $t0, 0x007F ## $a2 = 00000000
|
||||
/* 00508 80B92928 AFA6001C */ sw $a2, 0x001C($sp)
|
||||
/* 0050C 80B9292C AFAF0024 */ sw $t7, 0x0024($sp)
|
||||
/* 00510 80B92930 AFAE0018 */ sw $t6, 0x0018($sp)
|
||||
/* 00514 80B92934 AFAD0014 */ sw $t5, 0x0014($sp)
|
||||
/* 00518 80B92938 AFAC0010 */ sw $t4, 0x0010($sp)
|
||||
/* 0051C 80B9293C AFB80028 */ sw $t8, 0x0028($sp)
|
||||
/* 00520 80B92940 AFA00020 */ sw $zero, 0x0020($sp)
|
||||
/* 00524 80B92944 00002825 */ or $a1, $zero, $zero ## $a1 = 00000000
|
||||
/* 00528 80B92948 00003825 */ or $a3, $zero, $zero ## $a3 = 00000000
|
||||
/* 0052C 80B9294C 0C0253D0 */ jal Gfx_TwoTexScroll
|
||||
/* 00530 80B92950 AFA2004C */ sw $v0, 0x004C($sp)
|
||||
/* 00534 80B92954 8FA3004C */ lw $v1, 0x004C($sp)
|
||||
/* 00538 80B92958 3C09DA38 */ lui $t1, 0xDA38 ## $t1 = DA380000
|
||||
/* 0053C 80B9295C 35290003 */ ori $t1, $t1, 0x0003 ## $t1 = DA380003
|
||||
/* 00540 80B92960 AC620004 */ sw $v0, 0x0004($v1) ## 00000004
|
||||
/* 00544 80B92964 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
|
||||
/* 00548 80B92968 3C0580B9 */ lui $a1, %hi(D_80B92A68) ## $a1 = 80B90000
|
||||
/* 0054C 80B9296C 24A52A68 */ addiu $a1, $a1, %lo(D_80B92A68) ## $a1 = 80B92A68
|
||||
/* 00550 80B92970 24590008 */ addiu $t9, $v0, 0x0008 ## $t9 = 00000008
|
||||
/* 00554 80B92974 AE1902D0 */ sw $t9, 0x02D0($s0) ## 000002D0
|
||||
/* 00558 80B92978 AC490000 */ sw $t1, 0x0000($v0) ## 00000000
|
||||
/* 0055C 80B9297C 8E240000 */ lw $a0, 0x0000($s1) ## 00000000
|
||||
/* 00560 80B92980 2406018F */ addiu $a2, $zero, 0x018F ## $a2 = 0000018F
|
||||
/* 00564 80B92984 0C0346A2 */ jal Matrix_NewMtx
|
||||
/* 00568 80B92988 AFA20048 */ sw $v0, 0x0048($sp)
|
||||
/* 0056C 80B9298C 8FA30048 */ lw $v1, 0x0048($sp)
|
||||
/* 00570 80B92990 3C0C0600 */ lui $t4, 0x0600 ## $t4 = 06000000
|
||||
/* 00574 80B92994 258C32D8 */ addiu $t4, $t4, 0x32D8 ## $t4 = 060032D8
|
||||
/* 00578 80B92998 AC620004 */ sw $v0, 0x0004($v1) ## 00000004
|
||||
/* 0057C 80B9299C 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
|
||||
/* 00580 80B929A0 3C0BDE00 */ lui $t3, 0xDE00 ## $t3 = DE000000
|
||||
/* 00584 80B929A4 3C0680B9 */ lui $a2, %hi(D_80B92A7C) ## $a2 = 80B90000
|
||||
/* 00588 80B929A8 244A0008 */ addiu $t2, $v0, 0x0008 ## $t2 = 00000008
|
||||
/* 0058C 80B929AC AE0A02D0 */ sw $t2, 0x02D0($s0) ## 000002D0
|
||||
/* 00590 80B929B0 AC4C0004 */ sw $t4, 0x0004($v0) ## 00000004
|
||||
/* 00594 80B929B4 AC4B0000 */ sw $t3, 0x0000($v0) ## 00000000
|
||||
/* 00598 80B929B8 8E250000 */ lw $a1, 0x0000($s1) ## 00000000
|
||||
/* 0059C 80B929BC 24C62A7C */ addiu $a2, $a2, %lo(D_80B92A7C) ## $a2 = 80B92A7C
|
||||
/* 005A0 80B929C0 27A40058 */ addiu $a0, $sp, 0x0058 ## $a0 = FFFFFFE8
|
||||
/* 005A4 80B929C4 0C031AD5 */ jal Graph_CloseDisps
|
||||
/* 005A8 80B929C8 24070199 */ addiu $a3, $zero, 0x0199 ## $a3 = 00000199
|
||||
/* 005AC 80B929CC 8FBF003C */ lw $ra, 0x003C($sp)
|
||||
/* 005B0 80B929D0 8FB00034 */ lw $s0, 0x0034($sp)
|
||||
/* 005B4 80B929D4 8FB10038 */ lw $s1, 0x0038($sp)
|
||||
/* 005B8 80B929D8 03E00008 */ jr $ra
|
||||
/* 005BC 80B929DC 27BD0070 */ addiu $sp, $sp, 0x0070 ## $sp = 00000000
|
|
@ -1,78 +0,0 @@
|
|||
glabel ObjDekujr_Init
|
||||
/* 00000 80B92420 3C028016 */ lui $v0, %hi(gSaveContext)
|
||||
/* 00004 80B92424 2442E660 */ addiu $v0, %lo(gSaveContext)
|
||||
/* 00008 80B92428 8C4E0008 */ lw $t6, 0x0008($v0) ## 8015E668
|
||||
/* 0000C 80B9242C 27BDFFD0 */ addiu $sp, $sp, 0xFFD0 ## $sp = FFFFFFD0
|
||||
/* 00010 80B92430 3401FFF0 */ ori $at, $zero, 0xFFF0 ## $at = 0000FFF0
|
||||
/* 00014 80B92434 AFB00018 */ sw $s0, 0x0018($sp)
|
||||
/* 00018 80B92438 01C1082A */ slt $at, $t6, $at
|
||||
/* 0001C 80B9243C 00808025 */ or $s0, $a0, $zero ## $s0 = 00000000
|
||||
/* 00020 80B92440 AFBF001C */ sw $ra, 0x001C($sp)
|
||||
/* 00024 80B92444 1020000C */ beq $at, $zero, .L80B92478
|
||||
/* 00028 80B92448 AFA50034 */ sw $a1, 0x0034($sp)
|
||||
/* 0002C 80B9244C 8C4F0004 */ lw $t7, 0x0004($v0) ## 8015E664
|
||||
/* 00030 80B92450 24180002 */ addiu $t8, $zero, 0x0002 ## $t8 = 00000002
|
||||
/* 00034 80B92454 51E00006 */ beql $t7, $zero, .L80B92470
|
||||
/* 00038 80B92458 A218019C */ sb $t8, 0x019C($s0) ## 0000019C
|
||||
/* 0003C 80B9245C 0C00B55C */ jal Actor_Kill
|
||||
|
||||
/* 00040 80B92460 00000000 */ nop
|
||||
/* 00044 80B92464 1000002D */ beq $zero, $zero, .L80B9251C
|
||||
/* 00048 80B92468 8FBF001C */ lw $ra, 0x001C($sp)
|
||||
/* 0004C 80B9246C A218019C */ sb $t8, 0x019C($s0) ## 0000019C
|
||||
.L80B92470:
|
||||
/* 00050 80B92470 10000004 */ beq $zero, $zero, .L80B92484
|
||||
/* 00054 80B92474 A200019B */ sb $zero, 0x019B($s0) ## 0000019B
|
||||
.L80B92478:
|
||||
/* 00058 80B92478 24190001 */ addiu $t9, $zero, 0x0001 ## $t9 = 00000001
|
||||
/* 0005C 80B9247C A200019C */ sb $zero, 0x019C($s0) ## 0000019C
|
||||
/* 00060 80B92480 A219019B */ sb $t9, 0x019B($s0) ## 0000019B
|
||||
.L80B92484:
|
||||
/* 00064 80B92484 3C088012 */ lui $t0, %hi(gBitFlags)
|
||||
/* 00068 80B92488 8D087120 */ lw $t0, %lo(gBitFlags)($t0)
|
||||
/* 0006C 80B9248C 8C4900A4 */ lw $t1, 0x00A4($v0) ## 000000A4
|
||||
/* 00070 80B92490 01095024 */ and $t2, $t0, $t1
|
||||
/* 00074 80B92494 55400006 */ bnel $t2, $zero, .L80B924B0
|
||||
/* 00078 80B92498 44800000 */ mtc1 $zero, $f0 ## $f0 = 0.00
|
||||
/* 0007C 80B9249C 0C00B55C */ jal Actor_Kill
|
||||
|
||||
/* 00080 80B924A0 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000
|
||||
/* 00084 80B924A4 1000001D */ beq $zero, $zero, .L80B9251C
|
||||
/* 00088 80B924A8 8FBF001C */ lw $ra, 0x001C($sp)
|
||||
/* 0008C 80B924AC 44800000 */ mtc1 $zero, $f0 ## $f0 = 0.00
|
||||
.L80B924B0:
|
||||
/* 00090 80B924B0 260400B4 */ addiu $a0, $s0, 0x00B4 ## $a0 = 000000B4
|
||||
/* 00094 80B924B4 00003025 */ or $a2, $zero, $zero ## $a2 = 00000000
|
||||
/* 00098 80B924B8 44050000 */ mfc1 $a1, $f0
|
||||
/* 0009C 80B924BC 44070000 */ mfc1 $a3, $f0
|
||||
/* 000A0 80B924C0 0C00AC78 */ jal ActorShape_Init
|
||||
|
||||
/* 000A4 80B924C4 00000000 */ nop
|
||||
/* 000A8 80B924C8 2605014C */ addiu $a1, $s0, 0x014C ## $a1 = 0000014C
|
||||
/* 000AC 80B924CC AFA50024 */ sw $a1, 0x0024($sp)
|
||||
/* 000B0 80B924D0 0C0170D9 */ jal Collider_InitCylinder
|
||||
|
||||
/* 000B4 80B924D4 8FA40034 */ lw $a0, 0x0034($sp)
|
||||
/* 000B8 80B924D8 3C0680B9 */ lui $a2, %hi(D_80B92A00) ## $a2 = 80B90000
|
||||
/* 000BC 80B924DC 24C62A00 */ addiu $a2, $a2, %lo(D_80B92A00) ## $a2 = 80B92A00
|
||||
/* 000C0 80B924E0 8FA50024 */ lw $a1, 0x0024($sp)
|
||||
/* 000C4 80B924E4 ACD00000 */ sw $s0, 0x0000($a2) ## 80B92A00
|
||||
/* 000C8 80B924E8 0C0170FD */ jal Collider_SetCylinder_Actor
|
||||
/* 000CC 80B924EC 8FA40034 */ lw $a0, 0x0034($sp)
|
||||
/* 000D0 80B924F0 240B00FF */ addiu $t3, $zero, 0x00FF ## $t3 = 000000FF
|
||||
/* 000D4 80B924F4 A20B00AE */ sb $t3, 0x00AE($s0) ## 000000AE
|
||||
/* 000D8 80B924F8 8FA40034 */ lw $a0, 0x0034($sp)
|
||||
/* 000DC 80B924FC 0C00DF0C */ jal func_80037C30
|
||||
/* 000E0 80B92500 2405000F */ addiu $a1, $zero, 0x000F ## $a1 = 0000000F
|
||||
/* 000E4 80B92504 3C053ECC */ lui $a1, 0x3ECC ## $a1 = 3ECC0000
|
||||
/* 000E8 80B92508 A602010E */ sh $v0, 0x010E($s0) ## 0000010E
|
||||
/* 000EC 80B9250C 34A5CCCD */ ori $a1, $a1, 0xCCCD ## $a1 = 3ECCCCCD
|
||||
/* 000F0 80B92510 0C00B58B */ jal Actor_SetScale
|
||||
|
||||
/* 000F4 80B92514 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000
|
||||
/* 000F8 80B92518 8FBF001C */ lw $ra, 0x001C($sp)
|
||||
.L80B9251C:
|
||||
/* 000FC 80B9251C 8FB00018 */ lw $s0, 0x0018($sp)
|
||||
/* 00100 80B92520 27BD0030 */ addiu $sp, $sp, 0x0030 ## $sp = 00000000
|
||||
/* 00104 80B92524 03E00008 */ jr $ra
|
||||
/* 00108 80B92528 00000000 */ nop
|
|
@ -1,67 +0,0 @@
|
|||
glabel ObjDekujr_Update
|
||||
/* 00348 80B92768 27BDFFD0 */ addiu $sp, $sp, 0xFFD0 ## $sp = FFFFFFD0
|
||||
/* 0034C 80B9276C AFB00018 */ sw $s0, 0x0018($sp)
|
||||
/* 00350 80B92770 00808025 */ or $s0, $a0, $zero ## $s0 = 00000000
|
||||
/* 00354 80B92774 AFBF001C */ sw $ra, 0x001C($sp)
|
||||
/* 00358 80B92778 AFA50034 */ sw $a1, 0x0034($sp)
|
||||
/* 0035C 80B9277C 2606014C */ addiu $a2, $s0, 0x014C ## $a2 = 0000014C
|
||||
/* 00360 80B92780 00C02825 */ or $a1, $a2, $zero ## $a1 = 0000014C
|
||||
/* 00364 80B92784 0C0189B7 */ jal Collider_CylinderUpdate
|
||||
|
||||
/* 00368 80B92788 AFA60024 */ sw $a2, 0x0024($sp)
|
||||
/* 0036C 80B9278C 8FA40034 */ lw $a0, 0x0034($sp)
|
||||
/* 00370 80B92790 3C010001 */ lui $at, 0x0001 ## $at = 00010000
|
||||
/* 00374 80B92794 34211E60 */ ori $at, $at, 0x1E60 ## $at = 00011E60
|
||||
/* 00378 80B92798 8FA60024 */ lw $a2, 0x0024($sp)
|
||||
/* 0037C 80B9279C 0C017713 */ jal CollisionCheck_SetOC
|
||||
## CollisionCheck_setOT
|
||||
/* 00380 80B927A0 00812821 */ addu $a1, $a0, $at
|
||||
/* 00384 80B927A4 3C0E8016 */ lui $t6, %hi(gSaveContext+8)
|
||||
/* 00388 80B927A8 8DCEE668 */ lw $t6, %lo(gSaveContext+8)($t6)
|
||||
/* 0038C 80B927AC 3401FFF0 */ ori $at, $zero, 0xFFF0 ## $at = 0000FFF0
|
||||
/* 00390 80B927B0 02002825 */ or $a1, $s0, $zero ## $a1 = 00000000
|
||||
/* 00394 80B927B4 01C1082A */ slt $at, $t6, $at
|
||||
/* 00398 80B927B8 14200007 */ bne $at, $zero, .L80B927D8
|
||||
/* 0039C 80B927BC 2406000F */ addiu $a2, $zero, 0x000F ## $a2 = 0000000F
|
||||
/* 003A0 80B927C0 920F019B */ lbu $t7, 0x019B($s0) ## 0000019B
|
||||
/* 003A4 80B927C4 24180001 */ addiu $t8, $zero, 0x0001 ## $t8 = 00000001
|
||||
/* 003A8 80B927C8 55E00004 */ bnel $t7, $zero, .L80B927DC
|
||||
/* 003AC 80B927CC 9219019B */ lbu $t9, 0x019B($s0) ## 0000019B
|
||||
/* 003B0 80B927D0 A200019C */ sb $zero, 0x019C($s0) ## 0000019C
|
||||
/* 003B4 80B927D4 A218019B */ sb $t8, 0x019B($s0) ## 0000019B
|
||||
.L80B927D8:
|
||||
/* 003B8 80B927D8 9219019B */ lbu $t9, 0x019B($s0) ## 0000019B
|
||||
.L80B927DC:
|
||||
/* 003BC 80B927DC 24010001 */ addiu $at, $zero, 0x0001 ## $at = 00000001
|
||||
/* 003C0 80B927E0 8FA40034 */ lw $a0, 0x0034($sp)
|
||||
/* 003C4 80B927E4 17210011 */ bne $t9, $at, .L80B9282C
|
||||
/* 003C8 80B927E8 00000000 */ nop
|
||||
/* 003CC 80B927EC 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000
|
||||
/* 003D0 80B927F0 0C2E496E */ jal func_80B925B8
|
||||
/* 003D4 80B927F4 8FA50034 */ lw $a1, 0x0034($sp)
|
||||
/* 003D8 80B927F8 C6040024 */ lwc1 $f4, 0x0024($s0) ## 00000024
|
||||
/* 003DC 80B927FC C606005C */ lwc1 $f6, 0x005C($s0) ## 0000005C
|
||||
/* 003E0 80B92800 C60A0028 */ lwc1 $f10, 0x0028($s0) ## 00000028
|
||||
/* 003E4 80B92804 C6100060 */ lwc1 $f16, 0x0060($s0) ## 00000060
|
||||
/* 003E8 80B92808 46062200 */ add.s $f8, $f4, $f6
|
||||
/* 003EC 80B9280C C6060064 */ lwc1 $f6, 0x0064($s0) ## 00000064
|
||||
/* 003F0 80B92810 C604002C */ lwc1 $f4, 0x002C($s0) ## 0000002C
|
||||
/* 003F4 80B92814 46105480 */ add.s $f18, $f10, $f16
|
||||
/* 003F8 80B92818 E6080024 */ swc1 $f8, 0x0024($s0) ## 00000024
|
||||
/* 003FC 80B9281C 46062200 */ add.s $f8, $f4, $f6
|
||||
/* 00400 80B92820 E6120028 */ swc1 $f18, 0x0028($s0) ## 00000028
|
||||
/* 00404 80B92824 10000006 */ beq $zero, $zero, .L80B92840
|
||||
/* 00408 80B92828 E608002C */ swc1 $f8, 0x002C($s0) ## 0000002C
|
||||
.L80B9282C:
|
||||
/* 0040C 80B9282C 0C00DF66 */ jal func_80037D98
|
||||
/* 00410 80B92830 260701A0 */ addiu $a3, $s0, 0x01A0 ## $a3 = 000001A0
|
||||
/* 00414 80B92834 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000
|
||||
/* 00418 80B92838 0C00B56E */ jal Actor_SetHeight
|
||||
|
||||
/* 0041C 80B9283C 3C054220 */ lui $a1, 0x4220 ## $a1 = 42200000
|
||||
.L80B92840:
|
||||
/* 00420 80B92840 8FBF001C */ lw $ra, 0x001C($sp)
|
||||
/* 00424 80B92844 8FB00018 */ lw $s0, 0x0018($sp)
|
||||
/* 00428 80B92848 27BD0030 */ addiu $sp, $sp, 0x0030 ## $sp = 00000000
|
||||
/* 0042C 80B9284C 03E00008 */ jr $ra
|
||||
/* 00430 80B92850 00000000 */ nop
|
|
@ -1,17 +0,0 @@
|
|||
glabel func_80B92538
|
||||
/* 00118 80B92538 8C8E000C */ lw $t6, 0x000C($a0) ## 0000000C
|
||||
/* 0011C 80B9253C 448E2000 */ mtc1 $t6, $f4 ## $f4 = 0.00
|
||||
/* 00120 80B92540 00000000 */ nop
|
||||
/* 00124 80B92544 468021A0 */ cvt.s.w $f6, $f4
|
||||
/* 00128 80B92548 E4A60000 */ swc1 $f6, 0x0000($a1) ## 00000000
|
||||
/* 0012C 80B9254C 8C8F0010 */ lw $t7, 0x0010($a0) ## 00000010
|
||||
/* 00130 80B92550 448F4000 */ mtc1 $t7, $f8 ## $f8 = 0.00
|
||||
/* 00134 80B92554 00000000 */ nop
|
||||
/* 00138 80B92558 468042A0 */ cvt.s.w $f10, $f8
|
||||
/* 0013C 80B9255C E4AA0004 */ swc1 $f10, 0x0004($a1) ## 00000004
|
||||
/* 00140 80B92560 8C980014 */ lw $t8, 0x0014($a0) ## 00000014
|
||||
/* 00144 80B92564 44988000 */ mtc1 $t8, $f16 ## $f16 = 0.00
|
||||
/* 00148 80B92568 00000000 */ nop
|
||||
/* 0014C 80B9256C 468084A0 */ cvt.s.w $f18, $f16
|
||||
/* 00150 80B92570 03E00008 */ jr $ra
|
||||
/* 00154 80B92574 E4B20008 */ swc1 $f18, 0x0008($a1) ## 00000008
|
|
@ -1,17 +0,0 @@
|
|||
glabel func_80B92578
|
||||
/* 00158 80B92578 8C8E0018 */ lw $t6, 0x0018($a0) ## 00000018
|
||||
/* 0015C 80B9257C 448E2000 */ mtc1 $t6, $f4 ## $f4 = 0.00
|
||||
/* 00160 80B92580 00000000 */ nop
|
||||
/* 00164 80B92584 468021A0 */ cvt.s.w $f6, $f4
|
||||
/* 00168 80B92588 E4A60000 */ swc1 $f6, 0x0000($a1) ## 00000000
|
||||
/* 0016C 80B9258C 8C8F001C */ lw $t7, 0x001C($a0) ## 0000001C
|
||||
/* 00170 80B92590 448F4000 */ mtc1 $t7, $f8 ## $f8 = 0.00
|
||||
/* 00174 80B92594 00000000 */ nop
|
||||
/* 00178 80B92598 468042A0 */ cvt.s.w $f10, $f8
|
||||
/* 0017C 80B9259C E4AA0004 */ swc1 $f10, 0x0004($a1) ## 00000004
|
||||
/* 00180 80B925A0 8C980020 */ lw $t8, 0x0020($a0) ## 00000020
|
||||
/* 00184 80B925A4 44988000 */ mtc1 $t8, $f16 ## $f16 = 0.00
|
||||
/* 00188 80B925A8 00000000 */ nop
|
||||
/* 0018C 80B925AC 468084A0 */ cvt.s.w $f18, $f16
|
||||
/* 00190 80B925B0 03E00008 */ jr $ra
|
||||
/* 00194 80B925B4 E4B20008 */ swc1 $f18, 0x0008($a1) ## 00000008
|
|
@ -1,116 +0,0 @@
|
|||
glabel func_80B925B8
|
||||
/* 00198 80B925B8 27BDFFB0 */ addiu $sp, $sp, 0xFFB0 ## $sp = FFFFFFB0
|
||||
/* 0019C 80B925BC 3C0F80B9 */ lui $t7, %hi(D_80B92A2C) ## $t7 = 80B90000
|
||||
/* 001A0 80B925C0 AFBF0014 */ sw $ra, 0x0014($sp)
|
||||
/* 001A4 80B925C4 25EF2A2C */ addiu $t7, $t7, %lo(D_80B92A2C) ## $t7 = 80B92A2C
|
||||
/* 001A8 80B925C8 8DF90000 */ lw $t9, 0x0000($t7) ## 80B92A2C
|
||||
/* 001AC 80B925CC 27AE0028 */ addiu $t6, $sp, 0x0028 ## $t6 = FFFFFFD8
|
||||
/* 001B0 80B925D0 8DF80004 */ lw $t8, 0x0004($t7) ## 80B92A30
|
||||
/* 001B4 80B925D4 ADD90000 */ sw $t9, 0x0000($t6) ## FFFFFFD8
|
||||
/* 001B8 80B925D8 8DF90008 */ lw $t9, 0x0008($t7) ## 80B92A34
|
||||
/* 001BC 80B925DC ADD80004 */ sw $t8, 0x0004($t6) ## FFFFFFDC
|
||||
/* 001C0 80B925E0 00803025 */ or $a2, $a0, $zero ## $a2 = 00000000
|
||||
/* 001C4 80B925E4 ADD90008 */ sw $t9, 0x0008($t6) ## FFFFFFE0
|
||||
/* 001C8 80B925E8 90A81D6C */ lbu $t0, 0x1D6C($a1) ## 00001D6C
|
||||
/* 001CC 80B925EC 00A03825 */ or $a3, $a1, $zero ## $a3 = 00000000
|
||||
/* 001D0 80B925F0 24090002 */ addiu $t1, $zero, 0x0002 ## $t1 = 00000002
|
||||
/* 001D4 80B925F4 55000005 */ bnel $t0, $zero, .L80B9260C
|
||||
/* 001D8 80B925F8 94EA1D74 */ lhu $t2, 0x1D74($a3) ## 00001D74
|
||||
/* 001DC 80B925FC A089019C */ sb $t1, 0x019C($a0) ## 0000019C
|
||||
/* 001E0 80B92600 10000055 */ beq $zero, $zero, .L80B92758
|
||||
/* 001E4 80B92604 A080019B */ sb $zero, 0x019B($a0) ## 0000019B
|
||||
/* 001E8 80B92608 94EA1D74 */ lhu $t2, 0x1D74($a3) ## 00001D74
|
||||
.L80B9260C:
|
||||
/* 001EC 80B9260C 2401015F */ addiu $at, $zero, 0x015F ## $at = 0000015F
|
||||
/* 001F0 80B92610 00C02025 */ or $a0, $a2, $zero ## $a0 = 00000000
|
||||
/* 001F4 80B92614 15410006 */ bne $t2, $at, .L80B92630
|
||||
/* 001F8 80B92618 240528BF */ addiu $a1, $zero, 0x28BF ## $a1 = 000028BF
|
||||
/* 001FC 80B9261C AFA60050 */ sw $a2, 0x0050($sp)
|
||||
/* 00200 80B92620 0C00BE0A */ jal Audio_PlayActorSound2
|
||||
|
||||
/* 00204 80B92624 AFA70054 */ sw $a3, 0x0054($sp)
|
||||
/* 00208 80B92628 8FA60050 */ lw $a2, 0x0050($sp)
|
||||
/* 0020C 80B9262C 8FA70054 */ lw $a3, 0x0054($sp)
|
||||
.L80B92630:
|
||||
/* 00210 80B92630 8CE41D90 */ lw $a0, 0x1D90($a3) ## 00001D90
|
||||
/* 00214 80B92634 27A50040 */ addiu $a1, $sp, 0x0040 ## $a1 = FFFFFFF0
|
||||
/* 00218 80B92638 50800048 */ beql $a0, $zero, .L80B9275C
|
||||
/* 0021C 80B9263C 8FBF0014 */ lw $ra, 0x0014($sp)
|
||||
/* 00220 80B92640 AFA4004C */ sw $a0, 0x004C($sp)
|
||||
/* 00224 80B92644 AFA60050 */ sw $a2, 0x0050($sp)
|
||||
/* 00228 80B92648 0C2E494E */ jal func_80B92538
|
||||
/* 0022C 80B9264C AFA70054 */ sw $a3, 0x0054($sp)
|
||||
/* 00230 80B92650 8FA4004C */ lw $a0, 0x004C($sp)
|
||||
/* 00234 80B92654 0C2E495E */ jal func_80B92578
|
||||
/* 00238 80B92658 27A50034 */ addiu $a1, $sp, 0x0034 ## $a1 = FFFFFFE4
|
||||
/* 0023C 80B9265C 8FA60050 */ lw $a2, 0x0050($sp)
|
||||
/* 00240 80B92660 8FA4004C */ lw $a0, 0x004C($sp)
|
||||
/* 00244 80B92664 8FA70054 */ lw $a3, 0x0054($sp)
|
||||
/* 00248 80B92668 90CB019C */ lbu $t3, 0x019C($a2) ## 0000019C
|
||||
/* 0024C 80B9266C 27AC0040 */ addiu $t4, $sp, 0x0040 ## $t4 = FFFFFFF0
|
||||
/* 00250 80B92670 5560000A */ bnel $t3, $zero, .L80B9269C
|
||||
/* 00254 80B92674 94980006 */ lhu $t8, 0x0006($a0) ## 00000006
|
||||
/* 00258 80B92678 8D8E0000 */ lw $t6, 0x0000($t4) ## FFFFFFF0
|
||||
/* 0025C 80B9267C 240F0001 */ addiu $t7, $zero, 0x0001 ## $t7 = 00000001
|
||||
/* 00260 80B92680 ACCE0024 */ sw $t6, 0x0024($a2) ## 00000024
|
||||
/* 00264 80B92684 8D8D0004 */ lw $t5, 0x0004($t4) ## FFFFFFF4
|
||||
/* 00268 80B92688 ACCD0028 */ sw $t5, 0x0028($a2) ## 00000028
|
||||
/* 0026C 80B9268C 8D8E0008 */ lw $t6, 0x0008($t4) ## FFFFFFF8
|
||||
/* 00270 80B92690 A0CF019C */ sb $t7, 0x019C($a2) ## 0000019C
|
||||
/* 00274 80B92694 ACCE002C */ sw $t6, 0x002C($a2) ## 0000002C
|
||||
/* 00278 80B92698 94980006 */ lhu $t8, 0x0006($a0) ## 00000006
|
||||
.L80B9269C:
|
||||
/* 0027C 80B9269C 27A90028 */ addiu $t1, $sp, 0x0028 ## $t1 = FFFFFFD8
|
||||
/* 00280 80B926A0 A4D800B4 */ sh $t8, 0x00B4($a2) ## 000000B4
|
||||
/* 00284 80B926A4 94990008 */ lhu $t9, 0x0008($a0) ## 00000008
|
||||
/* 00288 80B926A8 A4D900B6 */ sh $t9, 0x00B6($a2) ## 000000B6
|
||||
/* 0028C 80B926AC 9488000A */ lhu $t0, 0x000A($a0) ## 0000000A
|
||||
/* 00290 80B926B0 A4C800B8 */ sh $t0, 0x00B8($a2) ## 000000B8
|
||||
/* 00294 80B926B4 8D2B0000 */ lw $t3, 0x0000($t1) ## FFFFFFD8
|
||||
/* 00298 80B926B8 ACCB005C */ sw $t3, 0x005C($a2) ## 0000005C
|
||||
/* 0029C 80B926BC 8D2A0004 */ lw $t2, 0x0004($t1) ## FFFFFFDC
|
||||
/* 002A0 80B926C0 ACCA0060 */ sw $t2, 0x0060($a2) ## 00000060
|
||||
/* 002A4 80B926C4 8D2B0008 */ lw $t3, 0x0008($t1) ## FFFFFFE0
|
||||
/* 002A8 80B926C8 ACCB0064 */ sw $t3, 0x0064($a2) ## 00000064
|
||||
/* 002AC 80B926CC 94EC1D74 */ lhu $t4, 0x1D74($a3) ## 00001D74
|
||||
/* 002B0 80B926D0 94820004 */ lhu $v0, 0x0004($a0) ## 00000004
|
||||
/* 002B4 80B926D4 004C082A */ slt $at, $v0, $t4
|
||||
/* 002B8 80B926D8 54200020 */ bnel $at, $zero, .L80B9275C
|
||||
/* 002BC 80B926DC 8FBF0014 */ lw $ra, 0x0014($sp)
|
||||
/* 002C0 80B926E0 948D0002 */ lhu $t5, 0x0002($a0) ## 00000002
|
||||
/* 002C4 80B926E4 C7A60034 */ lwc1 $f6, 0x0034($sp)
|
||||
/* 002C8 80B926E8 C7A80040 */ lwc1 $f8, 0x0040($sp)
|
||||
/* 002CC 80B926EC 004D7023 */ subu $t6, $v0, $t5
|
||||
/* 002D0 80B926F0 448E2000 */ mtc1 $t6, $f4 ## $f4 = 0.00
|
||||
/* 002D4 80B926F4 46083281 */ sub.s $f10, $f6, $f8
|
||||
/* 002D8 80B926F8 C4C2006C */ lwc1 $f2, 0x006C($a2) ## 0000006C
|
||||
/* 002DC 80B926FC C4CC0070 */ lwc1 $f12, 0x0070($a2) ## 00000070
|
||||
/* 002E0 80B92700 46802020 */ cvt.s.w $f0, $f4
|
||||
/* 002E4 80B92704 46005403 */ div.s $f16, $f10, $f0
|
||||
/* 002E8 80B92708 E4D0005C */ swc1 $f16, 0x005C($a2) ## 0000005C
|
||||
/* 002EC 80B9270C C7A40044 */ lwc1 $f4, 0x0044($sp)
|
||||
/* 002F0 80B92710 C7B20038 */ lwc1 $f18, 0x0038($sp)
|
||||
/* 002F4 80B92714 46049181 */ sub.s $f6, $f18, $f4
|
||||
/* 002F8 80B92718 46003203 */ div.s $f8, $f6, $f0
|
||||
/* 002FC 80B9271C E4C80060 */ swc1 $f8, 0x0060($a2) ## 00000060
|
||||
/* 00300 80B92720 C4CA0060 */ lwc1 $f10, 0x0060($a2) ## 00000060
|
||||
/* 00304 80B92724 46025400 */ add.s $f16, $f10, $f2
|
||||
/* 00308 80B92728 E4D00060 */ swc1 $f16, 0x0060($a2) ## 00000060
|
||||
/* 0030C 80B9272C C4D20060 */ lwc1 $f18, 0x0060($a2) ## 00000060
|
||||
/* 00310 80B92730 460C903C */ c.lt.s $f18, $f12
|
||||
/* 00314 80B92734 00000000 */ nop
|
||||
/* 00318 80B92738 45020003 */ bc1fl .L80B92748
|
||||
/* 0031C 80B9273C C7A4003C */ lwc1 $f4, 0x003C($sp)
|
||||
/* 00320 80B92740 E4CC0060 */ swc1 $f12, 0x0060($a2) ## 00000060
|
||||
/* 00324 80B92744 C7A4003C */ lwc1 $f4, 0x003C($sp)
|
||||
.L80B92748:
|
||||
/* 00328 80B92748 C7A60048 */ lwc1 $f6, 0x0048($sp)
|
||||
/* 0032C 80B9274C 46062201 */ sub.s $f8, $f4, $f6
|
||||
/* 00330 80B92750 46004283 */ div.s $f10, $f8, $f0
|
||||
/* 00334 80B92754 E4CA0064 */ swc1 $f10, 0x0064($a2) ## 00000064
|
||||
.L80B92758:
|
||||
/* 00338 80B92758 8FBF0014 */ lw $ra, 0x0014($sp)
|
||||
.L80B9275C:
|
||||
/* 0033C 80B9275C 27BD0050 */ addiu $sp, $sp, 0x0050 ## $sp = 00000000
|
||||
/* 00340 80B92760 03E00008 */ jr $ra
|
||||
/* 00344 80B92764 00000000 */ nop
|
|
@ -1,22 +0,0 @@
|
|||
.include "macro.inc"
|
||||
|
||||
# assembler directives
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
.set gp=64 # allow use of 64-bit general purpose registers
|
||||
|
||||
.section .data
|
||||
|
||||
.balign 16
|
||||
|
||||
glabel Obj_Dekujr_InitVars
|
||||
.word 0x00D30400, 0x00000009, 0x00CC0000, 0x000001A4
|
||||
.word ObjDekujr_Init
|
||||
.word ObjDekujr_Destroy
|
||||
.word ObjDekujr_Update
|
||||
.word ObjDekujr_Draw
|
||||
glabel D_80B92A00
|
||||
.word 0x00000000, 0x00003901, 0x02000000, 0x00000000, 0x00000000, 0xFFCFFFFF, 0x00000000, 0x00000100, 0x003C0050, 0x00000000, 0x00000000
|
||||
glabel D_80B92A2C
|
||||
.word 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000
|
||||
|
|
@ -1,13 +0,0 @@
|
|||
.include "macro.inc"
|
||||
|
||||
# assembler directives
|
||||
.set noat # allow manual use of $at
|
||||
.set noreorder # don't insert nops after branches
|
||||
.set gp=64 # allow use of 64-bit general purpose registers
|
||||
|
||||
.section .rodata
|
||||
|
||||
.balign 16
|
||||
|
||||
glabel D_80B92A90
|
||||
.incbin "baserom/ovl_Obj_Dekujr", 0x670, 0x00000070
|
|
@ -74,7 +74,10 @@ typedef struct {
|
|||
/* 0x00 */ u16 action; // "dousa"
|
||||
/* 0x02 */ u16 startFrame;
|
||||
/* 0x04 */ u16 endFrame;
|
||||
/* 0x06 */ Vec3s rot;
|
||||
union {
|
||||
/* 0x06 */ Vec3s rot;
|
||||
/* 0x06 */ Vec3us urot;
|
||||
};
|
||||
/* 0x0C */ Vec3i startPos;
|
||||
/* 0x18 */ Vec3i endPos;
|
||||
/* 0x24 */ Vec3i normal;
|
||||
|
|
|
@ -13,6 +13,10 @@ typedef struct {
|
|||
f32 x, y, z;
|
||||
} Vec3f;
|
||||
|
||||
typedef struct {
|
||||
u16 x, y, z;
|
||||
} Vec3us;
|
||||
|
||||
typedef struct {
|
||||
s16 x, y, z;
|
||||
} Vec3s;
|
||||
|
|
3
spec
3
spec
|
@ -3584,8 +3584,7 @@ endseg
|
|||
beginseg
|
||||
name "ovl_Obj_Dekujr"
|
||||
include "build/src/overlays/actors/ovl_Obj_Dekujr/z_obj_dekujr.o"
|
||||
include "build/data/overlays/actors/z_obj_dekujr.data.o"
|
||||
include "build/data/overlays/actors/z_obj_dekujr.reloc.o"
|
||||
include "build/src/overlays/actors/ovl_Obj_Dekujr/ovl_Obj_Dekujr_reloc.o"
|
||||
endseg
|
||||
|
||||
beginseg
|
||||
|
|
|
@ -15,7 +15,8 @@ void ObjDekujr_Destroy(Actor* thisx, GlobalContext* globalCtx);
|
|||
void ObjDekujr_Update(Actor* thisx, GlobalContext* globalCtx);
|
||||
void ObjDekujr_Draw(Actor* thisx, GlobalContext* globalCtx);
|
||||
|
||||
/*
|
||||
void ObjDekujr_ComeUp(ObjDekujr* this, GlobalContext* globalCtx);
|
||||
|
||||
const ActorInit Obj_Dekujr_InitVars = {
|
||||
ACTOR_OBJ_DEKUJR,
|
||||
ACTORTYPE_NPC,
|
||||
|
@ -27,17 +28,141 @@ const ActorInit Obj_Dekujr_InitVars = {
|
|||
(ActorFunc)ObjDekujr_Update,
|
||||
(ActorFunc)ObjDekujr_Draw,
|
||||
};
|
||||
*/
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Obj_Dekujr/ObjDekujr_Init.s")
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Obj_Dekujr/ObjDekujr_Destroy.s")
|
||||
static ColliderCylinderInit_Actor sCylinderInit = {
|
||||
{ NULL, 0x00, 0x00, 0x39, COLSHAPE_CYLINDER },
|
||||
{ 0x02, { 0x00000000, 0x00, 0x00 }, { 0xFFCFFFFF, 0x00, 0x00 }, 0x00, 0x00, 0x01 },
|
||||
{ 60, 80, 0, { 0, 0, 0 } },
|
||||
};
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Obj_Dekujr/func_80B92538.s")
|
||||
extern Gfx D_060030D0[]; // Display list for dekujr body
|
||||
extern Gfx D_060032D8[]; // Display list for dekujr face and shadow
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Obj_Dekujr/func_80B92578.s")
|
||||
void ObjDekujr_Init(Actor* thisx, GlobalContext* globalCtx) {
|
||||
ObjDekujr* this = THIS;
|
||||
s32 pad;
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Obj_Dekujr/func_80B925B8.s")
|
||||
if (gSaveContext.cutsceneIndex < 0xFFF0) {
|
||||
if (!LINK_IS_ADULT) {
|
||||
Actor_Kill(&this->actor);
|
||||
return;
|
||||
}
|
||||
this->unk_19C = 2;
|
||||
this->unk_19B = 0;
|
||||
} else {
|
||||
this->unk_19C = 0;
|
||||
this->unk_19B = 1;
|
||||
}
|
||||
if (!CHECK_QUEST_ITEM(QUEST_MEDALLION_FOREST)) {
|
||||
Actor_Kill(&this->actor);
|
||||
} else {
|
||||
ActorShape_Init(&this->actor.shape, 0.0f, NULL, 0.0f);
|
||||
Collider_InitCylinder(globalCtx, &this->collider);
|
||||
sCylinderInit.base.actor = thisx; // thisx required to match here
|
||||
Collider_SetCylinder_Actor(globalCtx, &this->collider, &sCylinderInit);
|
||||
this->actor.colChkInfo.mass = 0xFF;
|
||||
this->actor.textId = func_80037C30(globalCtx, 0xF);
|
||||
Actor_SetScale(&this->actor, 0.4f);
|
||||
}
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Obj_Dekujr/ObjDekujr_Update.s")
|
||||
void ObjDekujr_Destroy(Actor* thisx, GlobalContext* globalCtx) {
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Obj_Dekujr/ObjDekujr_Draw.s")
|
||||
void ObjDekujr_SetInitialPos(CsCmdActorAction* npcAction, Vec3f* initPos) {
|
||||
initPos->x = npcAction->startPos.x;
|
||||
initPos->y = npcAction->startPos.y;
|
||||
initPos->z = npcAction->startPos.z;
|
||||
}
|
||||
|
||||
void ObjDekujr_SetFinalPos(CsCmdActorAction* npcAction, Vec3f* finalPos) {
|
||||
finalPos->x = npcAction->endPos.x;
|
||||
finalPos->y = npcAction->endPos.y;
|
||||
finalPos->z = npcAction->endPos.z;
|
||||
}
|
||||
|
||||
void ObjDekujr_ComeUp(ObjDekujr* this, GlobalContext* globalCtx) {
|
||||
CsCmdActorAction* csCmdNPCAction;
|
||||
Vec3f initPos;
|
||||
Vec3f finalPos;
|
||||
Vec3f velocity = { 0.0f, 0.0f, 0.0f };
|
||||
f32 actionLength;
|
||||
f32 gravity;
|
||||
|
||||
if (globalCtx->csCtx.state == 0) {
|
||||
this->unk_19C = 2;
|
||||
this->unk_19B = 0;
|
||||
} else {
|
||||
if (globalCtx->csCtx.frames == 351) {
|
||||
Audio_PlayActorSound2(&this->actor, NA_SE_EV_COME_UP_DEKU_JR);
|
||||
}
|
||||
csCmdNPCAction = globalCtx->csCtx.npcActions[1];
|
||||
if (csCmdNPCAction != NULL) {
|
||||
ObjDekujr_SetInitialPos(csCmdNPCAction, &initPos);
|
||||
ObjDekujr_SetFinalPos(csCmdNPCAction, &finalPos);
|
||||
if (this->unk_19C == 0) {
|
||||
this->actor.posRot.pos = initPos;
|
||||
this->unk_19C = 1;
|
||||
}
|
||||
this->actor.shape.rot.x = csCmdNPCAction->urot.x;
|
||||
this->actor.shape.rot.y = csCmdNPCAction->urot.y;
|
||||
this->actor.shape.rot.z = csCmdNPCAction->urot.z;
|
||||
this->actor.velocity = velocity;
|
||||
if (csCmdNPCAction->endFrame >= globalCtx->csCtx.frames) {
|
||||
actionLength = csCmdNPCAction->endFrame - csCmdNPCAction->startFrame;
|
||||
this->actor.velocity.x = (finalPos.x - initPos.x) / actionLength;
|
||||
gravity = this->actor.gravity;
|
||||
this->actor.velocity.y = (finalPos.y - initPos.y) / actionLength;
|
||||
this->actor.velocity.y += gravity;
|
||||
if (this->actor.velocity.y < this->actor.minVelocityY) {
|
||||
this->actor.velocity.y = this->actor.minVelocityY;
|
||||
}
|
||||
this->actor.velocity.z = (finalPos.z - initPos.z) / actionLength;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void ObjDekujr_Update(Actor* thisx, GlobalContext* globalCtx) {
|
||||
ObjDekujr* this = THIS;
|
||||
s32 pad;
|
||||
|
||||
Collider_CylinderUpdate(&this->actor, &this->collider);
|
||||
CollisionCheck_SetOC(globalCtx, &globalCtx->colChkCtx, &this->collider.base);
|
||||
if ((gSaveContext.cutsceneIndex >= 0xFFF0) && (this->unk_19B == 0)) {
|
||||
this->unk_19C = 0;
|
||||
this->unk_19B = 1;
|
||||
}
|
||||
if (this->unk_19B == 1) {
|
||||
ObjDekujr_ComeUp(this, globalCtx);
|
||||
this->actor.posRot.pos.x += this->actor.velocity.x;
|
||||
this->actor.posRot.pos.y += this->actor.velocity.y;
|
||||
this->actor.posRot.pos.z += this->actor.velocity.z;
|
||||
} else {
|
||||
func_80037D98(globalCtx, &this->actor, 0xF, &this->unk_1A0);
|
||||
Actor_SetHeight(&this->actor, 40.0f);
|
||||
}
|
||||
}
|
||||
|
||||
void ObjDekujr_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
||||
u32 frameCount;
|
||||
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
|
||||
Gfx* dispRefs[4];
|
||||
|
||||
Graph_OpenDisps(dispRefs, globalCtx->state.gfxCtx, "../z_obj_dekujr.c", 370);
|
||||
func_80093D18(globalCtx->state.gfxCtx);
|
||||
func_80093D84(globalCtx->state.gfxCtx);
|
||||
|
||||
gSPMatrix(gfxCtx->polyOpa.p++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_obj_dekujr.c", 379),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gSPDisplayList(gfxCtx->polyOpa.p++, D_060030D0);
|
||||
|
||||
frameCount = globalCtx->state.frames;
|
||||
gSPSegment(
|
||||
gfxCtx->polyXlu.p++, 0x08,
|
||||
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, frameCount % 128, 0, 32, 32, 1, frameCount % 128, 0, 32, 32));
|
||||
gSPMatrix(gfxCtx->polyXlu.p++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_obj_dekujr.c", 399),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gSPDisplayList(gfxCtx->polyXlu.p++, D_060032D8);
|
||||
Graph_CloseDisps(dispRefs, globalCtx->state.gfxCtx, "../z_obj_dekujr.c", 409);
|
||||
}
|
||||
|
|
|
@ -8,7 +8,12 @@ struct ObjDekujr;
|
|||
|
||||
typedef struct ObjDekujr {
|
||||
/* 0x0000 */ Actor actor;
|
||||
/* 0x014C */ char unk_14C[0x58];
|
||||
/* 0x014C */ ColliderCylinder collider;
|
||||
/* 0x0198 */ char unk_198[0x3];
|
||||
/* 0x019B */ u8 unk_19B;
|
||||
/* 0x019C */ u8 unk_19C;
|
||||
/* 0x019D */ char unk_19D[0x3];
|
||||
/* 0x01A0 */ s32 unk_1A0;
|
||||
} ObjDekujr; // size = 0x01A4
|
||||
|
||||
extern const ActorInit Obj_Dekujr_InitVars;
|
||||
|
|
|
@ -745,6 +745,10 @@ D_06000A60 = 0x06000A60;
|
|||
D_04035590 = 0x04035590;
|
||||
D_040341FC = 0x040341FC;
|
||||
|
||||
// z_obj_dekujr
|
||||
D_060030D0 = 0x060030D0;
|
||||
D_060032D8 = 0x060032D8;
|
||||
|
||||
// z_en_okarina_Tag
|
||||
D_02003C80 = 0x02003C80;
|
||||
D_02005020 = 0x02005020;
|
||||
|
|
Loading…
Reference in a new issue