From e68822d44467b4ca90b59c8d0c31fa0d7f0512eb Mon Sep 17 00:00:00 2001 From: Ryan Dwyer Date: Tue, 18 Oct 2022 22:24:24 +1000 Subject: [PATCH] pal-beta and above: Decompile bgun0f0981e8 --- src/game/bondgun.c | 1781 ++------------------------------------------ 1 file changed, 63 insertions(+), 1718 deletions(-) diff --git a/src/game/bondgun.c b/src/game/bondgun.c index b145d4dcc..015780f0d 100644 --- a/src/game/bondgun.c +++ b/src/game/bondgun.c @@ -574,1725 +574,24 @@ f32 bgun0f09815c(struct hand *hand) return 0; } -#if VERSION >= VERSION_JPN_FINAL -GLOBAL_ASM( -glabel bgun0f0981e8 -.late_rodata -glabel var7f1ac1a8 -.word 0x461c4000 -glabel var7f1ac1ac -.word 0x3f451eb8 -glabel var7f1ac1b0 -.word 0x3f333333 -.text -/* f098f88: 27bdfea0 */ addiu $sp,$sp,-352 -/* f098f8c: afbf004c */ sw $ra,0x4c($sp) -/* f098f90: afb40048 */ sw $s4,0x48($sp) -/* f098f94: afb30044 */ sw $s3,0x44($sp) -/* f098f98: afb20040 */ sw $s2,0x40($sp) -/* f098f9c: afb1003c */ sw $s1,0x3c($sp) -/* f098fa0: afb00038 */ sw $s0,0x38($sp) -/* f098fa4: f7b40030 */ sdc1 $f20,0x30($sp) -/* f098fa8: afa50164 */ sw $a1,0x164($sp) -/* f098fac: 908e0690 */ lbu $t6,0x690($a0) -/* f098fb0: 8c98068c */ lw $t8,0x68c($a0) -/* f098fb4: 24010002 */ li $at,0x2 -/* f098fb8: 31cfffe3 */ andi $t7,$t6,0xffe3 -/* f098fbc: 00809025 */ move $s2,$a0 -/* f098fc0: 1701000f */ bne $t8,$at,.JF0f099000 -/* f098fc4: a08f0690 */ sb $t7,0x690($a0) -/* f098fc8: 0fc263bf */ jal bgun0f09815c -/* f098fcc: 00000000 */ nop -/* f098fd0: 46000506 */ mov.s $f20,$f0 -/* f098fd4: 0c00747e */ jal modelGetNumAnimFrames -/* f098fd8: 26440384 */ addiu $a0,$s2,0x384 -/* f098fdc: 2459ffff */ addiu $t9,$v0,-1 -/* f098fe0: 44992000 */ mtc1 $t9,$f4 -/* f098fe4: 00000000 */ nop -/* f098fe8: 468021a0 */ cvt.s.w $f6,$f4 -/* f098fec: 4614303e */ c.le.s $f6,$f20 -/* f098ff0: 00000000 */ nop -/* f098ff4: 45020003 */ bc1fl .JF0f099004 -/* f098ff8: 8e480680 */ lw $t0,0x680($s2) -/* f098ffc: ae40068c */ sw $zero,0x68c($s2) -.JF0f099000: -/* f099000: 8e480680 */ lw $t0,0x680($s2) -.JF0f099004: -/* f099004: 8e49068c */ lw $t1,0x68c($s2) -/* f099008: 29020000 */ slti $v0,$t0,0x0 -/* f09900c: 392a0002 */ xori $t2,$t1,0x2 -/* f099010: 2d4a0001 */ sltiu $t2,$t2,0x1 -/* f099014: 38420001 */ xori $v0,$v0,0x1 -/* f099018: 01425825 */ or $t3,$t2,$v0 -/* f09901c: 516001c7 */ beqzl $t3,.JF0f09973c -/* f099020: 8fbf004c */ lw $ra,0x4c($sp) -/* f099024: 44801000 */ mtc1 $zero,$f2 -/* f099028: c64806d0 */ lwc1 $f8,0x6d0($s2) -/* f09902c: 26540384 */ addiu $s4,$s2,0x384 -/* f099030: 4608103c */ c.lt.s $f2,$f8 -/* f099034: 00000000 */ nop -/* f099038: 45000006 */ bc1f .JF0f099054 -/* f09903c: 00000000 */ nop -/* f099040: 8e480680 */ lw $t0,0x680($s2) -/* f099044: ae400684 */ sw $zero,0x684($s2) -/* f099048: e6420688 */ swc1 $f2,0x688($s2) -/* f09904c: 29020000 */ slti $v0,$t0,0x0 -/* f099050: 38420001 */ xori $v0,$v0,0x1 -.JF0f099054: -/* f099054: 50400057 */ beqzl $v0,.JF0f0991b4 -/* f099058: 8e4d0690 */ lw $t5,0x690($s2) -/* f09905c: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f099060: 3c013f80 */ lui $at,0x3f80 -/* f099064: 924d06d6 */ lbu $t5,0x6d6($s2) -/* f099068: 8c6c0004 */ lw $t4,0x4($v1) -/* f09906c: 44810000 */ mtc1 $at,$f0 -/* f099070: 3c017f1b */ lui $at,0x7f1b -/* f099074: 448c5000 */ mtc1 $t4,$f10 -/* f099078: c432ce28 */ lwc1 $f18,-0x31d8($at) -/* f09907c: 31ae0001 */ andi $t6,$t5,0x1 -/* f099080: 46805420 */ cvt.s.w $f16,$f10 -/* f099084: 3c0f800a */ lui $t7,0x800a -/* f099088: 11c0001a */ beqz $t6,.JF0f0990f4 -/* f09908c: 46128503 */ div.s $f20,$f16,$f18 -/* f099090: 8defa8b4 */ lw $t7,-0x574c($t7) -/* f099094: 81f80de4 */ lb $t8,0xde4($t7) -/* f099098: 13000016 */ beqz $t8,.JF0f0990f4 -/* f09909c: 00000000 */ nop -/* f0990a0: 0c004b60 */ jal random -/* f0990a4: 00000000 */ nop -/* f0990a8: 44822000 */ mtc1 $v0,$f4 -/* f0990ac: 3c014f80 */ lui $at,0x4f80 -/* f0990b0: 04410004 */ bgez $v0,.JF0f0990c4 -/* f0990b4: 468021a0 */ cvt.s.w $f6,$f4 -/* f0990b8: 44814000 */ mtc1 $at,$f8 -/* f0990bc: 00000000 */ nop -/* f0990c0: 46083180 */ add.s $f6,$f6,$f8 -.JF0f0990c4: -/* f0990c4: 3c012f80 */ lui $at,0x2f80 -/* f0990c8: 44815000 */ mtc1 $at,$f10 -/* f0990cc: 3c017f1b */ lui $at,0x7f1b -/* f0990d0: c432ce2c */ lwc1 $f18,-0x31d4($at) -/* f0990d4: 460a3402 */ mul.s $f16,$f6,$f10 -/* f0990d8: 3c017f1b */ lui $at,0x7f1b -/* f0990dc: c428ce30 */ lwc1 $f8,-0x31d0($at) -/* f0990e0: 44801000 */ mtc1 $zero,$f2 -/* f0990e4: 8e480680 */ lw $t0,0x680($s2) -/* f0990e8: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f0990ec: 46128102 */ mul.s $f4,$f16,$f18 -/* f0990f0: 46082000 */ add.s $f0,$f4,$f8 -.JF0f0990f4: -/* f0990f4: 10600018 */ beqz $v1,.JF0f099158 -/* f0990f8: 02802025 */ move $a0,$s4 -/* f0990fc: 4602a03c */ c.lt.s $f20,$f2 -/* f099100: 00082c00 */ sll $a1,$t0,0x10 -/* f099104: 0005cc03 */ sra $t9,$a1,0x10 -/* f099108: 45000013 */ bc1f .JF0f099158 -/* f09910c: 00000000 */ nop -/* f099110: 46140182 */ mul.s $f6,$f0,$f20 -/* f099114: 44071000 */ mfc1 $a3,$f2 -/* f099118: 02802025 */ move $a0,$s4 -/* f09911c: 03202825 */ move $a1,$t9 -/* f099120: 00003025 */ move $a2,$zero -/* f099124: e7a20014 */ swc1 $f2,0x14($sp) -/* f099128: 0c00772b */ jal modelSetAnimation -/* f09912c: e7a60010 */ swc1 $f6,0x10($sp) -/* f099130: 0c00747e */ jal modelGetNumAnimFrames -/* f099134: 02802025 */ move $a0,$s4 -/* f099138: 44825000 */ mtc1 $v0,$f10 -/* f09913c: 02802025 */ move $a0,$s4 -/* f099140: 468052a0 */ cvt.s.w $f10,$f10 -/* f099144: 44055000 */ mfc1 $a1,$f10 -/* f099148: 0c0077fe */ jal model0001e018 -/* f09914c: 00000000 */ nop -/* f099150: 1000000b */ b .JF0f099180 -/* f099154: 240affff */ li $t2,-1 -.JF0f099158: -/* f099158: 46140402 */ mul.s $f16,$f0,$f20 -/* f09915c: 00082c00 */ sll $a1,$t0,0x10 -/* f099160: 00054c03 */ sra $t1,$a1,0x10 -/* f099164: 44071000 */ mfc1 $a3,$f2 -/* f099168: 01202825 */ move $a1,$t1 -/* f09916c: 00003025 */ move $a2,$zero -/* f099170: e7a20014 */ swc1 $f2,0x14($sp) -/* f099174: 0c00772b */ jal modelSetAnimation -/* f099178: e7b00010 */ swc1 $f16,0x10($sp) -/* f09917c: 240affff */ li $t2,-1 -.JF0f099180: -/* f099180: 240b0002 */ li $t3,0x2 -/* f099184: ae4a0680 */ sw $t2,0x680($s2) -/* f099188: ae4b068c */ sw $t3,0x68c($s2) -/* f09918c: 0c00749a */ jal modelGetAbsAnimSpeed -/* f099190: 02802025 */ move $a0,$s4 -/* f099194: 8e4c0684 */ lw $t4,0x684($s2) -/* f099198: 44801000 */ mtc1 $zero,$f2 -/* f09919c: 448c9000 */ mtc1 $t4,$f18 -/* f0991a0: 00000000 */ nop -/* f0991a4: 46809120 */ cvt.s.w $f4,$f18 -/* f0991a8: 46040202 */ mul.s $f8,$f0,$f4 -/* f0991ac: e6480688 */ swc1 $f8,0x688($s2) -/* f0991b0: 8e4d0690 */ lw $t5,0x690($s2) -.JF0f0991b4: -/* f0991b4: 000d7840 */ sll $t7,$t5,0x1 -/* f0991b8: 05e10003 */ bgez $t7,.JF0f0991c8 -/* f0991bc: 00000000 */ nop -/* f0991c0: ae400684 */ sw $zero,0x684($s2) -/* f0991c4: e6420688 */ swc1 $f2,0x688($s2) -.JF0f0991c8: -/* f0991c8: 0fc263bf */ jal bgun0f09815c -/* f0991cc: 02402025 */ move $a0,$s2 -/* f0991d0: 44805000 */ mtc1 $zero,$f10 -/* f0991d4: c6460688 */ lwc1 $f6,0x688($s2) -/* f0991d8: 46000506 */ mov.s $f20,$f0 -/* f0991dc: 460a0032 */ c.eq.s $f0,$f10 -/* f0991e0: 46003380 */ add.s $f14,$f6,$f0 -/* f0991e4: 4502000b */ bc1fl .JF0f099214 -/* f0991e8: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f0991ec: 44808000 */ mtc1 $zero,$f16 -/* f0991f0: 3c013f80 */ lui $at,0x3f80 -/* f0991f4: 460e803c */ c.lt.s $f16,$f14 -/* f0991f8: 00000000 */ nop -/* f0991fc: 45020005 */ bc1fl .JF0f099214 -/* f099200: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f099204: 44819000 */ mtc1 $at,$f18 -/* f099208: 00000000 */ nop -/* f09920c: 46120501 */ sub.s $f20,$f0,$f18 -/* f099210: 8e4306b0 */ lw $v1,0x6b0($s2) -.JF0f099214: -/* f099214: 106000d1 */ beqz $v1,.JF0f09955c -/* f099218: 00608825 */ move $s1,$v1 -/* f09921c: 106000cf */ beqz $v1,.JF0f09955c -/* f099220: afa0014c */ sw $zero,0x14c($sp) -/* f099224: 00008025 */ move $s0,$zero -/* f099228: 24130001 */ li $s3,0x1 -/* f09922c: 92230000 */ lbu $v1,0x0($s1) -.JF0f099230: -/* f099230: 14600003 */ bnez $v1,.JF0f099240 -/* f099234: 00000000 */ nop -/* f099238: 100000af */ b .JF0f0994f8 -/* f09923c: afb3014c */ sw $s3,0x14c($sp) -.JF0f099240: -/* f099240: 12630003 */ beq $s3,$v1,.JF0f099250 -/* f099244: 24010002 */ li $at,0x2 -/* f099248: 54610036 */ bnel $v1,$at,.JF0f099324 -/* f09924c: 24010003 */ li $at,0x3 -.JF0f099250: -/* f099250: 96260002 */ lhu $a2,0x2($s1) -/* f099254: 3c014f80 */ lui $at,0x4f80 -/* f099258: 2405ffff */ li $a1,-1 -/* f09925c: 44862000 */ mtc1 $a2,$f4 -/* f099260: 27ab0094 */ addiu $t3,$sp,0x94 -/* f099264: 04c10004 */ bgez $a2,.JF0f099278 -/* f099268: 46802220 */ cvt.s.w $f8,$f4 -/* f09926c: 44813000 */ mtc1 $at,$f6 -/* f099270: 00000000 */ nop -/* f099274: 46064200 */ add.s $f8,$f8,$f6 -.JF0f099278: -/* f099278: 460e403e */ c.le.s $f8,$f14 -/* f09927c: 2401ffff */ li $at,-1 -/* f099280: 4502009e */ bc1fl .JF0f0994fc -/* f099284: 8fac014c */ lw $t4,0x14c($sp) -/* f099288: 1a00000a */ blez $s0,.JF0f0992b4 -/* f09928c: 00001025 */ move $v0,$zero -/* f099290: 8e240004 */ lw $a0,0x4($s1) -/* f099294: 27a3010c */ addiu $v1,$sp,0x10c -.JF0f099298: -/* f099298: 8c780000 */ lw $t8,0x0($v1) -/* f09929c: 54980003 */ bnel $a0,$t8,.JF0f0992ac -/* f0992a0: 24420001 */ addiu $v0,$v0,0x1 -/* f0992a4: 00402825 */ move $a1,$v0 -/* f0992a8: 24420001 */ addiu $v0,$v0,0x1 -.JF0f0992ac: -/* f0992ac: 1450fffa */ bne $v0,$s0,.JF0f099298 -/* f0992b0: 24630004 */ addiu $v1,$v1,0x4 -.JF0f0992b4: -/* f0992b4: 14a1000a */ bne $a1,$at,.JF0f0992e0 -/* f0992b8: 2409ffff */ li $t1,-1 -/* f0992bc: 8e240004 */ lw $a0,0x4($s1) -/* f0992c0: 02002825 */ move $a1,$s0 -/* f0992c4: 00051080 */ sll $v0,$a1,0x2 -/* f0992c8: 03a2c821 */ addu $t9,$sp,$v0 -/* f0992cc: 03a25021 */ addu $t2,$sp,$v0 -/* f0992d0: af24010c */ sw $a0,0x10c($t9) -/* f0992d4: ad490094 */ sw $t1,0x94($t2) -/* f0992d8: 26100001 */ addiu $s0,$s0,0x1 -/* f0992dc: 96260002 */ lhu $a2,0x2($s1) -.JF0f0992e0: -/* f0992e0: 00051080 */ sll $v0,$a1,0x2 -/* f0992e4: 004b1821 */ addu $v1,$v0,$t3 -/* f0992e8: 8c6c0000 */ lw $t4,0x0($v1) -/* f0992ec: 0186082a */ slt $at,$t4,$a2 -/* f0992f0: 50200082 */ beqzl $at,.JF0f0994fc -/* f0992f4: 8fac014c */ lw $t4,0x14c($sp) -/* f0992f8: ac660000 */ sw $a2,0x0($v1) -/* f0992fc: 922d0000 */ lbu $t5,0x0($s1) -/* f099300: 03a27821 */ addu $t7,$sp,$v0 -/* f099304: 03a27021 */ addu $t6,$sp,$v0 -/* f099308: 166d0003 */ bne $s3,$t5,.JF0f099318 -/* f09930c: 00000000 */ nop -/* f099310: 10000079 */ b .JF0f0994f8 -/* f099314: add300d0 */ sw $s3,0xd0($t6) -.JF0f099318: -/* f099318: 10000077 */ b .JF0f0994f8 -/* f09931c: ade000d0 */ sw $zero,0xd0($t7) -/* f099320: 24010003 */ li $at,0x3 -.JF0f099324: -/* f099324: 10610005 */ beq $v1,$at,.JF0f09933c -/* f099328: 24010008 */ li $at,0x8 -/* f09932c: 50610042 */ beql $v1,$at,.JF0f099438 -/* f099330: 8e4e0690 */ lw $t6,0x690($s2) -/* f099334: 10000071 */ b .JF0f0994fc -/* f099338: 8fac014c */ lw $t4,0x14c($sp) -.JF0f09933c: -/* f09933c: 8e580690 */ lw $t8,0x690($s2) -/* f099340: 0018cfc2 */ srl $t9,$t8,0x1f -/* f099344: 5320006d */ beqzl $t9,.JF0f0994fc -/* f099348: 8fac014c */ lw $t4,0x14c($sp) -/* f09934c: 96290002 */ lhu $t1,0x2($s1) -/* f099350: 3c014f80 */ lui $at,0x4f80 -/* f099354: 44895000 */ mtc1 $t1,$f10 -/* f099358: 05210004 */ bgez $t1,.JF0f09936c -/* f09935c: 468050a0 */ cvt.s.w $f2,$f10 -/* f099360: 44818000 */ mtc1 $at,$f16 -/* f099364: 00000000 */ nop -/* f099368: 46101080 */ add.s $f2,$f2,$f16 -.JF0f09936c: -/* f09936c: 460e103e */ c.le.s $f2,$f14 -/* f099370: 00000000 */ nop -/* f099374: 45020061 */ bc1fl .JF0f0994fc -/* f099378: 8fac014c */ lw $t4,0x14c($sp) -/* f09937c: 4602a03c */ c.lt.s $f20,$f2 -/* f099380: 00000000 */ nop -/* f099384: 4502005d */ bc1fl .JF0f0994fc -/* f099388: 8fac014c */ lw $t4,0x14c($sp) -/* f09938c: 460ea03c */ c.lt.s $f20,$f14 -/* f099390: 00000000 */ nop -/* f099394: 45020059 */ bc1fl .JF0f0994fc -/* f099398: 8fac014c */ lw $t4,0x14c($sp) -/* f09939c: 0fc263bf */ jal bgun0f09815c -/* f0993a0: 02402025 */ move $a0,$s2 -/* f0993a4: 962a0002 */ lhu $t2,0x2($s1) -/* f0993a8: 3c014f80 */ lui $at,0x4f80 -/* f0993ac: 02802025 */ move $a0,$s4 -/* f0993b0: 448a9000 */ mtc1 $t2,$f18 -/* f0993b4: 05410004 */ bgez $t2,.JF0f0993c8 -/* f0993b8: 46809120 */ cvt.s.w $f4,$f18 -/* f0993bc: 44813000 */ mtc1 $at,$f6 -/* f0993c0: 00000000 */ nop -/* f0993c4: 46062100 */ add.s $f4,$f4,$f6 -.JF0f0993c8: -/* f0993c8: 46002081 */ sub.s $f2,$f4,$f0 -/* f0993cc: 3c014000 */ lui $at,0x4000 -/* f0993d0: 44814000 */ mtc1 $at,$f8 -/* f0993d4: c64c0688 */ lwc1 $f12,0x688($s2) -/* f0993d8: 46081083 */ div.s $f2,$f2,$f8 -/* f0993dc: 460c103c */ c.lt.s $f2,$f12 -/* f0993e0: 00000000 */ nop -/* f0993e4: 45000011 */ bc1f .JF0f09942c -/* f0993e8: 00000000 */ nop -/* f0993ec: 0c00749a */ jal modelGetAbsAnimSpeed -/* f0993f0: e7a20084 */ swc1 $f2,0x84($sp) -/* f0993f4: c7a20084 */ lwc1 $f2,0x84($sp) -/* f0993f8: 02802025 */ move $a0,$s4 -/* f0993fc: 46001283 */ div.s $f10,$f2,$f0 -/* f099400: 4600540d */ trunc.w.s $f16,$f10 -/* f099404: 440c8000 */ mfc1 $t4,$f16 -/* f099408: 0c00749a */ jal modelGetAbsAnimSpeed -/* f09940c: ae4c0684 */ sw $t4,0x684($s2) -/* f099410: 8e4d0684 */ lw $t5,0x684($s2) -/* f099414: 448d9000 */ mtc1 $t5,$f18 -/* f099418: 00000000 */ nop -/* f09941c: 468091a0 */ cvt.s.w $f6,$f18 -/* f099420: 46060102 */ mul.s $f4,$f0,$f6 -/* f099424: e6440688 */ swc1 $f4,0x688($s2) -/* f099428: c64c0688 */ lwc1 $f12,0x688($s2) -.JF0f09942c: -/* f09942c: 10000032 */ b .JF0f0994f8 -/* f099430: 46146380 */ add.s $f14,$f12,$f20 -/* f099434: 8e4e0690 */ lw $t6,0x690($s2) -.JF0f099438: -/* f099438: 000ec080 */ sll $t8,$t6,0x2 -/* f09943c: 0703002f */ bgezl $t8,.JF0f0994fc -/* f099440: 8fac014c */ lw $t4,0x14c($sp) -/* f099444: 96260002 */ lhu $a2,0x2($s1) -/* f099448: 3c014f80 */ lui $at,0x4f80 -/* f09944c: 44864000 */ mtc1 $a2,$f8 -/* f099450: 04c10004 */ bgez $a2,.JF0f099464 -/* f099454: 468040a0 */ cvt.s.w $f2,$f8 -/* f099458: 44815000 */ mtc1 $at,$f10 -/* f09945c: 00000000 */ nop -/* f099460: 460a1080 */ add.s $f2,$f2,$f10 -.JF0f099464: -/* f099464: 460e103e */ c.le.s $f2,$f14 -/* f099468: 00000000 */ nop -/* f09946c: 45020023 */ bc1fl .JF0f0994fc -/* f099470: 8fac014c */ lw $t4,0x14c($sp) -/* f099474: 4602a03c */ c.lt.s $f20,$f2 -/* f099478: 00000000 */ nop -/* f09947c: 4502001f */ bc1fl .JF0f0994fc -/* f099480: 8fac014c */ lw $t4,0x14c($sp) -/* f099484: 460ea03c */ c.lt.s $f20,$f14 -/* f099488: 02802025 */ move $a0,$s4 -/* f09948c: 4502001b */ bc1fl .JF0f0994fc -/* f099490: 8fac014c */ lw $t4,0x14c($sp) -/* f099494: 460e103e */ c.le.s $f2,$f14 -/* f099498: 44809000 */ mtc1 $zero,$f18 -/* f09949c: 46007006 */ mov.s $f0,$f14 -/* f0994a0: 4502000c */ bc1fl .JF0f0994d4 -/* f0994a4: ae400684 */ sw $zero,0x684($s2) -/* f0994a8: 8e390004 */ lw $t9,0x4($s1) -/* f0994ac: 03264823 */ subu $t1,$t9,$a2 -/* f0994b0: 44898000 */ mtc1 $t1,$f16 -/* f0994b4: 00000000 */ nop -/* f0994b8: 46808320 */ cvt.s.w $f12,$f16 -/* f0994bc: 460c0000 */ add.s $f0,$f0,$f12 -.JF0f0994c0: -/* f0994c0: 4600103e */ c.le.s $f2,$f0 -/* f0994c4: 00000000 */ nop -/* f0994c8: 4503fffd */ bc1tl .JF0f0994c0 -/* f0994cc: 460c0000 */ add.s $f0,$f0,$f12 -/* f0994d0: ae400684 */ sw $zero,0x684($s2) -.JF0f0994d4: -/* f0994d4: e6520688 */ swc1 $f18,0x688($s2) -/* f0994d8: 44050000 */ mfc1 $a1,$f0 -/* f0994dc: 46000506 */ mov.s $f20,$f0 -/* f0994e0: 0c0077fe */ jal model0001e018 -/* f0994e4: e7a00080 */ swc1 $f0,0x80($sp) -/* f0994e8: 924a0691 */ lbu $t2,0x691($s2) -/* f0994ec: c7ae0080 */ lwc1 $f14,0x80($sp) -/* f0994f0: 254b0001 */ addiu $t3,$t2,0x1 -/* f0994f4: a24b0691 */ sb $t3,0x691($s2) -.JF0f0994f8: -/* f0994f8: 8fac014c */ lw $t4,0x14c($sp) -.JF0f0994fc: -/* f0994fc: 26310008 */ addiu $s1,$s1,0x8 -/* f099500: 5180ff4b */ beqzl $t4,.JF0f099230 -/* f099504: 92230000 */ lbu $v1,0x0($s1) -/* f099508: 5a000015 */ blezl $s0,.JF0f099560 -/* f09950c: 02802025 */ move $a0,$s4 -/* f099510: 1a000012 */ blez $s0,.JF0f09955c -/* f099514: 00001025 */ move $v0,$zero -/* f099518: 27a3010c */ addiu $v1,$sp,0x10c -/* f09951c: 27a800d0 */ addiu $t0,$sp,0xd0 -.JF0f099520: -/* f099520: 84640002 */ lh $a0,0x2($v1) -/* f099524: 8d050000 */ lw $a1,0x0($t0) -/* f099528: afa80058 */ sw $t0,0x58($sp) -/* f09952c: afa3005c */ sw $v1,0x5c($sp) -/* f099530: afa2007c */ sw $v0,0x7c($sp) -/* f099534: 02403025 */ move $a2,$s2 -/* f099538: 0fc26305 */ jal bgunSetPartVisible -/* f09953c: 8fa70164 */ lw $a3,0x164($sp) -/* f099540: 8fa2007c */ lw $v0,0x7c($sp) -/* f099544: 8fa3005c */ lw $v1,0x5c($sp) -/* f099548: 8fa80058 */ lw $t0,0x58($sp) -/* f09954c: 24420001 */ addiu $v0,$v0,0x1 -/* f099550: 24630004 */ addiu $v1,$v1,0x4 -/* f099554: 1450fff2 */ bne $v0,$s0,.JF0f099520 -/* f099558: 25080004 */ addiu $t0,$t0,0x4 -.JF0f09955c: -/* f09955c: 02802025 */ move $a0,$s4 -.JF0f099560: -/* f099560: 3c054080 */ lui $a1,0x4080 -/* f099564: 0c0077e3 */ jal modelSetAnimPlaySpeed -/* f099568: 24060000 */ li $a2,0x0 -/* f09956c: 02802025 */ move $a0,$s4 -/* f099570: 8e450684 */ lw $a1,0x684($s2) -/* f099574: 0c007b7e */ jal model0001ee18 -/* f099578: 24060001 */ li $a2,0x1 -/* f09957c: 0fc263bf */ jal bgun0f09815c -/* f099580: 02402025 */ move $a0,$s2 -/* f099584: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f099588: 46000386 */ mov.s $f14,$f0 -/* f09958c: 00004025 */ move $t0,$zero -/* f099590: 10600069 */ beqz $v1,.JF0f099738 -/* f099594: 00608025 */ move $s0,$v1 -/* f099598: 3c013f80 */ lui $at,0x3f80 -/* f09959c: 44813000 */ mtc1 $at,$f6 -/* f0995a0: 00008825 */ move $s1,$zero -/* f0995a4: 10600064 */ beqz $v1,.JF0f099738 -/* f0995a8: e7a60070 */ swc1 $f6,0x70($sp) -/* f0995ac: 24140009 */ li $s4,0x9 -/* f0995b0: 24130005 */ li $s3,0x5 -.JF0f0995b4: -/* f0995b4: 92030000 */ lbu $v1,0x0($s0) -/* f0995b8: 54600004 */ bnezl $v1,.JF0f0995cc -/* f0995bc: 960d0002 */ lhu $t5,0x2($s0) -/* f0995c0: 1000005b */ b .JF0f099730 -/* f0995c4: 24080001 */ li $t0,0x1 -/* f0995c8: 960d0002 */ lhu $t5,0x2($s0) -.JF0f0995cc: -/* f0995cc: 3c014f80 */ lui $at,0x4f80 -/* f0995d0: 448d2000 */ mtc1 $t5,$f4 -/* f0995d4: 05a10004 */ bgez $t5,.JF0f0995e8 -/* f0995d8: 46802020 */ cvt.s.w $f0,$f4 -/* f0995dc: 44814000 */ mtc1 $at,$f8 -/* f0995e0: 00000000 */ nop -/* f0995e4: 46080000 */ add.s $f0,$f0,$f8 -.JF0f0995e8: -/* f0995e8: 460e003e */ c.le.s $f0,$f14 -/* f0995ec: 00000000 */ nop -/* f0995f0: 4500004f */ bc1f .JF0f099730 -/* f0995f4: 00000000 */ nop -/* f0995f8: 4600a03c */ c.lt.s $f20,$f0 -/* f0995fc: 00000000 */ nop -/* f099600: 4500004b */ bc1f .JF0f099730 -/* f099604: 00000000 */ nop -/* f099608: 460ea03c */ c.lt.s $f20,$f14 -/* f09960c: 00000000 */ nop -/* f099610: 45000047 */ bc1f .JF0f099730 -/* f099614: 00000000 */ nop -/* f099618: 10730007 */ beq $v1,$s3,.JF0f099638 -/* f09961c: 00000000 */ nop -/* f099620: 10740039 */ beq $v1,$s4,.JF0f099708 -/* f099624: 2401000b */ li $at,0xb -/* f099628: 5061002f */ beql $v1,$at,.JF0f0996e8 -/* f09962c: 8e0d0004 */ lw $t5,0x4($s0) -/* f099630: 1000003f */ b .JF0f099730 -/* f099634: 00000000 */ nop -.JF0f099638: -/* f099638: 12200016 */ beqz $s1,.JF0f099694 -/* f09963c: 00002025 */ move $a0,$zero -/* f099640: 8e0e0004 */ lw $t6,0x4($s0) -/* f099644: c7aa0070 */ lwc1 $f10,0x70($sp) -/* f099648: 240f0001 */ li $t7,0x1 -/* f09964c: 2418ffff */ li $t8,-1 -/* f099650: 24190001 */ li $t9,0x1 -/* f099654: afb90020 */ sw $t9,0x20($sp) -/* f099658: afb8001c */ sw $t8,0x1c($sp) -/* f09965c: afaf0018 */ sw $t7,0x18($sp) -/* f099660: e7ae0158 */ swc1 $f14,0x158($sp) -/* f099664: afa80078 */ sw $t0,0x78($sp) -/* f099668: 00002025 */ move $a0,$zero -/* f09966c: 00002825 */ move $a1,$zero -/* f099670: 24067fff */ li $a2,0x7fff -/* f099674: 24070040 */ li $a3,0x40 -/* f099678: 00008825 */ move $s1,$zero -/* f09967c: afae0010 */ sw $t6,0x10($sp) -/* f099680: 0c0041b5 */ jal snd00010718 -/* f099684: e7aa0014 */ swc1 $f10,0x14($sp) -/* f099688: 8fa80078 */ lw $t0,0x78($sp) -/* f09968c: 10000028 */ b .JF0f099730 -/* f099690: c7ae0158 */ lwc1 $f14,0x158($sp) -.JF0f099694: -/* f099694: 8e090004 */ lw $t1,0x4($s0) -/* f099698: 3c013f80 */ lui $at,0x3f80 -/* f09969c: 44818000 */ mtc1 $at,$f16 -/* f0996a0: 240a0001 */ li $t2,0x1 -/* f0996a4: 240bffff */ li $t3,-1 -/* f0996a8: 240c0001 */ li $t4,0x1 -/* f0996ac: afac0020 */ sw $t4,0x20($sp) -/* f0996b0: afab001c */ sw $t3,0x1c($sp) -/* f0996b4: afaa0018 */ sw $t2,0x18($sp) -/* f0996b8: e7ae0158 */ swc1 $f14,0x158($sp) -/* f0996bc: afa80078 */ sw $t0,0x78($sp) -/* f0996c0: 00002825 */ move $a1,$zero -/* f0996c4: 24067fff */ li $a2,0x7fff -/* f0996c8: 24070040 */ li $a3,0x40 -/* f0996cc: afa90010 */ sw $t1,0x10($sp) -/* f0996d0: 0c0041b5 */ jal snd00010718 -/* f0996d4: e7b00014 */ swc1 $f16,0x14($sp) -/* f0996d8: 8fa80078 */ lw $t0,0x78($sp) -/* f0996dc: 10000014 */ b .JF0f099730 -/* f0996e0: c7ae0158 */ lwc1 $f14,0x158($sp) -/* f0996e4: 8e0d0004 */ lw $t5,0x4($s0) -.JF0f0996e8: -/* f0996e8: 3c01447a */ lui $at,0x447a -/* f0996ec: 44812000 */ mtc1 $at,$f4 -/* f0996f0: 448d9000 */ mtc1 $t5,$f18 -/* f0996f4: 24110001 */ li $s1,0x1 -/* f0996f8: 468091a0 */ cvt.s.w $f6,$f18 -/* f0996fc: 46043203 */ div.s $f8,$f6,$f4 -/* f099700: 1000000b */ b .JF0f099730 -/* f099704: e7a80070 */ swc1 $f8,0x70($sp) -.JF0f099708: -/* f099708: 8e4e0690 */ lw $t6,0x690($s2) -/* f09970c: 924b0690 */ lbu $t3,0x690($s2) -/* f099710: 000e78c0 */ sll $t7,$t6,0x3 -/* f099714: 000fc742 */ srl $t8,$t7,0x1d -/* f099718: 27190001 */ addiu $t9,$t8,0x1 -/* f09971c: 00194880 */ sll $t1,$t9,0x2 -/* f099720: 312a001c */ andi $t2,$t1,0x1c -/* f099724: 316cffe3 */ andi $t4,$t3,0xffe3 -/* f099728: 014c6825 */ or $t5,$t2,$t4 -/* f09972c: a24d0690 */ sb $t5,0x690($s2) -.JF0f099730: -/* f099730: 1100ffa0 */ beqz $t0,.JF0f0995b4 -/* f099734: 26100008 */ addiu $s0,$s0,0x8 -.JF0f099738: -/* f099738: 8fbf004c */ lw $ra,0x4c($sp) -.JF0f09973c: -/* f09973c: d7b40030 */ ldc1 $f20,0x30($sp) -/* f099740: 8fb00038 */ lw $s0,0x38($sp) -/* f099744: 8fb1003c */ lw $s1,0x3c($sp) -/* f099748: 8fb20040 */ lw $s2,0x40($sp) -/* f09974c: 8fb30044 */ lw $s3,0x44($sp) -/* f099750: 8fb40048 */ lw $s4,0x48($sp) -/* f099754: 03e00008 */ jr $ra -/* f099758: 27bd0160 */ addiu $sp,$sp,0x160 -); -#elif VERSION >= VERSION_PAL_FINAL -GLOBAL_ASM( -glabel bgun0f0981e8 -.late_rodata -glabel var7f1ad398pf -.word 0x461c4000 -glabel var7f1ad39cpf -.word 0x3f451eb8 -glabel var7f1ad3a0pf -.word 0x3f333333 -glabel var7f1ad3a4pf -.word 0x3f99999a -glabel var7f1ad3a8pf -.word 0x3f555555 -glabel var7f1ad3acpf -.word 0x3f99999a -.text -/* f098108: 27bdfea0 */ addiu $sp,$sp,-352 -/* f09810c: afbf004c */ sw $ra,0x4c($sp) -/* f098110: afb40048 */ sw $s4,0x48($sp) -/* f098114: afb30044 */ sw $s3,0x44($sp) -/* f098118: afb20040 */ sw $s2,0x40($sp) -/* f09811c: afb1003c */ sw $s1,0x3c($sp) -/* f098120: afb00038 */ sw $s0,0x38($sp) -/* f098124: f7b40030 */ sdc1 $f20,0x30($sp) -/* f098128: afa50164 */ sw $a1,0x164($sp) -/* f09812c: 908e0690 */ lbu $t6,0x690($a0) -/* f098130: 8c98068c */ lw $t8,0x68c($a0) -/* f098134: 24010002 */ li $at,0x2 -/* f098138: 31cfffe3 */ andi $t7,$t6,0xffe3 -/* f09813c: 00809025 */ move $s2,$a0 -/* f098140: 1701000f */ bne $t8,$at,.PF0f098180 -/* f098144: a08f0690 */ sb $t7,0x690($a0) -/* f098148: 0fc2601f */ jal bgun0f09815c -/* f09814c: 00000000 */ nop -/* f098150: 46000506 */ mov.s $f20,$f0 -/* f098154: 0c0073fa */ jal modelGetNumAnimFrames -/* f098158: 26440384 */ addiu $a0,$s2,0x384 -/* f09815c: 2459ffff */ addiu $t9,$v0,-1 -/* f098160: 44992000 */ mtc1 $t9,$f4 -/* f098164: 00000000 */ nop -/* f098168: 468021a0 */ cvt.s.w $f6,$f4 -/* f09816c: 4614303e */ c.le.s $f6,$f20 -/* f098170: 00000000 */ nop -/* f098174: 45020003 */ bc1fl .PF0f098184 -/* f098178: 8e480680 */ lw $t0,0x680($s2) -/* f09817c: ae40068c */ sw $zero,0x68c($s2) -.PF0f098180: -/* f098180: 8e480680 */ lw $t0,0x680($s2) -.PF0f098184: -/* f098184: 8e49068c */ lw $t1,0x68c($s2) -/* f098188: 29020000 */ slti $v0,$t0,0x0 -/* f09818c: 392a0002 */ xori $t2,$t1,0x2 -/* f098190: 2d4a0001 */ sltiu $t2,$t2,0x1 -/* f098194: 38420001 */ xori $v0,$v0,0x1 -/* f098198: 01425825 */ or $t3,$t2,$v0 -/* f09819c: 516001d2 */ beqzl $t3,.PF0f0988e8 -/* f0981a0: 8fbf004c */ lw $ra,0x4c($sp) -/* f0981a4: 44801000 */ mtc1 $zero,$f2 -/* f0981a8: c64806d0 */ lwc1 $f8,0x6d0($s2) -/* f0981ac: 26540384 */ addiu $s4,$s2,0x384 -/* f0981b0: 4608103c */ c.lt.s $f2,$f8 -/* f0981b4: 00000000 */ nop -/* f0981b8: 45000006 */ bc1f .PF0f0981d4 -/* f0981bc: 00000000 */ nop -/* f0981c0: 8e480680 */ lw $t0,0x680($s2) -/* f0981c4: ae400684 */ sw $zero,0x684($s2) -/* f0981c8: e6420688 */ swc1 $f2,0x688($s2) -/* f0981cc: 29020000 */ slti $v0,$t0,0x0 -/* f0981d0: 38420001 */ xori $v0,$v0,0x1 -.PF0f0981d4: -/* f0981d4: 5040005a */ beqzl $v0,.PF0f098340 -/* f0981d8: 8e4d0690 */ lw $t5,0x690($s2) -/* f0981dc: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f0981e0: 3c013f80 */ lui $at,0x3f80 -/* f0981e4: 924d06d6 */ lbu $t5,0x6d6($s2) -/* f0981e8: 8c6c0004 */ lw $t4,0x4($v1) -/* f0981ec: 44810000 */ mtc1 $at,$f0 -/* f0981f0: 3c017f1b */ lui $at,0x7f1b -/* f0981f4: 448c5000 */ mtc1 $t4,$f10 -/* f0981f8: c432d398 */ lwc1 $f18,-0x2c68($at) -/* f0981fc: 31ae0001 */ andi $t6,$t5,0x1 -/* f098200: 46805420 */ cvt.s.w $f16,$f10 -/* f098204: 3c0f800a */ lui $t7,0x800a -/* f098208: 11c0001a */ beqz $t6,.PF0f098274 -/* f09820c: 46128503 */ div.s $f20,$f16,$f18 -/* f098210: 8defa794 */ lw $t7,-0x586c($t7) -/* f098214: 81f80de4 */ lb $t8,0xde4($t7) -/* f098218: 13000016 */ beqz $t8,.PF0f098274 -/* f09821c: 00000000 */ nop -/* f098220: 0c004ad4 */ jal random -/* f098224: 00000000 */ nop -/* f098228: 44822000 */ mtc1 $v0,$f4 -/* f09822c: 3c014f80 */ lui $at,0x4f80 -/* f098230: 04410004 */ bgez $v0,.PF0f098244 -/* f098234: 468021a0 */ cvt.s.w $f6,$f4 -/* f098238: 44814000 */ mtc1 $at,$f8 -/* f09823c: 00000000 */ nop -/* f098240: 46083180 */ add.s $f6,$f6,$f8 -.PF0f098244: -/* f098244: 3c012f80 */ lui $at,0x2f80 -/* f098248: 44815000 */ mtc1 $at,$f10 -/* f09824c: 3c017f1b */ lui $at,0x7f1b -/* f098250: c432d39c */ lwc1 $f18,-0x2c64($at) -/* f098254: 460a3402 */ mul.s $f16,$f6,$f10 -/* f098258: 3c017f1b */ lui $at,0x7f1b -/* f09825c: c428d3a0 */ lwc1 $f8,-0x2c60($at) -/* f098260: 44801000 */ mtc1 $zero,$f2 -/* f098264: 8e480680 */ lw $t0,0x680($s2) -/* f098268: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f09826c: 46128102 */ mul.s $f4,$f16,$f18 -/* f098270: 46082000 */ add.s $f0,$f4,$f8 -.PF0f098274: -/* f098274: 10600018 */ beqz $v1,.PF0f0982d8 -/* f098278: 02802025 */ move $a0,$s4 -/* f09827c: 4602a03c */ c.lt.s $f20,$f2 -/* f098280: 00082c00 */ sll $a1,$t0,0x10 -/* f098284: 0005cc03 */ sra $t9,$a1,0x10 -/* f098288: 45000013 */ bc1f .PF0f0982d8 -/* f09828c: 00000000 */ nop -/* f098290: 46140182 */ mul.s $f6,$f0,$f20 -/* f098294: 44071000 */ mfc1 $a3,$f2 -/* f098298: 02802025 */ move $a0,$s4 -/* f09829c: 03202825 */ move $a1,$t9 -/* f0982a0: 00003025 */ move $a2,$zero -/* f0982a4: e7a20014 */ swc1 $f2,0x14($sp) -/* f0982a8: 0c0076a7 */ jal modelSetAnimation -/* f0982ac: e7a60010 */ swc1 $f6,0x10($sp) -/* f0982b0: 0c0073fa */ jal modelGetNumAnimFrames -/* f0982b4: 02802025 */ move $a0,$s4 -/* f0982b8: 44825000 */ mtc1 $v0,$f10 -/* f0982bc: 02802025 */ move $a0,$s4 -/* f0982c0: 468052a0 */ cvt.s.w $f10,$f10 -/* f0982c4: 44055000 */ mfc1 $a1,$f10 -/* f0982c8: 0c00777a */ jal model0001e018 -/* f0982cc: 00000000 */ nop -/* f0982d0: 1000000b */ b .PF0f098300 -/* f0982d4: 240affff */ li $t2,-1 -.PF0f0982d8: -/* f0982d8: 46140402 */ mul.s $f16,$f0,$f20 -/* f0982dc: 00082c00 */ sll $a1,$t0,0x10 -/* f0982e0: 00054c03 */ sra $t1,$a1,0x10 -/* f0982e4: 44071000 */ mfc1 $a3,$f2 -/* f0982e8: 01202825 */ move $a1,$t1 -/* f0982ec: 00003025 */ move $a2,$zero -/* f0982f0: e7a20014 */ swc1 $f2,0x14($sp) -/* f0982f4: 0c0076a7 */ jal modelSetAnimation -/* f0982f8: e7b00010 */ swc1 $f16,0x10($sp) -/* f0982fc: 240affff */ li $t2,-1 -.PF0f098300: -/* f098300: 240b0002 */ li $t3,0x2 -/* f098304: ae4a0680 */ sw $t2,0x680($s2) -/* f098308: ae4b068c */ sw $t3,0x68c($s2) -/* f09830c: 0c007416 */ jal modelGetAbsAnimSpeed -/* f098310: 02802025 */ move $a0,$s4 -/* f098314: 8e4c0684 */ lw $t4,0x684($s2) -/* f098318: 3c017f1b */ lui $at,0x7f1b -/* f09831c: c428d3a4 */ lwc1 $f8,-0x2c5c($at) -/* f098320: 448c9000 */ mtc1 $t4,$f18 -/* f098324: 44801000 */ mtc1 $zero,$f2 -/* f098328: 46809120 */ cvt.s.w $f4,$f18 -/* f09832c: 46082182 */ mul.s $f6,$f4,$f8 -/* f098330: 00000000 */ nop -/* f098334: 46060282 */ mul.s $f10,$f0,$f6 -/* f098338: e64a0688 */ swc1 $f10,0x688($s2) -/* f09833c: 8e4d0690 */ lw $t5,0x690($s2) -.PF0f098340: -/* f098340: 000d7840 */ sll $t7,$t5,0x1 -/* f098344: 05e10003 */ bgez $t7,.PF0f098354 -/* f098348: 00000000 */ nop -/* f09834c: ae400684 */ sw $zero,0x684($s2) -/* f098350: e6420688 */ swc1 $f2,0x688($s2) -.PF0f098354: -/* f098354: 0fc2601f */ jal bgun0f09815c -/* f098358: 02402025 */ move $a0,$s2 -/* f09835c: 44809000 */ mtc1 $zero,$f18 -/* f098360: c6500688 */ lwc1 $f16,0x688($s2) -/* f098364: 46000506 */ mov.s $f20,$f0 -/* f098368: 46120032 */ c.eq.s $f0,$f18 -/* f09836c: 46008380 */ add.s $f14,$f16,$f0 -/* f098370: 4502000b */ bc1fl .PF0f0983a0 -/* f098374: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f098378: 44802000 */ mtc1 $zero,$f4 -/* f09837c: 3c013f80 */ lui $at,0x3f80 -/* f098380: 460e203c */ c.lt.s $f4,$f14 -/* f098384: 00000000 */ nop -/* f098388: 45020005 */ bc1fl .PF0f0983a0 -/* f09838c: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f098390: 44814000 */ mtc1 $at,$f8 -/* f098394: 00000000 */ nop -/* f098398: 46080501 */ sub.s $f20,$f0,$f8 -/* f09839c: 8e4306b0 */ lw $v1,0x6b0($s2) -.PF0f0983a0: -/* f0983a0: 106000d8 */ beqz $v1,.PF0f098704 -/* f0983a4: 00608825 */ move $s1,$v1 -/* f0983a8: 106000d6 */ beqz $v1,.PF0f098704 -/* f0983ac: afa0014c */ sw $zero,0x14c($sp) -/* f0983b0: 00008025 */ move $s0,$zero -/* f0983b4: 24130001 */ li $s3,0x1 -/* f0983b8: 92230000 */ lbu $v1,0x0($s1) -.PF0f0983bc: -/* f0983bc: 14600003 */ bnez $v1,.PF0f0983cc -/* f0983c0: 00000000 */ nop -/* f0983c4: 100000b6 */ b .PF0f0986a0 -/* f0983c8: afb3014c */ sw $s3,0x14c($sp) -.PF0f0983cc: -/* f0983cc: 12630003 */ beq $s3,$v1,.PF0f0983dc -/* f0983d0: 24010002 */ li $at,0x2 -/* f0983d4: 54610036 */ bnel $v1,$at,.PF0f0984b0 -/* f0983d8: 24010003 */ li $at,0x3 -.PF0f0983dc: -/* f0983dc: 96260002 */ lhu $a2,0x2($s1) -/* f0983e0: 3c014f80 */ lui $at,0x4f80 -/* f0983e4: 2405ffff */ li $a1,-1 -/* f0983e8: 44863000 */ mtc1 $a2,$f6 -/* f0983ec: 27ab0094 */ addiu $t3,$sp,0x94 -/* f0983f0: 04c10004 */ bgez $a2,.PF0f098404 -/* f0983f4: 468032a0 */ cvt.s.w $f10,$f6 -/* f0983f8: 44818000 */ mtc1 $at,$f16 -/* f0983fc: 00000000 */ nop -/* f098400: 46105280 */ add.s $f10,$f10,$f16 -.PF0f098404: -/* f098404: 460e503e */ c.le.s $f10,$f14 -/* f098408: 2401ffff */ li $at,-1 -/* f09840c: 450200a5 */ bc1fl .PF0f0986a4 -/* f098410: 8fac014c */ lw $t4,0x14c($sp) -/* f098414: 1a00000a */ blez $s0,.PF0f098440 -/* f098418: 00001025 */ move $v0,$zero -/* f09841c: 8e240004 */ lw $a0,0x4($s1) -/* f098420: 27a3010c */ addiu $v1,$sp,0x10c -.PF0f098424: -/* f098424: 8c780000 */ lw $t8,0x0($v1) -/* f098428: 54980003 */ bnel $a0,$t8,.PF0f098438 -/* f09842c: 24420001 */ addiu $v0,$v0,0x1 -/* f098430: 00402825 */ move $a1,$v0 -/* f098434: 24420001 */ addiu $v0,$v0,0x1 -.PF0f098438: -/* f098438: 1450fffa */ bne $v0,$s0,.PF0f098424 -/* f09843c: 24630004 */ addiu $v1,$v1,0x4 -.PF0f098440: -/* f098440: 14a1000a */ bne $a1,$at,.PF0f09846c -/* f098444: 2409ffff */ li $t1,-1 -/* f098448: 8e240004 */ lw $a0,0x4($s1) -/* f09844c: 02002825 */ move $a1,$s0 -/* f098450: 00051080 */ sll $v0,$a1,0x2 -/* f098454: 03a2c821 */ addu $t9,$sp,$v0 -/* f098458: 03a25021 */ addu $t2,$sp,$v0 -/* f09845c: af24010c */ sw $a0,0x10c($t9) -/* f098460: ad490094 */ sw $t1,0x94($t2) -/* f098464: 26100001 */ addiu $s0,$s0,0x1 -/* f098468: 96260002 */ lhu $a2,0x2($s1) -.PF0f09846c: -/* f09846c: 00051080 */ sll $v0,$a1,0x2 -/* f098470: 004b1821 */ addu $v1,$v0,$t3 -/* f098474: 8c6c0000 */ lw $t4,0x0($v1) -/* f098478: 0186082a */ slt $at,$t4,$a2 -/* f09847c: 50200089 */ beqzl $at,.PF0f0986a4 -/* f098480: 8fac014c */ lw $t4,0x14c($sp) -/* f098484: ac660000 */ sw $a2,0x0($v1) -/* f098488: 922d0000 */ lbu $t5,0x0($s1) -/* f09848c: 03a27821 */ addu $t7,$sp,$v0 -/* f098490: 03a27021 */ addu $t6,$sp,$v0 -/* f098494: 166d0003 */ bne $s3,$t5,.PF0f0984a4 -/* f098498: 00000000 */ nop -/* f09849c: 10000080 */ b .PF0f0986a0 -/* f0984a0: add300d0 */ sw $s3,0xd0($t6) -.PF0f0984a4: -/* f0984a4: 1000007e */ b .PF0f0986a0 -/* f0984a8: ade000d0 */ sw $zero,0xd0($t7) -/* f0984ac: 24010003 */ li $at,0x3 -.PF0f0984b0: -/* f0984b0: 10610005 */ beq $v1,$at,.PF0f0984c8 -/* f0984b4: 24010008 */ li $at,0x8 -/* f0984b8: 50610049 */ beql $v1,$at,.PF0f0985e0 -/* f0984bc: 8e4e0690 */ lw $t6,0x690($s2) -/* f0984c0: 10000078 */ b .PF0f0986a4 -/* f0984c4: 8fac014c */ lw $t4,0x14c($sp) -.PF0f0984c8: -/* f0984c8: 8e580690 */ lw $t8,0x690($s2) -/* f0984cc: 0018cfc2 */ srl $t9,$t8,0x1f -/* f0984d0: 53200074 */ beqzl $t9,.PF0f0986a4 -/* f0984d4: 8fac014c */ lw $t4,0x14c($sp) -/* f0984d8: 96290002 */ lhu $t1,0x2($s1) -/* f0984dc: 3c014f80 */ lui $at,0x4f80 -/* f0984e0: 44899000 */ mtc1 $t1,$f18 -/* f0984e4: 05210004 */ bgez $t1,.PF0f0984f8 -/* f0984e8: 468090a0 */ cvt.s.w $f2,$f18 -/* f0984ec: 44812000 */ mtc1 $at,$f4 -/* f0984f0: 00000000 */ nop -/* f0984f4: 46041080 */ add.s $f2,$f2,$f4 -.PF0f0984f8: -/* f0984f8: 460e103e */ c.le.s $f2,$f14 -/* f0984fc: 00000000 */ nop -/* f098500: 45020068 */ bc1fl .PF0f0986a4 -/* f098504: 8fac014c */ lw $t4,0x14c($sp) -/* f098508: 4602a03c */ c.lt.s $f20,$f2 -/* f09850c: 00000000 */ nop -/* f098510: 45020064 */ bc1fl .PF0f0986a4 -/* f098514: 8fac014c */ lw $t4,0x14c($sp) -/* f098518: 460ea03c */ c.lt.s $f20,$f14 -/* f09851c: 00000000 */ nop -/* f098520: 45020060 */ bc1fl .PF0f0986a4 -/* f098524: 8fac014c */ lw $t4,0x14c($sp) -/* f098528: 0fc2601f */ jal bgun0f09815c -/* f09852c: 02402025 */ move $a0,$s2 -/* f098530: 962a0002 */ lhu $t2,0x2($s1) -/* f098534: 3c014f80 */ lui $at,0x4f80 -/* f098538: 02802025 */ move $a0,$s4 -/* f09853c: 448a4000 */ mtc1 $t2,$f8 -/* f098540: 05410004 */ bgez $t2,.PF0f098554 -/* f098544: 468041a0 */ cvt.s.w $f6,$f8 -/* f098548: 44818000 */ mtc1 $at,$f16 -/* f09854c: 00000000 */ nop -/* f098550: 46103180 */ add.s $f6,$f6,$f16 -.PF0f098554: -/* f098554: 46003081 */ sub.s $f2,$f6,$f0 -/* f098558: 3c014000 */ lui $at,0x4000 -/* f09855c: 44815000 */ mtc1 $at,$f10 -/* f098560: c64c0688 */ lwc1 $f12,0x688($s2) -/* f098564: 460a1083 */ div.s $f2,$f2,$f10 -/* f098568: 460c103c */ c.lt.s $f2,$f12 -/* f09856c: 00000000 */ nop -/* f098570: 45000018 */ bc1f .PF0f0985d4 -/* f098574: 00000000 */ nop -/* f098578: 0c007416 */ jal modelGetAbsAnimSpeed -/* f09857c: e7a20084 */ swc1 $f2,0x84($sp) -/* f098580: 3c017f1b */ lui $at,0x7f1b -/* f098584: c432d3a8 */ lwc1 $f18,-0x2c58($at) -/* f098588: c7a20084 */ lwc1 $f2,0x84($sp) -/* f09858c: 02802025 */ move $a0,$s4 -/* f098590: 46121102 */ mul.s $f4,$f2,$f18 -/* f098594: 46002203 */ div.s $f8,$f4,$f0 -/* f098598: 4600440d */ trunc.w.s $f16,$f8 -/* f09859c: 440c8000 */ mfc1 $t4,$f16 -/* f0985a0: 0c007416 */ jal modelGetAbsAnimSpeed -/* f0985a4: ae4c0684 */ sw $t4,0x684($s2) -/* f0985a8: 8e4d0684 */ lw $t5,0x684($s2) -/* f0985ac: 3c017f1b */ lui $at,0x7f1b -/* f0985b0: c432d3ac */ lwc1 $f18,-0x2c54($at) -/* f0985b4: 448d3000 */ mtc1 $t5,$f6 -/* f0985b8: 00000000 */ nop -/* f0985bc: 468032a0 */ cvt.s.w $f10,$f6 -/* f0985c0: 46125102 */ mul.s $f4,$f10,$f18 -/* f0985c4: 00000000 */ nop -/* f0985c8: 46040202 */ mul.s $f8,$f0,$f4 -/* f0985cc: e6480688 */ swc1 $f8,0x688($s2) -/* f0985d0: c64c0688 */ lwc1 $f12,0x688($s2) -.PF0f0985d4: -/* f0985d4: 10000032 */ b .PF0f0986a0 -/* f0985d8: 46146380 */ add.s $f14,$f12,$f20 -/* f0985dc: 8e4e0690 */ lw $t6,0x690($s2) -.PF0f0985e0: -/* f0985e0: 000ec080 */ sll $t8,$t6,0x2 -/* f0985e4: 0703002f */ bgezl $t8,.PF0f0986a4 -/* f0985e8: 8fac014c */ lw $t4,0x14c($sp) -/* f0985ec: 96260002 */ lhu $a2,0x2($s1) -/* f0985f0: 3c014f80 */ lui $at,0x4f80 -/* f0985f4: 44868000 */ mtc1 $a2,$f16 -/* f0985f8: 04c10004 */ bgez $a2,.PF0f09860c -/* f0985fc: 468080a0 */ cvt.s.w $f2,$f16 -/* f098600: 44813000 */ mtc1 $at,$f6 -/* f098604: 00000000 */ nop -/* f098608: 46061080 */ add.s $f2,$f2,$f6 -.PF0f09860c: -/* f09860c: 460e103e */ c.le.s $f2,$f14 -/* f098610: 00000000 */ nop -/* f098614: 45020023 */ bc1fl .PF0f0986a4 -/* f098618: 8fac014c */ lw $t4,0x14c($sp) -/* f09861c: 4602a03c */ c.lt.s $f20,$f2 -/* f098620: 00000000 */ nop -/* f098624: 4502001f */ bc1fl .PF0f0986a4 -/* f098628: 8fac014c */ lw $t4,0x14c($sp) -/* f09862c: 460ea03c */ c.lt.s $f20,$f14 -/* f098630: 02802025 */ move $a0,$s4 -/* f098634: 4502001b */ bc1fl .PF0f0986a4 -/* f098638: 8fac014c */ lw $t4,0x14c($sp) -/* f09863c: 460e103e */ c.le.s $f2,$f14 -/* f098640: 44809000 */ mtc1 $zero,$f18 -/* f098644: 46007006 */ mov.s $f0,$f14 -/* f098648: 4502000c */ bc1fl .PF0f09867c -/* f09864c: ae400684 */ sw $zero,0x684($s2) -/* f098650: 8e390004 */ lw $t9,0x4($s1) -/* f098654: 03264823 */ subu $t1,$t9,$a2 -/* f098658: 44895000 */ mtc1 $t1,$f10 -/* f09865c: 00000000 */ nop -/* f098660: 46805320 */ cvt.s.w $f12,$f10 -/* f098664: 460c0000 */ add.s $f0,$f0,$f12 -.PF0f098668: -/* f098668: 4600103e */ c.le.s $f2,$f0 -/* f09866c: 00000000 */ nop -/* f098670: 4503fffd */ bc1tl .PF0f098668 -/* f098674: 460c0000 */ add.s $f0,$f0,$f12 -/* f098678: ae400684 */ sw $zero,0x684($s2) -.PF0f09867c: -/* f09867c: e6520688 */ swc1 $f18,0x688($s2) -/* f098680: 44050000 */ mfc1 $a1,$f0 -/* f098684: 46000506 */ mov.s $f20,$f0 -/* f098688: 0c00777a */ jal model0001e018 -/* f09868c: e7a00080 */ swc1 $f0,0x80($sp) -/* f098690: 924a0691 */ lbu $t2,0x691($s2) -/* f098694: c7ae0080 */ lwc1 $f14,0x80($sp) -/* f098698: 254b0001 */ addiu $t3,$t2,0x1 -/* f09869c: a24b0691 */ sb $t3,0x691($s2) -.PF0f0986a0: -/* f0986a0: 8fac014c */ lw $t4,0x14c($sp) -.PF0f0986a4: -/* f0986a4: 26310008 */ addiu $s1,$s1,0x8 -/* f0986a8: 5180ff44 */ beqzl $t4,.PF0f0983bc -/* f0986ac: 92230000 */ lbu $v1,0x0($s1) -/* f0986b0: 5a000015 */ blezl $s0,.PF0f098708 -/* f0986b4: 3c054099 */ lui $a1,0x4099 -/* f0986b8: 1a000012 */ blez $s0,.PF0f098704 -/* f0986bc: 00001025 */ move $v0,$zero -/* f0986c0: 27a3010c */ addiu $v1,$sp,0x10c -/* f0986c4: 27a800d0 */ addiu $t0,$sp,0xd0 -.PF0f0986c8: -/* f0986c8: 84640002 */ lh $a0,0x2($v1) -/* f0986cc: 8d050000 */ lw $a1,0x0($t0) -/* f0986d0: afa80058 */ sw $t0,0x58($sp) -/* f0986d4: afa3005c */ sw $v1,0x5c($sp) -/* f0986d8: afa2007c */ sw $v0,0x7c($sp) -/* f0986dc: 02403025 */ move $a2,$s2 -/* f0986e0: 0fc25f65 */ jal bgunSetPartVisible -/* f0986e4: 8fa70164 */ lw $a3,0x164($sp) -/* f0986e8: 8fa2007c */ lw $v0,0x7c($sp) -/* f0986ec: 8fa3005c */ lw $v1,0x5c($sp) -/* f0986f0: 8fa80058 */ lw $t0,0x58($sp) -/* f0986f4: 24420001 */ addiu $v0,$v0,0x1 -/* f0986f8: 24630004 */ addiu $v1,$v1,0x4 -/* f0986fc: 1450fff2 */ bne $v0,$s0,.PF0f0986c8 -/* f098700: 25080004 */ addiu $t0,$t0,0x4 -.PF0f098704: -/* f098704: 3c054099 */ lui $a1,0x4099 -.PF0f098708: -/* f098708: 34a5999a */ ori $a1,$a1,0x999a -/* f09870c: 02802025 */ move $a0,$s4 -/* f098710: 0c00775f */ jal modelSetAnimPlaySpeed -/* f098714: 24060000 */ li $a2,0x0 -/* f098718: 02802025 */ move $a0,$s4 -/* f09871c: 8e450684 */ lw $a1,0x684($s2) -/* f098720: 0c007afa */ jal model0001ee18 -/* f098724: 24060001 */ li $a2,0x1 -/* f098728: 0fc2601f */ jal bgun0f09815c -/* f09872c: 02402025 */ move $a0,$s2 -/* f098730: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f098734: 46000386 */ mov.s $f14,$f0 -/* f098738: 00004025 */ move $t0,$zero -/* f09873c: 10600069 */ beqz $v1,.PF0f0988e4 -/* f098740: 00608025 */ move $s0,$v1 -/* f098744: 3c013f80 */ lui $at,0x3f80 -/* f098748: 44812000 */ mtc1 $at,$f4 -/* f09874c: 00008825 */ move $s1,$zero -/* f098750: 10600064 */ beqz $v1,.PF0f0988e4 -/* f098754: e7a40070 */ swc1 $f4,0x70($sp) -/* f098758: 24140009 */ li $s4,0x9 -/* f09875c: 24130005 */ li $s3,0x5 -.PF0f098760: -/* f098760: 92030000 */ lbu $v1,0x0($s0) -/* f098764: 54600004 */ bnezl $v1,.PF0f098778 -/* f098768: 960d0002 */ lhu $t5,0x2($s0) -/* f09876c: 1000005b */ b .PF0f0988dc -/* f098770: 24080001 */ li $t0,0x1 -/* f098774: 960d0002 */ lhu $t5,0x2($s0) -.PF0f098778: -/* f098778: 3c014f80 */ lui $at,0x4f80 -/* f09877c: 448d4000 */ mtc1 $t5,$f8 -/* f098780: 05a10004 */ bgez $t5,.PF0f098794 -/* f098784: 46804020 */ cvt.s.w $f0,$f8 -/* f098788: 44818000 */ mtc1 $at,$f16 -/* f09878c: 00000000 */ nop -/* f098790: 46100000 */ add.s $f0,$f0,$f16 -.PF0f098794: -/* f098794: 460e003e */ c.le.s $f0,$f14 -/* f098798: 00000000 */ nop -/* f09879c: 4500004f */ bc1f .PF0f0988dc -/* f0987a0: 00000000 */ nop -/* f0987a4: 4600a03c */ c.lt.s $f20,$f0 -/* f0987a8: 00000000 */ nop -/* f0987ac: 4500004b */ bc1f .PF0f0988dc -/* f0987b0: 00000000 */ nop -/* f0987b4: 460ea03c */ c.lt.s $f20,$f14 -/* f0987b8: 00000000 */ nop -/* f0987bc: 45000047 */ bc1f .PF0f0988dc -/* f0987c0: 00000000 */ nop -/* f0987c4: 10730007 */ beq $v1,$s3,.PF0f0987e4 -/* f0987c8: 00000000 */ nop -/* f0987cc: 10740039 */ beq $v1,$s4,.PF0f0988b4 -/* f0987d0: 2401000b */ li $at,0xb -/* f0987d4: 5061002f */ beql $v1,$at,.PF0f098894 -/* f0987d8: 8e0d0004 */ lw $t5,0x4($s0) -/* f0987dc: 1000003f */ b .PF0f0988dc -/* f0987e0: 00000000 */ nop -.PF0f0987e4: -/* f0987e4: 12200016 */ beqz $s1,.PF0f098840 -/* f0987e8: 00002025 */ move $a0,$zero -/* f0987ec: 8e0e0004 */ lw $t6,0x4($s0) -/* f0987f0: c7a60070 */ lwc1 $f6,0x70($sp) -/* f0987f4: 240f0001 */ li $t7,0x1 -/* f0987f8: 2418ffff */ li $t8,-1 -/* f0987fc: 24190001 */ li $t9,0x1 -/* f098800: afb90020 */ sw $t9,0x20($sp) -/* f098804: afb8001c */ sw $t8,0x1c($sp) -/* f098808: afaf0018 */ sw $t7,0x18($sp) -/* f09880c: e7ae0158 */ swc1 $f14,0x158($sp) -/* f098810: afa80078 */ sw $t0,0x78($sp) -/* f098814: 00002025 */ move $a0,$zero -/* f098818: 00002825 */ move $a1,$zero -/* f09881c: 24067fff */ li $a2,0x7fff -/* f098820: 24070040 */ li $a3,0x40 -/* f098824: 00008825 */ move $s1,$zero -/* f098828: afae0010 */ sw $t6,0x10($sp) -/* f09882c: 0c004125 */ jal snd00010718 -/* f098830: e7a60014 */ swc1 $f6,0x14($sp) -/* f098834: 8fa80078 */ lw $t0,0x78($sp) -/* f098838: 10000028 */ b .PF0f0988dc -/* f09883c: c7ae0158 */ lwc1 $f14,0x158($sp) -.PF0f098840: -/* f098840: 8e090004 */ lw $t1,0x4($s0) -/* f098844: 3c013f80 */ lui $at,0x3f80 -/* f098848: 44815000 */ mtc1 $at,$f10 -/* f09884c: 240a0001 */ li $t2,0x1 -/* f098850: 240bffff */ li $t3,-1 -/* f098854: 240c0001 */ li $t4,0x1 -/* f098858: afac0020 */ sw $t4,0x20($sp) -/* f09885c: afab001c */ sw $t3,0x1c($sp) -/* f098860: afaa0018 */ sw $t2,0x18($sp) -/* f098864: e7ae0158 */ swc1 $f14,0x158($sp) -/* f098868: afa80078 */ sw $t0,0x78($sp) -/* f09886c: 00002825 */ move $a1,$zero -/* f098870: 24067fff */ li $a2,0x7fff -/* f098874: 24070040 */ li $a3,0x40 -/* f098878: afa90010 */ sw $t1,0x10($sp) -/* f09887c: 0c004125 */ jal snd00010718 -/* f098880: e7aa0014 */ swc1 $f10,0x14($sp) -/* f098884: 8fa80078 */ lw $t0,0x78($sp) -/* f098888: 10000014 */ b .PF0f0988dc -/* f09888c: c7ae0158 */ lwc1 $f14,0x158($sp) -/* f098890: 8e0d0004 */ lw $t5,0x4($s0) -.PF0f098894: -/* f098894: 3c01447a */ lui $at,0x447a -/* f098898: 44814000 */ mtc1 $at,$f8 -/* f09889c: 448d9000 */ mtc1 $t5,$f18 -/* f0988a0: 24110001 */ li $s1,0x1 -/* f0988a4: 46809120 */ cvt.s.w $f4,$f18 -/* f0988a8: 46082403 */ div.s $f16,$f4,$f8 -/* f0988ac: 1000000b */ b .PF0f0988dc -/* f0988b0: e7b00070 */ swc1 $f16,0x70($sp) -.PF0f0988b4: -/* f0988b4: 8e4e0690 */ lw $t6,0x690($s2) -/* f0988b8: 924b0690 */ lbu $t3,0x690($s2) -/* f0988bc: 000e78c0 */ sll $t7,$t6,0x3 -/* f0988c0: 000fc742 */ srl $t8,$t7,0x1d -/* f0988c4: 27190001 */ addiu $t9,$t8,0x1 -/* f0988c8: 00194880 */ sll $t1,$t9,0x2 -/* f0988cc: 312a001c */ andi $t2,$t1,0x1c -/* f0988d0: 316cffe3 */ andi $t4,$t3,0xffe3 -/* f0988d4: 014c6825 */ or $t5,$t2,$t4 -/* f0988d8: a24d0690 */ sb $t5,0x690($s2) -.PF0f0988dc: -/* f0988dc: 1100ffa0 */ beqz $t0,.PF0f098760 -/* f0988e0: 26100008 */ addiu $s0,$s0,0x8 -.PF0f0988e4: -/* f0988e4: 8fbf004c */ lw $ra,0x4c($sp) -.PF0f0988e8: -/* f0988e8: d7b40030 */ ldc1 $f20,0x30($sp) -/* f0988ec: 8fb00038 */ lw $s0,0x38($sp) -/* f0988f0: 8fb1003c */ lw $s1,0x3c($sp) -/* f0988f4: 8fb20040 */ lw $s2,0x40($sp) -/* f0988f8: 8fb30044 */ lw $s3,0x44($sp) -/* f0988fc: 8fb40048 */ lw $s4,0x48($sp) -/* f098900: 03e00008 */ jr $ra -/* f098904: 27bd0160 */ addiu $sp,$sp,0x160 -); -#elif VERSION >= VERSION_PAL_BETA -GLOBAL_ASM( -glabel bgun0f0981e8 -.late_rodata -glabel var7f1ad398pf -.word 0x461c4000 -glabel var7f1ad39cpf -.word 0x3f451eb8 -glabel var7f1ad3a0pf -.word 0x3f333333 -glabel var7f1ad3a4pf -.word 0x3f99999a -glabel var7f1ad3a8pf -.word 0x3f555555 -glabel var7f1ad3acpf -.word 0x3f99999a -.text -/* f098058: 27bdfea0 */ addiu $sp,$sp,-352 -/* f09805c: afbf004c */ sw $ra,0x4c($sp) -/* f098060: afb40048 */ sw $s4,0x48($sp) -/* f098064: afb30044 */ sw $s3,0x44($sp) -/* f098068: afb20040 */ sw $s2,0x40($sp) -/* f09806c: afb1003c */ sw $s1,0x3c($sp) -/* f098070: afb00038 */ sw $s0,0x38($sp) -/* f098074: f7b40030 */ sdc1 $f20,0x30($sp) -/* f098078: afa50164 */ sw $a1,0x164($sp) -/* f09807c: 908e0690 */ lbu $t6,0x690($a0) -/* f098080: 8c98068c */ lw $t8,0x68c($a0) -/* f098084: 24010002 */ li $at,0x2 -/* f098088: 31cfffe3 */ andi $t7,$t6,0xffe3 -/* f09808c: 00809025 */ move $s2,$a0 -/* f098090: 1701000f */ bne $t8,$at,.PB0f0980d0 -/* f098094: a08f0690 */ sb $t7,0x690($a0) -/* f098098: 0fc25ff3 */ jal bgun0f09815c -/* f09809c: 00000000 */ nop -/* f0980a0: 46000506 */ mov.s $f20,$f0 -/* f0980a4: 0c00772a */ jal modelGetNumAnimFrames -/* f0980a8: 26440384 */ addiu $a0,$s2,0x384 -/* f0980ac: 2459ffff */ addiu $t9,$v0,-1 -/* f0980b0: 44992000 */ mtc1 $t9,$f4 -/* f0980b4: 00000000 */ nop -/* f0980b8: 468021a0 */ cvt.s.w $f6,$f4 -/* f0980bc: 4614303e */ c.le.s $f6,$f20 -/* f0980c0: 00000000 */ nop -/* f0980c4: 45020003 */ bc1fl .PB0f0980d4 -/* f0980c8: 8e480680 */ lw $t0,0x680($s2) -/* f0980cc: ae40068c */ sw $zero,0x68c($s2) -.PB0f0980d0: -/* f0980d0: 8e480680 */ lw $t0,0x680($s2) -.PB0f0980d4: -/* f0980d4: 8e49068c */ lw $t1,0x68c($s2) -/* f0980d8: 29020000 */ slti $v0,$t0,0x0 -/* f0980dc: 392a0002 */ xori $t2,$t1,0x2 -/* f0980e0: 2d4a0001 */ sltiu $t2,$t2,0x1 -/* f0980e4: 38420001 */ xori $v0,$v0,0x1 -/* f0980e8: 01425825 */ or $t3,$t2,$v0 -/* f0980ec: 516001d2 */ beqzl $t3,.PB0f098838 -/* f0980f0: 8fbf004c */ lw $ra,0x4c($sp) -/* f0980f4: 44801000 */ mtc1 $zero,$f2 -/* f0980f8: c64806d0 */ lwc1 $f8,0x6d0($s2) -/* f0980fc: 26540384 */ addiu $s4,$s2,0x384 -/* f098100: 4608103c */ c.lt.s $f2,$f8 -/* f098104: 00000000 */ nop -/* f098108: 45000006 */ bc1f .PB0f098124 -/* f09810c: 00000000 */ nop -/* f098110: 8e480680 */ lw $t0,0x680($s2) -/* f098114: ae400684 */ sw $zero,0x684($s2) -/* f098118: e6420688 */ swc1 $f2,0x688($s2) -/* f09811c: 29020000 */ slti $v0,$t0,0x0 -/* f098120: 38420001 */ xori $v0,$v0,0x1 -.PB0f098124: -/* f098124: 5040005a */ beqzl $v0,.PB0f098290 -/* f098128: 8e4d0690 */ lw $t5,0x690($s2) -/* f09812c: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f098130: 3c013f80 */ lui $at,0x3f80 -/* f098134: 924d06d6 */ lbu $t5,0x6d6($s2) -/* f098138: 8c6c0004 */ lw $t4,0x4($v1) -/* f09813c: 44810000 */ mtc1 $at,$f0 -/* f098140: 3c017f1b */ lui $at,0x7f1b -/* f098144: 448c5000 */ mtc1 $t4,$f10 -/* f098148: c432dde8 */ lwc1 $f18,-0x2218($at) -/* f09814c: 31ae0001 */ andi $t6,$t5,0x1 -/* f098150: 46805420 */ cvt.s.w $f16,$f10 -/* f098154: 3c0f800a */ lui $t7,0x800a -/* f098158: 11c0001a */ beqz $t6,.PB0f0981c4 -/* f09815c: 46128503 */ div.s $f20,$f16,$f18 -/* f098160: 8defe754 */ lw $t7,-0x18ac($t7) -/* f098164: 81f80de4 */ lb $t8,0xde4($t7) -/* f098168: 13000016 */ beqz $t8,.PB0f0981c4 -/* f09816c: 00000000 */ nop -/* f098170: 0c004be0 */ jal random -/* f098174: 00000000 */ nop -/* f098178: 44822000 */ mtc1 $v0,$f4 -/* f09817c: 3c014f80 */ lui $at,0x4f80 -/* f098180: 04410004 */ bgez $v0,.PB0f098194 -/* f098184: 468021a0 */ cvt.s.w $f6,$f4 -/* f098188: 44814000 */ mtc1 $at,$f8 -/* f09818c: 00000000 */ nop -/* f098190: 46083180 */ add.s $f6,$f6,$f8 -.PB0f098194: -/* f098194: 3c012f80 */ lui $at,0x2f80 -/* f098198: 44815000 */ mtc1 $at,$f10 -/* f09819c: 3c017f1b */ lui $at,0x7f1b -/* f0981a0: c432ddec */ lwc1 $f18,-0x2214($at) -/* f0981a4: 460a3402 */ mul.s $f16,$f6,$f10 -/* f0981a8: 3c017f1b */ lui $at,0x7f1b -/* f0981ac: c428ddf0 */ lwc1 $f8,-0x2210($at) -/* f0981b0: 44801000 */ mtc1 $zero,$f2 -/* f0981b4: 8e480680 */ lw $t0,0x680($s2) -/* f0981b8: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f0981bc: 46128102 */ mul.s $f4,$f16,$f18 -/* f0981c0: 46082000 */ add.s $f0,$f4,$f8 -.PB0f0981c4: -/* f0981c4: 10600018 */ beqz $v1,.PB0f098228 -/* f0981c8: 02802025 */ move $a0,$s4 -/* f0981cc: 4602a03c */ c.lt.s $f20,$f2 -/* f0981d0: 00082c00 */ sll $a1,$t0,0x10 -/* f0981d4: 0005cc03 */ sra $t9,$a1,0x10 -/* f0981d8: 45000013 */ bc1f .PB0f098228 -/* f0981dc: 00000000 */ nop -/* f0981e0: 46140182 */ mul.s $f6,$f0,$f20 -/* f0981e4: 44071000 */ mfc1 $a3,$f2 -/* f0981e8: 02802025 */ move $a0,$s4 -/* f0981ec: 03202825 */ move $a1,$t9 -/* f0981f0: 00003025 */ move $a2,$zero -/* f0981f4: e7a20014 */ swc1 $f2,0x14($sp) -/* f0981f8: 0c0079d7 */ jal modelSetAnimation -/* f0981fc: e7a60010 */ swc1 $f6,0x10($sp) -/* f098200: 0c00772a */ jal modelGetNumAnimFrames -/* f098204: 02802025 */ move $a0,$s4 -/* f098208: 44825000 */ mtc1 $v0,$f10 -/* f09820c: 02802025 */ move $a0,$s4 -/* f098210: 468052a0 */ cvt.s.w $f10,$f10 -/* f098214: 44055000 */ mfc1 $a1,$f10 -/* f098218: 0c007aaa */ jal model0001e018 -/* f09821c: 00000000 */ nop -/* f098220: 1000000b */ b .PB0f098250 -/* f098224: 240affff */ li $t2,-1 -.PB0f098228: -/* f098228: 46140402 */ mul.s $f16,$f0,$f20 -/* f09822c: 00082c00 */ sll $a1,$t0,0x10 -/* f098230: 00054c03 */ sra $t1,$a1,0x10 -/* f098234: 44071000 */ mfc1 $a3,$f2 -/* f098238: 01202825 */ move $a1,$t1 -/* f09823c: 00003025 */ move $a2,$zero -/* f098240: e7a20014 */ swc1 $f2,0x14($sp) -/* f098244: 0c0079d7 */ jal modelSetAnimation -/* f098248: e7b00010 */ swc1 $f16,0x10($sp) -/* f09824c: 240affff */ li $t2,-1 -.PB0f098250: -/* f098250: 240b0002 */ li $t3,0x2 -/* f098254: ae4a0680 */ sw $t2,0x680($s2) -/* f098258: ae4b068c */ sw $t3,0x68c($s2) -/* f09825c: 0c007746 */ jal modelGetAbsAnimSpeed -/* f098260: 02802025 */ move $a0,$s4 -/* f098264: 8e4c0684 */ lw $t4,0x684($s2) -/* f098268: 3c017f1b */ lui $at,0x7f1b -/* f09826c: c428ddf4 */ lwc1 $f8,-0x220c($at) -/* f098270: 448c9000 */ mtc1 $t4,$f18 -/* f098274: 44801000 */ mtc1 $zero,$f2 -/* f098278: 46809120 */ cvt.s.w $f4,$f18 -/* f09827c: 46082182 */ mul.s $f6,$f4,$f8 -/* f098280: 00000000 */ nop -/* f098284: 46060282 */ mul.s $f10,$f0,$f6 -/* f098288: e64a0688 */ swc1 $f10,0x688($s2) -/* f09828c: 8e4d0690 */ lw $t5,0x690($s2) -.PB0f098290: -/* f098290: 000d7840 */ sll $t7,$t5,0x1 -/* f098294: 05e10003 */ bgez $t7,.PB0f0982a4 -/* f098298: 00000000 */ nop -/* f09829c: ae400684 */ sw $zero,0x684($s2) -/* f0982a0: e6420688 */ swc1 $f2,0x688($s2) -.PB0f0982a4: -/* f0982a4: 0fc25ff3 */ jal bgun0f09815c -/* f0982a8: 02402025 */ move $a0,$s2 -/* f0982ac: 44809000 */ mtc1 $zero,$f18 -/* f0982b0: c6500688 */ lwc1 $f16,0x688($s2) -/* f0982b4: 46000506 */ mov.s $f20,$f0 -/* f0982b8: 46120032 */ c.eq.s $f0,$f18 -/* f0982bc: 46008380 */ add.s $f14,$f16,$f0 -/* f0982c0: 4502000b */ bc1fl .PB0f0982f0 -/* f0982c4: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f0982c8: 44802000 */ mtc1 $zero,$f4 -/* f0982cc: 3c013f80 */ lui $at,0x3f80 -/* f0982d0: 460e203c */ c.lt.s $f4,$f14 -/* f0982d4: 00000000 */ nop -/* f0982d8: 45020005 */ bc1fl .PB0f0982f0 -/* f0982dc: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f0982e0: 44814000 */ mtc1 $at,$f8 -/* f0982e4: 00000000 */ nop -/* f0982e8: 46080501 */ sub.s $f20,$f0,$f8 -/* f0982ec: 8e4306b0 */ lw $v1,0x6b0($s2) -.PB0f0982f0: -/* f0982f0: 106000d8 */ beqz $v1,.PB0f098654 -/* f0982f4: 00608825 */ move $s1,$v1 -/* f0982f8: 106000d6 */ beqz $v1,.PB0f098654 -/* f0982fc: afa0014c */ sw $zero,0x14c($sp) -/* f098300: 00008025 */ move $s0,$zero -/* f098304: 24130001 */ li $s3,0x1 -/* f098308: 92230000 */ lbu $v1,0x0($s1) -.PB0f09830c: -/* f09830c: 14600003 */ bnez $v1,.PB0f09831c -/* f098310: 00000000 */ nop -/* f098314: 100000b6 */ b .PB0f0985f0 -/* f098318: afb3014c */ sw $s3,0x14c($sp) -.PB0f09831c: -/* f09831c: 12630003 */ beq $s3,$v1,.PB0f09832c -/* f098320: 24010002 */ li $at,0x2 -/* f098324: 54610036 */ bnel $v1,$at,.PB0f098400 -/* f098328: 24010003 */ li $at,0x3 -.PB0f09832c: -/* f09832c: 96260002 */ lhu $a2,0x2($s1) -/* f098330: 3c014f80 */ lui $at,0x4f80 -/* f098334: 2405ffff */ li $a1,-1 -/* f098338: 44863000 */ mtc1 $a2,$f6 -/* f09833c: 27ab0094 */ addiu $t3,$sp,0x94 -/* f098340: 04c10004 */ bgez $a2,.PB0f098354 -/* f098344: 468032a0 */ cvt.s.w $f10,$f6 -/* f098348: 44818000 */ mtc1 $at,$f16 -/* f09834c: 00000000 */ nop -/* f098350: 46105280 */ add.s $f10,$f10,$f16 -.PB0f098354: -/* f098354: 460e503e */ c.le.s $f10,$f14 -/* f098358: 2401ffff */ li $at,-1 -/* f09835c: 450200a5 */ bc1fl .PB0f0985f4 -/* f098360: 8fac014c */ lw $t4,0x14c($sp) -/* f098364: 1a00000a */ blez $s0,.PB0f098390 -/* f098368: 00001025 */ move $v0,$zero -/* f09836c: 8e240004 */ lw $a0,0x4($s1) -/* f098370: 27a3010c */ addiu $v1,$sp,0x10c -.PB0f098374: -/* f098374: 8c780000 */ lw $t8,0x0($v1) -/* f098378: 54980003 */ bnel $a0,$t8,.PB0f098388 -/* f09837c: 24420001 */ addiu $v0,$v0,0x1 -/* f098380: 00402825 */ move $a1,$v0 -/* f098384: 24420001 */ addiu $v0,$v0,0x1 -.PB0f098388: -/* f098388: 1450fffa */ bne $v0,$s0,.PB0f098374 -/* f09838c: 24630004 */ addiu $v1,$v1,0x4 -.PB0f098390: -/* f098390: 14a1000a */ bne $a1,$at,.PB0f0983bc -/* f098394: 2409ffff */ li $t1,-1 -/* f098398: 8e240004 */ lw $a0,0x4($s1) -/* f09839c: 02002825 */ move $a1,$s0 -/* f0983a0: 00051080 */ sll $v0,$a1,0x2 -/* f0983a4: 03a2c821 */ addu $t9,$sp,$v0 -/* f0983a8: 03a25021 */ addu $t2,$sp,$v0 -/* f0983ac: af24010c */ sw $a0,0x10c($t9) -/* f0983b0: ad490094 */ sw $t1,0x94($t2) -/* f0983b4: 26100001 */ addiu $s0,$s0,0x1 -/* f0983b8: 96260002 */ lhu $a2,0x2($s1) -.PB0f0983bc: -/* f0983bc: 00051080 */ sll $v0,$a1,0x2 -/* f0983c0: 004b1821 */ addu $v1,$v0,$t3 -/* f0983c4: 8c6c0000 */ lw $t4,0x0($v1) -/* f0983c8: 0186082a */ slt $at,$t4,$a2 -/* f0983cc: 50200089 */ beqzl $at,.PB0f0985f4 -/* f0983d0: 8fac014c */ lw $t4,0x14c($sp) -/* f0983d4: ac660000 */ sw $a2,0x0($v1) -/* f0983d8: 922d0000 */ lbu $t5,0x0($s1) -/* f0983dc: 03a27821 */ addu $t7,$sp,$v0 -/* f0983e0: 03a27021 */ addu $t6,$sp,$v0 -/* f0983e4: 166d0003 */ bne $s3,$t5,.PB0f0983f4 -/* f0983e8: 00000000 */ nop -/* f0983ec: 10000080 */ b .PB0f0985f0 -/* f0983f0: add300d0 */ sw $s3,0xd0($t6) -.PB0f0983f4: -/* f0983f4: 1000007e */ b .PB0f0985f0 -/* f0983f8: ade000d0 */ sw $zero,0xd0($t7) -/* f0983fc: 24010003 */ li $at,0x3 -.PB0f098400: -/* f098400: 10610005 */ beq $v1,$at,.PB0f098418 -/* f098404: 24010008 */ li $at,0x8 -/* f098408: 50610049 */ beql $v1,$at,.PB0f098530 -/* f09840c: 8e4e0690 */ lw $t6,0x690($s2) -/* f098410: 10000078 */ b .PB0f0985f4 -/* f098414: 8fac014c */ lw $t4,0x14c($sp) -.PB0f098418: -/* f098418: 8e580690 */ lw $t8,0x690($s2) -/* f09841c: 0018cfc2 */ srl $t9,$t8,0x1f -/* f098420: 53200074 */ beqzl $t9,.PB0f0985f4 -/* f098424: 8fac014c */ lw $t4,0x14c($sp) -/* f098428: 96290002 */ lhu $t1,0x2($s1) -/* f09842c: 3c014f80 */ lui $at,0x4f80 -/* f098430: 44899000 */ mtc1 $t1,$f18 -/* f098434: 05210004 */ bgez $t1,.PB0f098448 -/* f098438: 468090a0 */ cvt.s.w $f2,$f18 -/* f09843c: 44812000 */ mtc1 $at,$f4 -/* f098440: 00000000 */ nop -/* f098444: 46041080 */ add.s $f2,$f2,$f4 -.PB0f098448: -/* f098448: 460e103e */ c.le.s $f2,$f14 -/* f09844c: 00000000 */ nop -/* f098450: 45020068 */ bc1fl .PB0f0985f4 -/* f098454: 8fac014c */ lw $t4,0x14c($sp) -/* f098458: 4602a03c */ c.lt.s $f20,$f2 -/* f09845c: 00000000 */ nop -/* f098460: 45020064 */ bc1fl .PB0f0985f4 -/* f098464: 8fac014c */ lw $t4,0x14c($sp) -/* f098468: 460ea03c */ c.lt.s $f20,$f14 -/* f09846c: 00000000 */ nop -/* f098470: 45020060 */ bc1fl .PB0f0985f4 -/* f098474: 8fac014c */ lw $t4,0x14c($sp) -/* f098478: 0fc25ff3 */ jal bgun0f09815c -/* f09847c: 02402025 */ move $a0,$s2 -/* f098480: 962a0002 */ lhu $t2,0x2($s1) -/* f098484: 3c014f80 */ lui $at,0x4f80 -/* f098488: 02802025 */ move $a0,$s4 -/* f09848c: 448a4000 */ mtc1 $t2,$f8 -/* f098490: 05410004 */ bgez $t2,.PB0f0984a4 -/* f098494: 468041a0 */ cvt.s.w $f6,$f8 -/* f098498: 44818000 */ mtc1 $at,$f16 -/* f09849c: 00000000 */ nop -/* f0984a0: 46103180 */ add.s $f6,$f6,$f16 -.PB0f0984a4: -/* f0984a4: 46003081 */ sub.s $f2,$f6,$f0 -/* f0984a8: 3c014000 */ lui $at,0x4000 -/* f0984ac: 44815000 */ mtc1 $at,$f10 -/* f0984b0: c64c0688 */ lwc1 $f12,0x688($s2) -/* f0984b4: 460a1083 */ div.s $f2,$f2,$f10 -/* f0984b8: 460c103c */ c.lt.s $f2,$f12 -/* f0984bc: 00000000 */ nop -/* f0984c0: 45000018 */ bc1f .PB0f098524 -/* f0984c4: 00000000 */ nop -/* f0984c8: 0c007746 */ jal modelGetAbsAnimSpeed -/* f0984cc: e7a20084 */ swc1 $f2,0x84($sp) -/* f0984d0: 3c017f1b */ lui $at,0x7f1b -/* f0984d4: c432ddf8 */ lwc1 $f18,-0x2208($at) -/* f0984d8: c7a20084 */ lwc1 $f2,0x84($sp) -/* f0984dc: 02802025 */ move $a0,$s4 -/* f0984e0: 46121102 */ mul.s $f4,$f2,$f18 -/* f0984e4: 46002203 */ div.s $f8,$f4,$f0 -/* f0984e8: 4600440d */ trunc.w.s $f16,$f8 -/* f0984ec: 440c8000 */ mfc1 $t4,$f16 -/* f0984f0: 0c007746 */ jal modelGetAbsAnimSpeed -/* f0984f4: ae4c0684 */ sw $t4,0x684($s2) -/* f0984f8: 8e4d0684 */ lw $t5,0x684($s2) -/* f0984fc: 3c017f1b */ lui $at,0x7f1b -/* f098500: c432ddfc */ lwc1 $f18,-0x2204($at) -/* f098504: 448d3000 */ mtc1 $t5,$f6 -/* f098508: 00000000 */ nop -/* f09850c: 468032a0 */ cvt.s.w $f10,$f6 -/* f098510: 46125102 */ mul.s $f4,$f10,$f18 -/* f098514: 00000000 */ nop -/* f098518: 46040202 */ mul.s $f8,$f0,$f4 -/* f09851c: e6480688 */ swc1 $f8,0x688($s2) -/* f098520: c64c0688 */ lwc1 $f12,0x688($s2) -.PB0f098524: -/* f098524: 10000032 */ b .PB0f0985f0 -/* f098528: 46146380 */ add.s $f14,$f12,$f20 -/* f09852c: 8e4e0690 */ lw $t6,0x690($s2) -.PB0f098530: -/* f098530: 000ec080 */ sll $t8,$t6,0x2 -/* f098534: 0703002f */ bgezl $t8,.PB0f0985f4 -/* f098538: 8fac014c */ lw $t4,0x14c($sp) -/* f09853c: 96260002 */ lhu $a2,0x2($s1) -/* f098540: 3c014f80 */ lui $at,0x4f80 -/* f098544: 44868000 */ mtc1 $a2,$f16 -/* f098548: 04c10004 */ bgez $a2,.PB0f09855c -/* f09854c: 468080a0 */ cvt.s.w $f2,$f16 -/* f098550: 44813000 */ mtc1 $at,$f6 -/* f098554: 00000000 */ nop -/* f098558: 46061080 */ add.s $f2,$f2,$f6 -.PB0f09855c: -/* f09855c: 460e103e */ c.le.s $f2,$f14 -/* f098560: 00000000 */ nop -/* f098564: 45020023 */ bc1fl .PB0f0985f4 -/* f098568: 8fac014c */ lw $t4,0x14c($sp) -/* f09856c: 4602a03c */ c.lt.s $f20,$f2 -/* f098570: 00000000 */ nop -/* f098574: 4502001f */ bc1fl .PB0f0985f4 -/* f098578: 8fac014c */ lw $t4,0x14c($sp) -/* f09857c: 460ea03c */ c.lt.s $f20,$f14 -/* f098580: 02802025 */ move $a0,$s4 -/* f098584: 4502001b */ bc1fl .PB0f0985f4 -/* f098588: 8fac014c */ lw $t4,0x14c($sp) -/* f09858c: 460e103e */ c.le.s $f2,$f14 -/* f098590: 44809000 */ mtc1 $zero,$f18 -/* f098594: 46007006 */ mov.s $f0,$f14 -/* f098598: 4502000c */ bc1fl .PB0f0985cc -/* f09859c: ae400684 */ sw $zero,0x684($s2) -/* f0985a0: 8e390004 */ lw $t9,0x4($s1) -/* f0985a4: 03264823 */ subu $t1,$t9,$a2 -/* f0985a8: 44895000 */ mtc1 $t1,$f10 -/* f0985ac: 00000000 */ nop -/* f0985b0: 46805320 */ cvt.s.w $f12,$f10 -/* f0985b4: 460c0000 */ add.s $f0,$f0,$f12 -.PB0f0985b8: -/* f0985b8: 4600103e */ c.le.s $f2,$f0 -/* f0985bc: 00000000 */ nop -/* f0985c0: 4503fffd */ bc1tl .PB0f0985b8 -/* f0985c4: 460c0000 */ add.s $f0,$f0,$f12 -/* f0985c8: ae400684 */ sw $zero,0x684($s2) -.PB0f0985cc: -/* f0985cc: e6520688 */ swc1 $f18,0x688($s2) -/* f0985d0: 44050000 */ mfc1 $a1,$f0 -/* f0985d4: 46000506 */ mov.s $f20,$f0 -/* f0985d8: 0c007aaa */ jal model0001e018 -/* f0985dc: e7a00080 */ swc1 $f0,0x80($sp) -/* f0985e0: 924a0691 */ lbu $t2,0x691($s2) -/* f0985e4: c7ae0080 */ lwc1 $f14,0x80($sp) -/* f0985e8: 254b0001 */ addiu $t3,$t2,0x1 -/* f0985ec: a24b0691 */ sb $t3,0x691($s2) -.PB0f0985f0: -/* f0985f0: 8fac014c */ lw $t4,0x14c($sp) -.PB0f0985f4: -/* f0985f4: 26310008 */ addiu $s1,$s1,0x8 -/* f0985f8: 5180ff44 */ beqzl $t4,.PB0f09830c -/* f0985fc: 92230000 */ lbu $v1,0x0($s1) -/* f098600: 5a000015 */ blezl $s0,.PB0f098658 -/* f098604: 3c054099 */ lui $a1,0x4099 -/* f098608: 1a000012 */ blez $s0,.PB0f098654 -/* f09860c: 00001025 */ move $v0,$zero -/* f098610: 27a3010c */ addiu $v1,$sp,0x10c -/* f098614: 27a800d0 */ addiu $t0,$sp,0xd0 -.PB0f098618: -/* f098618: 84640002 */ lh $a0,0x2($v1) -/* f09861c: 8d050000 */ lw $a1,0x0($t0) -/* f098620: afa80058 */ sw $t0,0x58($sp) -/* f098624: afa3005c */ sw $v1,0x5c($sp) -/* f098628: afa2007c */ sw $v0,0x7c($sp) -/* f09862c: 02403025 */ move $a2,$s2 -/* f098630: 0fc25f39 */ jal bgunSetPartVisible -/* f098634: 8fa70164 */ lw $a3,0x164($sp) -/* f098638: 8fa2007c */ lw $v0,0x7c($sp) -/* f09863c: 8fa3005c */ lw $v1,0x5c($sp) -/* f098640: 8fa80058 */ lw $t0,0x58($sp) -/* f098644: 24420001 */ addiu $v0,$v0,0x1 -/* f098648: 24630004 */ addiu $v1,$v1,0x4 -/* f09864c: 1450fff2 */ bne $v0,$s0,.PB0f098618 -/* f098650: 25080004 */ addiu $t0,$t0,0x4 -.PB0f098654: -/* f098654: 3c054099 */ lui $a1,0x4099 -.PB0f098658: -/* f098658: 34a5999a */ ori $a1,$a1,0x999a -/* f09865c: 02802025 */ move $a0,$s4 -/* f098660: 0c007a8f */ jal modelSetAnimPlaySpeed -/* f098664: 24060000 */ li $a2,0x0 -/* f098668: 02802025 */ move $a0,$s4 -/* f09866c: 8e450684 */ lw $a1,0x684($s2) -/* f098670: 0c007e2a */ jal model0001ee18 -/* f098674: 24060001 */ li $a2,0x1 -/* f098678: 0fc25ff3 */ jal bgun0f09815c -/* f09867c: 02402025 */ move $a0,$s2 -/* f098680: 8e4306b0 */ lw $v1,0x6b0($s2) -/* f098684: 46000386 */ mov.s $f14,$f0 -/* f098688: 00004025 */ move $t0,$zero -/* f09868c: 10600069 */ beqz $v1,.PB0f098834 -/* f098690: 00608025 */ move $s0,$v1 -/* f098694: 3c013f80 */ lui $at,0x3f80 -/* f098698: 44812000 */ mtc1 $at,$f4 -/* f09869c: 00008825 */ move $s1,$zero -/* f0986a0: 10600064 */ beqz $v1,.PB0f098834 -/* f0986a4: e7a40070 */ swc1 $f4,0x70($sp) -/* f0986a8: 24140009 */ li $s4,0x9 -/* f0986ac: 24130005 */ li $s3,0x5 -.PB0f0986b0: -/* f0986b0: 92030000 */ lbu $v1,0x0($s0) -/* f0986b4: 54600004 */ bnezl $v1,.PB0f0986c8 -/* f0986b8: 960d0002 */ lhu $t5,0x2($s0) -/* f0986bc: 1000005b */ b .PB0f09882c -/* f0986c0: 24080001 */ li $t0,0x1 -/* f0986c4: 960d0002 */ lhu $t5,0x2($s0) -.PB0f0986c8: -/* f0986c8: 3c014f80 */ lui $at,0x4f80 -/* f0986cc: 448d4000 */ mtc1 $t5,$f8 -/* f0986d0: 05a10004 */ bgez $t5,.PB0f0986e4 -/* f0986d4: 46804020 */ cvt.s.w $f0,$f8 -/* f0986d8: 44818000 */ mtc1 $at,$f16 -/* f0986dc: 00000000 */ nop -/* f0986e0: 46100000 */ add.s $f0,$f0,$f16 -.PB0f0986e4: -/* f0986e4: 460e003e */ c.le.s $f0,$f14 -/* f0986e8: 00000000 */ nop -/* f0986ec: 4500004f */ bc1f .PB0f09882c -/* f0986f0: 00000000 */ nop -/* f0986f4: 4600a03c */ c.lt.s $f20,$f0 -/* f0986f8: 00000000 */ nop -/* f0986fc: 4500004b */ bc1f .PB0f09882c -/* f098700: 00000000 */ nop -/* f098704: 460ea03c */ c.lt.s $f20,$f14 -/* f098708: 00000000 */ nop -/* f09870c: 45000047 */ bc1f .PB0f09882c -/* f098710: 00000000 */ nop -/* f098714: 10730007 */ beq $v1,$s3,.PB0f098734 -/* f098718: 00000000 */ nop -/* f09871c: 10740039 */ beq $v1,$s4,.PB0f098804 -/* f098720: 2401000b */ li $at,0xb -/* f098724: 5061002f */ beql $v1,$at,.PB0f0987e4 -/* f098728: 8e0d0004 */ lw $t5,0x4($s0) -/* f09872c: 1000003f */ b .PB0f09882c -/* f098730: 00000000 */ nop -.PB0f098734: -/* f098734: 12200016 */ beqz $s1,.PB0f098790 -/* f098738: 00002025 */ move $a0,$zero -/* f09873c: 8e0e0004 */ lw $t6,0x4($s0) -/* f098740: c7a60070 */ lwc1 $f6,0x70($sp) -/* f098744: 240f0001 */ li $t7,0x1 -/* f098748: 2418ffff */ li $t8,-1 -/* f09874c: 24190001 */ li $t9,0x1 -/* f098750: afb90020 */ sw $t9,0x20($sp) -/* f098754: afb8001c */ sw $t8,0x1c($sp) -/* f098758: afaf0018 */ sw $t7,0x18($sp) -/* f09875c: e7ae0158 */ swc1 $f14,0x158($sp) -/* f098760: afa80078 */ sw $t0,0x78($sp) -/* f098764: 00002025 */ move $a0,$zero -/* f098768: 00002825 */ move $a1,$zero -/* f09876c: 24067fff */ li $a2,0x7fff -/* f098770: 24070040 */ li $a3,0x40 -/* f098774: 00008825 */ move $s1,$zero -/* f098778: afae0010 */ sw $t6,0x10($sp) -/* f09877c: 0c0041d9 */ jal snd00010718 -/* f098780: e7a60014 */ swc1 $f6,0x14($sp) -/* f098784: 8fa80078 */ lw $t0,0x78($sp) -/* f098788: 10000028 */ b .PB0f09882c -/* f09878c: c7ae0158 */ lwc1 $f14,0x158($sp) -.PB0f098790: -/* f098790: 8e090004 */ lw $t1,0x4($s0) -/* f098794: 3c013f80 */ lui $at,0x3f80 -/* f098798: 44815000 */ mtc1 $at,$f10 -/* f09879c: 240a0001 */ li $t2,0x1 -/* f0987a0: 240bffff */ li $t3,-1 -/* f0987a4: 240c0001 */ li $t4,0x1 -/* f0987a8: afac0020 */ sw $t4,0x20($sp) -/* f0987ac: afab001c */ sw $t3,0x1c($sp) -/* f0987b0: afaa0018 */ sw $t2,0x18($sp) -/* f0987b4: e7ae0158 */ swc1 $f14,0x158($sp) -/* f0987b8: afa80078 */ sw $t0,0x78($sp) -/* f0987bc: 00002825 */ move $a1,$zero -/* f0987c0: 24067fff */ li $a2,0x7fff -/* f0987c4: 24070040 */ li $a3,0x40 -/* f0987c8: afa90010 */ sw $t1,0x10($sp) -/* f0987cc: 0c0041d9 */ jal snd00010718 -/* f0987d0: e7aa0014 */ swc1 $f10,0x14($sp) -/* f0987d4: 8fa80078 */ lw $t0,0x78($sp) -/* f0987d8: 10000014 */ b .PB0f09882c -/* f0987dc: c7ae0158 */ lwc1 $f14,0x158($sp) -/* f0987e0: 8e0d0004 */ lw $t5,0x4($s0) -.PB0f0987e4: -/* f0987e4: 3c01447a */ lui $at,0x447a -/* f0987e8: 44814000 */ mtc1 $at,$f8 -/* f0987ec: 448d9000 */ mtc1 $t5,$f18 -/* f0987f0: 24110001 */ li $s1,0x1 -/* f0987f4: 46809120 */ cvt.s.w $f4,$f18 -/* f0987f8: 46082403 */ div.s $f16,$f4,$f8 -/* f0987fc: 1000000b */ b .PB0f09882c -/* f098800: e7b00070 */ swc1 $f16,0x70($sp) -.PB0f098804: -/* f098804: 8e4e0690 */ lw $t6,0x690($s2) -/* f098808: 924b0690 */ lbu $t3,0x690($s2) -/* f09880c: 000e78c0 */ sll $t7,$t6,0x3 -/* f098810: 000fc742 */ srl $t8,$t7,0x1d -/* f098814: 27190001 */ addiu $t9,$t8,0x1 -/* f098818: 00194880 */ sll $t1,$t9,0x2 -/* f09881c: 312a001c */ andi $t2,$t1,0x1c -/* f098820: 316cffe3 */ andi $t4,$t3,0xffe3 -/* f098824: 014c6825 */ or $t5,$t2,$t4 -/* f098828: a24d0690 */ sb $t5,0x690($s2) -.PB0f09882c: -/* f09882c: 1100ffa0 */ beqz $t0,.PB0f0986b0 -/* f098830: 26100008 */ addiu $s0,$s0,0x8 -.PB0f098834: -/* f098834: 8fbf004c */ lw $ra,0x4c($sp) -.PB0f098838: -/* f098838: d7b40030 */ ldc1 $f20,0x30($sp) -/* f09883c: 8fb00038 */ lw $s0,0x38($sp) -/* f098840: 8fb1003c */ lw $s1,0x3c($sp) -/* f098844: 8fb20040 */ lw $s2,0x40($sp) -/* f098848: 8fb30044 */ lw $s3,0x44($sp) -/* f09884c: 8fb40048 */ lw $s4,0x48($sp) -/* f098850: 03e00008 */ jr $ra -/* f098854: 27bd0160 */ addiu $sp,$sp,0x160 -); -#else void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) { - s32 s0; - s32 index; +#if VERSION >= VERSION_PAL_BETA + f32 s4; + f32 s2; +#else + s32 s2; + s32 s4; +#endif struct guncmd *cmd; f32 animspeed; bool done; - s32 s4; + f32 animspeedmult; s32 partnums[15]; bool partsvisible[15]; s32 partframes[15]; - s32 s2; - f32 animspeedmult; - s32 tmp; - s32 i; - s32 sp78; + s32 s0; + s32 index; hand->unk0cc8_04 = false; @@ -2305,6 +604,9 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) if ((hand->animmode == (u32)HANDANIMMODE_BUSY) | (hand->animload >= 0)) { if (hand->gangstarot > 0.0f) { hand->animframeinc = 0; +#if VERSION >= VERSION_PAL_BETA + hand->animframeincfreal = 0.0f; +#endif } if (hand->animload >= 0) { @@ -2324,21 +626,32 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) hand->animload = -1; hand->animmode = HANDANIMMODE_BUSY; +#if VERSION >= VERSION_PAL_BETA + hand->animframeincfreal = modelGetAbsAnimSpeed(&hand->gunmodel) * PALUPF(hand->animframeinc); +#endif } if (hand->unk0cc8_02) { hand->animframeinc = 0; +#if VERSION >= VERSION_PAL_BETA + hand->animframeincfreal = 0.0f; +#endif } s4 = bgun0f09815c(hand); + +#if VERSION >= VERSION_PAL_BETA + s2 = hand->animframeincfreal + s4; +#else s2 = hand->animframeinc + s4; - done = false; +#endif if (s4 == 0 && s2 > 0) { s4--; } if (hand->unk0ce8) { + done = false; cmd = hand->unk0ce8; if (cmd) { @@ -2349,6 +662,7 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) done = true; } else if (cmd->type == GUNCMD_SHOWPART || cmd->type == GUNCMD_HIDEPART) { if (s2 >= cmd->unk02) { + s32 i; index = -1; for (i = 0; i < s0; i++) { @@ -2377,7 +691,22 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) case GUNCMD_WAITFORZRELEASED: if (hand->unk0cc8_01) { if (s2 >= cmd->unk02 && s4 < cmd->unk02 && s4 < s2) { - tmp = cmd->unk02 - (s32)bgun0f09815c(hand); +#if VERSION >= VERSION_PAL_BETA + f32 tmp = cmd->unk02 - bgun0f09815c(hand); + tmp /= 2; + + if (hand->animframeincfreal > tmp) { +#if PAL + hand->animframeinc = tmp * 0.83333333f / modelGetAbsAnimSpeed(&hand->gunmodel); +#else + hand->animframeinc = tmp / modelGetAbsAnimSpeed(&hand->gunmodel); +#endif + hand->animframeincfreal = modelGetAbsAnimSpeed(&hand->gunmodel) * PALUPF(hand->animframeinc); + } + + s2 = hand->animframeincfreal + s4; +#else + s32 tmp = cmd->unk02 - (s32) bgun0f09815c(hand); tmp /= 2; if (hand->animframeinc > tmp) { @@ -2385,14 +714,28 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) } s2 = hand->animframeinc + s4; +#endif } } break; case GUNCMD_REPEATUNTILFULL: if (hand->unk0cc8_03 && s2 >= cmd->unk02 && s4 < cmd->unk02 && s4 < s2) { - sp78 = cmd->unk04 + ((s2 - cmd->unk02) % ((cmd->unk02 - cmd->unk04) + 1)); +#if VERSION >= VERSION_PAL_BETA + f32 sp78 = s2; + + while (sp78 >= cmd->unk02) { + sp78 += cmd->unk04 - cmd->unk02; + } + s4 = sp78; hand->animframeinc = 0; + hand->animframeincfreal = 0; +#else + s32 sp78 = cmd->unk04 + (((s32)s2 - cmd->unk02) % ((cmd->unk02 - cmd->unk04) + 1)); + s4 = sp78; + hand->animframeinc = 0; +#endif + model0001e018(&hand->gunmodel, sp78); hand->animloopcount++; s2 = sp78; @@ -2414,7 +757,12 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) } } +#if VERSION >= VERSION_PAL_BETA + modelSetAnimPlaySpeed(&hand->gunmodel, PALUPF(4.0f), 0); + model0001ee18(&hand->gunmodel, hand->animframeinc, true); +#else model0001f314(&hand->gunmodel, hand->animframeinc, true); +#endif s2 = bgun0f09815c(hand); @@ -2432,9 +780,7 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) if (cmd->type == GUNCMD_END) { done = true; } else { - tmp = cmd->unk02; - - if (s2 >= tmp && s4 < tmp && s4 < s2) { + if (s2 >= cmd->unk02 && s4 < cmd->unk02 && s4 < s2) { switch (cmd->type) { case GUNCMD_PLAYSOUND: #if VERSION >= VERSION_NTSC_1_0 @@ -2470,7 +816,6 @@ void bgun0f0981e8(struct hand *hand, struct modelfiledata *modeldef) } } } -#endif bool bgun0f098884(struct guncmd *cmd, struct gset *gset) {