### RAW ASSEMBLY INSTRUCTIONS:

glabel IdleRunToGoal
/* 1A8B44 8027A264 27BDFFB8 */  addiu     $sp, $sp, -0x48
/* 1A8B48 8027A268 AFB20020 */  sw        $s2, 0x20($sp)
/* 1A8B4C 8027A26C 0080902D */  daddu     $s2, $a0, $zero
/* 1A8B50 8027A270 AFBF0024 */  sw        $ra, 0x24($sp)
/* 1A8B54 8027A274 AFB1001C */  sw        $s1, 0x1C($sp)
/* 1A8B58 8027A278 AFB00018 */  sw        $s0, 0x18($sp)
/* 1A8B5C 8027A27C F7BA0040 */  sdc1      $f26, 0x40($sp)
/* 1A8B60 8027A280 F7B80038 */  sdc1      $f24, 0x38($sp)
/* 1A8B64 8027A284 F7B60030 */  sdc1      $f22, 0x30($sp)
/* 1A8B68 8027A288 F7B40028 */  sdc1      $f20, 0x28($sp)
/* 1A8B6C 8027A28C 8E51000C */  lw        $s1, 0xC($s2)
/* 1A8B70 8027A290 54A00001 */  bnel      $a1, $zero, .L8027A298
/* 1A8B74 8027A294 AE400070 */   sw       $zero, 0x70($s2)
.L8027A298:
/* 1A8B78 8027A298 8E420070 */  lw        $v0, 0x70($s2)
/* 1A8B7C 8027A29C 14400055 */  bnez      $v0, .L8027A3F4
/* 1A8B80 8027A2A0 00000000 */   nop
/* 1A8B84 8027A2A4 8E250000 */  lw        $a1, 0x0($s1)
/* 1A8B88 8027A2A8 26310004 */  addiu     $s1, $s1, 0x4
/* 1A8B8C 8027A2AC 0C0B1EAF */  jal       evt_get_variable
/* 1A8B90 8027A2B0 0240202D */   daddu    $a0, $s2, $zero
/* 1A8B94 8027A2B4 0040202D */  daddu     $a0, $v0, $zero
/* 1A8B98 8027A2B8 2402FF81 */  addiu     $v0, $zero, -0x7F
/* 1A8B9C 8027A2BC 14820002 */  bne       $a0, $v0, .L8027A2C8
/* 1A8BA0 8027A2C0 00000000 */   nop
/* 1A8BA4 8027A2C4 8E440148 */  lw        $a0, 0x148($s2)
.L8027A2C8:
/* 1A8BA8 8027A2C8 0C09A75B */  jal       get_actor
/* 1A8BAC 8027A2CC 00000000 */   nop
/* 1A8BB0 8027A2D0 0040802D */  daddu     $s0, $v0, $zero
/* 1A8BB4 8027A2D4 AE500074 */  sw        $s0, 0x74($s2)
/* 1A8BB8 8027A2D8 8E250000 */  lw        $a1, 0x0($s1)
/* 1A8BBC 8027A2DC 0C0B1EAF */  jal       evt_get_variable
/* 1A8BC0 8027A2E0 0240202D */   daddu    $a0, $s2, $zero
/* 1A8BC4 8027A2E4 C61600D4 */  lwc1      $f22, 0xD4($s0)
/* 1A8BC8 8027A2E8 C61800DC */  lwc1      $f24, 0xDC($s0)
/* 1A8BCC 8027A2EC C6000144 */  lwc1      $f0, 0x144($s0)
/* 1A8BD0 8027A2F0 C614014C */  lwc1      $f20, 0x14C($s0)
/* 1A8BD4 8027A2F4 C60200D8 */  lwc1      $f2, 0xD8($s0)
/* 1A8BD8 8027A2F8 4406B000 */  mfc1      $a2, $f22
/* 1A8BDC 8027A2FC 4407C000 */  mfc1      $a3, $f24
/* 1A8BE0 8027A300 261100C8 */  addiu     $s1, $s0, 0xC8
/* 1A8BE4 8027A304 A6020120 */  sh        $v0, 0x120($s0)
/* 1A8BE8 8027A308 E60000C8 */  swc1      $f0, 0xC8($s0)
/* 1A8BEC 8027A30C C6000148 */  lwc1      $f0, 0x148($s0)
/* 1A8BF0 8027A310 C61A00C8 */  lwc1      $f26, 0xC8($s0)
/* 1A8BF4 8027A314 4600A386 */  mov.s     $f14, $f20
/* 1A8BF8 8027A318 E61400D0 */  swc1      $f20, 0xD0($s0)
/* 1A8BFC 8027A31C E61600E0 */  swc1      $f22, 0xE0($s0)
/* 1A8C00 8027A320 E60200E4 */  swc1      $f2, 0xE4($s0)
/* 1A8C04 8027A324 E61800E8 */  swc1      $f24, 0xE8($s0)
/* 1A8C08 8027A328 4600D306 */  mov.s     $f12, $f26
/* 1A8C0C 8027A32C 0C00A720 */  jal       atan2
/* 1A8C10 8027A330 E60000CC */   swc1     $f0, 0xCC($s0)
/* 1A8C14 8027A334 4600D306 */  mov.s     $f12, $f26
/* 1A8C18 8027A338 4406B000 */  mfc1      $a2, $f22
/* 1A8C1C 8027A33C 4407C000 */  mfc1      $a3, $f24
/* 1A8C20 8027A340 4600A386 */  mov.s     $f14, $f20
/* 1A8C24 8027A344 0C00A7B5 */  jal       dist2D
/* 1A8C28 8027A348 E6000110 */   swc1     $f0, 0x110($s0)
/* 1A8C2C 8027A34C 86020120 */  lh        $v0, 0x120($s0)
/* 1A8C30 8027A350 46000086 */  mov.s     $f2, $f0
/* 1A8C34 8027A354 14400018 */  bnez      $v0, .L8027A3B8
/* 1A8C38 8027A358 E6020114 */   swc1     $f2, 0x114($s0)
/* 1A8C3C 8027A35C C6000108 */  lwc1      $f0, 0x108($s0)
/* 1A8C40 8027A360 46001003 */  div.s     $f0, $f2, $f0
/* 1A8C44 8027A364 4600020D */  trunc.w.s $f8, $f0
/* 1A8C48 8027A368 44024000 */  mfc1      $v0, $f8
/* 1A8C4C 8027A36C 00000000 */  nop
/* 1A8C50 8027A370 A6020120 */  sh        $v0, 0x120($s0)
/* 1A8C54 8027A374 00021400 */  sll       $v0, $v0, 16
/* 1A8C58 8027A378 14400002 */  bnez      $v0, .L8027A384
/* 1A8C5C 8027A37C 24020001 */   addiu    $v0, $zero, 0x1
/* 1A8C60 8027A380 A6020120 */  sh        $v0, 0x120($s0)
.L8027A384:
/* 1A8C64 8027A384 86020120 */  lh        $v0, 0x120($s0)
/* 1A8C68 8027A388 C6020108 */  lwc1      $f2, 0x108($s0)
/* 1A8C6C 8027A38C 44823000 */  mtc1      $v0, $f6
/* 1A8C70 8027A390 00000000 */  nop
/* 1A8C74 8027A394 468031A0 */  cvt.s.w   $f6, $f6
/* 1A8C78 8027A398 46023102 */  mul.s     $f4, $f6, $f2
/* 1A8C7C 8027A39C 00000000 */  nop
/* 1A8C80 8027A3A0 C6000114 */  lwc1      $f0, 0x114($s0)
/* 1A8C84 8027A3A4 46040001 */  sub.s     $f0, $f0, $f4
/* 1A8C88 8027A3A8 46060003 */  div.s     $f0, $f0, $f6
/* 1A8C8C 8027A3AC 46001080 */  add.s     $f2, $f2, $f0
/* 1A8C90 8027A3B0 0809E8F3 */  j         .L8027A3CC
/* 1A8C94 8027A3B4 E6020108 */   swc1     $f2, 0x108($s0)
.L8027A3B8:
/* 1A8C98 8027A3B8 44820000 */  mtc1      $v0, $f0
/* 1A8C9C 8027A3BC 00000000 */  nop
/* 1A8CA0 8027A3C0 46800020 */  cvt.s.w   $f0, $f0
/* 1A8CA4 8027A3C4 46001003 */  div.s     $f0, $f2, $f0
/* 1A8CA8 8027A3C8 E6000108 */  swc1      $f0, 0x108($s0)
.L8027A3CC:
/* 1A8CAC 8027A3CC 860201B4 */  lh        $v0, 0x1B4($s0)
/* 1A8CB0 8027A3D0 04420002 */  bltzl     $v0, .L8027A3DC
/* 1A8CB4 8027A3D4 00021027 */   nor      $v0, $zero, $v0
/* 1A8CB8 8027A3D8 24420001 */  addiu     $v0, $v0, 0x1
.L8027A3DC:
/* 1A8CBC 8027A3DC 44820000 */  mtc1      $v0, $f0
/* 1A8CC0 8027A3E0 00000000 */  nop
/* 1A8CC4 8027A3E4 46800020 */  cvt.s.w   $f0, $f0
/* 1A8CC8 8027A3E8 E620004C */  swc1      $f0, 0x4C($s1)
/* 1A8CCC 8027A3EC 24020001 */  addiu     $v0, $zero, 0x1
/* 1A8CD0 8027A3F0 AE420070 */  sw        $v0, 0x70($s2)
.L8027A3F4:
/* 1A8CD4 8027A3F4 8E500074 */  lw        $s0, 0x74($s2)
/* 1A8CD8 8027A3F8 261100C8 */  addiu     $s1, $s0, 0xC8
/* 1A8CDC 8027A3FC 8E050108 */  lw        $a1, 0x108($s0)
/* 1A8CE0 8027A400 8E060110 */  lw        $a2, 0x110($s0)
/* 1A8CE4 8027A404 0C099096 */  jal       add_xz_vec3f_copy2
/* 1A8CE8 8027A408 0220202D */   daddu    $a0, $s1, $zero
/* 1A8CEC 8027A40C C6020108 */  lwc1      $f2, 0x108($s0)
/* 1A8CF0 8027A410 3C014080 */  lui       $at, (0x40800000 >> 16)
/* 1A8CF4 8027A414 44810000 */  mtc1      $at, $f0
/* 1A8CF8 8027A418 00000000 */  nop
/* 1A8CFC 8027A41C 4600103C */  c.lt.s    $f2, $f0
/* 1A8D00 8027A420 00000000 */  nop
/* 1A8D04 8027A424 45000007 */  bc1f      .L8027A444
/* 1A8D08 8027A428 0000202D */   daddu    $a0, $zero, $zero
/* 1A8D0C 8027A42C C6000110 */  lwc1      $f0, 0x110($s0)
/* 1A8D10 8027A430 E7A00010 */  swc1      $f0, 0x10($sp)
/* 1A8D14 8027A434 8E0500C8 */  lw        $a1, 0xC8($s0)
/* 1A8D18 8027A438 8E0600CC */  lw        $a2, 0xCC($s0)
/* 1A8D1C 8027A43C 0809E917 */  j         .L8027A45C
/* 1A8D20 8027A440 8E0700D0 */   lw       $a3, 0xD0($s0)
.L8027A444:
/* 1A8D24 8027A444 C6000110 */  lwc1      $f0, 0x110($s0)
/* 1A8D28 8027A448 E7A00010 */  swc1      $f0, 0x10($sp)
/* 1A8D2C 8027A44C 8E0500C8 */  lw        $a1, 0xC8($s0)
/* 1A8D30 8027A450 8E0600CC */  lw        $a2, 0xCC($s0)
/* 1A8D34 8027A454 8E0700D0 */  lw        $a3, 0xD0($s0)
/* 1A8D38 8027A458 24040001 */  addiu     $a0, $zero, 0x1
.L8027A45C:
/* 1A8D3C 8027A45C 0C0990BC */  jal       play_movement_dust_effects
/* 1A8D40 8027A460 00000000 */   nop
/* 1A8D44 8027A464 C6200000 */  lwc1      $f0, 0x0($s1)
/* 1A8D48 8027A468 E6000144 */  swc1      $f0, 0x144($s0)
/* 1A8D4C 8027A46C C6200008 */  lwc1      $f0, 0x8($s1)
/* 1A8D50 8027A470 E600014C */  swc1      $f0, 0x14C($s0)
/* 1A8D54 8027A474 96220058 */  lhu       $v0, 0x58($s1)
/* 1A8D58 8027A478 2442FFFF */  addiu     $v0, $v0, -0x1
/* 1A8D5C 8027A47C A6220058 */  sh        $v0, 0x58($s1)
/* 1A8D60 8027A480 00021400 */  sll       $v0, $v0, 16
/* 1A8D64 8027A484 1C40000D */  bgtz      $v0, .L8027A4BC
/* 1A8D68 8027A488 0000102D */   daddu    $v0, $zero, $zero
/* 1A8D6C 8027A48C C6200018 */  lwc1      $f0, 0x18($s1)
/* 1A8D70 8027A490 8E04019C */  lw        $a0, 0x19C($s0)
/* 1A8D74 8027A494 E6000144 */  swc1      $f0, 0x144($s0)
/* 1A8D78 8027A498 C6200020 */  lwc1      $f0, 0x20($s1)
/* 1A8D7C 8027A49C 10800006 */  beqz      $a0, .L8027A4B8
/* 1A8D80 8027A4A0 E600014C */   swc1     $f0, 0x14C($s0)
/* 1A8D84 8027A4A4 8E0201A0 */  lw        $v0, 0x1A0($s0)
/* 1A8D88 8027A4A8 14400004 */  bnez      $v0, .L8027A4BC
/* 1A8D8C 8027A4AC 24020001 */   addiu    $v0, $zero, 0x1
/* 1A8D90 8027A4B0 0C0154F0 */  jal       snd_stop_sound
/* 1A8D94 8027A4B4 00000000 */   nop
.L8027A4B8:
/* 1A8D98 8027A4B8 24020001 */  addiu     $v0, $zero, 0x1
.L8027A4BC:
/* 1A8D9C 8027A4BC 8FBF0024 */  lw        $ra, 0x24($sp)
/* 1A8DA0 8027A4C0 8FB20020 */  lw        $s2, 0x20($sp)
/* 1A8DA4 8027A4C4 8FB1001C */  lw        $s1, 0x1C($sp)
/* 1A8DA8 8027A4C8 8FB00018 */  lw        $s0, 0x18($sp)
/* 1A8DAC 8027A4CC D7BA0040 */  ldc1      $f26, 0x40($sp)
/* 1A8DB0 8027A4D0 D7B80038 */  ldc1      $f24, 0x38($sp)
/* 1A8DB4 8027A4D4 D7B60030 */  ldc1      $f22, 0x30($sp)
/* 1A8DB8 8027A4D8 D7B40028 */  ldc1      $f20, 0x28($sp)
/* 1A8DBC 8027A4DC 03E00008 */  jr        $ra
/* 1A8DC0 8027A4E0 27BD0048 */   addiu    $sp, $sp, 0x48

### DECOMPILED C INSTRUCTIONS:

ApiStatus IdleRunToGoal(Evt* script, s32 isInitialCall) {
    Bytecode* args = script->ptrReadPos;
    Actor* actor;
    ActorMovement* movement;
    f32 posX, posY, posZ;
    f32 goalX, goalY, goalZ;
    s32 actorID;

    if (isInitialCall) {
        script->functionTemp[0] = FALSE;
    }

    if (!script->functionTemp[0]) {
        actorID = evt_get_variable(script, *args++);
        if (actorID == ACTOR_SELF) {
            actorID = script->owner1.actorID;
        }
        script->functionTempPtr[1] = actor = get_actor(actorID);
        movement = &actor->fly;

        movement->flyTime = evt_get_variable(script, *args++);

        movement->currentPos.x = actor->currentPos.x;
        movement->currentPos.y = actor->currentPos.y;
        movement->currentPos.z = actor->currentPos.z;

        goalX = movement->goalPos.x;
        goalY = movement->goalPos.y;
        goalZ = movement->goalPos.z;

        posX = movement->currentPos.x;
        posY = movement->currentPos.y;
        posZ = movement->currentPos.z;

        movement->unk_18.x = goalX;
        movement->unk_18.y = goalY;
        movement->unk_18.z = goalZ;

        movement->angle = atan2(posX, posZ, goalX, goalZ);
        movement->distance = dist2D(posX, posZ, goalX, goalZ);

        if (movement->flyTime == 0) {
            movement->flyTime = movement->distance / movement->speed;
            if (movement->flyTime == 0) {
                movement->flyTime = 1;
            }
            // this simplifies to: flyMotion->speed = flyMotion->distance / flyMotion->flyTime
            movement->speed += (movement->distance - movement->flyTime * movement->speed) / movement->flyTime;
        } else {
            movement->speed = movement->distance / movement->flyTime;
        }

        if (actor->actorTypeData1b[0] >= 0) {
            movement->distance = actor->actorTypeData1b[0] + 1;
        } else {
            movement->distance = ~actor->actorTypeData1b[0];
        }
        script->functionTemp[0] = TRUE;
    }

    actor = script->functionTempPtr[1];
    movement = &actor->fly;

    add_xz_vec3f_copy2(&movement->currentPos, movement->speed, movement->angle);
    if (movement->speed < 4.0f) {
        play_movement_dust_effects(0, movement->currentPos.x, movement->currentPos.y, movement->currentPos.z, movement->angle);
    } else {
        play_movement_dust_effects(1, movement->currentPos.x, movement->currentPos.y, movement->currentPos.z, movement->angle);
    }
    actor->currentPos.x = movement->currentPos.x;
    actor->currentPos.z = movement->currentPos.z;

    movement->flyTime--;
    if (movement->flyTime > 0) {
        return ApiStatus_BLOCK;
    }

    actor->currentPos.x = movement->unk_18.x;
    actor->currentPos.z = movement->unk_18.z;
    if (actor->actorTypeData1[0] != 0 && actor->actorTypeData1[1] == 0) {
        snd_stop_sound(actor->actorTypeData1[0]);
    }
    return ApiStatus_DONE1;
}


### RAW ASSEMBLY INSTRUCTIONS:

glabel action_hammer_play_hit_fx
/* E24F18 802B6048 27BDFFA8 */  addiu     $sp, $sp, -0x58
.L802B604C:
/* E24F1C 802B604C AFB3002C */  sw        $s3, 0x2C($sp)
.L802B6050:
/* E24F20 802B6050 AFB40030 */  sw        $s4, 0x30($sp)
/* E24F24 802B6054 3C148011 */  lui       $s4, %hi(gPlayerStatus)
.L802B6058:
/* E24F28 802B6058 2694EFC8 */  addiu     $s4, $s4, %lo(gPlayerStatus)
/* E24F2C 802B605C 3C038011 */  lui       $v1, %hi(gPlayerData + 0x1)
glabel action_update_sliding
/* E24F30 802B6060 8063F291 */  lb        $v1, %lo(gPlayerData + 0x1)($v1)
/* E24F34 802B6064 24020002 */  addiu     $v0, $zero, 0x2
.L802B6068:
/* E24F38 802B6068 AFBF0034 */  sw        $ra, 0x34($sp)
/* E24F3C 802B606C AFB20028 */  sw        $s2, 0x28($sp)
/* E24F40 802B6070 AFB10024 */  sw        $s1, 0x24($sp)
.L802B6074:
/* E24F44 802B6074 AFB00020 */  sw        $s0, 0x20($sp)
/* E24F48 802B6078 F7BA0050 */  sdc1      $f26, 0x50($sp)
glabel .L802B607C
/* E24F4C 802B607C F7B80048 */  sdc1      $f24, 0x48($sp)
.L802B6080:
/* E24F50 802B6080 F7B60040 */  sdc1      $f22, 0x40($sp)
/* E24F54 802B6084 F7B40038 */  sdc1      $f20, 0x38($sp)
/* E24F58 802B6088 14620008 */  bne       $v1, $v0, .L802B60AC
.L802B608C:
/* E24F5C 802B608C 0080982D */   daddu    $s3, $a0, $zero
.L802B6090:
/* E24F60 802B6090 3C013F99 */  lui       $at, (0x3F99999A >> 16)
.L802B6094:
/* E24F64 802B6094 3421999A */  ori       $at, $at, (0x3F99999A & 0xFFFF)
/* E24F68 802B6098 4481C000 */  mtc1      $at, $f24
glabel action_update_state_23
/* E24F6C 802B609C 24120001 */  addiu     $s2, $zero, 0x1
/* E24F70 802B60A0 2411001C */  addiu     $s1, $zero, 0x1C
glabel action_update_use_spinning_flower
/* E24F74 802B60A4 080AD83A */  j         .L802B60E8
.L802B60A8:
/* E24F78 802B60A8 2410211A */   addiu    $s0, $zero, 0x211A
.L802B60AC:
/* E24F7C 802B60AC 24020001 */  addiu     $v0, $zero, 0x1
/* E24F80 802B60B0 14620008 */  bne       $v1, $v0, .L802B60D4
glabel action_update_jump
/* E24F84 802B60B4 24120001 */   addiu    $s2, $zero, 0x1
/* E24F88 802B60B8 3C013F4C */  lui       $at, (0x3F4CCCCD >> 16)
/* E24F8C 802B60BC 3421CCCD */  ori       $at, $at, (0x3F4CCCCD & 0xFFFF)
/* E24F90 802B60C0 4481C000 */  mtc1      $at, $f24
/* E24F94 802B60C4 0040902D */  daddu     $s2, $v0, $zero
.L802B60C8:
/* E24F98 802B60C8 24110010 */  addiu     $s1, $zero, 0x10
/* E24F9C 802B60CC 080AD83A */  j         .L802B60E8
glabel .L802B60D0
/* E24FA0 802B60D0 24102119 */   addiu    $s0, $zero, 0x2119
.L802B60D4:
/* E24FA4 802B60D4 3C013ECC */  lui       $at, (0x3ECCCCCD >> 16)
/* E24FA8 802B60D8 3421CCCD */  ori       $at, $at, (0x3ECCCCCD & 0xFFFF)
/* E24FAC 802B60DC 4481C000 */  mtc1      $at, $f24
/* E24FB0 802B60E0 24110004 */  addiu     $s1, $zero, 0x4
/* E24FB4 802B60E4 24102118 */  addiu     $s0, $zero, 0x2118
.L802B60E8:
/* E24FB8 802B60E8 0C0394D2 */  jal       func_800E5348
.L802B60EC:
/* E24FBC 802B60EC 00000000 */   nop
.L802B60F0:
/* E24FC0 802B60F0 3C0140C9 */  lui       $at, (0x40C90FD0 >> 16)
glabel .L802B60F4
/* E24FC4 802B60F4 34210FD0 */  ori       $at, $at, (0x40C90FD0 & 0xFFFF)
/* E24FC8 802B60F8 44811000 */  mtc1      $at, $f2
/* E24FCC 802B60FC 00000000 */  nop
.L802B6100:
/* E24FD0 802B6100 46020502 */  mul.s     $f20, $f0, $f2
.L802B6104:
/* E24FD4 802B6104 00000000 */  nop
.L802B6108:
/* E24FD8 802B6108 3C0143B4 */  lui       $at, (0x43B40000 >> 16)
glabel .L802B610C
/* E24FDC 802B610C 44810000 */  mtc1      $at, $f0
.L802B6110:
/* E24FE0 802B6110 00000000 */  nop
/* E24FE4 802B6114 4600A503 */  div.s     $f20, $f20, $f0
.L802B6118:
/* E24FE8 802B6118 0C00A85B */  jal       sin_rad
/* E24FEC 802B611C 4600A306 */   mov.s    $f12, $f20
glabel action_update_parasol
/* E24FF0 802B6120 3C0141C8 */  lui       $at, (0x41C80000 >> 16)
.L802B6124:
/* E24FF4 802B6124 44811000 */  mtc1      $at, $f2
.L802B6128:
/* E24FF8 802B6128 00000000 */  nop
/* E24FFC 802B612C 46020582 */  mul.s     $f22, $f0, $f2
/* E25000 802B6130 00000000 */  nop
glabel .L802B6134
/* E25004 802B6134 0C00A874 */  jal       cos_rad
/* E25008 802B6138 4600A306 */   mov.s    $f12, $f20
.L802B613C:
/* E2500C 802B613C 3C01C1C8 */  lui       $at, (0xC1C80000 >> 16)
.L802B6140:
/* E25010 802B6140 44811000 */  mtc1      $at, $f2
.L802B6144:
/* E25014 802B6144 00000000 */  nop
/* E25018 802B6148 46020082 */  mul.s     $f2, $f0, $f2
.L802B614C:
/* E2501C 802B614C 00000000 */  nop
.L802B6150:
/* E25020 802B6150 06610008 */  bgez      $s3, .L802B6174
.L802B6154:
/* E25024 802B6154 24130003 */   addiu    $s3, $zero, 0x3
.L802B6158:
/* E25028 802B6158 C6800028 */  lwc1      $f0, 0x28($s4)
.L802B615C:
/* E2502C 802B615C 24130006 */  addiu     $s3, $zero, 0x6
/* E25030 802B6160 46160680 */  add.s     $f26, $f0, $f22
.L802B6164:
/* E25034 802B6164 C6800030 */  lwc1      $f0, 0x30($s4)
.L802B6168:
/* E25038 802B6168 C694002C */  lwc1      $f20, 0x2C($s4)
/* E2503C 802B616C 080AD86D */  j         .L802B61B4
glabel .L802B6170
/* E25040 802B6170 46020580 */   add.s    $f22, $f0, $f2
glabel .L802B6174
/* E25044 802B6174 3C02802B */  lui       $v0, %hi(HammerHit)
/* E25048 802B6178 8C426DB0 */  lw        $v0, %lo(HammerHit)($v0)
.L802B617C:
/* E2504C 802B617C C4400000 */  lwc1      $f0, 0x0($v0)
.L802B6180:
/* E25050 802B6180 46160680 */  add.s     $f26, $f0, $f22
glabel .L802B6184
/* E25054 802B6184 C4400008 */  lwc1      $f0, 0x8($v0)
.L802B6188:
/* E25058 802B6188 868300B0 */  lh        $v1, 0xB0($s4)
.L802B618C:
/* E2505C 802B618C 46020580 */  add.s     $f22, $f0, $f2
.L802B6190:
/* E25060 802B6190 C4420004 */  lwc1      $f2, 0x4($v0)
.L802B6194:
/* E25064 802B6194 44830000 */  mtc1      $v1, $f0
glabel func_802B6198
/* E25068 802B6198 00000000 */  nop
/* E2506C 802B619C 46800020 */  cvt.s.w   $f0, $f0
.L802B61A0:
/* E25070 802B61A0 46001080 */  add.s     $f2, $f2, $f0
.L802B61A4:
/* E25074 802B61A4 3C0140A0 */  lui       $at, (0x40A00000 >> 16)
.L802B61A8:
/* E25078 802B61A8 44810000 */  mtc1      $at, $f0
.L802B61AC:
/* E2507C 802B61AC 24110001 */  addiu     $s1, $zero, 0x1
.L802B61B0:
/* E25080 802B61B0 46001501 */  sub.s     $f20, $f2, $f0
.L802B61B4:
/* E25084 802B61B4 0000202D */  daddu     $a0, $zero, $zero
/* E25088 802B61B8 24050002 */  addiu     $a1, $zero, 0x2
/* E2508C 802B61BC 4407C000 */  mfc1      $a3, $f24
glabel func_802B61C0
/* E25090 802B61C0 0C0B2D72 */  jal       exec_ShakeCamX
/* E25094 802B61C4 0240302D */   daddu    $a2, $s2, $zero
.L802B61C8:
/* E25098 802B61C8 0000202D */  daddu     $a0, $zero, $zero
.L802B61CC:
/* E2509C 802B61CC 44910000 */  mtc1      $s1, $f0
/* E250A0 802B61D0 00000000 */  nop
.L802B61D4:
/* E250A4 802B61D4 46800020 */  cvt.s.w   $f0, $f0
.L802B61D8:
/* E250A8 802B61D8 26430003 */  addiu     $v1, $s2, 0x3
.L802B61DC:
/* E250AC 802B61DC 00031040 */  sll       $v0, $v1, 1
/* E250B0 802B61E0 4405D000 */  mfc1      $a1, $f26
glabel func_802B61E4
/* E250B4 802B61E4 4406A000 */  mfc1      $a2, $f20
.L802B61E8:
/* E250B8 802B61E8 4407B000 */  mfc1      $a3, $f22
.L802B61EC:
/* E250BC 802B61EC 00431021 */  addu      $v0, $v0, $v1
.L802B61F0:
/* E250C0 802B61F0 E7A00010 */  swc1      $f0, 0x10($sp)
.L802B61F4:
/* E250C4 802B61F4 AFB30014 */  sw        $s3, 0x14($sp)
.L802B61F8:
/* E250C8 802B61F8 AFA00018 */  sw        $zero, 0x18($sp)
.L802B61FC:
/* E250CC 802B61FC 0C01C0DC */  jal       fx_smoke_impact
.L802B6200:
/* E250D0 802B6200 AFA2001C */   sw       $v0, 0x1C($sp)
.L802B6204:
/* E250D4 802B6204 0C03A752 */  jal       is_ability_active
glabel .L802B6208
/* E250D8 802B6208 2404000F */   addiu    $a0, $zero, 0xF
/* E250DC 802B620C 2443FFFF */  addiu     $v1, $v0, -0x1
.L802B6210:
/* E250E0 802B6210 2C620006 */  sltiu     $v0, $v1, 0x6
.L802B6214:
/* E250E4 802B6214 10400011 */  beqz      $v0, .L802B625C
glabel .L802B6218
/* E250E8 802B6218 00031080 */   sll      $v0, $v1, 2
/* E250EC 802B621C 3C01802B */  lui       $at, %hi(jtbl_802B6DF0)
.L802B6220:
/* E250F0 802B6220 00220821 */  addu      $at, $at, $v0
.L802B6224:
/* E250F4 802B6224 8C226DF0 */  lw        $v0, %lo(jtbl_802B6DF0)($at)
glabel .L802B6228
/* E250F8 802B6228 00400008 */  jr        $v0
.L802B622C:
/* E250FC 802B622C 00000000 */   nop
glabel action_update_step_up_peach
/* E25100 802B6230 080AD897 */  j         .L802B625C
/* E25104 802B6234 24100372 */   addiu    $s0, $zero, 0x372
glabel .L802B6238
/* E25108 802B6238 080AD897 */  j         .L802B625C
glabel .L802B623C
/* E2510C 802B623C 241000F1 */   addiu    $s0, $zero, 0xF1
glabel .L802B6240
/* E25110 802B6240 080AD897 */  j         .L802B625C
glabel .L802B6244
/* E25114 802B6244 241000DC */   addiu    $s0, $zero, 0xDC
glabel .L802B6248
/* E25118 802B6248 080AD897 */  j         .L802B625C
/* E2511C 802B624C 24102072 */   addiu    $s0, $zero, 0x2072
glabel .L802B6250
/* E25120 802B6250 080AD897 */  j         .L802B625C
.L802B6254:
/* E25124 802B6254 24102073 */   addiu    $s0, $zero, 0x2073
glabel .L802B6258
/* E25128 802B6258 2410205B */  addiu     $s0, $zero, 0x205B
.L802B625C:
/* E2512C 802B625C 0200202D */  daddu     $a0, $s0, $zero
/* E25130 802B6260 0C052736 */  jal       sfx_play_sound_at_player
/* E25134 802B6264 0000282D */   daddu    $a1, $zero, $zero
.L802B6268:
/* E25138 802B6268 24040100 */  addiu     $a0, $zero, 0x100
.L802B626C:
/* E2513C 802B626C 0C00A3C2 */  jal       start_rumble
/* E25140 802B6270 24050032 */   addiu    $a1, $zero, 0x32
.L802B6274:
/* E25144 802B6274 8FBF0034 */  lw        $ra, 0x34($sp)
glabel .L802B6278
/* E25148 802B6278 8FB40030 */  lw        $s4, 0x30($sp)
/* E2514C 802B627C 8FB3002C */  lw        $s3, 0x2C($sp)
.L802B6280:
/* E25150 802B6280 8FB20028 */  lw        $s2, 0x28($sp)
.L802B6284:
/* E25154 802B6284 8FB10024 */  lw        $s1, 0x24($sp)
glabel action_update_run
/* E25158 802B6288 8FB00020 */  lw        $s0, 0x20($sp)
/* E2515C 802B628C D7BA0050 */  ldc1      $f26, 0x50($sp)
.L802B6290:
/* E25160 802B6290 D7B80048 */  ldc1      $f24, 0x48($sp)
glabel func_802B6294
/* E25164 802B6294 D7B60040 */  ldc1      $f22, 0x40($sp)
glabel .L802B6298
/* E25168 802B6298 D7B40038 */  ldc1      $f20, 0x38($sp)
/* E2516C 802B629C 03E00008 */  jr        $ra
/* E25170 802B62A0 27BD0058 */   addiu    $sp, $sp, 0x58

### DECOMPILED C INSTRUCTIONS:

void action_hammer_play_hit_fx(s32 hitID) {
    PlayerStatus* playerStatus = &gPlayerStatus;
    f32 shakeAmt;
    s32 time;
    s32 radius;
    s32 soundID;
    f32 theta, sinTheta, cosTheta;
    s32 numParticles;
    f32 x, y, z;

    if (gPlayerData.hammerLevel == 2) {
        shakeAmt = 1.2f;
        time = 1;
        radius = 28;
        soundID = SOUND_211A;
    } else if (gPlayerData.hammerLevel == 1) {
        shakeAmt = 0.8f;
        time = 1;
        radius = 16;
        soundID = SOUND_2119;
    } else {
        shakeAmt = 0.4f;
        time = 1;
        radius = 4;
        soundID = SOUND_2118;
    }

    theta = DEG_TO_RAD(func_800E5348());
    sinTheta = sin_rad(theta) * 25.0f;
    cosTheta = cos_rad(theta) * -25.0f;

    if (hitID < 0) {
        numParticles = 6;
        x = playerStatus->position.x + sinTheta;
        y = playerStatus->position.y;
        z = playerStatus->position.z + cosTheta;
    } else {
        numParticles = 3;
        x = HammerHit->hitPos.x + sinTheta;
        y = HammerHit->hitPos.y + playerStatus->colliderHeight - 5.0f;
        z = HammerHit->hitPos.z + cosTheta;
        radius = 1;
    }

    exec_ShakeCamX(0, 2, time, shakeAmt);
    fx_smoke_impact(0, x, y, z, radius, numParticles, 0, (time + 3) * 3);

    switch (is_ability_active(ABILITY_ATTACK_FX)) {
        case 1:
            soundID = SOUND_372;
            break;
        case 2:
            soundID = SOUND_F1;
            break;
        case 3:
            soundID = SOUND_DC;
            break;
        case 4:
            soundID = SOUND_2072;
            break;
        case 5:
            soundID = SOUND_2073;
            break;
        case 6:
            soundID = SOUND_205B;
            break;
    }

    sfx_play_sound_at_player(soundID, SOUND_SPACE_MODE_0);
    start_rumble(256, 50);
}


### RAW ASSEMBLY INSTRUCTIONS:

glabel energy_shockwave_appendGfx
/* 375224 E00723D4 27BDFF50 */  addiu     $sp, $sp, -0xB0
/* 375228 E00723D8 3C03DB06 */  lui       $v1, (0xDB060024 >> 16)
/* 37522C E00723DC 34630024 */  ori       $v1, $v1, (0xDB060024 & 0xFFFF)
/* 375230 E00723E0 3C05FFB3 */  lui       $a1, (0xFFB31E00 >> 16)
/* 375234 E00723E4 AFB10094 */  sw        $s1, 0x94($sp)
/* 375238 E00723E8 3C11800A */  lui       $s1, %hi(gMainGfxPos)
/* 37523C E00723EC 2631A66C */  addiu     $s1, $s1, %lo(gMainGfxPos)
/* 375240 E00723F0 34A51E00 */  ori       $a1, $a1, (0xFFB31E00 & 0xFFFF)
/* 375244 E00723F4 AFB500A4 */  sw        $s5, 0xA4($sp)
/* 375248 E00723F8 3C15E700 */  lui       $s5, (0xE7000000 >> 16)
/* 37524C E00723FC AFBF00A8 */  sw        $ra, 0xA8($sp)
/* 375250 E0072400 AFB400A0 */  sw        $s4, 0xA0($sp)
/* 375254 E0072404 AFB3009C */  sw        $s3, 0x9C($sp)
/* 375258 E0072408 AFB20098 */  sw        $s2, 0x98($sp)
/* 37525C E007240C AFB00090 */  sw        $s0, 0x90($sp)
/* 375260 E0072410 8E280000 */  lw        $t0, 0x0($s1)
/* 375264 E0072414 3C014080 */  lui       $at, (0x40800000 >> 16)
/* 375268 E0072418 44812000 */  mtc1      $at, $f4
/* 37526C E007241C 0100102D */  daddu     $v0, $t0, $zero
/* 375270 E0072420 25080008 */  addiu     $t0, $t0, 0x8
/* 375274 E0072424 AE280000 */  sw        $t0, 0x0($s1)
/* 375278 E0072428 8C90000C */  lw        $s0, 0xC($a0)
/* 37527C E007242C 3C14DE00 */  lui       $s4, (0xDE000000 >> 16)
/* 375280 E0072430 AC550000 */  sw        $s5, 0x0($v0)
/* 375284 E0072434 AC400004 */  sw        $zero, 0x4($v0)
/* 375288 E0072438 25020008 */  addiu     $v0, $t0, 0x8
/* 37528C E007243C AE220000 */  sw        $v0, 0x0($s1)
/* 375290 E0072440 25020010 */  addiu     $v0, $t0, 0x10
/* 375294 E0072444 AD030000 */  sw        $v1, 0x0($t0)
/* 375298 E0072448 AE220000 */  sw        $v0, 0x0($s1)
/* 37529C E007244C 8C830010 */  lw        $v1, 0x10($a0)
/* 3752A0 E0072450 25020018 */  addiu     $v0, $t0, 0x18
/* 3752A4 E0072454 AE220000 */  sw        $v0, 0x0($s1)
/* 3752A8 E0072458 8C63001C */  lw        $v1, 0x1C($v1)
/* 3752AC E007245C 3C020900 */  lui       $v0, %hi(D_09000E60_40E0F0)
/* 3752B0 E0072460 24420E60 */  addiu     $v0, $v0, %lo(D_09000E60_40E0F0)
/* 3752B4 E0072464 AD02000C */  sw        $v0, 0xC($t0)
/* 3752B8 E0072468 3C02FA00 */  lui       $v0, (0xFA000000 >> 16)
/* 3752BC E007246C AD020010 */  sw        $v0, 0x10($t0)
/* 3752C0 E0072470 3C028000 */  lui       $v0, (0x80000000 >> 16)
/* 3752C4 E0072474 AD140008 */  sw        $s4, 0x8($t0)
/* 3752C8 E0072478 00621821 */  addu      $v1, $v1, $v0
/* 3752CC E007247C AD030004 */  sw        $v1, 0x4($t0)
/* 3752D0 E0072480 92030027 */  lbu       $v1, 0x27($s0)
/* 3752D4 E0072484 25020020 */  addiu     $v0, $t0, 0x20
/* 3752D8 E0072488 AE220000 */  sw        $v0, 0x0($s1)
/* 3752DC E007248C 3C02FB00 */  lui       $v0, (0xFB000000 >> 16)
/* 3752E0 E0072490 AD020018 */  sw        $v0, 0x18($t0)
/* 3752E4 E0072494 00651825 */  or        $v1, $v1, $a1
/* 3752E8 E0072498 AD030014 */  sw        $v1, 0x14($t0)
/* 3752EC E007249C 92020050 */  lbu       $v0, 0x50($s0)
/* 3752F0 E00724A0 92040051 */  lbu       $a0, 0x51($s0)
/* 3752F4 E00724A4 92030052 */  lbu       $v1, 0x52($s0)
/* 3752F8 E00724A8 00021600 */  sll       $v0, $v0, 24
/* 3752FC E00724AC 00042400 */  sll       $a0, $a0, 16
/* 375300 E00724B0 00441025 */  or        $v0, $v0, $a0
/* 375304 E00724B4 00031A00 */  sll       $v1, $v1, 8
/* 375308 E00724B8 00431025 */  or        $v0, $v0, $v1
/* 37530C E00724BC 34420080 */  ori       $v0, $v0, 0x80
/* 375310 E00724C0 AD02001C */  sw        $v0, 0x1C($t0)
/* 375314 E00724C4 C6020030 */  lwc1      $f2, 0x30($s0)
/* 375318 E00724C8 46041082 */  mul.s     $f2, $f2, $f4
/* 37531C E00724CC 00000000 */  nop
/* 375320 E00724D0 3C130001 */  lui       $s3, (0x11630 >> 16)
/* 375324 E00724D4 36731630 */  ori       $s3, $s3, (0x11630 & 0xFFFF)
/* 375328 E00724D8 C6000034 */  lwc1      $f0, 0x34($s0)
/* 37532C E00724DC 3C07F200 */  lui       $a3, (0xF2000000 >> 16)
/* 375330 E00724E0 46040002 */  mul.s     $f0, $f0, $f4
/* 375334 E00724E4 00000000 */  nop
/* 375338 E00724E8 27A40010 */  addiu     $a0, $sp, 0x10
/* 37533C E00724EC 25020028 */  addiu     $v0, $t0, 0x28
/* 375340 E00724F0 AE220000 */  sw        $v0, 0x0($s1)
/* 375344 E00724F4 4600118D */  trunc.w.s $f6, $f2
/* 375348 E00724F8 44023000 */  mfc1      $v0, $f6
/* 37534C E00724FC 4600018D */  trunc.w.s $f6, $f0
/* 375350 E0072500 44063000 */  mfc1      $a2, $f6
/* 375354 E0072504 30450FFF */  andi      $a1, $v0, 0xFFF
/* 375358 E0072508 00052B00 */  sll       $a1, $a1, 12
/* 37535C E007250C 30C30FFF */  andi      $v1, $a2, 0xFFF
/* 375360 E0072510 00671825 */  or        $v1, $v1, $a3
/* 375364 E0072514 00A32825 */  or        $a1, $a1, $v1
/* 375368 E0072518 244200FC */  addiu     $v0, $v0, 0xFC
/* 37536C E007251C C6000038 */  lwc1      $f0, 0x38($s0)
/* 375370 E0072520 30420FFF */  andi      $v0, $v0, 0xFFF
/* 375374 E0072524 46040002 */  mul.s     $f0, $f0, $f4
/* 375378 E0072528 00000000 */  nop
/* 37537C E007252C 00021300 */  sll       $v0, $v0, 12
/* 375380 E0072530 24C600FC */  addiu     $a2, $a2, 0xFC
/* 375384 E0072534 C602003C */  lwc1      $f2, 0x3C($s0)
/* 375388 E0072538 30C60FFF */  andi      $a2, $a2, 0xFFF
/* 37538C E007253C 46041082 */  mul.s     $f2, $f2, $f4
/* 375390 E0072540 00000000 */  nop
/* 375394 E0072544 00461025 */  or        $v0, $v0, $a2
/* 375398 E0072548 AD050020 */  sw        $a1, 0x20($t0)
/* 37539C E007254C AD020024 */  sw        $v0, 0x24($t0)
/* 3753A0 E0072550 4600018D */  trunc.w.s $f6, $f0
/* 3753A4 E0072554 44053000 */  mfc1      $a1, $f6
/* 3753A8 E0072558 4600118D */  trunc.w.s $f6, $f2
/* 3753AC E007255C 44063000 */  mfc1      $a2, $f6
/* 3753B0 E0072560 30A30FFF */  andi      $v1, $a1, 0xFFF
/* 3753B4 E0072564 00031B00 */  sll       $v1, $v1, 12
/* 3753B8 E0072568 30C20FFF */  andi      $v0, $a2, 0xFFF
/* 3753BC E007256C 00471025 */  or        $v0, $v0, $a3
/* 3753C0 E0072570 00621825 */  or        $v1, $v1, $v0
/* 3753C4 E0072574 24A5007C */  addiu     $a1, $a1, 0x7C
/* 3753C8 E0072578 30A50FFF */  andi      $a1, $a1, 0xFFF
/* 3753CC E007257C 00052B00 */  sll       $a1, $a1, 12
/* 3753D0 E0072580 24C6007C */  addiu     $a2, $a2, 0x7C
/* 3753D4 E0072584 30C60FFF */  andi      $a2, $a2, 0xFFF
/* 3753D8 E0072588 3C020100 */  lui       $v0, (0x1000000 >> 16)
/* 3753DC E007258C 00C23025 */  or        $a2, $a2, $v0
/* 3753E0 E0072590 00A62825 */  or        $a1, $a1, $a2
/* 3753E4 E0072594 AD030028 */  sw        $v1, 0x28($t0)
/* 3753E8 E0072598 AD05002C */  sw        $a1, 0x2C($t0)
/* 3753EC E007259C 8E050004 */  lw        $a1, 0x4($s0)
/* 3753F0 E00725A0 8E060008 */  lw        $a2, 0x8($s0)
/* 3753F4 E00725A4 8E07000C */  lw        $a3, 0xC($s0)
/* 3753F8 E00725A8 25080030 */  addiu     $t0, $t0, 0x30
/* 3753FC E00725AC 0C080108 */  jal       shim_guTranslateF
/* 375400 E00725B0 AE280000 */   sw       $t0, 0x0($s1)
/* 375404 E00725B4 8E05001C */  lw        $a1, 0x1C($s0)
/* 375408 E00725B8 27B00050 */  addiu     $s0, $sp, 0x50
/* 37540C E00725BC 0200202D */  daddu     $a0, $s0, $zero
/* 375410 E00725C0 00A0302D */  daddu     $a2, $a1, $zero
/* 375414 E00725C4 0C080110 */  jal       shim_guScaleF
/* 375418 E00725C8 00A0382D */   daddu    $a3, $a1, $zero
/* 37541C E00725CC 0200202D */  daddu     $a0, $s0, $zero
/* 375420 E00725D0 27A50010 */  addiu     $a1, $sp, 0x10
/* 375424 E00725D4 0C080114 */  jal       shim_guMtxCatF
/* 375428 E00725D8 00A0302D */   daddu    $a2, $a1, $zero
/* 37542C E00725DC 27A40010 */  addiu     $a0, $sp, 0x10
/* 375430 E00725E0 3C108007 */  lui       $s0, %hi(gMatrixListPos)
/* 375434 E00725E4 261041F0 */  addiu     $s0, $s0, %lo(gMatrixListPos)
/* 375438 E00725E8 3C12800A */  lui       $s2, %hi(gDisplayContext)
/* 37543C E00725EC 2652A674 */  addiu     $s2, $s2, %lo(gDisplayContext)
/* 375440 E00725F0 96050000 */  lhu       $a1, 0x0($s0)
/* 375444 E00725F4 8E420000 */  lw        $v0, 0x0($s2)
/* 375448 E00725F8 00052980 */  sll       $a1, $a1, 6
/* 37544C E00725FC 00B32821 */  addu      $a1, $a1, $s3
/* 375450 E0072600 0C080118 */  jal       shim_guMtxF2L
/* 375454 E0072604 00452821 */   addu     $a1, $v0, $a1
/* 375458 E0072608 3C06D838 */  lui       $a2, (0xD8380002 >> 16)
/* 37545C E007260C 8E240000 */  lw        $a0, 0x0($s1)
/* 375460 E0072610 34C60002 */  ori       $a2, $a2, (0xD8380002 & 0xFFFF)
/* 375464 E0072614 0080282D */  daddu     $a1, $a0, $zero
/* 375468 E0072618 24840008 */  addiu     $a0, $a0, 0x8
/* 37546C E007261C AE240000 */  sw        $a0, 0x0($s1)
/* 375470 E0072620 96020000 */  lhu       $v0, 0x0($s0)
/* 375474 E0072624 3C03DA38 */  lui       $v1, (0xDA380000 >> 16)
/* 375478 E0072628 ACA30000 */  sw        $v1, 0x0($a1)
/* 37547C E007262C 24430001 */  addiu     $v1, $v0, 0x1
/* 375480 E0072630 3042FFFF */  andi      $v0, $v0, 0xFFFF
/* 375484 E0072634 00021180 */  sll       $v0, $v0, 6
/* 375488 E0072638 A6030000 */  sh        $v1, 0x0($s0)
/* 37548C E007263C 8E430000 */  lw        $v1, 0x0($s2)
/* 375490 E0072640 00531021 */  addu      $v0, $v0, $s3
/* 375494 E0072644 00621821 */  addu      $v1, $v1, $v0
/* 375498 E0072648 24820008 */  addiu     $v0, $a0, 0x8
/* 37549C E007264C ACA30004 */  sw        $v1, 0x4($a1)
/* 3754A0 E0072650 AE220000 */  sw        $v0, 0x0($s1)
/* 3754A4 E0072654 3C020900 */  lui       $v0, %hi(D_09000DC0_40E050)
/* 3754A8 E0072658 24420DC0 */  addiu     $v0, $v0, %lo(D_09000DC0_40E050)
/* 3754AC E007265C AC820004 */  sw        $v0, 0x4($a0)
/* 3754B0 E0072660 24820010 */  addiu     $v0, $a0, 0x10
/* 3754B4 E0072664 AC940000 */  sw        $s4, 0x0($a0)
/* 3754B8 E0072668 AE220000 */  sw        $v0, 0x0($s1)
/* 3754BC E007266C 24020040 */  addiu     $v0, $zero, 0x40
/* 3754C0 E0072670 AC82000C */  sw        $v0, 0xC($a0)
/* 3754C4 E0072674 24820018 */  addiu     $v0, $a0, 0x18
/* 3754C8 E0072678 AC860008 */  sw        $a2, 0x8($a0)
/* 3754CC E007267C AE220000 */  sw        $v0, 0x0($s1)
/* 3754D0 E0072680 AC950010 */  sw        $s5, 0x10($a0)
/* 3754D4 E0072684 AC800014 */  sw        $zero, 0x14($a0)
/* 3754D8 E0072688 8FBF00A8 */  lw        $ra, 0xA8($sp)
/* 3754DC E007268C 8FB500A4 */  lw        $s5, 0xA4($sp)
/* 3754E0 E0072690 8FB400A0 */  lw        $s4, 0xA0($sp)
/* 3754E4 E0072694 8FB3009C */  lw        $s3, 0x9C($sp)
/* 3754E8 E0072698 8FB20098 */  lw        $s2, 0x98($sp)
/* 3754EC E007269C 8FB10094 */  lw        $s1, 0x94($sp)
/* 3754F0 E00726A0 8FB00090 */  lw        $s0, 0x90($sp)
/* 3754F4 E00726A4 03E00008 */  jr        $ra
/* 3754F8 E00726A8 27BD00B0 */   addiu    $sp, $sp, 0xB0
/* 3754FC E00726AC 00000000 */  nop

### DECOMPILED C INSTRUCTIONS:

void energy_shockwave_appendGfx(void* effect) {
    EnergyShockwaveFXData* data = ((EffectInstance*)effect)->data.energyShockwave;
    Matrix4f sp10;
    Matrix4f sp50;
    s32 uls;
    s32 ult;
    s32 uls2;
    s32 ult2;

    gDPPipeSync(gMainGfxPos++);
    gSPSegment(gMainGfxPos++, 0x09, VIRTUAL_TO_PHYSICAL(((EffectInstance*)effect)->graphics->data));
    gSPDisplayList(gMainGfxPos++, D_09000E60_376370);
    gDPSetPrimColor(gMainGfxPos++, 0, 0, 255, 179, 30, data->unk_24);
    gDPSetEnvColor(gMainGfxPos++, data->unk_50, data->unk_51, data->unk_52, 128);

    uls = data->unk_30 * 4;
    ult = data->unk_34 * 4;
    uls2 = data->unk_38 * 4;
    ult2 = data->unk_3C * 4;

    gDPSetTileSize(gMainGfxPos++, G_TX_RENDERTILE, uls, ult, uls + 252, ult + 252);
    gDPSetTileSize(gMainGfxPos++, 1, uls2, ult2, uls2 + 124, ult2 + 124);

    shim_guTranslateF(sp10, data->unk_04, data->unk_08, data->unk_0C);
    shim_guScaleF(sp50, data->unk_1C, data->unk_1C, data->unk_1C);
    shim_guMtxCatF(sp50, sp10, sp10);
    shim_guMtxF2L(sp10, &gDisplayContext->matrixStack[gMatrixListPos]);

    gSPMatrix(gMainGfxPos++, &gDisplayContext->matrixStack[gMatrixListPos++], G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
    gSPDisplayList(gMainGfxPos++, D_09000DC0_3762D0);
    gSPPopMatrix(gMainGfxPos++, G_MTX_MODELVIEW);
    gDPPipeSync(gMainGfxPos++);
}


### RAW ASSEMBLY INSTRUCTIONS:

glabel shiny_flare_appendGfx
/* 3D7470 E00DA230 27BDFF48 */  addiu     $sp, $sp, -0xB8
/* 3D7474 E00DA234 0080302D */  daddu     $a2, $a0, $zero
/* 3D7478 E00DA238 3C07DB06 */  lui       $a3, (0xDB060024 >> 16)
/* 3D747C E00DA23C 34E70024 */  ori       $a3, $a3, (0xDB060024 & 0xFFFF)
/* 3D7480 E00DA240 27A40010 */  addiu     $a0, $sp, 0x10
/* 3D7484 E00DA244 AFB600A8 */  sw        $s6, 0xA8($sp)
/* 3D7488 E00DA248 3C160001 */  lui       $s6, (0x11630 >> 16)
/* 3D748C E00DA24C AFB3009C */  sw        $s3, 0x9C($sp)
/* 3D7490 E00DA250 3C13800A */  lui       $s3, %hi(gMainGfxPos)
/* 3D7494 E00DA254 2673A66C */  addiu     $s3, $s3, %lo(gMainGfxPos)
/* 3D7498 E00DA258 36D61630 */  ori       $s6, $s6, (0x11630 & 0xFFFF)
/* 3D749C E00DA25C AFBF00AC */  sw        $ra, 0xAC($sp)
/* 3D74A0 E00DA260 AFB500A4 */  sw        $s5, 0xA4($sp)
/* 3D74A4 E00DA264 AFB400A0 */  sw        $s4, 0xA0($sp)
/* 3D74A8 E00DA268 AFB20098 */  sw        $s2, 0x98($sp)
/* 3D74AC E00DA26C AFB10094 */  sw        $s1, 0x94($sp)
/* 3D74B0 E00DA270 AFB00090 */  sw        $s0, 0x90($sp)
/* 3D74B4 E00DA274 F7B400B0 */  sdc1      $f20, 0xB0($sp)
/* 3D74B8 E00DA278 8E650000 */  lw        $a1, 0x0($s3)
/* 3D74BC E00DA27C 8CD2000C */  lw        $s2, 0xC($a2)
/* 3D74C0 E00DA280 00A0182D */  daddu     $v1, $a1, $zero
/* 3D74C4 E00DA284 24A50008 */  addiu     $a1, $a1, 0x8
/* 3D74C8 E00DA288 AE650000 */  sw        $a1, 0x0($s3)
/* 3D74CC E00DA28C 8E550024 */  lw        $s5, 0x24($s2)
/* 3D74D0 E00DA290 C6540028 */  lwc1      $f20, 0x28($s2)
/* 3D74D4 E00DA294 C640002C */  lwc1      $f0, 0x2C($s2)
/* 3D74D8 E00DA298 3C02E700 */  lui       $v0, (0xE7000000 >> 16)
/* 3D74DC E00DA29C AC620000 */  sw        $v0, 0x0($v1)
/* 3D74E0 E00DA2A0 AC600004 */  sw        $zero, 0x4($v1)
/* 3D74E4 E00DA2A4 ACA70000 */  sw        $a3, 0x0($a1)
/* 3D74E8 E00DA2A8 8CC30010 */  lw        $v1, 0x10($a2)
/* 3D74EC E00DA2AC 24A20008 */  addiu     $v0, $a1, 0x8
/* 3D74F0 E00DA2B0 AE620000 */  sw        $v0, 0x0($s3)
/* 3D74F4 E00DA2B4 8C62001C */  lw        $v0, 0x1C($v1)
/* 3D74F8 E00DA2B8 3C038000 */  lui       $v1, (0x80000000 >> 16)
/* 3D74FC E00DA2BC 4600A502 */  mul.s     $f20, $f20, $f0
/* 3D7500 E00DA2C0 00000000 */  nop
/* 3D7504 E00DA2C4 00431021 */  addu      $v0, $v0, $v1
/* 3D7508 E00DA2C8 3C03800B */  lui       $v1, %hi(gCameras)
/* 3D750C E00DA2CC 24631D80 */  addiu     $v1, $v1, %lo(gCameras)
/* 3D7510 E00DA2D0 ACA20004 */  sw        $v0, 0x4($a1)
/* 3D7514 E00DA2D4 8E450004 */  lw        $a1, 0x4($s2)
/* 3D7518 E00DA2D8 8E460008 */  lw        $a2, 0x8($s2)
/* 3D751C E00DA2DC 3C028007 */  lui       $v0, %hi(gCurrentCameraID)
/* 3D7520 E00DA2E0 8C427410 */  lw        $v0, %lo(gCurrentCameraID)($v0)
/* 3D7524 E00DA2E4 8E47000C */  lw        $a3, 0xC($s2)
/* 3D7528 E00DA2E8 00028880 */  sll       $s1, $v0, 2
/* 3D752C E00DA2EC 02228821 */  addu      $s1, $s1, $v0
/* 3D7530 E00DA2F0 00118880 */  sll       $s1, $s1, 2
/* 3D7534 E00DA2F4 02228823 */  subu      $s1, $s1, $v0
/* 3D7538 E00DA2F8 001110C0 */  sll       $v0, $s1, 3
/* 3D753C E00DA2FC 02228821 */  addu      $s1, $s1, $v0
/* 3D7540 E00DA300 001188C0 */  sll       $s1, $s1, 3
/* 3D7544 E00DA304 0C080108 */  jal       shim_guTranslateF
/* 3D7548 E00DA308 02238821 */   addu     $s1, $s1, $v1
/* 3D754C E00DA30C 27B00050 */  addiu     $s0, $sp, 0x50
/* 3D7550 E00DA310 4405A000 */  mfc1      $a1, $f20
/* 3D7554 E00DA314 0200202D */  daddu     $a0, $s0, $zero
/* 3D7558 E00DA318 00A0302D */  daddu     $a2, $a1, $zero
/* 3D755C E00DA31C 0C080110 */  jal       shim_guScaleF
/* 3D7560 E00DA320 00A0382D */   daddu    $a3, $a1, $zero
/* 3D7564 E00DA324 0200202D */  daddu     $a0, $s0, $zero
/* 3D7568 E00DA328 27A50010 */  addiu     $a1, $sp, 0x10
/* 3D756C E00DA32C 0C080114 */  jal       shim_guMtxCatF
/* 3D7570 E00DA330 00A0302D */   daddu    $a2, $a1, $zero
/* 3D7574 E00DA334 27A40010 */  addiu     $a0, $sp, 0x10
/* 3D7578 E00DA338 3C108007 */  lui       $s0, %hi(gMatrixListPos)
/* 3D757C E00DA33C 261041F0 */  addiu     $s0, $s0, %lo(gMatrixListPos)
/* 3D7580 E00DA340 3C14800A */  lui       $s4, %hi(gDisplayContext)
/* 3D7584 E00DA344 2694A674 */  addiu     $s4, $s4, %lo(gDisplayContext)
/* 3D7588 E00DA348 96050000 */  lhu       $a1, 0x0($s0)
/* 3D758C E00DA34C 8E820000 */  lw        $v0, 0x0($s4)
/* 3D7590 E00DA350 00052980 */  sll       $a1, $a1, 6
/* 3D7594 E00DA354 00B62821 */  addu      $a1, $a1, $s6
/* 3D7598 E00DA358 0C080118 */  jal       shim_guMtxF2L
/* 3D759C E00DA35C 00452821 */   addu     $a1, $v0, $a1
/* 3D75A0 E00DA360 3C03DA38 */  lui       $v1, (0xDA380002 >> 16)
/* 3D75A4 E00DA364 34630002 */  ori       $v1, $v1, (0xDA380002 & 0xFFFF)
/* 3D75A8 E00DA368 3C06DA38 */  lui       $a2, (0xDA380001 >> 16)
/* 3D75AC E00DA36C 34C60001 */  ori       $a2, $a2, (0xDA380001 & 0xFFFF)
/* 3D75B0 E00DA370 3C092AAA */  lui       $t1, (0x2AAAAAAB >> 16)
/* 3D75B4 E00DA374 3529AAAB */  ori       $t1, $t1, (0x2AAAAAAB & 0xFFFF)
/* 3D75B8 E00DA378 3C08DE00 */  lui       $t0, (0xDE000000 >> 16)
/* 3D75BC E00DA37C 32B500FF */  andi      $s5, $s5, 0xFF
/* 3D75C0 E00DA380 3C07D838 */  lui       $a3, (0xD8380002 >> 16)
/* 3D75C4 E00DA384 8E650000 */  lw        $a1, 0x0($s3)
/* 3D75C8 E00DA388 96020000 */  lhu       $v0, 0x0($s0)
/* 3D75CC E00DA38C 00A0202D */  daddu     $a0, $a1, $zero
/* 3D75D0 E00DA390 24A50008 */  addiu     $a1, $a1, 0x8
/* 3D75D4 E00DA394 AE650000 */  sw        $a1, 0x0($s3)
/* 3D75D8 E00DA398 AC830000 */  sw        $v1, 0x0($a0)
/* 3D75DC E00DA39C 24430001 */  addiu     $v1, $v0, 0x1
/* 3D75E0 E00DA3A0 3042FFFF */  andi      $v0, $v0, 0xFFFF
/* 3D75E4 E00DA3A4 00021180 */  sll       $v0, $v0, 6
/* 3D75E8 E00DA3A8 A6030000 */  sh        $v1, 0x0($s0)
/* 3D75EC E00DA3AC 8E830000 */  lw        $v1, 0x0($s4)
/* 3D75F0 E00DA3B0 00561021 */  addu      $v0, $v0, $s6
/* 3D75F4 E00DA3B4 00621821 */  addu      $v1, $v1, $v0
/* 3D75F8 E00DA3B8 24A20008 */  addiu     $v0, $a1, 0x8
/* 3D75FC E00DA3BC AC830004 */  sw        $v1, 0x4($a0)
/* 3D7600 E00DA3C0 AE620000 */  sw        $v0, 0x0($s3)
/* 3D7604 E00DA3C4 24A20010 */  addiu     $v0, $a1, 0x10
/* 3D7608 E00DA3C8 ACA60000 */  sw        $a2, 0x0($a1)
/* 3D760C E00DA3CC AE620000 */  sw        $v0, 0x0($s3)
/* 3D7610 E00DA3D0 8E230204 */  lw        $v1, 0x204($s1)
/* 3D7614 E00DA3D4 3C020900 */  lui       $v0, %hi(D_09000240_4152A0)
/* 3D7618 E00DA3D8 24420240 */  addiu     $v0, $v0, %lo(D_09000240_4152A0)
/* 3D761C E00DA3DC ACA2000C */  sw        $v0, 0xC($a1)
/* 3D7620 E00DA3E0 24A20018 */  addiu     $v0, $a1, 0x18
/* 3D7624 E00DA3E4 3C06FA00 */  lui       $a2, (0xFA000000 >> 16)
/* 3D7628 E00DA3E8 ACA80008 */  sw        $t0, 0x8($a1)
/* 3D762C E00DA3EC AE620000 */  sw        $v0, 0x0($s3)
/* 3D7630 E00DA3F0 ACA60010 */  sw        $a2, 0x10($a1)
/* 3D7634 E00DA3F4 ACA30004 */  sw        $v1, 0x4($a1)
/* 3D7638 E00DA3F8 9242001B */  lbu       $v0, 0x1B($s2)
/* 3D763C E00DA3FC 9244001F */  lbu       $a0, 0x1F($s2)
/* 3D7640 E00DA400 92430023 */  lbu       $v1, 0x23($s2)
/* 3D7644 E00DA404 00021600 */  sll       $v0, $v0, 24
/* 3D7648 E00DA408 00042400 */  sll       $a0, $a0, 16
/* 3D764C E00DA40C 00441025 */  or        $v0, $v0, $a0
/* 3D7650 E00DA410 00031A00 */  sll       $v1, $v1, 8
/* 3D7654 E00DA414 00431025 */  or        $v0, $v0, $v1
/* 3D7658 E00DA418 00551025 */  or        $v0, $v0, $s5
/* 3D765C E00DA41C ACA20014 */  sw        $v0, 0x14($a1)
/* 3D7660 E00DA420 8E420014 */  lw        $v0, 0x14($s2)
/* 3D7664 E00DA424 34E70002 */  ori       $a3, $a3, (0xD8380002 & 0xFFFF)
/* 3D7668 E00DA428 00022040 */  sll       $a0, $v0, 1
/* 3D766C E00DA42C 00822021 */  addu      $a0, $a0, $v0
/* 3D7670 E00DA430 00890018 */  mult      $a0, $t1
/* 3D7674 E00DA434 24A20020 */  addiu     $v0, $a1, 0x20
/* 3D7678 E00DA438 AE620000 */  sw        $v0, 0x0($s3)
/* 3D767C E00DA43C 000417C3 */  sra       $v0, $a0, 31
/* 3D7680 E00DA440 ACA60018 */  sw        $a2, 0x18($a1)
/* 3D7684 E00DA444 00005010 */  mfhi      $t2
/* 3D7688 E00DA448 000A1883 */  sra       $v1, $t2, 2
/* 3D768C E00DA44C 00621823 */  subu      $v1, $v1, $v0
/* 3D7690 E00DA450 00031040 */  sll       $v0, $v1, 1
/* 3D7694 E00DA454 00431021 */  addu      $v0, $v0, $v1
/* 3D7698 E00DA458 000210C0 */  sll       $v0, $v0, 3
/* 3D769C E00DA45C 00822023 */  subu      $a0, $a0, $v0
/* 3D76A0 E00DA460 3C03E00E */  lui       $v1, (0xE00E0000 >> 16)
/* 3D76A4 E00DA464 00641821 */  addu      $v1, $v1, $a0
/* 3D76A8 E00DA468 9063A500 */  lbu       $v1, -0x5B00($v1)
/* 3D76AC E00DA46C 3C06E00E */  lui       $a2, (0xE00E0000 >> 16)
/* 3D76B0 E00DA470 00C43021 */  addu      $a2, $a2, $a0
/* 3D76B4 E00DA474 90C6A501 */  lbu       $a2, -0x5AFF($a2)
/* 3D76B8 E00DA478 3C01E00E */  lui       $at, (0xE00E0000 >> 16)
/* 3D76BC E00DA47C 00240821 */  addu      $at, $at, $a0
/* 3D76C0 E00DA480 9024A502 */  lbu       $a0, -0x5AFE($at)
/* 3D76C4 E00DA484 24A20028 */  addiu     $v0, $a1, 0x28
/* 3D76C8 E00DA488 AE620000 */  sw        $v0, 0x0($s3)
/* 3D76CC E00DA48C 3C020900 */  lui       $v0, %hi(D_090002E0_415340)
/* 3D76D0 E00DA490 244202E0 */  addiu     $v0, $v0, %lo(D_090002E0_415340)
/* 3D76D4 E00DA494 ACA20024 */  sw        $v0, 0x24($a1)
/* 3D76D8 E00DA498 24A20030 */  addiu     $v0, $a1, 0x30
/* 3D76DC E00DA49C ACA80020 */  sw        $t0, 0x20($a1)
/* 3D76E0 E00DA4A0 AE620000 */  sw        $v0, 0x0($s3)
/* 3D76E4 E00DA4A4 24020040 */  addiu     $v0, $zero, 0x40
/* 3D76E8 E00DA4A8 ACA70028 */  sw        $a3, 0x28($a1)
/* 3D76EC E00DA4AC ACA2002C */  sw        $v0, 0x2C($a1)
/* 3D76F0 E00DA4B0 00031E00 */  sll       $v1, $v1, 24
/* 3D76F4 E00DA4B4 00063400 */  sll       $a2, $a2, 16
/* 3D76F8 E00DA4B8 00661825 */  or        $v1, $v1, $a2
/* 3D76FC E00DA4BC 00042200 */  sll       $a0, $a0, 8
/* 3D7700 E00DA4C0 00641825 */  or        $v1, $v1, $a0
/* 3D7704 E00DA4C4 00751825 */  or        $v1, $v1, $s5
/* 3D7708 E00DA4C8 ACA3001C */  sw        $v1, 0x1C($a1)
/* 3D770C E00DA4CC 8FBF00AC */  lw        $ra, 0xAC($sp)
/* 3D7710 E00DA4D0 8FB600A8 */  lw        $s6, 0xA8($sp)
/* 3D7714 E00DA4D4 8FB500A4 */  lw        $s5, 0xA4($sp)
/* 3D7718 E00DA4D8 8FB400A0 */  lw        $s4, 0xA0($sp)
/* 3D771C E00DA4DC 8FB3009C */  lw        $s3, 0x9C($sp)
/* 3D7720 E00DA4E0 8FB20098 */  lw        $s2, 0x98($sp)
/* 3D7724 E00DA4E4 8FB10094 */  lw        $s1, 0x94($sp)
/* 3D7728 E00DA4E8 8FB00090 */  lw        $s0, 0x90($sp)
/* 3D772C E00DA4EC D7B400B0 */  ldc1      $f20, 0xB0($sp)
/* 3D7730 E00DA4F0 03E00008 */  jr        $ra
/* 3D7734 E00DA4F4 27BD00B8 */   addiu    $sp, $sp, 0xB8
/* 3D7738 E00DA4F8 00000000 */  nop
/* 3D773C E00DA4FC 00000000 */  nop

### DECOMPILED C INSTRUCTIONS:

void shiny_flare_appendGfx(void* effect) {
    ShinyFlareFXData* data = ((EffectInstance*)effect)->data.shinyFlare;
    Camera* camera = &gCameras[gCurrentCameraID];
    s32 unk_24 = data->unk_24;
    f32 scale = data->unk_28 * data->unk_2C;
    s32 idx;
    Matrix4f sp10;
    Matrix4f sp50;

    gDPPipeSync(gMainGfxPos++);
    gSPSegment(gMainGfxPos++, 0x09, VIRTUAL_TO_PHYSICAL(((EffectInstance*)effect)->graphics->data));

    shim_guTranslateF(sp10, data->pos.x, data->pos.y, data->pos.z);
    shim_guScaleF(sp50, scale, scale, scale);
    shim_guMtxCatF(sp50, sp10, sp10);
    shim_guMtxF2L(sp10, &gDisplayContext->matrixStack[gMatrixListPos]);

    gSPMatrix(gMainGfxPos++, &gDisplayContext->matrixStack[gMatrixListPos++], G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
    gSPMatrix(gMainGfxPos++, camera->unkMatrix, G_MTX_NOPUSH | G_MTX_MUL | G_MTX_MODELVIEW);
    gSPDisplayList(gMainGfxPos++, D_09000240_3D79B0);
    gDPSetPrimColor(gMainGfxPos++, 0, 0, data->unk_18, data->unk_1C, data->unk_20, unk_24);

    idx = data->lifeTime * 3;

    gDPSetPrimColor(gMainGfxPos++, 0, 0,
        D_E00DA500[idx % ARRAY_COUNT(D_E00DA500)    ],
        D_E00DA500[idx % ARRAY_COUNT(D_E00DA500) + 1],
        D_E00DA500[idx % ARRAY_COUNT(D_E00DA500) + 2],
        unk_24);
    gSPDisplayList(gMainGfxPos++, D_090002E0_3D7A50);
    gSPPopMatrix(gMainGfxPos++, G_MTX_MODELVIEW);
}


### RAW ASSEMBLY INSTRUCTIONS:

glabel cloud_trail_appendGfx
/* 32F284 E0016454 27BDFF28 */  addiu     $sp, $sp, -0xD8
/* 32F288 E0016458 AFB600B8 */  sw        $s6, 0xB8($sp)
/* 32F28C E001645C 0080B02D */  daddu     $s6, $a0, $zero
/* 32F290 E0016460 3C05DB06 */  lui       $a1, (0xDB060024 >> 16)
/* 32F294 E0016464 34A50024 */  ori       $a1, $a1, (0xDB060024 & 0xFFFF)
/* 32F298 E0016468 AFB300AC */  sw        $s3, 0xAC($sp)
/* 32F29C E001646C 0000982D */  daddu     $s3, $zero, $zero
/* 32F2A0 E0016470 3C06800A */  lui       $a2, %hi(gMainGfxPos)
/* 32F2A4 E0016474 24C6A66C */  addiu     $a2, $a2, %lo(gMainGfxPos)
/* 32F2A8 E0016478 3C02E700 */  lui       $v0, (0xE7000000 >> 16)
/* 32F2AC E001647C AFBF00C4 */  sw        $ra, 0xC4($sp)
/* 32F2B0 E0016480 AFBE00C0 */  sw        $fp, 0xC0($sp)
/* 32F2B4 E0016484 AFB700BC */  sw        $s7, 0xBC($sp)
/* 32F2B8 E0016488 AFB500B4 */  sw        $s5, 0xB4($sp)
/* 32F2BC E001648C AFB400B0 */  sw        $s4, 0xB0($sp)
/* 32F2C0 E0016490 AFB200A8 */  sw        $s2, 0xA8($sp)
/* 32F2C4 E0016494 AFB100A4 */  sw        $s1, 0xA4($sp)
/* 32F2C8 E0016498 AFB000A0 */  sw        $s0, 0xA0($sp)
/* 32F2CC E001649C F7B600D0 */  sdc1      $f22, 0xD0($sp)
/* 32F2D0 E00164A0 F7B400C8 */  sdc1      $f20, 0xC8($sp)
/* 32F2D4 E00164A4 8CC30000 */  lw        $v1, 0x0($a2)
/* 32F2D8 E00164A8 8ED2000C */  lw        $s2, 0xC($s6)
/* 32F2DC E00164AC 0060202D */  daddu     $a0, $v1, $zero
/* 32F2E0 E00164B0 24630008 */  addiu     $v1, $v1, 0x8
/* 32F2E4 E00164B4 ACC30000 */  sw        $v1, 0x0($a2)
/* 32F2E8 E00164B8 AC820000 */  sw        $v0, 0x0($a0)
/* 32F2EC E00164BC AC800004 */  sw        $zero, 0x4($a0)
/* 32F2F0 E00164C0 AC650000 */  sw        $a1, 0x0($v1)
/* 32F2F4 E00164C4 8EC40010 */  lw        $a0, 0x10($s6)
/* 32F2F8 E00164C8 24620008 */  addiu     $v0, $v1, 0x8
/* 32F2FC E00164CC ACC20000 */  sw        $v0, 0x0($a2)
/* 32F300 E00164D0 8C84001C */  lw        $a0, 0x1C($a0)
/* 32F304 E00164D4 3C02DE00 */  lui       $v0, (0xDE000000 >> 16)
/* 32F308 E00164D8 AC620008 */  sw        $v0, 0x8($v1)
/* 32F30C E00164DC 3C020900 */  lui       $v0, %hi(D_090000E0_415140)
/* 32F310 E00164E0 244200E0 */  addiu     $v0, $v0, %lo(D_090000E0_415140)
/* 32F314 E00164E4 AC62000C */  sw        $v0, 0xC($v1)
/* 32F318 E00164E8 3C028000 */  lui       $v0, (0x80000000 >> 16)
/* 32F31C E00164EC 00822021 */  addu      $a0, $a0, $v0
/* 32F320 E00164F0 AC640004 */  sw        $a0, 0x4($v1)
/* 32F324 E00164F4 8EC20008 */  lw        $v0, 0x8($s6)
/* 32F328 E00164F8 24630010 */  addiu     $v1, $v1, 0x10
/* 32F32C E00164FC 18400070 */  blez      $v0, .LE00166C0
/* 32F330 E0016500 ACC30000 */   sw       $v1, 0x0($a2)
/* 32F334 E0016504 27B10060 */  addiu     $s1, $sp, 0x60
/* 32F338 E0016508 3C1E800A */  lui       $fp, %hi(gDisplayContext)
/* 32F33C E001650C 27DEA674 */  addiu     $fp, $fp, %lo(gDisplayContext)
/* 32F340 E0016510 3C178007 */  lui       $s7, %hi(gMatrixListPos)
/* 32F344 E0016514 26F741F0 */  addiu     $s7, $s7, %lo(gMatrixListPos)
/* 32F348 E0016518 3C150001 */  lui       $s5, (0x11630 >> 16)
/* 32F34C E001651C 36B51630 */  ori       $s5, $s5, (0x11630 & 0xFFFF)
/* 32F350 E0016520 00C0A02D */  daddu     $s4, $a2, $zero
/* 32F354 E0016524 26500008 */  addiu     $s0, $s2, 0x8
/* 32F358 E0016528 4480A000 */  mtc1      $zero, $f20
/* 32F35C E001652C 3C013F80 */  lui       $at, (0x3F800000 >> 16)
/* 32F360 E0016530 4481B000 */  mtc1      $at, $f22
.LE0016534:
/* 32F364 E0016534 8E420000 */  lw        $v0, 0x0($s2)
/* 32F368 E0016538 5040005C */  beql      $v0, $zero, .LE00166AC
/* 32F36C E001653C 26730001 */   addiu    $s3, $s3, 0x1
/* 32F370 E0016540 3C09800B */  lui       $t1, %hi(gCameras)
/* 32F374 E0016544 25291D80 */  addiu     $t1, $t1, %lo(gCameras)
/* 32F378 E0016548 4405A000 */  mfc1      $a1, $f20
/* 32F37C E001654C 3C038007 */  lui       $v1, %hi(gCurrentCameraID)
/* 32F380 E0016550 8C637410 */  lw        $v1, %lo(gCurrentCameraID)($v1)
/* 32F384 E0016554 4407A000 */  mfc1      $a3, $f20
/* 32F388 E0016558 00031080 */  sll       $v0, $v1, 2
/* 32F38C E001655C 00431021 */  addu      $v0, $v0, $v1
/* 32F390 E0016560 00021080 */  sll       $v0, $v0, 2
/* 32F394 E0016564 00431023 */  subu      $v0, $v0, $v1
/* 32F398 E0016568 000218C0 */  sll       $v1, $v0, 3
/* 32F39C E001656C 00431021 */  addu      $v0, $v0, $v1
/* 32F3A0 E0016570 000210C0 */  sll       $v0, $v0, 3
/* 32F3A4 E0016574 00491021 */  addu      $v0, $v0, $t1
/* 32F3A8 E0016578 C442006C */  lwc1      $f2, 0x6C($v0)
/* 32F3AC E001657C E7B60010 */  swc1      $f22, 0x10($sp)
/* 32F3B0 E0016580 C6000004 */  lwc1      $f0, 0x4($s0)
/* 32F3B4 E0016584 46001087 */  neg.s     $f2, $f2
/* 32F3B8 E0016588 E7A00014 */  swc1      $f0, 0x14($sp)
/* 32F3BC E001658C C6000008 */  lwc1      $f0, 0x8($s0)
/* 32F3C0 E0016590 44061000 */  mfc1      $a2, $f2
/* 32F3C4 E0016594 E7A00018 */  swc1      $f0, 0x18($sp)
/* 32F3C8 E0016598 C600000C */  lwc1      $f0, 0xC($s0)
/* 32F3CC E001659C 27A40020 */  addiu     $a0, $sp, 0x20
/* 32F3D0 E00165A0 0C080180 */  jal       shim_guPositionF
/* 32F3D4 E00165A4 E7A0001C */   swc1     $f0, 0x1C($sp)
/* 32F3D8 E00165A8 8E050014 */  lw        $a1, 0x14($s0)
/* 32F3DC E00165AC 8E060018 */  lw        $a2, 0x18($s0)
/* 32F3E0 E00165B0 8E07001C */  lw        $a3, 0x1C($s0)
/* 32F3E4 E00165B4 0C080110 */  jal       shim_guScaleF
/* 32F3E8 E00165B8 0220202D */   daddu    $a0, $s1, $zero
/* 32F3EC E00165BC 0220202D */  daddu     $a0, $s1, $zero
/* 32F3F0 E00165C0 27A50020 */  addiu     $a1, $sp, 0x20
/* 32F3F4 E00165C4 0C080114 */  jal       shim_guMtxCatF
/* 32F3F8 E00165C8 00A0302D */   daddu    $a2, $a1, $zero
/* 32F3FC E00165CC E7B60010 */  swc1      $f22, 0x10($sp)
/* 32F400 E00165D0 8E050010 */  lw        $a1, 0x10($s0)
/* 32F404 E00165D4 4406A000 */  mfc1      $a2, $f20
/* 32F408 E00165D8 4407A000 */  mfc1      $a3, $f20
/* 32F40C E00165DC 0C080104 */  jal       shim_guRotateF
/* 32F410 E00165E0 0220202D */   daddu    $a0, $s1, $zero
/* 32F414 E00165E4 0220202D */  daddu     $a0, $s1, $zero
/* 32F418 E00165E8 27A50020 */  addiu     $a1, $sp, 0x20
/* 32F41C E00165EC 0C080114 */  jal       shim_guMtxCatF
/* 32F420 E00165F0 00A0302D */   daddu    $a2, $a1, $zero
/* 32F424 E00165F4 27A40020 */  addiu     $a0, $sp, 0x20
/* 32F428 E00165F8 96E50000 */  lhu       $a1, 0x0($s7)
/* 32F42C E00165FC 8FC20000 */  lw        $v0, 0x0($fp)
/* 32F430 E0016600 00052980 */  sll       $a1, $a1, 6
/* 32F434 E0016604 00B52821 */  addu      $a1, $a1, $s5
/* 32F438 E0016608 0C080118 */  jal       shim_guMtxF2L
/* 32F43C E001660C 00452821 */   addu     $a1, $v0, $a1
/* 32F440 E0016610 3C077060 */  lui       $a3, (0x70601800 >> 16)
/* 32F444 E0016614 34E71800 */  ori       $a3, $a3, (0x70601800 & 0xFFFF)
/* 32F448 E0016618 3C08D838 */  lui       $t0, (0xD8380002 >> 16)
/* 32F44C E001661C 35080002 */  ori       $t0, $t0, (0xD8380002 & 0xFFFF)
/* 32F450 E0016620 8E840000 */  lw        $a0, 0x0($s4)
/* 32F454 E0016624 3C02FA00 */  lui       $v0, (0xFA000000 >> 16)
/* 32F458 E0016628 0080302D */  daddu     $a2, $a0, $zero
/* 32F45C E001662C 24840008 */  addiu     $a0, $a0, 0x8
/* 32F460 E0016630 AE840000 */  sw        $a0, 0x0($s4)
/* 32F464 E0016634 ACC20000 */  sw        $v0, 0x0($a2)
/* 32F468 E0016638 92050000 */  lbu       $a1, 0x0($s0)
/* 32F46C E001663C 96E30000 */  lhu       $v1, 0x0($s7)
/* 32F470 E0016640 24820008 */  addiu     $v0, $a0, 0x8
/* 32F474 E0016644 AE820000 */  sw        $v0, 0x0($s4)
/* 32F478 E0016648 24620001 */  addiu     $v0, $v1, 0x1
/* 32F47C E001664C A6E20000 */  sh        $v0, 0x0($s7)
/* 32F480 E0016650 24820010 */  addiu     $v0, $a0, 0x10
/* 32F484 E0016654 AE820000 */  sw        $v0, 0x0($s4)
/* 32F488 E0016658 24820018 */  addiu     $v0, $a0, 0x18
/* 32F48C E001665C 00A72825 */  or        $a1, $a1, $a3
/* 32F490 E0016660 AE820000 */  sw        $v0, 0x0($s4)
/* 32F494 E0016664 3C02DA38 */  lui       $v0, (0xDA380000 >> 16)
/* 32F498 E0016668 3063FFFF */  andi      $v1, $v1, 0xFFFF
/* 32F49C E001666C 00031980 */  sll       $v1, $v1, 6
/* 32F4A0 E0016670 ACC50004 */  sw        $a1, 0x4($a2)
/* 32F4A4 E0016674 AC820000 */  sw        $v0, 0x0($a0)
/* 32F4A8 E0016678 8FC20000 */  lw        $v0, 0x0($fp)
/* 32F4AC E001667C 00751821 */  addu      $v1, $v1, $s5
/* 32F4B0 E0016680 AC880010 */  sw        $t0, 0x10($a0)
/* 32F4B4 E0016684 00431021 */  addu      $v0, $v0, $v1
/* 32F4B8 E0016688 AC820004 */  sw        $v0, 0x4($a0)
/* 32F4BC E001668C 3C02DE00 */  lui       $v0, (0xDE000000 >> 16)
/* 32F4C0 E0016690 AC820008 */  sw        $v0, 0x8($a0)
/* 32F4C4 E0016694 3C020900 */  lui       $v0, %hi(D_090001B8_415218)
/* 32F4C8 E0016698 244201B8 */  addiu     $v0, $v0, %lo(D_090001B8_415218)
/* 32F4CC E001669C AC82000C */  sw        $v0, 0xC($a0)
/* 32F4D0 E00166A0 24020040 */  addiu     $v0, $zero, 0x40
/* 32F4D4 E00166A4 AC820014 */  sw        $v0, 0x14($a0)
/* 32F4D8 E00166A8 26730001 */  addiu     $s3, $s3, 0x1
.LE00166AC:
/* 32F4DC E00166AC 26100050 */  addiu     $s0, $s0, 0x50
/* 32F4E0 E00166B0 8EC20008 */  lw        $v0, 0x8($s6)
/* 32F4E4 E00166B4 0262102A */  slt       $v0, $s3, $v0
/* 32F4E8 E00166B8 1440FF9E */  bnez      $v0, .LE0016534
/* 32F4EC E00166BC 26520050 */   addiu    $s2, $s2, 0x50
.LE00166C0:
/* 32F4F0 E00166C0 3C03800A */  lui       $v1, %hi(gMainGfxPos)
/* 32F4F4 E00166C4 2463A66C */  addiu     $v1, $v1, %lo(gMainGfxPos)
/* 32F4F8 E00166C8 8C620000 */  lw        $v0, 0x0($v1)
/* 32F4FC E00166CC 0040202D */  daddu     $a0, $v0, $zero
/* 32F500 E00166D0 24420008 */  addiu     $v0, $v0, 0x8
/* 32F504 E00166D4 AC620000 */  sw        $v0, 0x0($v1)
/* 32F508 E00166D8 3C02E700 */  lui       $v0, (0xE7000000 >> 16)
/* 32F50C E00166DC AC820000 */  sw        $v0, 0x0($a0)
/* 32F510 E00166E0 AC800004 */  sw        $zero, 0x4($a0)
/* 32F514 E00166E4 8FBF00C4 */  lw        $ra, 0xC4($sp)
/* 32F518 E00166E8 8FBE00C0 */  lw        $fp, 0xC0($sp)
/* 32F51C E00166EC 8FB700BC */  lw        $s7, 0xBC($sp)
/* 32F520 E00166F0 8FB600B8 */  lw        $s6, 0xB8($sp)
/* 32F524 E00166F4 8FB500B4 */  lw        $s5, 0xB4($sp)
/* 32F528 E00166F8 8FB400B0 */  lw        $s4, 0xB0($sp)
/* 32F52C E00166FC 8FB300AC */  lw        $s3, 0xAC($sp)
/* 32F530 E0016700 8FB200A8 */  lw        $s2, 0xA8($sp)
/* 32F534 E0016704 8FB100A4 */  lw        $s1, 0xA4($sp)
/* 32F538 E0016708 8FB000A0 */  lw        $s0, 0xA0($sp)
/* 32F53C E001670C D7B600D0 */  ldc1      $f22, 0xD0($sp)
/* 32F540 E0016710 D7B400C8 */  ldc1      $f20, 0xC8($sp)
/* 32F544 E0016714 03E00008 */  jr        $ra
/* 32F548 E0016718 27BD00D8 */   addiu    $sp, $sp, 0xD8
/* 32F54C E001671C 00000000 */  nop

### DECOMPILED C INSTRUCTIONS:

void cloud_trail_appendGfx(void* effect) {
    EffectInstance* effectTemp = effect;
    CloudTrailFXData* part = effectTemp->data.cloudTrail;
    Matrix4f sp20;
    Matrix4f sp60;
    s32 i;

    gDPPipeSync(gMainGfxPos++);
    gSPSegment(gMainGfxPos++, 0x09, VIRTUAL_TO_PHYSICAL(effectTemp->graphics->data));
    gSPDisplayList(gMainGfxPos++, D_090000E0_32ED30);

    for (i = 0; i < effectTemp->numParts; i++, part++) {
        if (part->alive) {
            shim_guPositionF(sp20, 0.0f, -gCameras[gCurrentCameraID].currentYaw, 0.0f, 1.0f,
                             part->unk_0C, part->unk_10, part->unk_14);
            shim_guScaleF(sp60, part->unk_1C, part->unk_20, part->unk_24);
            shim_guMtxCatF(sp60, sp20, sp20);
            shim_guRotateF(sp60, part->unk_18, 0.0f, 0.0f, 1.0f);
            shim_guMtxCatF(sp60, sp20, sp20);
            shim_guMtxF2L(sp20, &gDisplayContext->matrixStack[gMatrixListPos]);

            gDPSetPrimColor(gMainGfxPos++, 0, 0, 112, 96, 24, part->alpha);
            gSPMatrix(gMainGfxPos++, &gDisplayContext->matrixStack[gMatrixListPos++],
                        G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
            gSPDisplayList(gMainGfxPos++, D_090001B8_32EE08);
            gSPPopMatrix(gMainGfxPos++, G_MTX_MODELVIEW);
        }
    }
    gDPPipeSync(gMainGfxPos++);
}


### RAW ASSEMBLY INSTRUCTIONS:

glabel snowflake_appendGfx
/* 330C1C E001C30C 27BDFE70 */  addiu     $sp, $sp, -0x190
/* 330C20 E001C310 0080302D */  daddu     $a2, $a0, $zero
/* 330C24 E001C314 3C07DB06 */  lui       $a3, (0xDB060024 >> 16)
/* 330C28 E001C318 34E70024 */  ori       $a3, $a3, (0xDB060024 & 0xFFFF)
/* 330C2C E001C31C 27A40018 */  addiu     $a0, $sp, 0x18
/* 330C30 E001C320 AFB70174 */  sw        $s7, 0x174($sp)
/* 330C34 E001C324 3C170001 */  lui       $s7, (0x11630 >> 16)
/* 330C38 E001C328 AFB1015C */  sw        $s1, 0x15C($sp)
/* 330C3C E001C32C 3C11800A */  lui       $s1, %hi(gMainGfxPos)
/* 330C40 E001C330 2631A66C */  addiu     $s1, $s1, %lo(gMainGfxPos)
/* 330C44 E001C334 AFBF017C */  sw        $ra, 0x17C($sp)
/* 330C48 E001C338 AFBE0178 */  sw        $fp, 0x178($sp)
/* 330C4C E001C33C AFB60170 */  sw        $s6, 0x170($sp)
/* 330C50 E001C340 AFB5016C */  sw        $s5, 0x16C($sp)
/* 330C54 E001C344 AFB40168 */  sw        $s4, 0x168($sp)
/* 330C58 E001C348 AFB30164 */  sw        $s3, 0x164($sp)
/* 330C5C E001C34C AFB20160 */  sw        $s2, 0x160($sp)
/* 330C60 E001C350 AFB00158 */  sw        $s0, 0x158($sp)
/* 330C64 E001C354 F7B60188 */  sdc1      $f22, 0x188($sp)
/* 330C68 E001C358 F7B40180 */  sdc1      $f20, 0x180($sp)
/* 330C6C E001C35C 8E230000 */  lw        $v1, 0x0($s1)
/* 330C70 E001C360 36F71630 */  ori       $s7, $s7, (0x11630 & 0xFFFF)
/* 330C74 E001C364 0060282D */  daddu     $a1, $v1, $zero
/* 330C78 E001C368 24630008 */  addiu     $v1, $v1, 0x8
/* 330C7C E001C36C AE230000 */  sw        $v1, 0x0($s1)
/* 330C80 E001C370 8CD6000C */  lw        $s6, 0xC($a2)
/* 330C84 E001C374 3C02E700 */  lui       $v0, (0xE7000000 >> 16)
/* 330C88 E001C378 ACA20000 */  sw        $v0, 0x0($a1)
/* 330C8C E001C37C ACA00004 */  sw        $zero, 0x4($a1)
/* 330C90 E001C380 AC670000 */  sw        $a3, 0x0($v1)
/* 330C94 E001C384 8CC50010 */  lw        $a1, 0x10($a2)
/* 330C98 E001C388 24620008 */  addiu     $v0, $v1, 0x8
/* 330C9C E001C38C AE220000 */  sw        $v0, 0x0($s1)
/* 330CA0 E001C390 3C020900 */  lui       $v0, %hi(D_09000900_415960)
/* 330CA4 E001C394 24420900 */  addiu     $v0, $v0, %lo(D_09000900_415960)
/* 330CA8 E001C398 8CA5001C */  lw        $a1, 0x1C($a1)
/* 330CAC E001C39C 3C0ADE00 */  lui       $t2, (0xDE000000 >> 16)
/* 330CB0 E001C3A0 AC62000C */  sw        $v0, 0xC($v1)
/* 330CB4 E001C3A4 3C028000 */  lui       $v0, (0x80000000 >> 16)
/* 330CB8 E001C3A8 AC6A0008 */  sw        $t2, 0x8($v1)
/* 330CBC E001C3AC 00A22821 */  addu      $a1, $a1, $v0
/* 330CC0 E001C3B0 AC650004 */  sw        $a1, 0x4($v1)
/* 330CC4 E001C3B4 8EC50000 */  lw        $a1, 0x0($s6)
/* 330CC8 E001C3B8 8EC60004 */  lw        $a2, 0x4($s6)
/* 330CCC E001C3BC 8EC70008 */  lw        $a3, 0x8($s6)
/* 330CD0 E001C3C0 24630010 */  addiu     $v1, $v1, 0x10
/* 330CD4 E001C3C4 0C080108 */  jal       shim_guTranslateF
/* 330CD8 E001C3C8 AE230000 */   sw       $v1, 0x0($s1)
/* 330CDC E001C3CC 27B000D8 */  addiu     $s0, $sp, 0xD8
/* 330CE0 E001C3D0 4480A000 */  mtc1      $zero, $f20
/* 330CE4 E001C3D4 3C038007 */  lui       $v1, %hi(gCurrentCameraID)
/* 330CE8 E001C3D8 8C637410 */  lw        $v1, %lo(gCurrentCameraID)($v1)
/* 330CEC E001C3DC 3C013F80 */  lui       $at, (0x3F800000 >> 16)
/* 330CF0 E001C3E0 4481B000 */  mtc1      $at, $f22
/* 330CF4 E001C3E4 00031080 */  sll       $v0, $v1, 2
/* 330CF8 E001C3E8 00431021 */  addu      $v0, $v0, $v1
/* 330CFC E001C3EC 00021080 */  sll       $v0, $v0, 2
/* 330D00 E001C3F0 00431023 */  subu      $v0, $v0, $v1
/* 330D04 E001C3F4 000218C0 */  sll       $v1, $v0, 3
/* 330D08 E001C3F8 00431021 */  addu      $v0, $v0, $v1
/* 330D0C E001C3FC 000210C0 */  sll       $v0, $v0, 3
/* 330D10 E001C400 4406A000 */  mfc1      $a2, $f20
/* 330D14 E001C404 3C01800B */  lui       $at, %hi(gCameras + 0x6C)
/* 330D18 E001C408 00220821 */  addu      $at, $at, $v0
/* 330D1C E001C40C C4201DEC */  lwc1      $f0, %lo(gCameras + 0x6C)($at)
/* 330D20 E001C410 4407B000 */  mfc1      $a3, $f22
/* 330D24 E001C414 46000007 */  neg.s     $f0, $f0
/* 330D28 E001C418 44050000 */  mfc1      $a1, $f0
/* 330D2C E001C41C 0200202D */  daddu     $a0, $s0, $zero
/* 330D30 E001C420 0C080104 */  jal       shim_guRotateF
/* 330D34 E001C424 E7B40010 */   swc1     $f20, 0x10($sp)
/* 330D38 E001C428 0200202D */  daddu     $a0, $s0, $zero
/* 330D3C E001C42C 27A50018 */  addiu     $a1, $sp, 0x18
/* 330D40 E001C430 27B40118 */  addiu     $s4, $sp, 0x118
/* 330D44 E001C434 0C080114 */  jal       shim_guMtxCatF
/* 330D48 E001C438 0280302D */   daddu    $a2, $s4, $zero
/* 330D4C E001C43C 0280202D */  daddu     $a0, $s4, $zero
/* 330D50 E001C440 3C128007 */  lui       $s2, %hi(gMatrixListPos)
/* 330D54 E001C444 265241F0 */  addiu     $s2, $s2, %lo(gMatrixListPos)
/* 330D58 E001C448 3C15800A */  lui       $s5, %hi(gDisplayContext)
/* 330D5C E001C44C 26B5A674 */  addiu     $s5, $s5, %lo(gDisplayContext)
/* 330D60 E001C450 96450000 */  lhu       $a1, 0x0($s2)
/* 330D64 E001C454 8EA20000 */  lw        $v0, 0x0($s5)
/* 330D68 E001C458 00052980 */  sll       $a1, $a1, 6
/* 330D6C E001C45C 00B72821 */  addu      $a1, $a1, $s7
/* 330D70 E001C460 0C080118 */  jal       shim_guMtxF2L
/* 330D74 E001C464 00452821 */   addu     $a1, $v0, $a1
/* 330D78 E001C468 3C1EDA38 */  lui       $fp, (0xDA380000 >> 16)
/* 330D7C E001C46C 27B30058 */  addiu     $s3, $sp, 0x58
/* 330D80 E001C470 8E280000 */  lw        $t0, 0x0($s1)
/* 330D84 E001C474 4406B000 */  mfc1      $a2, $f22
/* 330D88 E001C478 4407A000 */  mfc1      $a3, $f20
/* 330D8C E001C47C 96490000 */  lhu       $t1, 0x0($s2)
/* 330D90 E001C480 0100202D */  daddu     $a0, $t0, $zero
/* 330D94 E001C484 25080008 */  addiu     $t0, $t0, 0x8
/* 330D98 E001C488 3122FFFF */  andi      $v0, $t1, 0xFFFF
/* 330D9C E001C48C 00021180 */  sll       $v0, $v0, 6
/* 330DA0 E001C490 00571021 */  addu      $v0, $v0, $s7
/* 330DA4 E001C494 AC9E0000 */  sw        $fp, 0x0($a0)
/* 330DA8 E001C498 8EA30000 */  lw        $v1, 0x0($s5)
/* 330DAC E001C49C 25290001 */  addiu     $t1, $t1, 0x1
/* 330DB0 E001C4A0 00621821 */  addu      $v1, $v1, $v0
/* 330DB4 E001C4A4 3C02FA00 */  lui       $v0, (0xFA000000 >> 16)
/* 330DB8 E001C4A8 AC830004 */  sw        $v1, 0x4($a0)
/* 330DBC E001C4AC AD020000 */  sw        $v0, 0x0($t0)
/* 330DC0 E001C4B0 240200FF */  addiu     $v0, $zero, 0xFF
/* 330DC4 E001C4B4 AD020004 */  sw        $v0, 0x4($t0)
/* 330DC8 E001C4B8 E7B40010 */  swc1      $f20, 0x10($sp)
/* 330DCC E001C4BC 8EC50018 */  lw        $a1, 0x18($s6)
/* 330DD0 E001C4C0 0260202D */  daddu     $a0, $s3, $zero
/* 330DD4 E001C4C4 AE280000 */  sw        $t0, 0x0($s1)
/* 330DD8 E001C4C8 25080008 */  addiu     $t0, $t0, 0x8
/* 330DDC E001C4CC A6490000 */  sh        $t1, 0x0($s2)
/* 330DE0 E001C4D0 0C080104 */  jal       shim_guRotateF
/* 330DE4 E001C4D4 AE280000 */   sw       $t0, 0x0($s1)
/* 330DE8 E001C4D8 27B00098 */  addiu     $s0, $sp, 0x98
/* 330DEC E001C4DC E7B40010 */  swc1      $f20, 0x10($sp)
/* 330DF0 E001C4E0 8EC5001C */  lw        $a1, 0x1C($s6)
/* 330DF4 E001C4E4 4406A000 */  mfc1      $a2, $f20
/* 330DF8 E001C4E8 4407B000 */  mfc1      $a3, $f22
/* 330DFC E001C4EC 0C080104 */  jal       shim_guRotateF
/* 330E00 E001C4F0 0200202D */   daddu    $a0, $s0, $zero
/* 330E04 E001C4F4 0260202D */  daddu     $a0, $s3, $zero
/* 330E08 E001C4F8 0200282D */  daddu     $a1, $s0, $zero
/* 330E0C E001C4FC 0C080114 */  jal       shim_guMtxCatF
/* 330E10 E001C500 0280302D */   daddu    $a2, $s4, $zero
/* 330E14 E001C504 0280202D */  daddu     $a0, $s4, $zero
/* 330E18 E001C508 96450000 */  lhu       $a1, 0x0($s2)
/* 330E1C E001C50C 8EA20000 */  lw        $v0, 0x0($s5)
/* 330E20 E001C510 00052980 */  sll       $a1, $a1, 6
/* 330E24 E001C514 00B72821 */  addu      $a1, $a1, $s7
/* 330E28 E001C518 0C080118 */  jal       shim_guMtxF2L
/* 330E2C E001C51C 00452821 */   addu     $a1, $v0, $a1
/* 330E30 E001C520 3C06D838 */  lui       $a2, (0xD8380002 >> 16)
/* 330E34 E001C524 34C60002 */  ori       $a2, $a2, (0xD8380002 & 0xFFFF)
/* 330E38 E001C528 8E240000 */  lw        $a0, 0x0($s1)
/* 330E3C E001C52C 96420000 */  lhu       $v0, 0x0($s2)
/* 330E40 E001C530 0080282D */  daddu     $a1, $a0, $zero
/* 330E44 E001C534 24840008 */  addiu     $a0, $a0, 0x8
/* 330E48 E001C538 24430001 */  addiu     $v1, $v0, 0x1
/* 330E4C E001C53C 3042FFFF */  andi      $v0, $v0, 0xFFFF
/* 330E50 E001C540 00021180 */  sll       $v0, $v0, 6
/* 330E54 E001C544 AE240000 */  sw        $a0, 0x0($s1)
/* 330E58 E001C548 ACBE0000 */  sw        $fp, 0x0($a1)
/* 330E5C E001C54C A6430000 */  sh        $v1, 0x0($s2)
/* 330E60 E001C550 8EA30000 */  lw        $v1, 0x0($s5)
/* 330E64 E001C554 00571021 */  addu      $v0, $v0, $s7
/* 330E68 E001C558 00621821 */  addu      $v1, $v1, $v0
/* 330E6C E001C55C 24820008 */  addiu     $v0, $a0, 0x8
/* 330E70 E001C560 ACA30004 */  sw        $v1, 0x4($a1)
/* 330E74 E001C564 3C0ADE00 */  lui       $t2, (0xDE000000 >> 16)
/* 330E78 E001C568 AE220000 */  sw        $v0, 0x0($s1)
/* 330E7C E001C56C 3C020900 */  lui       $v0, %hi(D_090009E8_415A48)
/* 330E80 E001C570 244209E8 */  addiu     $v0, $v0, %lo(D_090009E8_415A48)
/* 330E84 E001C574 AC820004 */  sw        $v0, 0x4($a0)
/* 330E88 E001C578 24820010 */  addiu     $v0, $a0, 0x10
/* 330E8C E001C57C 24030040 */  addiu     $v1, $zero, 0x40
/* 330E90 E001C580 AC8A0000 */  sw        $t2, 0x0($a0)
/* 330E94 E001C584 AE220000 */  sw        $v0, 0x0($s1)
/* 330E98 E001C588 24820018 */  addiu     $v0, $a0, 0x18
/* 330E9C E001C58C AC860008 */  sw        $a2, 0x8($a0)
/* 330EA0 E001C590 AC83000C */  sw        $v1, 0xC($a0)
/* 330EA4 E001C594 AE220000 */  sw        $v0, 0x0($s1)
/* 330EA8 E001C598 AC860010 */  sw        $a2, 0x10($a0)
/* 330EAC E001C59C AC830014 */  sw        $v1, 0x14($a0)
/* 330EB0 E001C5A0 8FBF017C */  lw        $ra, 0x17C($sp)
/* 330EB4 E001C5A4 8FBE0178 */  lw        $fp, 0x178($sp)
/* 330EB8 E001C5A8 8FB70174 */  lw        $s7, 0x174($sp)
/* 330EBC E001C5AC 8FB60170 */  lw        $s6, 0x170($sp)
/* 330EC0 E001C5B0 8FB5016C */  lw        $s5, 0x16C($sp)
/* 330EC4 E001C5B4 8FB40168 */  lw        $s4, 0x168($sp)
/* 330EC8 E001C5B8 8FB30164 */  lw        $s3, 0x164($sp)
/* 330ECC E001C5BC 8FB20160 */  lw        $s2, 0x160($sp)
/* 330ED0 E001C5C0 8FB1015C */  lw        $s1, 0x15C($sp)
/* 330ED4 E001C5C4 8FB00158 */  lw        $s0, 0x158($sp)
/* 330ED8 E001C5C8 D7B60188 */  ldc1      $f22, 0x188($sp)
/* 330EDC E001C5CC D7B40180 */  ldc1      $f20, 0x180($sp)
/* 330EE0 E001C5D0 03E00008 */  jr        $ra
/* 330EE4 E001C5D4 27BD0190 */   addiu    $sp, $sp, 0x190
/* 330EE8 E001C5D8 00000000 */  nop
/* 330EEC E001C5DC 00000000 */  nop

### DECOMPILED C INSTRUCTIONS:

void snowflake_appendGfx(void* effect) {
    Matrix4f sp18, sp58, sp98, spD8, sp118;
    EffectInstance* effectTemp = effect;
    SnowflakeFXData* data = effectTemp->data.snowflake;

    gDPPipeSync(gMainGfxPos++);
    gSPSegment(gMainGfxPos++, 0x09, VIRTUAL_TO_PHYSICAL(effectTemp->graphics->data));
    gSPDisplayList(gMainGfxPos++, D_09000900_331800);

    shim_guTranslateF(sp18, data->pos.x, data->pos.y, data->pos.z);
    shim_guRotateF(spD8, -gCameras[gCurrentCameraID].currentYaw, 0.0f, 1.0f, 0.0f);
    shim_guMtxCatF(spD8, sp18, sp118);
    shim_guMtxF2L(sp118, &gDisplayContext->matrixStack[gMatrixListPos]);

    gSPMatrix(gMainGfxPos++, &gDisplayContext->matrixStack[gMatrixListPos++], G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
    gDPSetPrimColor(gMainGfxPos++, 0, 0, 0, 0, 0, 255);

    shim_guRotateF(sp58, data->unk_18, 1.0f, 0.0f, 0.0f);
    shim_guRotateF(sp98, data->unk_1C, 0.0f, 1.0f, 0.0f);
    shim_guMtxCatF(sp58, sp98, sp118);
    shim_guMtxF2L(sp118, &gDisplayContext->matrixStack[gMatrixListPos]);

    gSPMatrix(gMainGfxPos++, &gDisplayContext->matrixStack[gMatrixListPos++], G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
    gSPDisplayList(gMainGfxPos++, D_090009E8_3318E8);
    gSPPopMatrix(gMainGfxPos++, G_MTX_MODELVIEW);
    gSPPopMatrix(gMainGfxPos++, G_MTX_MODELVIEW);
}


### RAW ASSEMBLY INSTRUCTIONS:

glabel func_80240FDC
/* 16F8BC 80240FDC 27BDFFD8 */  addiu     $sp, $sp, -0x28
glabel func_80240FE0
/* 16F8C0 80240FE0 AFB40020 */  sw        $s4, 0x20($sp)
glabel func_80240FE4
/* 16F8C4 80240FE4 3C14800E */  lui       $s4, %hi(gBattleStatus)
glabel func_80240FE8
/* 16F8C8 80240FE8 2694C070 */  addiu     $s4, $s4, %lo(gBattleStatus)
glabel end_00_CharAnim_HoldClearImgFX
/* 16F8CC 80240FEC AFB3001C */  sw        $s3, 0x1C($sp)
glabel func_80240FF0
/* 16F8D0 80240FF0 3C13800B */  lui       $s3, %hi(gCurrentEncounter)
glabel omo_04_FlyingAI_Jump
/* 16F8D4 80240FF4 26730F10 */  addiu     $s3, $s3, %lo(gCurrentEncounter)
glabel func_80240FF8
/* 16F8D8 80240FF8 AFB00010 */  sw        $s0, 0x10($sp)
glabel func_80240FFC
/* 16F8DC 80240FFC 3C108011 */  lui       $s0, %hi(gPlayerData)
glabel dead_flo_16_FlyingAI_Wander
/* 16F8E0 80241000 2610F290 */  addiu     $s0, $s0, %lo(gPlayerData)
glabel pra_28_GetItemName
/* 16F8E4 80241004 AFBF0024 */  sw        $ra, 0x24($sp)
glabel func_80241008
/* 16F8E8 80241008 AFB20018 */  sw        $s2, 0x18($sp)
D_8024100C:
/* 16F8EC 8024100C AFB10014 */  sw        $s1, 0x14($sp)
glabel func_80241010
/* 16F8F0 80241010 8E820004 */  lw        $v0, 0x4($s4)
glabel func_80241014
/* 16F8F4 80241014 30420040 */  andi      $v0, $v0, 0x40
glabel func_80241018
/* 16F8F8 80241018 14400055 */  bnez      $v0, mgm_00_GetAvailableGamesCount
glabel dead_flo_13_FlyingAI_LosePlayer
/* 16F8FC 8024101C 24110003 */   addiu    $s1, $zero, 0x3
glabel func_80241020
/* 16F900 80241020 8282008A */  lb        $v0, 0x8A($s4)
glabel func_80241024
/* 16F904 80241024 10510052 */  beq       $v0, $s1, mgm_00_GetAvailableGamesCount
glabel UpdateAntiGuyPosition
/* 16F908 80241028 24120004 */   addiu    $s2, $zero, 0x4
glabel func_8024102C
/* 16F90C 8024102C 10520050 */  beq       $v0, $s2, mgm_00_GetAvailableGamesCount
glabel func_80241030
/* 16F910 80241030 00000000 */   nop
.L80241034:
/* 16F914 80241034 8202028A */  lb        $v0, 0x28A($s0)
glabel func_80241038
/* 16F918 80241038 1840004D */  blez      $v0, mgm_00_GetAvailableGamesCount
glabel func_8024103C
/* 16F91C 8024103C 00000000 */   nop
glabel func_80241040
/* 16F920 80241040 8602028C */  lh        $v0, 0x28C($s0)
flo_19_pad_1044:
/* 16F924 80241044 1C400039 */  bgtz      $v0, func_8024112C
glabel .L80241048
/* 16F928 80241048 00000000 */   nop
D_8024104C:
/* 16F92C 8024104C 0C00A67F */  jal       rand_int
D_80241050:
/* 16F930 80241050 24040064 */   addiu    $a0, $zero, 0x64
glabel func_80241054
/* 16F934 80241054 8E63008C */  lw        $v1, 0x8C($s3)
glabel func_80241058
/* 16F938 80241058 10600018 */  beqz      $v1, func_802410BC
.L8024105C:
/* 16F93C 8024105C 0040202D */   daddu    $a0, $v0, $zero
glabel omo_04_FlyingAI_ChaseInit
/* 16F940 80241060 8C620000 */  lw        $v0, 0x0($v1)
glabel func_80241064
/* 16F944 80241064 3C030004 */  lui       $v1, (0x40000 >> 16)
glabel func_80241068
/* 16F948 80241068 00431024 */  and       $v0, $v0, $v1
glabel func_8024106C
/* 16F94C 8024106C 10400008 */  beqz      $v0, mgm_01_OnBreakBlock
glabel func_80241070
/* 16F950 80241070 2882002E */   slti     $v0, $a0, 0x2E
glabel func_80241074
/* 16F954 80241074 14400014 */  bnez      $v0, func_802410C8
glabel pra_35_PatrolAI_Move
/* 16F958 80241078 24020001 */   addiu    $v0, $zero, 0x1
glabel func_8024107C
/* 16F95C 8024107C 2882005B */  slti      $v0, $a0, 0x5B
glabel func_80241080
/* 16F960 80241080 14400016 */  bnez      $v0, D_802410DC
glabel func_80241084
/* 16F964 80241084 24020002 */   addiu    $v0, $zero, 0x2
glabel sam_07_PiranhaPlantAI_10
/* 16F968 80241088 0809043D */  j         func_802410F4
glabel func_8024108C
/* 16F96C 8024108C A2110289 */   sb       $s1, 0x289($s0)
glabel mgm_01_OnBreakBlock
/* 16F970 80241090 2882001F */  slti      $v0, $a0, 0x1F
D_80241094:
/* 16F974 80241094 1440000C */  bnez      $v0, func_802410C8
glabel func_80241098
/* 16F978 80241098 24020001 */   addiu    $v0, $zero, 0x1
glabel func_8024109C
/* 16F97C 8024109C 2882003D */  slti      $v0, $a0, 0x3D
D_802410A0:
/* 16F980 802410A0 1440000E */  bnez      $v0, D_802410DC
glabel omo_09_PatrolAI_Move
/* 16F984 802410A4 24020002 */   addiu    $v0, $zero, 0x2
D_802410A8:
/* 16F988 802410A8 28820051 */  slti      $v0, $a0, 0x51
D_802410AC:
/* 16F98C 802410AC 54400011 */  bnel      $v0, $zero, func_802410F4
glabel omo_02_GuardAI_AlertInit
/* 16F990 802410B0 A2110289 */   sb       $s1, 0x289($s0)
glabel func_802410B4
/* 16F994 802410B4 0809043D */  j         func_802410F4
glabel func_802410B8
/* 16F998 802410B8 A2120289 */   sb       $s2, 0x289($s0)
glabel func_802410BC
/* 16F99C 802410BC 2882001F */  slti      $v0, $a0, 0x1F
glabel func_802410C0
/* 16F9A0 802410C0 10400003 */  beqz      $v0, func_802410D0
glabel func_802410C4
/* 16F9A4 802410C4 24020001 */   addiu    $v0, $zero, 0x1
glabel func_802410C8
/* 16F9A8 802410C8 0809043D */  j         func_802410F4
glabel func_802410CC
/* 16F9AC 802410CC A2020289 */   sb       $v0, 0x289($s0)
glabel func_802410D0
/* 16F9B0 802410D0 2882003D */  slti      $v0, $a0, 0x3D
glabel func_802410D4
/* 16F9B4 802410D4 10400003 */  beqz      $v0, func_802410E4_EB9F34
.L802410D8:
/* 16F9B8 802410D8 24020002 */   addiu    $v0, $zero, 0x2
D_802410DC:
/* 16F9BC 802410DC 0809043D */  j         func_802410F4
glabel func_802410E0
/* 16F9C0 802410E0 A2020289 */   sb       $v0, 0x289($s0)
glabel func_802410E4_EB9F34
/* 16F9C4 802410E4 28820051 */  slti      $v0, $a0, 0x51
.L802410E8:
/* 16F9C8 802410E8 50400002 */  beql      $v0, $zero, func_802410F4
glabel func_802410EC
/* 16F9CC 802410EC A2120289 */   sb       $s2, 0x289($s0)
D_802410F0:
/* 16F9D0 802410F0 A2110289 */  sb        $s1, 0x289($s0)
glabel func_802410F4
/* 16F9D4 802410F4 82030289 */  lb        $v1, 0x289($s0)
D_802410F8:
/* 16F9D8 802410F8 24020004 */  addiu     $v0, $zero, 0x4
glabel func_802410FC
/* 16F9DC 802410FC 10620006 */  beq       $v1, $v0, D_80241118
glabel omo_07_PatrolNoAttackAI_Main
/* 16F9E0 80241100 2402FFFF */   addiu    $v0, $zero, -0x1
glabel func_80241104
/* 16F9E4 80241104 8603028C */  lh        $v1, 0x28C($s0)
glabel func_80241108
/* 16F9E8 80241108 10620004 */  beq       $v1, $v0, func_8024111C
glabel func_8024110C
/* 16F9EC 8024110C 24040005 */   addiu    $a0, $zero, 0x5
glabel func_80241110
/* 16F9F0 80241110 08090447 */  j         func_8024111C
glabel dead_flo_09_FlyingAI_Chase
/* 16F9F4 80241114 00000000 */   nop
D_80241118:
/* 16F9F8 80241118 24040008 */  addiu     $a0, $zero, 0x8
glabel func_8024111C
/* 16F9FC 8024111C 0C00A67F */  jal       rand_int
glabel func_80241120
/* 16FA00 80241120 00000000 */   nop
glabel func_80241124
/* 16FA04 80241124 24440005 */  addiu     $a0, $v0, 0x5
glabel func_80241128
/* 16FA08 80241128 A604028C */  sh        $a0, 0x28C($s0)
glabel func_8024112C
/* 16FA0C 8024112C 92040289 */  lbu       $a0, 0x289($s0)
glabel func_80241130
/* 16FA10 80241130 2482FFFD */  addiu     $v0, $a0, -0x3
glabel func_80241134
/* 16FA14 80241134 2C420002 */  sltiu     $v0, $v0, 0x2
glabel func_80241138
/* 16FA18 80241138 1040000D */  beqz      $v0, mgm_00_GetAvailableGamesCount
glabel func_8024113C
/* 16FA1C 8024113C 00000000 */   nop
.L80241140:
/* 16FA20 80241140 8602028C */  lh        $v0, 0x28C($s0)
glabel func_80241144
/* 16FA24 80241144 9603028C */  lhu       $v1, 0x28C($s0)
glabel .L80241148
/* 16FA28 80241148 28420002 */  slti      $v0, $v0, 0x2
glabel func_8024114C
/* 16FA2C 8024114C 14400003 */  bnez      $v0, func_8024115C
glabel func_80241150
/* 16FA30 80241150 2462FFFF */   addiu    $v0, $v1, -0x1
glabel func_80241154
/* 16FA34 80241154 0809045C */  j         mgm_00_GetAvailableGamesCount
glabel pra_37_MeleeHitbox_CanSeePlayer
/* 16FA38 80241158 A602028C */   sh       $v0, 0x28C($s0)
glabel func_8024115C
/* 16FA3C 8024115C 9202028A */  lbu       $v0, 0x28A($s0)
glabel func_80241160
/* 16FA40 80241160 A284008A */  sb        $a0, 0x8A($s4)
glabel func_80241164
/* 16FA44 80241164 A600028C */  sh        $zero, 0x28C($s0)
glabel func_80241168
/* 16FA48 80241168 2442FFFF */  addiu     $v0, $v0, -0x1
D_8024116C:
/* 16FA4C 8024116C A202028A */  sb        $v0, 0x28A($s0)
glabel mgm_00_GetAvailableGamesCount
/* 16FA50 80241170 8FBF0024 */  lw        $ra, 0x24($sp)
glabel func_80241174
/* 16FA54 80241174 8FB40020 */  lw        $s4, 0x20($sp)
glabel dead_flo_09_FlyingAI_LosePlayer
/* 16FA58 80241178 8FB3001C */  lw        $s3, 0x1C($sp)
.L8024117C:
/* 16FA5C 8024117C 8FB20018 */  lw        $s2, 0x18($sp)
glabel func_80241180
/* 16FA60 80241180 8FB10014 */  lw        $s1, 0x14($sp)
.L80241184:
/* 16FA64 80241184 8FB00010 */  lw        $s0, 0x10($sp)
glabel omo_02_GuardAI_ChaseInit
/* 16FA68 80241188 03E00008 */  jr        $ra
D_8024118C:
/* 16FA6C 8024118C 27BD0028 */   addiu    $sp, $sp, 0x28

### DECOMPILED C INSTRUCTIONS:

void btl_merlee_on_first_strike(void) {
    BattleStatus* battleStatus = &gBattleStatus;
    EncounterStatus* currentEncounter = &gCurrentEncounter;
    PlayerData* playerData = &gPlayerData;

    do {
        if (!(gBattleStatus.flags2 & BS_FLAGS2_PEACH_BATTLE)
            && battleStatus->nextMerleeSpellType != MERLEE_SPELL_EXP_BOOST
            && battleStatus->nextMerleeSpellType != MERLEE_SPELL_COIN_BOOST
            && playerData->merleeCastsLeft > 0)
        {
            if (playerData->merleeTurnCount <= 0) {
                s32 temp = rand_int(100);

                if (currentEncounter->currentEnemy != NULL) {
                    if (currentEncounter->currentEnemy->flags & ACTOR_FLAG_NO_HEALTH_BAR) {
                        if (temp <= 45) {
                            playerData->merleeSpellType = MERLEE_SPELL_1;
                        } else if (temp <= 90) {
                            playerData->merleeSpellType = MERLEE_SPELL_2;
                        } else {
                            playerData->merleeSpellType = MERLEE_SPELL_EXP_BOOST;
                        }
                    } else if (temp <= 30) {
                        playerData->merleeSpellType = MERLEE_SPELL_1;
                    } else if (temp <= 60) {
                        playerData->merleeSpellType = MERLEE_SPELL_2;
                    } else if (temp <= 80) {
                        playerData->merleeSpellType = MERLEE_SPELL_EXP_BOOST;
                    } else {
                        playerData->merleeSpellType = MERLEE_SPELL_COIN_BOOST;
                    }
                } else if (temp <= 30) {
                    playerData->merleeSpellType = MERLEE_SPELL_1;
                } else if (temp <= 60) {
                    playerData->merleeSpellType = MERLEE_SPELL_2;
                } else if (temp <= 80) {
                    playerData->merleeSpellType = MERLEE_SPELL_EXP_BOOST;
                } else {
                    playerData->merleeSpellType = MERLEE_SPELL_COIN_BOOST;
                }

                if (playerData->merleeSpellType != MERLEE_SPELL_COIN_BOOST) {
                    // same outcome either way. has to be written like this, and the check does exist in the code. bug?
                    if (playerData->merleeTurnCount == -1) {
                        temp = rand_int(5) + 5;
                    } else {
                        temp = rand_int(5) + 5;

                    }
                } else {
                    temp = rand_int(8) + 5;
                }
                playerData->merleeTurnCount = temp;
            }

            if (playerData->merleeSpellType == MERLEE_SPELL_EXP_BOOST || playerData->merleeSpellType == MERLEE_SPELL_COIN_BOOST) {
                if (playerData->merleeTurnCount >= 2) {
                    playerData->merleeTurnCount--;
                } else {
                    battleStatus->nextMerleeSpellType = playerData->merleeSpellType;
                    playerData->merleeTurnCount = 0;
                    playerData->merleeCastsLeft--;
                }
            }
        }
    } while (0); // TODO: required to match
}


### RAW ASSEMBLY INSTRUCTIONS:

glabel damage_stars_update
/* 342870 E0030730 27BDFFB0 */  addiu     $sp, $sp, -0x50
/* 342874 E0030734 AFB40020 */  sw        $s4, 0x20($sp)
/* 342878 E0030738 0080A02D */  daddu     $s4, $a0, $zero
/* 34287C E003073C AFBF002C */  sw        $ra, 0x2C($sp)
/* 342880 E0030740 AFB60028 */  sw        $s6, 0x28($sp)
/* 342884 E0030744 AFB50024 */  sw        $s5, 0x24($sp)
/* 342888 E0030748 AFB3001C */  sw        $s3, 0x1C($sp)
/* 34288C E003074C AFB20018 */  sw        $s2, 0x18($sp)
/* 342890 E0030750 AFB10014 */  sw        $s1, 0x14($sp)
/* 342894 E0030754 AFB00010 */  sw        $s0, 0x10($sp)
/* 342898 E0030758 F7BA0048 */  sdc1      $f26, 0x48($sp)
/* 34289C E003075C F7B80040 */  sdc1      $f24, 0x40($sp)
/* 3428A0 E0030760 F7B60038 */  sdc1      $f22, 0x38($sp)
/* 3428A4 E0030764 F7B40030 */  sdc1      $f20, 0x30($sp)
/* 3428A8 E0030768 8E91000C */  lw        $s1, 0xC($s4)
/* 3428AC E003076C 8E220028 */  lw        $v0, 0x28($s1)
/* 3428B0 E0030770 2442FFFF */  addiu     $v0, $v0, -0x1
/* 3428B4 E0030774 AE220028 */  sw        $v0, 0x28($s1)
/* 3428B8 E0030778 8E22002C */  lw        $v0, 0x2C($s1)
/* 3428BC E003077C 8E240028 */  lw        $a0, 0x28($s1)
/* 3428C0 E0030780 24430001 */  addiu     $v1, $v0, 0x1
/* 3428C4 E0030784 04810005 */  bgez      $a0, .LE003079C
/* 3428C8 E0030788 AE23002C */   sw       $v1, 0x2C($s1)
/* 3428CC E003078C 0C080128 */  jal       shim_remove_effect
/* 3428D0 E0030790 0280202D */   daddu    $a0, $s4, $zero
/* 3428D4 E0030794 0800C27B */  j         .LE00309EC
/* 3428D8 E0030798 00000000 */   nop
.LE003079C:
/* 3428DC E003079C 0000902D */  daddu     $s2, $zero, $zero
/* 3428E0 E00307A0 8E820008 */  lw        $v0, 0x8($s4)
/* 3428E4 E00307A4 18400091 */  blez      $v0, .LE00309EC
/* 3428E8 E00307A8 0080982D */   daddu    $s3, $a0, $zero
/* 3428EC E00307AC 00031040 */  sll       $v0, $v1, 1
/* 3428F0 E00307B0 00431021 */  addu      $v0, $v0, $v1
/* 3428F4 E00307B4 0002B040 */  sll       $s6, $v0, 1
/* 3428F8 E00307B8 2662FFFA */  addiu     $v0, $s3, -0x6
/* 3428FC E00307BC 2C55000E */  sltiu     $s5, $v0, 0xE
/* 342900 E00307C0 2630001C */  addiu     $s0, $s1, 0x1C
/* 342904 E00307C4 3C01E003 */  lui       $at, (0xE0030ED8 >> 16)
/* 342908 E00307C8 D43A0ED8 */  ldc1      $f26, (0xE0030ED8 & 0xFFFF)($at)
/* 34290C E00307CC 3C01E003 */  lui       $at, (0xE0030EE0 >> 16)
/* 342910 E00307D0 D4340EE0 */  ldc1      $f20, (0xE0030EE0 & 0xFFFF)($at)
/* 342914 E00307D4 3C01E003 */  lui       $at, (0xE0030EE8 >> 16)
/* 342918 E00307D8 D4380EE8 */  ldc1      $f24, (0xE0030EE8 & 0xFFFF)($at)
/* 34291C E00307DC 3C01E003 */  lui       $at, (0xE0030EF0 >> 16)
/* 342920 E00307E0 D4360EF0 */  ldc1      $f22, (0xE0030EF0 & 0xFFFF)($at)
.LE00307E4:
/* 342924 E00307E4 8E230000 */  lw        $v1, 0x0($s1)
/* 342928 E00307E8 24020002 */  addiu     $v0, $zero, 0x2
/* 34292C E00307EC 14620029 */  bne       $v1, $v0, .LE0030894
/* 342930 E00307F0 2A620006 */   slti     $v0, $s3, 0x6
/* 342934 E00307F4 44966000 */  mtc1      $s6, $f12
/* 342938 E00307F8 00000000 */  nop
/* 34293C E00307FC 0C080144 */  jal       shim_cos_deg
/* 342940 E0030800 46806320 */   cvt.s.w  $f12, $f12
/* 342944 E0030804 C604FFF4 */  lwc1      $f4, -0xC($s0)
/* 342948 E0030808 46002121 */  cvt.d.s   $f4, $f4
/* 34294C E003080C 463A2102 */  mul.d     $f4, $f4, $f26
/* 342950 E0030810 00000000 */  nop
/* 342954 E0030814 3C014080 */  lui       $at, (0x40800000 >> 16)
/* 342958 E0030818 44811000 */  mtc1      $at, $f2
/* 34295C E003081C 00000000 */  nop
/* 342960 E0030820 46020002 */  mul.s     $f0, $f0, $f2
/* 342964 E0030824 00000000 */  nop
/* 342968 E0030828 C602FFFC */  lwc1      $f2, -0x4($s0)
/* 34296C E003082C 460010A1 */  cvt.d.s   $f2, $f2
/* 342970 E0030830 463A1082 */  mul.d     $f2, $f2, $f26
/* 342974 E0030834 00000000 */  nop
/* 342978 E0030838 E600FFF8 */  swc1      $f0, -0x8($s0)
/* 34297C E003083C 46202120 */  cvt.s.d   $f4, $f4
/* 342980 E0030840 E604FFF4 */  swc1      $f4, -0xC($s0)
/* 342984 E0030844 46000106 */  mov.s     $f4, $f0
/* 342988 E0030848 44800000 */  mtc1      $zero, $f0
/* 34298C E003084C 462010A0 */  cvt.s.d   $f2, $f2
/* 342990 E0030850 4600203C */  c.lt.s    $f4, $f0
/* 342994 E0030854 00000000 */  nop
/* 342998 E0030858 4500004E */  bc1f      .LE0030994
/* 34299C E003085C E602FFFC */   swc1     $f2, -0x4($s0)
/* 3429A0 E0030860 C6020008 */  lwc1      $f2, 0x8($s0)
/* 3429A4 E0030864 468010A1 */  cvt.d.w   $f2, $f2
/* 3429A8 E0030868 46381082 */  mul.d     $f2, $f2, $f24
/* 3429AC E003086C 00000000 */  nop
/* 3429B0 E0030870 C6000004 */  lwc1      $f0, 0x4($s0)
/* 3429B4 E0030874 46000021 */  cvt.d.s   $f0, $f0
/* 3429B8 E0030878 46340002 */  mul.d     $f0, $f0, $f20
/* 3429BC E003087C 00000000 */  nop
/* 3429C0 E0030880 4620128D */  trunc.w.d $f10, $f2
/* 3429C4 E0030884 E60A0008 */  swc1      $f10, 0x8($s0)
/* 3429C8 E0030888 46200020 */  cvt.s.d   $f0, $f0
/* 3429CC E003088C 0800C265 */  j         .LE0030994
/* 3429D0 E0030890 E6000004 */   swc1     $f0, 0x4($s0)
.LE0030894:
/* 3429D4 E0030894 14400013 */  bnez      $v0, .LE00308E4
/* 3429D8 E0030898 00000000 */   nop
/* 3429DC E003089C C604FFF4 */  lwc1      $f4, -0xC($s0)
/* 3429E0 E00308A0 46002121 */  cvt.d.s   $f4, $f4
/* 3429E4 E00308A4 46342102 */  mul.d     $f4, $f4, $f20
/* 3429E8 E00308A8 00000000 */  nop
/* 3429EC E00308AC C602FFF8 */  lwc1      $f2, -0x8($s0)
/* 3429F0 E00308B0 460010A1 */  cvt.d.s   $f2, $f2
/* 3429F4 E00308B4 46341082 */  mul.d     $f2, $f2, $f20
/* 3429F8 E00308B8 00000000 */  nop
/* 3429FC E00308BC C600FFFC */  lwc1      $f0, -0x4($s0)
/* 342A00 E00308C0 46000021 */  cvt.d.s   $f0, $f0
/* 342A04 E00308C4 46340002 */  mul.d     $f0, $f0, $f20
/* 342A08 E00308C8 00000000 */  nop
/* 342A0C E00308CC 46202120 */  cvt.s.d   $f4, $f4
/* 342A10 E00308D0 462010A0 */  cvt.s.d   $f2, $f2
/* 342A14 E00308D4 46200020 */  cvt.s.d   $f0, $f0
/* 342A18 E00308D8 E604FFF4 */  swc1      $f4, -0xC($s0)
/* 342A1C E00308DC E602FFF8 */  swc1      $f2, -0x8($s0)
/* 342A20 E00308E0 E600FFFC */  swc1      $f0, -0x4($s0)
.LE00308E4:
/* 342A24 E00308E4 12A0000B */  beqz      $s5, .LE0030914
/* 342A28 E00308E8 2A620005 */   slti     $v0, $s3, 0x5
/* 342A2C E00308EC 8E220000 */  lw        $v0, 0x0($s1)
/* 342A30 E00308F0 54400029 */  bnel      $v0, $zero, .LE0030998
/* 342A34 E00308F4 26520001 */   addiu    $s2, $s2, 0x1
/* 342A38 E00308F8 C6000004 */  lwc1      $f0, 0x4($s0)
/* 342A3C E00308FC 3C013F80 */  lui       $at, (0x3F800000 >> 16)
/* 342A40 E0030900 44811000 */  mtc1      $at, $f2
/* 342A44 E0030904 00000000 */  nop
/* 342A48 E0030908 46020000 */  add.s     $f0, $f0, $f2
/* 342A4C E003090C 0800C265 */  j         .LE0030994
/* 342A50 E0030910 E6000004 */   swc1     $f0, 0x4($s0)
.LE0030914:
/* 342A54 E0030914 50400020 */  beql      $v0, $zero, .LE0030998
/* 342A58 E0030918 26520001 */   addiu    $s2, $s2, 0x1
/* 342A5C E003091C C6080008 */  lwc1      $f8, 0x8($s0)
/* 342A60 E0030920 46804221 */  cvt.d.w   $f8, $f8
/* 342A64 E0030924 46384202 */  mul.d     $f8, $f8, $f24
/* 342A68 E0030928 00000000 */  nop
/* 342A6C E003092C C6060004 */  lwc1      $f6, 0x4($s0)
/* 342A70 E0030930 460031A1 */  cvt.d.s   $f6, $f6
/* 342A74 E0030934 46343182 */  mul.d     $f6, $f6, $f20
/* 342A78 E0030938 00000000 */  nop
/* 342A7C E003093C C604FFF4 */  lwc1      $f4, -0xC($s0)
/* 342A80 E0030940 46002121 */  cvt.d.s   $f4, $f4
/* 342A84 E0030944 46362102 */  mul.d     $f4, $f4, $f22
/* 342A88 E0030948 00000000 */  nop
/* 342A8C E003094C C602FFF8 */  lwc1      $f2, -0x8($s0)
/* 342A90 E0030950 460010A1 */  cvt.d.s   $f2, $f2
/* 342A94 E0030954 46361082 */  mul.d     $f2, $f2, $f22
/* 342A98 E0030958 00000000 */  nop
/* 342A9C E003095C C600FFFC */  lwc1      $f0, -0x4($s0)
/* 342AA0 E0030960 46000021 */  cvt.d.s   $f0, $f0
/* 342AA4 E0030964 46360002 */  mul.d     $f0, $f0, $f22
/* 342AA8 E0030968 00000000 */  nop
/* 342AAC E003096C 4620428D */  trunc.w.d $f10, $f8
/* 342AB0 E0030970 E60A0008 */  swc1      $f10, 0x8($s0)
/* 342AB4 E0030974 462031A0 */  cvt.s.d   $f6, $f6
/* 342AB8 E0030978 46202120 */  cvt.s.d   $f4, $f4
/* 342ABC E003097C 462010A0 */  cvt.s.d   $f2, $f2
/* 342AC0 E0030980 46200020 */  cvt.s.d   $f0, $f0
/* 342AC4 E0030984 E6060004 */  swc1      $f6, 0x4($s0)
/* 342AC8 E0030988 E604FFF4 */  swc1      $f4, -0xC($s0)
/* 342ACC E003098C E602FFF8 */  swc1      $f2, -0x8($s0)
/* 342AD0 E0030990 E600FFFC */  swc1      $f0, -0x4($s0)
.LE0030994:
/* 342AD4 E0030994 26520001 */  addiu     $s2, $s2, 0x1
.LE0030998:
/* 342AD8 E0030998 C608FFE8 */  lwc1      $f8, -0x18($s0)
/* 342ADC E003099C C600FFF4 */  lwc1      $f0, -0xC($s0)
/* 342AE0 E00309A0 C606FFEC */  lwc1      $f6, -0x14($s0)
/* 342AE4 E00309A4 46004200 */  add.s     $f8, $f8, $f0
/* 342AE8 E00309A8 C600FFF8 */  lwc1      $f0, -0x8($s0)
/* 342AEC E00309AC C604FFF0 */  lwc1      $f4, -0x10($s0)
/* 342AF0 E00309B0 46003180 */  add.s     $f6, $f6, $f0
/* 342AF4 E00309B4 C600FFFC */  lwc1      $f0, -0x4($s0)
/* 342AF8 E00309B8 C6020004 */  lwc1      $f2, 0x4($s0)
/* 342AFC E00309BC 46002100 */  add.s     $f4, $f4, $f0
/* 342B00 E00309C0 C6000000 */  lwc1      $f0, 0x0($s0)
/* 342B04 E00309C4 26310030 */  addiu     $s1, $s1, 0x30
/* 342B08 E00309C8 E608FFE8 */  swc1      $f8, -0x18($s0)
/* 342B0C E00309CC 46020000 */  add.s     $f0, $f0, $f2
/* 342B10 E00309D0 E606FFEC */  swc1      $f6, -0x14($s0)
/* 342B14 E00309D4 E604FFF0 */  swc1      $f4, -0x10($s0)
/* 342B18 E00309D8 E6000000 */  swc1      $f0, 0x0($s0)
/* 342B1C E00309DC 8E820008 */  lw        $v0, 0x8($s4)
/* 342B20 E00309E0 0242102A */  slt       $v0, $s2, $v0
/* 342B24 E00309E4 1440FF7F */  bnez      $v0, .LE00307E4
/* 342B28 E00309E8 26100030 */   addiu    $s0, $s0, 0x30
.LE00309EC:
/* 342B2C E00309EC 8FBF002C */  lw        $ra, 0x2C($sp)
/* 342B30 E00309F0 8FB60028 */  lw        $s6, 0x28($sp)
/* 342B34 E00309F4 8FB50024 */  lw        $s5, 0x24($sp)
/* 342B38 E00309F8 8FB40020 */  lw        $s4, 0x20($sp)
/* 342B3C E00309FC 8FB3001C */  lw        $s3, 0x1C($sp)
/* 342B40 E0030A00 8FB20018 */  lw        $s2, 0x18($sp)
/* 342B44 E0030A04 8FB10014 */  lw        $s1, 0x14($sp)
/* 342B48 E0030A08 8FB00010 */  lw        $s0, 0x10($sp)
/* 342B4C E0030A0C D7BA0048 */  ldc1      $f26, 0x48($sp)
/* 342B50 E0030A10 D7B80040 */  ldc1      $f24, 0x40($sp)
/* 342B54 E0030A14 D7B60038 */  ldc1      $f22, 0x38($sp)
/* 342B58 E0030A18 D7B40030 */  ldc1      $f20, 0x30($sp)
/* 342B5C E0030A1C 03E00008 */  jr        $ra
/* 342B60 E0030A20 27BD0050 */   addiu    $sp, $sp, 0x50

### DECOMPILED C INSTRUCTIONS:

void damage_stars_update(EffectInstance* effect) {
    DamageStarsFXData* part = effect->data.damageStars;
    s32 unk_28;
    s32 unk_2C;
    s32 i;

    part->unk_28--;
    part->unk_2C++;

    if (part->unk_28 < 0) {
        shim_remove_effect(effect);
        return;
    }

    unk_28 = part->unk_28;
    unk_2C = part->unk_2C;

    for (i = 0; i < effect->numParts; i++, part++) {
        if (part->unk_00 == 2) {
            part->unk_14 = shim_cos_deg(unk_2C * 6) * 4.0f;
            part->unk_10 *= 0.94;
            part->unk_18 *= 0.94;
            if (part->unk_14 < 0.0f) {
                part->unk_20 *= 0.8;
                part->unk_24 *= 0.6;
            }
        } else {
            if (unk_28 >= 6) {
                part->unk_10 *= 0.8;
                part->unk_14 *= 0.8;
                part->unk_18 *= 0.8;
            }
            if (unk_28 >= 6 && unk_28 <= 19) {
                if (part->unk_00 == 0) {
                    part->unk_20 += 1.0f;
                }
            } else if (unk_28 < 5) {
                part->unk_20 *= 0.8;
                part->unk_24 *= 0.6;
                part->unk_10 *= 0.7;
                part->unk_14 *= 0.7;
                part->unk_18 *= 0.7;
            }
        }

        part->unk_04 += part->unk_10;
        part->unk_08 += part->unk_14;
        part->unk_0C += part->unk_18;
        part->unk_1C += part->unk_20;
    }
}