.set noat # allow manual use of $at .set noreorder # don't insert nops after branches glabel ItemAfflictEnemy /* 181204 80252924 27BDFFD8 */ addiu $sp, $sp, -0x28 /* 181208 80252928 AFB20018 */ sw $s2, 0x18($sp) /* 18120C 8025292C 0080902D */ daddu $s2, $a0, $zero /* 181210 80252930 AFBF0020 */ sw $ra, 0x20($sp) /* 181214 80252934 AFB3001C */ sw $s3, 0x1c($sp) /* 181218 80252938 AFB10014 */ sw $s1, 0x14($sp) /* 18121C 8025293C AFB00010 */ sw $s0, 0x10($sp) /* 181220 80252940 8E50000C */ lw $s0, 0xc($s2) /* 181224 80252944 3C11800E */ lui $s1, 0x800e /* 181228 80252948 2631C070 */ addiu $s1, $s1, -0x3f90 /* 18122C 8025294C 8E130000 */ lw $s3, ($s0) /* 181230 80252950 26100004 */ addiu $s0, $s0, 4 /* 181234 80252954 8E020000 */ lw $v0, ($s0) /* 181238 80252958 26100004 */ addiu $s0, $s0, 4 /* 18123C 8025295C AE20018C */ sw $zero, 0x18c($s1) /* 181240 80252960 AE220188 */ sw $v0, 0x188($s1) /* 181244 80252964 8E020000 */ lw $v0, ($s0) /* 181248 80252968 26100004 */ addiu $s0, $s0, 4 /* 18124C 8025296C AE220190 */ sw $v0, 0x190($s1) /* 181250 80252970 8E050000 */ lw $a1, ($s0) /* 181254 80252974 0C0B1EAF */ jal get_variable /* 181258 80252978 26100004 */ addiu $s0, $s0, 4 /* 18125C 8025297C 8E230190 */ lw $v1, 0x190($s1) /* 181260 80252980 0240202D */ daddu $a0, $s2, $zero /* 181264 80252984 00621825 */ or $v1, $v1, $v0 /* 181268 80252988 AE230190 */ sw $v1, 0x190($s1) /* 18126C 8025298C 8E050000 */ lw $a1, ($s0) /* 181270 80252990 0C0B1EAF */ jal get_variable /* 181274 80252994 26100004 */ addiu $s0, $s0, 4 /* 181278 80252998 A622017E */ sh $v0, 0x17e($s1) /* 18127C 8025299C 8E100000 */ lw $s0, ($s0) /* 181280 802529A0 24020030 */ addiu $v0, $zero, 0x30 /* 181284 802529A4 32030030 */ andi $v1, $s0, 0x30 /* 181288 802529A8 54620004 */ bnel $v1, $v0, .L802529BC /* 18128C 802529AC 32020010 */ andi $v0, $s0, 0x10 /* 181290 802529B0 8E220000 */ lw $v0, ($s1) /* 181294 802529B4 08094A7F */ j .L802529FC /* 181298 802529B8 34420030 */ ori $v0, $v0, 0x30 .L802529BC: /* 18129C 802529BC 10400004 */ beqz $v0, .L802529D0 /* 1812A0 802529C0 2403FFDF */ addiu $v1, $zero, -0x21 /* 1812A4 802529C4 8E220000 */ lw $v0, ($s1) /* 1812A8 802529C8 08094A7E */ j .L802529F8 /* 1812AC 802529CC 34420010 */ ori $v0, $v0, 0x10 .L802529D0: /* 1812B0 802529D0 32020020 */ andi $v0, $s0, 0x20 /* 1812B4 802529D4 10400005 */ beqz $v0, .L802529EC /* 1812B8 802529D8 2403FFEF */ addiu $v1, $zero, -0x11 /* 1812BC 802529DC 8E220000 */ lw $v0, ($s1) /* 1812C0 802529E0 00431024 */ and $v0, $v0, $v1 /* 1812C4 802529E4 08094A7F */ j .L802529FC /* 1812C8 802529E8 34420020 */ ori $v0, $v0, 0x20 .L802529EC: /* 1812CC 802529EC 8E220000 */ lw $v0, ($s1) /* 1812D0 802529F0 00431024 */ and $v0, $v0, $v1 /* 1812D4 802529F4 2403FFDF */ addiu $v1, $zero, -0x21 .L802529F8: /* 1812D8 802529F8 00431024 */ and $v0, $v0, $v1 .L802529FC: /* 1812DC 802529FC AE220000 */ sw $v0, ($s1) /* 1812E0 80252A00 32020040 */ andi $v0, $s0, 0x40 /* 1812E4 80252A04 10400007 */ beqz $v0, .L80252A24 /* 1812E8 80252A08 2404FFBF */ addiu $a0, $zero, -0x41 /* 1812EC 80252A0C 3C03800E */ lui $v1, 0x800e /* 1812F0 80252A10 2463C070 */ addiu $v1, $v1, -0x3f90 /* 1812F4 80252A14 8C620000 */ lw $v0, ($v1) /* 1812F8 80252A18 34420040 */ ori $v0, $v0, 0x40 /* 1812FC 80252A1C 08094A8E */ j .L80252A38 /* 181300 80252A20 AC620000 */ sw $v0, ($v1) .L80252A24: /* 181304 80252A24 3C02800E */ lui $v0, 0x800e /* 181308 80252A28 2442C070 */ addiu $v0, $v0, -0x3f90 /* 18130C 80252A2C 8C430000 */ lw $v1, ($v0) /* 181310 80252A30 00641824 */ and $v1, $v1, $a0 /* 181314 80252A34 AC430000 */ sw $v1, ($v0) .L80252A38: /* 181318 80252A38 32020200 */ andi $v0, $s0, 0x200 /* 18131C 80252A3C 10400007 */ beqz $v0, .L80252A5C /* 181320 80252A40 2404FDFF */ addiu $a0, $zero, -0x201 /* 181324 80252A44 3C03800E */ lui $v1, 0x800e /* 181328 80252A48 2463C070 */ addiu $v1, $v1, -0x3f90 /* 18132C 80252A4C 8C620000 */ lw $v0, ($v1) /* 181330 80252A50 34420200 */ ori $v0, $v0, 0x200 /* 181334 80252A54 08094A9C */ j .L80252A70 /* 181338 80252A58 AC620000 */ sw $v0, ($v1) .L80252A5C: /* 18133C 80252A5C 3C02800E */ lui $v0, 0x800e /* 181340 80252A60 2442C070 */ addiu $v0, $v0, -0x3f90 /* 181344 80252A64 8C430000 */ lw $v1, ($v0) /* 181348 80252A68 00641824 */ and $v1, $v1, $a0 /* 18134C 80252A6C AC430000 */ sw $v1, ($v0) .L80252A70: /* 181350 80252A70 32020080 */ andi $v0, $s0, 0x80 /* 181354 80252A74 10400007 */ beqz $v0, .L80252A94 /* 181358 80252A78 2404FF7F */ addiu $a0, $zero, -0x81 /* 18135C 80252A7C 3C03800E */ lui $v1, 0x800e /* 181360 80252A80 2463C070 */ addiu $v1, $v1, -0x3f90 /* 181364 80252A84 8C620000 */ lw $v0, ($v1) /* 181368 80252A88 34420080 */ ori $v0, $v0, 0x80 /* 18136C 80252A8C 08094AAA */ j .L80252AA8 /* 181370 80252A90 AC620000 */ sw $v0, ($v1) .L80252A94: /* 181374 80252A94 3C02800E */ lui $v0, 0x800e /* 181378 80252A98 2442C070 */ addiu $v0, $v0, -0x3f90 /* 18137C 80252A9C 8C430000 */ lw $v1, ($v0) /* 181380 80252AA0 00641824 */ and $v1, $v1, $a0 /* 181384 80252AA4 AC430000 */ sw $v1, ($v0) .L80252AA8: /* 181388 80252AA8 0C09A75B */ jal get_actor /* 18138C 80252AAC 8E440148 */ lw $a0, 0x148($s2) /* 181390 80252AB0 94430428 */ lhu $v1, 0x428($v0) /* 181394 80252AB4 A62301A0 */ sh $v1, 0x1a0($s1) /* 181398 80252AB8 92230193 */ lbu $v1, 0x193($s1) /* 18139C 80252ABC 90420426 */ lbu $v0, 0x426($v0) /* 1813A0 80252AC0 A2230194 */ sb $v1, 0x194($s1) /* 1813A4 80252AC4 306300FF */ andi $v1, $v1, 0xff /* 1813A8 80252AC8 A22201A2 */ sb $v0, 0x1a2($s1) /* 1813AC 80252ACC 240200FF */ addiu $v0, $zero, 0xff /* 1813B0 80252AD0 50620001 */ beql $v1, $v0, .L80252AD8 /* 1813B4 80252AD4 A2200194 */ sb $zero, 0x194($s1) .L80252AD8: /* 1813B8 80252AD8 8E220190 */ lw $v0, 0x190($s1) /* 1813BC 80252ADC 30420F00 */ andi $v0, $v0, 0xf00 /* 1813C0 80252AE0 00021203 */ sra $v0, $v0, 8 /* 1813C4 80252AE4 0C0945BA */ jal calc_item_damage_enemy /* 1813C8 80252AE8 A2220195 */ sb $v0, 0x195($s1) /* 1813CC 80252AEC 0440000B */ bltz $v0, .L80252B1C /* 1813D0 80252AF0 0240202D */ daddu $a0, $s2, $zero /* 1813D4 80252AF4 0260282D */ daddu $a1, $s3, $zero /* 1813D8 80252AF8 0C0B2026 */ jal set_variable /* 1813DC 80252AFC 0040302D */ daddu $a2, $v0, $zero /* 1813E0 80252B00 0C0B1069 */ jal does_script_exist_by_ref /* 1813E4 80252B04 0240202D */ daddu $a0, $s2, $zero /* 1813E8 80252B08 0040182D */ daddu $v1, $v0, $zero /* 1813EC 80252B0C 10600004 */ beqz $v1, .L80252B20 /* 1813F0 80252B10 240200FF */ addiu $v0, $zero, 0xff /* 1813F4 80252B14 08094AC8 */ j .L80252B20 /* 1813F8 80252B18 24020002 */ addiu $v0, $zero, 2 .L80252B1C: /* 1813FC 80252B1C 240200FF */ addiu $v0, $zero, 0xff .L80252B20: .L80252B20: /* 181400 80252B20 8FBF0020 */ lw $ra, 0x20($sp) /* 181404 80252B24 8FB3001C */ lw $s3, 0x1c($sp) /* 181408 80252B28 8FB20018 */ lw $s2, 0x18($sp) /* 18140C 80252B2C 8FB10014 */ lw $s1, 0x14($sp) /* 181410 80252B30 8FB00010 */ lw $s0, 0x10($sp) /* 181414 80252B34 03E00008 */ jr $ra /* 181418 80252B38 27BD0028 */ addiu $sp, $sp, 0x28 /* 18141C 80252B3C 27BDFFD8 */ addiu $sp, $sp, -0x28 /* 181420 80252B40 AFB20018 */ sw $s2, 0x18($sp) /* 181424 80252B44 0080902D */ daddu $s2, $a0, $zero /* 181428 80252B48 AFBF0020 */ sw $ra, 0x20($sp) /* 18142C 80252B4C AFB3001C */ sw $s3, 0x1c($sp) /* 181430 80252B50 AFB10014 */ sw $s1, 0x14($sp) /* 181434 80252B54 AFB00010 */ sw $s0, 0x10($sp) /* 181438 80252B58 8E50000C */ lw $s0, 0xc($s2) /* 18143C 80252B5C 3C11800E */ lui $s1, 0x800e /* 181440 80252B60 2631C070 */ addiu $s1, $s1, -0x3f90 /* 181444 80252B64 8E130000 */ lw $s3, ($s0) /* 181448 80252B68 26100004 */ addiu $s0, $s0, 4 /* 18144C 80252B6C 8E020000 */ lw $v0, ($s0) /* 181450 80252B70 26100004 */ addiu $s0, $s0, 4 /* 181454 80252B74 AE20018C */ sw $zero, 0x18c($s1) /* 181458 80252B78 AE220188 */ sw $v0, 0x188($s1) /* 18145C 80252B7C 8E050000 */ lw $a1, ($s0) /* 181460 80252B80 0C0B1EAF */ jal get_variable /* 181464 80252B84 26100004 */ addiu $s0, $s0, 4 /* 181468 80252B88 AE220190 */ sw $v0, 0x190($s1) /* 18146C 80252B8C 8E050000 */ lw $a1, ($s0) /* 181470 80252B90 26100004 */ addiu $s0, $s0, 4 /* 181474 80252B94 0C0B1EAF */ jal get_variable /* 181478 80252B98 0240202D */ daddu $a0, $s2, $zero /* 18147C 80252B9C A622017E */ sh $v0, 0x17e($s1) /* 181480 80252BA0 8E100000 */ lw $s0, ($s0) /* 181484 80252BA4 24020030 */ addiu $v0, $zero, 0x30 /* 181488 80252BA8 32030030 */ andi $v1, $s0, 0x30 /* 18148C 80252BAC 54620004 */ bnel $v1, $v0, .L80252BC0 /* 181490 80252BB0 32020010 */ andi $v0, $s0, 0x10 /* 181494 80252BB4 8E220000 */ lw $v0, ($s1) /* 181498 80252BB8 08094B00 */ j .L80252C00 /* 18149C 80252BBC 34420030 */ ori $v0, $v0, 0x30 .L80252BC0: /* 1814A0 80252BC0 10400004 */ beqz $v0, .L80252BD4 /* 1814A4 80252BC4 2403FFDF */ addiu $v1, $zero, -0x21 /* 1814A8 80252BC8 8E220000 */ lw $v0, ($s1) /* 1814AC 80252BCC 08094AFF */ j .L80252BFC /* 1814B0 80252BD0 34420010 */ ori $v0, $v0, 0x10 .L80252BD4: /* 1814B4 80252BD4 32020020 */ andi $v0, $s0, 0x20 /* 1814B8 80252BD8 10400005 */ beqz $v0, .L80252BF0 /* 1814BC 80252BDC 2403FFEF */ addiu $v1, $zero, -0x11 /* 1814C0 80252BE0 8E220000 */ lw $v0, ($s1) /* 1814C4 80252BE4 00431024 */ and $v0, $v0, $v1 /* 1814C8 80252BE8 08094B00 */ j .L80252C00 /* 1814CC 80252BEC 34420020 */ ori $v0, $v0, 0x20 .L80252BF0: /* 1814D0 80252BF0 8E220000 */ lw $v0, ($s1) /* 1814D4 80252BF4 00431024 */ and $v0, $v0, $v1 /* 1814D8 80252BF8 2403FFDF */ addiu $v1, $zero, -0x21 .L80252BFC: /* 1814DC 80252BFC 00431024 */ and $v0, $v0, $v1 .L80252C00: /* 1814E0 80252C00 AE220000 */ sw $v0, ($s1) /* 1814E4 80252C04 32020040 */ andi $v0, $s0, 0x40 /* 1814E8 80252C08 10400007 */ beqz $v0, .L80252C28 /* 1814EC 80252C0C 2404FFBF */ addiu $a0, $zero, -0x41 /* 1814F0 80252C10 3C03800E */ lui $v1, 0x800e /* 1814F4 80252C14 2463C070 */ addiu $v1, $v1, -0x3f90 /* 1814F8 80252C18 8C620000 */ lw $v0, ($v1) /* 1814FC 80252C1C 34420040 */ ori $v0, $v0, 0x40 /* 181500 80252C20 08094B0F */ j .L80252C3C /* 181504 80252C24 AC620000 */ sw $v0, ($v1) .L80252C28: /* 181508 80252C28 3C02800E */ lui $v0, 0x800e /* 18150C 80252C2C 2442C070 */ addiu $v0, $v0, -0x3f90 /* 181510 80252C30 8C430000 */ lw $v1, ($v0) /* 181514 80252C34 00641824 */ and $v1, $v1, $a0 /* 181518 80252C38 AC430000 */ sw $v1, ($v0) .L80252C3C: /* 18151C 80252C3C 32020200 */ andi $v0, $s0, 0x200 /* 181520 80252C40 10400007 */ beqz $v0, .L80252C60 /* 181524 80252C44 2404FDFF */ addiu $a0, $zero, -0x201 /* 181528 80252C48 3C03800E */ lui $v1, 0x800e /* 18152C 80252C4C 2463C070 */ addiu $v1, $v1, -0x3f90 /* 181530 80252C50 8C620000 */ lw $v0, ($v1) /* 181534 80252C54 34420200 */ ori $v0, $v0, 0x200 /* 181538 80252C58 08094B1D */ j .L80252C74 /* 18153C 80252C5C AC620000 */ sw $v0, ($v1) .L80252C60: /* 181540 80252C60 3C02800E */ lui $v0, 0x800e /* 181544 80252C64 2442C070 */ addiu $v0, $v0, -0x3f90 /* 181548 80252C68 8C430000 */ lw $v1, ($v0) /* 18154C 80252C6C 00641824 */ and $v1, $v1, $a0 /* 181550 80252C70 AC430000 */ sw $v1, ($v0) .L80252C74: /* 181554 80252C74 32020080 */ andi $v0, $s0, 0x80 /* 181558 80252C78 10400007 */ beqz $v0, .L80252C98 /* 18155C 80252C7C 2404FF7F */ addiu $a0, $zero, -0x81 /* 181560 80252C80 3C03800E */ lui $v1, 0x800e /* 181564 80252C84 2463C070 */ addiu $v1, $v1, -0x3f90 /* 181568 80252C88 8C620000 */ lw $v0, ($v1) /* 18156C 80252C8C 34420080 */ ori $v0, $v0, 0x80 /* 181570 80252C90 08094B2B */ j .L80252CAC /* 181574 80252C94 AC620000 */ sw $v0, ($v1) .L80252C98: /* 181578 80252C98 3C02800E */ lui $v0, 0x800e /* 18157C 80252C9C 2442C070 */ addiu $v0, $v0, -0x3f90 /* 181580 80252CA0 8C430000 */ lw $v1, ($v0) /* 181584 80252CA4 00641824 */ and $v1, $v1, $a0 /* 181588 80252CA8 AC430000 */ sw $v1, ($v0) .L80252CAC: /* 18158C 80252CAC 0C09A75B */ jal get_actor /* 181590 80252CB0 8E440148 */ lw $a0, 0x148($s2) /* 181594 80252CB4 94430428 */ lhu $v1, 0x428($v0) /* 181598 80252CB8 A62301A0 */ sh $v1, 0x1a0($s1) /* 18159C 80252CBC 92230193 */ lbu $v1, 0x193($s1) /* 1815A0 80252CC0 90420426 */ lbu $v0, 0x426($v0) /* 1815A4 80252CC4 A2230194 */ sb $v1, 0x194($s1) /* 1815A8 80252CC8 306300FF */ andi $v1, $v1, 0xff /* 1815AC 80252CCC A22201A2 */ sb $v0, 0x1a2($s1) /* 1815B0 80252CD0 240200FF */ addiu $v0, $zero, 0xff /* 1815B4 80252CD4 50620001 */ beql $v1, $v0, .L80252CDC /* 1815B8 80252CD8 A2200194 */ sb $zero, 0x194($s1) .L80252CDC: /* 1815BC 80252CDC 8E220190 */ lw $v0, 0x190($s1) /* 1815C0 80252CE0 30420F00 */ andi $v0, $v0, 0xf00 /* 1815C4 80252CE4 00021203 */ sra $v0, $v0, 8 /* 1815C8 80252CE8 0C0945BA */ jal calc_item_damage_enemy /* 1815CC 80252CEC A2220195 */ sb $v0, 0x195($s1) /* 1815D0 80252CF0 0440000B */ bltz $v0, .L80252D20 /* 1815D4 80252CF4 0240202D */ daddu $a0, $s2, $zero /* 1815D8 80252CF8 0260282D */ daddu $a1, $s3, $zero /* 1815DC 80252CFC 0C0B2026 */ jal set_variable /* 1815E0 80252D00 0040302D */ daddu $a2, $v0, $zero /* 1815E4 80252D04 0C0B1069 */ jal does_script_exist_by_ref /* 1815E8 80252D08 0240202D */ daddu $a0, $s2, $zero /* 1815EC 80252D0C 0040182D */ daddu $v1, $v0, $zero /* 1815F0 80252D10 10600004 */ beqz $v1, .L80252D24 /* 1815F4 80252D14 240200FF */ addiu $v0, $zero, 0xff /* 1815F8 80252D18 08094B49 */ j .L80252D24 /* 1815FC 80252D1C 24020002 */ addiu $v0, $zero, 2 .L80252D20: /* 181600 80252D20 240200FF */ addiu $v0, $zero, 0xff .L80252D24: .L80252D24: /* 181604 80252D24 8FBF0020 */ lw $ra, 0x20($sp) /* 181608 80252D28 8FB3001C */ lw $s3, 0x1c($sp) /* 18160C 80252D2C 8FB20018 */ lw $s2, 0x18($sp) /* 181610 80252D30 8FB10014 */ lw $s1, 0x14($sp) /* 181614 80252D34 8FB00010 */ lw $s0, 0x10($sp) /* 181618 80252D38 03E00008 */ jr $ra /* 18161C 80252D3C 27BD0028 */ addiu $sp, $sp, 0x28