donut-decomp/asm/libnw4r_g3d/g3d_light.s

881 lines
41 KiB
ArmAsm

.include "macros.inc"
.section .text, "ax" # 0x80006A00 - 0x80406260 ; 0x003FF860
.global __as__Q34nw4r3g3d8LightObjFRCQ34nw4r3g3d8LightObj
__as__Q34nw4r3g3d8LightObjFRCQ34nw4r3g3d8LightObj:
/* 800F1900 000ED740 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1904 000ED744 7C 08 02 A6 */ mflr r0
/* 800F1908 000ED748 7C 03 20 40 */ cmplw r3, r4
/* 800F190C 000ED74C 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1910 000ED750 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F1914 000ED754 7C 7F 1B 78 */ mr r31, r3
/* 800F1918 000ED758 41 82 00 1C */ beq lbl_800F1934
/* 800F191C 000ED75C 80 04 00 00 */ lwz r0, 0x0(r4)
/* 800F1920 000ED760 38 A0 00 40 */ li r5, 0x40
/* 800F1924 000ED764 90 03 00 00 */ stw r0, 0x0(r3)
/* 800F1928 000ED768 38 84 00 04 */ addi r4, r4, 0x4
/* 800F192C 000ED76C 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1930 000ED770 4B FE AE A1 */ bl Copy32ByteBlocks__Q34nw4r3g3d6detailFPvPCvUl
.global lbl_800F1934
lbl_800F1934:
/* 800F1934 000ED774 7F E3 FB 78 */ mr r3, r31
/* 800F1938 000ED778 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F193C 000ED77C 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1940 000ED780 7C 08 03 A6 */ mtlr r0
/* 800F1944 000ED784 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1948 000ED788 4E 80 00 20 */ blr
/* 800F194C 000ED78C 00 00 00 00 */ .4byte 0x00000000
.global Clear__Q34nw4r3g3d8LightObjFv
Clear__Q34nw4r3g3d8LightObjFv:
/* 800F1950 000ED790 38 00 00 00 */ li r0, 0x0
/* 800F1954 000ED794 90 03 00 00 */ stw r0, 0x0(r3)
/* 800F1958 000ED798 38 80 00 40 */ li r4, 0x40
/* 800F195C 000ED79C 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1960 000ED7A0 4B FE AF 50 */ b ZeroMemory32ByteBlocks__Q34nw4r3g3d6detailFPvUl
/* 800F1964 000ED7A4 00 00 00 00 */ .4byte 0x00000000
/* 800F1968 000ED7A8 00 00 00 00 */ .4byte 0x00000000
/* 800F196C 000ED7AC 00 00 00 00 */ .4byte 0x00000000
.global InitLightColor__Q34nw4r3g3d8LightObjF8_GXColor
InitLightColor__Q34nw4r3g3d8LightObjF8_GXColor:
/* 800F1970 000ED7B0 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1974 000ED7B4 7C 08 02 A6 */ mflr r0
/* 800F1978 000ED7B8 38 63 00 04 */ addi r3, r3, 0x4
/* 800F197C 000ED7BC 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1980 000ED7C0 80 04 00 00 */ lwz r0, 0x0(r4)
/* 800F1984 000ED7C4 38 81 00 08 */ addi r4, r1, 0x8
/* 800F1988 000ED7C8 90 01 00 08 */ stw r0, 0x8(r1)
/* 800F198C 000ED7CC 4B F4 49 05 */ bl GXInitLightColor
/* 800F1990 000ED7D0 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1994 000ED7D4 7C 08 03 A6 */ mtlr r0
/* 800F1998 000ED7D8 38 21 00 10 */ addi r1, r1, 0x10
/* 800F199C 000ED7DC 4E 80 00 20 */ blr
.global InitLightPos__Q34nw4r3g3d8LightObjFfff
InitLightPos__Q34nw4r3g3d8LightObjFfff:
/* 800F19A0 000ED7E0 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F19A4 000ED7E4 7C 08 02 A6 */ mflr r0
/* 800F19A8 000ED7E8 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F19AC 000ED7EC 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F19B0 000ED7F0 7C 7F 1B 78 */ mr r31, r3
/* 800F19B4 000ED7F4 38 63 00 04 */ addi r3, r3, 0x4
/* 800F19B8 000ED7F8 4B F4 47 49 */ bl GXInitLightPos
/* 800F19BC 000ED7FC 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F19C0 000ED800 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F19C4 000ED804 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F19C8 000ED808 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F19CC 000ED80C 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F19D0 000ED810 7C 08 03 A6 */ mtlr r0
/* 800F19D4 000ED814 38 21 00 10 */ addi r1, r1, 0x10
/* 800F19D8 000ED818 4E 80 00 20 */ blr
/* 800F19DC 000ED81C 00 00 00 00 */ .4byte 0x00000000
.global InitLightDir__Q34nw4r3g3d8LightObjFfff
InitLightDir__Q34nw4r3g3d8LightObjFfff:
/* 800F19E0 000ED820 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F19E4 000ED824 7C 08 02 A6 */ mflr r0
/* 800F19E8 000ED828 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F19EC 000ED82C 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F19F0 000ED830 7C 7F 1B 78 */ mr r31, r3
/* 800F19F4 000ED834 38 63 00 04 */ addi r3, r3, 0x4
/* 800F19F8 000ED838 4B F4 47 39 */ bl GXInitLightDir
/* 800F19FC 000ED83C 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F1A00 000ED840 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1A04 000ED844 60 00 00 01 */ ori r0, r0, 0x1
/* 800F1A08 000ED848 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F1A0C 000ED84C 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F1A10 000ED850 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1A14 000ED854 7C 08 03 A6 */ mtlr r0
/* 800F1A18 000ED858 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1A1C 000ED85C 4E 80 00 20 */ blr
.global InitLightSpot__Q34nw4r3g3d8LightObjFf9_GXSpotFn
InitLightSpot__Q34nw4r3g3d8LightObjFf9_GXSpotFn:
/* 800F1A20 000ED860 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1A24 000ED864 7C 08 02 A6 */ mflr r0
/* 800F1A28 000ED868 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1A2C 000ED86C 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F1A30 000ED870 7C 7F 1B 78 */ mr r31, r3
/* 800F1A34 000ED874 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1A38 000ED878 4B F4 44 59 */ bl GXInitLightSpot
/* 800F1A3C 000ED87C 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F1A40 000ED880 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1A44 000ED884 60 00 00 01 */ ori r0, r0, 0x1
/* 800F1A48 000ED888 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F1A4C 000ED88C 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F1A50 000ED890 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1A54 000ED894 7C 08 03 A6 */ mtlr r0
/* 800F1A58 000ED898 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1A5C 000ED89C 4E 80 00 20 */ blr
.global InitLightAttnA__Q34nw4r3g3d8LightObjFfff
InitLightAttnA__Q34nw4r3g3d8LightObjFfff:
/* 800F1A60 000ED8A0 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1A64 000ED8A4 7C 08 02 A6 */ mflr r0
/* 800F1A68 000ED8A8 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1A6C 000ED8AC 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F1A70 000ED8B0 7C 7F 1B 78 */ mr r31, r3
/* 800F1A74 000ED8B4 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1A78 000ED8B8 4B F4 43 F9 */ bl GXInitLightAttnA
/* 800F1A7C 000ED8BC 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F1A80 000ED8C0 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1A84 000ED8C4 60 00 00 01 */ ori r0, r0, 0x1
/* 800F1A88 000ED8C8 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F1A8C 000ED8CC 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F1A90 000ED8D0 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1A94 000ED8D4 7C 08 03 A6 */ mtlr r0
/* 800F1A98 000ED8D8 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1A9C 000ED8DC 4E 80 00 20 */ blr
.global InitLightDistAttn__Q34nw4r3g3d8LightObjFff13_GXDistAttnFn
InitLightDistAttn__Q34nw4r3g3d8LightObjFff13_GXDistAttnFn:
/* 800F1AA0 000ED8E0 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1AA4 000ED8E4 7C 08 02 A6 */ mflr r0
/* 800F1AA8 000ED8E8 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1AAC 000ED8EC 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F1AB0 000ED8F0 7C 7F 1B 78 */ mr r31, r3
/* 800F1AB4 000ED8F4 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1AB8 000ED8F8 4B F4 45 79 */ bl GXInitLightDistAttn
/* 800F1ABC 000ED8FC 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F1AC0 000ED900 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1AC4 000ED904 60 00 00 01 */ ori r0, r0, 0x1
/* 800F1AC8 000ED908 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F1ACC 000ED90C 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F1AD0 000ED910 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1AD4 000ED914 7C 08 03 A6 */ mtlr r0
/* 800F1AD8 000ED918 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1ADC 000ED91C 4E 80 00 20 */ blr
.global InitLightAttnK__Q34nw4r3g3d8LightObjFfff
InitLightAttnK__Q34nw4r3g3d8LightObjFfff:
/* 800F1AE0 000ED920 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1AE4 000ED924 7C 08 02 A6 */ mflr r0
/* 800F1AE8 000ED928 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1AEC 000ED92C 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F1AF0 000ED930 7C 7F 1B 78 */ mr r31, r3
/* 800F1AF4 000ED934 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1AF8 000ED938 4B F4 43 89 */ bl GXInitLightAttnK
/* 800F1AFC 000ED93C 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F1B00 000ED940 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1B04 000ED944 60 00 00 01 */ ori r0, r0, 0x1
/* 800F1B08 000ED948 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F1B0C 000ED94C 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F1B10 000ED950 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1B14 000ED954 7C 08 03 A6 */ mtlr r0
/* 800F1B18 000ED958 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1B1C 000ED95C 4E 80 00 20 */ blr
.global InitSpecularDir__Q34nw4r3g3d8LightObjFfff
InitSpecularDir__Q34nw4r3g3d8LightObjFfff:
/* 800F1B20 000ED960 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1B24 000ED964 7C 08 02 A6 */ mflr r0
/* 800F1B28 000ED968 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1B2C 000ED96C 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F1B30 000ED970 7C 7F 1B 78 */ mr r31, r3
/* 800F1B34 000ED974 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1B38 000ED978 4B F4 45 F9 */ bl GXInitLightDir
/* 800F1B3C 000ED97C 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F1B40 000ED980 54 00 00 3C */ clrrwi r0, r0, 1
/* 800F1B44 000ED984 60 00 00 0A */ ori r0, r0, 0xa
/* 800F1B48 000ED988 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F1B4C 000ED98C 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F1B50 000ED990 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1B54 000ED994 7C 08 03 A6 */ mtlr r0
/* 800F1B58 000ED998 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1B5C 000ED99C 4E 80 00 20 */ blr
.global InitLightShininess__Q34nw4r3g3d8LightObjFf
InitLightShininess__Q34nw4r3g3d8LightObjFf:
/* 800F1B60 000ED9A0 94 21 FF F0 */ stwu r1, -0x10(r1)
/* 800F1B64 000ED9A4 7C 08 02 A6 */ mflr r0
/* 800F1B68 000ED9A8 FC 80 08 90 */ fmr f4, f1
/* 800F1B6C 000ED9AC C0 02 91 68 */ lfs f0, "@12222"@sda21(r2)
/* 800F1B70 000ED9B0 C0 22 91 60 */ lfs f1, "@12220"@sda21(r2)
/* 800F1B74 000ED9B4 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1B78 000ED9B8 EC 84 00 32 */ fmuls f4, f4, f0
/* 800F1B7C 000ED9BC C0 62 91 64 */ lfs f3, "@12221"@sda21(r2)
/* 800F1B80 000ED9C0 93 E1 00 0C */ stw r31, 0xc(r1)
/* 800F1B84 000ED9C4 7C 7F 1B 78 */ mr r31, r3
/* 800F1B88 000ED9C8 FC 40 08 90 */ fmr f2, f1
/* 800F1B8C 000ED9CC 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1B90 000ED9D0 FC A0 08 90 */ fmr f5, f1
/* 800F1B94 000ED9D4 EC C3 20 28 */ fsubs f6, f3, f4
/* 800F1B98 000ED9D8 4B F4 42 B9 */ bl GXInitLightAttn
/* 800F1B9C 000ED9DC 80 1F 00 00 */ lwz r0, 0x0(r31)
/* 800F1BA0 000ED9E0 54 00 00 3C */ clrrwi r0, r0, 1
/* 800F1BA4 000ED9E4 60 00 00 02 */ ori r0, r0, 0x2
/* 800F1BA8 000ED9E8 90 1F 00 00 */ stw r0, 0x0(r31)
/* 800F1BAC 000ED9EC 83 E1 00 0C */ lwz r31, 0xc(r1)
/* 800F1BB0 000ED9F0 80 01 00 14 */ lwz r0, 0x14(r1)
/* 800F1BB4 000ED9F4 7C 08 03 A6 */ mtlr r0
/* 800F1BB8 000ED9F8 38 21 00 10 */ addi r1, r1, 0x10
/* 800F1BBC 000ED9FC 4E 80 00 20 */ blr
.global GetLightPos__Q34nw4r3g3d8LightObjCFPQ34nw4r4math4VEC3
GetLightPos__Q34nw4r3g3d8LightObjCFPQ34nw4r4math4VEC3:
/* 800F1BC0 000EDA00 2C 04 00 00 */ cmpwi r4, 0x0
/* 800F1BC4 000EDA04 4D 82 00 20 */ beqlr
/* 800F1BC8 000EDA08 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1BCC 000EDA0C 38 A4 00 04 */ addi r5, r4, 0x4
/* 800F1BD0 000EDA10 38 C4 00 08 */ addi r6, r4, 0x8
/* 800F1BD4 000EDA14 4B F4 45 3C */ b GXGetLightPos
/* 800F1BD8 000EDA18 4E 80 00 20 */ blr
/* 800F1BDC 000EDA1C 00 00 00 00 */ .4byte 0x00000000
.global GetLightDir__Q34nw4r3g3d8LightObjCFPQ34nw4r4math4VEC3
GetLightDir__Q34nw4r3g3d8LightObjCFPQ34nw4r4math4VEC3:
/* 800F1BE0 000EDA20 2C 04 00 00 */ cmpwi r4, 0x0
/* 800F1BE4 000EDA24 4D 82 00 20 */ beqlr
/* 800F1BE8 000EDA28 38 63 00 04 */ addi r3, r3, 0x4
/* 800F1BEC 000EDA2C 38 A4 00 04 */ addi r5, r4, 0x4
/* 800F1BF0 000EDA30 38 C4 00 08 */ addi r6, r4, 0x8
/* 800F1BF4 000EDA34 4B F4 45 5C */ b GXGetLightDir
/* 800F1BF8 000EDA38 4E 80 00 20 */ blr
/* 800F1BFC 000EDA3C 00 00 00 00 */ .4byte 0x00000000
.global __ct__Q34nw4r3g3d12LightSettingFPQ34nw4r3g3d8LightObjPQ34nw4r3g3d11AmbLightObjUlPQ34nw4r3g3d12LightSetDataUl
__ct__Q34nw4r3g3d12LightSettingFPQ34nw4r3g3d8LightObjPQ34nw4r3g3d11AmbLightObjUlPQ34nw4r3g3d12LightSetDataUl:
/* 800F1C00 000EDA40 94 21 FE B0 */ stwu r1, -0x150(r1)
/* 800F1C04 000EDA44 7C 08 02 A6 */ mflr r0
/* 800F1C08 000EDA48 90 01 01 54 */ stw r0, 0x154(r1)
/* 800F1C0C 000EDA4C 39 61 01 50 */ addi r11, r1, 0x150
/* 800F1C10 000EDA50 4B F1 57 1D */ bl lbl_8000732C
/* 800F1C14 000EDA54 B0 C3 00 00 */ sth r6, 0x0(r3)
/* 800F1C18 000EDA58 7C 7F 1B 78 */ mr r31, r3
/* 800F1C1C 000EDA5C 39 40 00 00 */ li r10, 0x0
/* 800F1C20 000EDA60 39 20 00 00 */ li r9, 0x0
/* 800F1C24 000EDA64 B1 03 00 02 */ sth r8, 0x2(r3)
/* 800F1C28 000EDA68 38 C0 FF FF */ li r6, -0x1
/* 800F1C2C 000EDA6C 90 83 00 04 */ stw r4, 0x4(r3)
/* 800F1C30 000EDA70 90 A3 00 08 */ stw r5, 0x8(r3)
/* 800F1C34 000EDA74 90 E3 00 0C */ stw r7, 0xc(r3)
/* 800F1C38 000EDA78 48 00 00 38 */ b lbl_800F1C70
.global lbl_800F1C3C
lbl_800F1C3C:
/* 800F1C3C 000EDA7C 80 03 00 0C */ lwz r0, 0xc(r3)
/* 800F1C40 000EDA80 39 4A 00 01 */ addi r10, r10, 0x1
/* 800F1C44 000EDA84 7C 80 4A 14 */ add r4, r0, r9
/* 800F1C48 000EDA88 98 C4 00 08 */ stb r6, 0x8(r4)
/* 800F1C4C 000EDA8C 7C C9 01 AE */ stbx r6, r9, r0
/* 800F1C50 000EDA90 39 29 00 0C */ addi r9, r9, 0xc
/* 800F1C54 000EDA94 98 C4 00 01 */ stb r6, 0x1(r4)
/* 800F1C58 000EDA98 98 C4 00 02 */ stb r6, 0x2(r4)
/* 800F1C5C 000EDA9C 98 C4 00 03 */ stb r6, 0x3(r4)
/* 800F1C60 000EDAA0 98 C4 00 04 */ stb r6, 0x4(r4)
/* 800F1C64 000EDAA4 98 C4 00 05 */ stb r6, 0x5(r4)
/* 800F1C68 000EDAA8 98 C4 00 06 */ stb r6, 0x6(r4)
/* 800F1C6C 000EDAAC 98 C4 00 07 */ stb r6, 0x7(r4)
.global lbl_800F1C70
lbl_800F1C70:
/* 800F1C70 000EDAB0 A0 03 00 02 */ lhz r0, 0x2(r3)
/* 800F1C74 000EDAB4 7C 0A 00 40 */ cmplw r10, r0
/* 800F1C78 000EDAB8 41 80 FF C4 */ blt lbl_800F1C3C
/* 800F1C7C 000EDABC 80 83 00 0C */ lwz r4, 0xc(r3)
/* 800F1C80 000EDAC0 3B A0 00 00 */ li r29, 0x0
/* 800F1C84 000EDAC4 80 02 91 70 */ lwz r0, "@11841"@sda21(r2)
/* 800F1C88 000EDAC8 38 E0 00 02 */ li r7, 0x2
/* 800F1C8C 000EDACC 9B A4 00 00 */ stb r29, 0x0(r4)
/* 800F1C90 000EDAD0 38 C0 FF FF */ li r6, -0x1
/* 800F1C94 000EDAD4 38 80 00 40 */ li r4, 0x40
/* 800F1C98 000EDAD8 80 A3 00 0C */ lwz r5, 0xc(r3)
/* 800F1C9C 000EDADC 90 01 00 14 */ stw r0, 0x14(r1)
/* 800F1CA0 000EDAE0 98 E5 00 01 */ stb r7, 0x1(r5)
/* 800F1CA4 000EDAE4 80 A3 00 0C */ lwz r5, 0xc(r3)
/* 800F1CA8 000EDAE8 38 61 00 E8 */ addi r3, r1, 0xe8
/* 800F1CAC 000EDAEC 98 C5 00 08 */ stb r6, 0x8(r5)
/* 800F1CB0 000EDAF0 93 A1 00 A0 */ stw r29, 0xa0(r1)
/* 800F1CB4 000EDAF4 93 A1 00 5C */ stw r29, 0x5c(r1)
/* 800F1CB8 000EDAF8 93 A1 00 18 */ stw r29, 0x18(r1)
/* 800F1CBC 000EDAFC 93 A1 00 E4 */ stw r29, 0xe4(r1)
/* 800F1CC0 000EDB00 4B FE AB F1 */ bl ZeroMemory32ByteBlocks__Q34nw4r3g3d6detailFPvUl
/* 800F1CC4 000EDB04 93 A1 00 A0 */ stw r29, 0xa0(r1)
/* 800F1CC8 000EDB08 38 61 00 A4 */ addi r3, r1, 0xa4
/* 800F1CCC 000EDB0C 38 80 00 40 */ li r4, 0x40
/* 800F1CD0 000EDB10 4B FE AB E1 */ bl ZeroMemory32ByteBlocks__Q34nw4r3g3d6detailFPvUl
/* 800F1CD4 000EDB14 93 A1 00 5C */ stw r29, 0x5c(r1)
/* 800F1CD8 000EDB18 38 61 00 60 */ addi r3, r1, 0x60
/* 800F1CDC 000EDB1C 38 80 00 40 */ li r4, 0x40
/* 800F1CE0 000EDB20 4B FE AB D1 */ bl ZeroMemory32ByteBlocks__Q34nw4r3g3d6detailFPvUl
/* 800F1CE4 000EDB24 93 A1 00 18 */ stw r29, 0x18(r1)
/* 800F1CE8 000EDB28 38 61 00 1C */ addi r3, r1, 0x1c
/* 800F1CEC 000EDB2C 38 80 00 40 */ li r4, 0x40
/* 800F1CF0 000EDB30 4B FE AB C1 */ bl ZeroMemory32ByteBlocks__Q34nw4r3g3d6detailFPvUl
/* 800F1CF4 000EDB34 83 A2 91 6C */ lwz r29, "@11839"@sda21(r2)
/* 800F1CF8 000EDB38 38 61 00 E8 */ addi r3, r1, 0xe8
/* 800F1CFC 000EDB3C 93 A1 00 10 */ stw r29, 0x10(r1)
/* 800F1D00 000EDB40 38 81 00 10 */ addi r4, r1, 0x10
/* 800F1D04 000EDB44 4B F4 45 8D */ bl GXInitLightColor
/* 800F1D08 000EDB48 C0 22 91 74 */ lfs f1, "@12371"@sda21(r2)
/* 800F1D0C 000EDB4C 38 61 00 E8 */ addi r3, r1, 0xe8
/* 800F1D10 000EDB50 FC 40 08 90 */ fmr f2, f1
/* 800F1D14 000EDB54 FC 60 08 90 */ fmr f3, f1
/* 800F1D18 000EDB58 4B F4 43 E9 */ bl GXInitLightPos
/* 800F1D1C 000EDB5C C0 22 91 60 */ lfs f1, "@12220"@sda21(r2)
/* 800F1D20 000EDB60 38 61 00 E8 */ addi r3, r1, 0xe8
/* 800F1D24 000EDB64 80 01 00 E4 */ lwz r0, 0xe4(r1)
/* 800F1D28 000EDB68 FC 60 08 90 */ fmr f3, f1
/* 800F1D2C 000EDB6C C0 42 91 78 */ lfs f2, "@12372"@sda21(r2)
/* 800F1D30 000EDB70 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1D34 000EDB74 90 01 00 E4 */ stw r0, 0xe4(r1)
/* 800F1D38 000EDB78 4B F4 43 F9 */ bl GXInitLightDir
/* 800F1D3C 000EDB7C 80 01 00 E4 */ lwz r0, 0xe4(r1)
/* 800F1D40 000EDB80 38 61 00 E8 */ addi r3, r1, 0xe8
/* 800F1D44 000EDB84 C0 22 91 7C */ lfs f1, "@12373"@sda21(r2)
/* 800F1D48 000EDB88 38 80 00 00 */ li r4, 0x0
/* 800F1D4C 000EDB8C 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1D50 000EDB90 60 00 00 01 */ ori r0, r0, 0x1
/* 800F1D54 000EDB94 90 01 00 E4 */ stw r0, 0xe4(r1)
/* 800F1D58 000EDB98 4B F4 41 39 */ bl GXInitLightSpot
/* 800F1D5C 000EDB9C 80 01 00 E4 */ lwz r0, 0xe4(r1)
/* 800F1D60 000EDBA0 38 61 00 E8 */ addi r3, r1, 0xe8
/* 800F1D64 000EDBA4 C0 22 91 80 */ lfs f1, "@12374"@sda21(r2)
/* 800F1D68 000EDBA8 38 80 00 00 */ li r4, 0x0
/* 800F1D6C 000EDBAC 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1D70 000EDBB0 C0 42 91 68 */ lfs f2, "@12222"@sda21(r2)
/* 800F1D74 000EDBB4 60 00 00 01 */ ori r0, r0, 0x1
/* 800F1D78 000EDBB8 90 01 00 E4 */ stw r0, 0xe4(r1)
/* 800F1D7C 000EDBBC 4B F4 42 B5 */ bl GXInitLightDistAttn
/* 800F1D80 000EDBC0 80 01 00 E4 */ lwz r0, 0xe4(r1)
/* 800F1D84 000EDBC4 38 61 00 A4 */ addi r3, r1, 0xa4
/* 800F1D88 000EDBC8 93 A1 00 0C */ stw r29, 0xc(r1)
/* 800F1D8C 000EDBCC 38 81 00 0C */ addi r4, r1, 0xc
/* 800F1D90 000EDBD0 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1D94 000EDBD4 60 00 00 05 */ ori r0, r0, 0x5
/* 800F1D98 000EDBD8 90 01 00 E4 */ stw r0, 0xe4(r1)
/* 800F1D9C 000EDBDC 4B F4 44 F5 */ bl GXInitLightColor
/* 800F1DA0 000EDBE0 C0 22 91 74 */ lfs f1, "@12371"@sda21(r2)
/* 800F1DA4 000EDBE4 38 61 00 A4 */ addi r3, r1, 0xa4
/* 800F1DA8 000EDBE8 FC 40 08 90 */ fmr f2, f1
/* 800F1DAC 000EDBEC FC 60 08 90 */ fmr f3, f1
/* 800F1DB0 000EDBF0 4B F4 43 51 */ bl GXInitLightPos
/* 800F1DB4 000EDBF4 80 01 00 A0 */ lwz r0, 0xa0(r1)
/* 800F1DB8 000EDBF8 38 61 00 60 */ addi r3, r1, 0x60
/* 800F1DBC 000EDBFC 93 A1 00 08 */ stw r29, 0x8(r1)
/* 800F1DC0 000EDC00 38 81 00 08 */ addi r4, r1, 0x8
/* 800F1DC4 000EDC04 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1DC8 000EDC08 60 00 00 04 */ ori r0, r0, 0x4
/* 800F1DCC 000EDC0C 90 01 00 A0 */ stw r0, 0xa0(r1)
/* 800F1DD0 000EDC10 4B F4 44 C1 */ bl GXInitLightColor
/* 800F1DD4 000EDC14 C0 22 91 74 */ lfs f1, "@12371"@sda21(r2)
/* 800F1DD8 000EDC18 38 61 00 60 */ addi r3, r1, 0x60
/* 800F1DDC 000EDC1C FC 40 08 90 */ fmr f2, f1
/* 800F1DE0 000EDC20 FC 60 08 90 */ fmr f3, f1
/* 800F1DE4 000EDC24 4B F4 43 1D */ bl GXInitLightPos
/* 800F1DE8 000EDC28 C0 22 91 60 */ lfs f1, "@12220"@sda21(r2)
/* 800F1DEC 000EDC2C 38 61 00 60 */ addi r3, r1, 0x60
/* 800F1DF0 000EDC30 80 01 00 5C */ lwz r0, 0x5c(r1)
/* 800F1DF4 000EDC34 FC 60 08 90 */ fmr f3, f1
/* 800F1DF8 000EDC38 C0 42 91 78 */ lfs f2, "@12372"@sda21(r2)
/* 800F1DFC 000EDC3C 54 00 07 FA */ rlwinm r0, r0, 0, 31, 29
/* 800F1E00 000EDC40 90 01 00 5C */ stw r0, 0x5c(r1)
/* 800F1E04 000EDC44 4B F4 43 2D */ bl GXInitLightDir
/* 800F1E08 000EDC48 C0 22 91 60 */ lfs f1, "@12220"@sda21(r2)
/* 800F1E0C 000EDC4C 38 61 00 60 */ addi r3, r1, 0x60
/* 800F1E10 000EDC50 80 01 00 5C */ lwz r0, 0x5c(r1)
/* 800F1E14 000EDC54 FC 40 08 90 */ fmr f2, f1
/* 800F1E18 000EDC58 C0 62 91 64 */ lfs f3, "@12221"@sda21(r2)
/* 800F1E1C 000EDC5C 54 00 00 3C */ clrrwi r0, r0, 1
/* 800F1E20 000EDC60 FC A0 08 90 */ fmr f5, f1
/* 800F1E24 000EDC64 60 00 00 0A */ ori r0, r0, 0xa
/* 800F1E28 000EDC68 90 01 00 5C */ stw r0, 0x5c(r1)
/* 800F1E2C 000EDC6C C0 82 91 84 */ lfs f4, "@12375"@sda21(r2)
/* 800F1E30 000EDC70 C0 C2 91 88 */ lfs f6, "@12376_8055F108"@sda21(r2)
/* 800F1E34 000EDC74 4B F4 40 1D */ bl GXInitLightAttn
/* 800F1E38 000EDC78 80 61 00 5C */ lwz r3, 0x5c(r1)
/* 800F1E3C 000EDC7C 80 01 00 18 */ lwz r0, 0x18(r1)
/* 800F1E40 000EDC80 54 63 00 3C */ clrrwi r3, r3, 1
/* 800F1E44 000EDC84 60 63 00 06 */ ori r3, r3, 0x6
/* 800F1E48 000EDC88 54 00 07 B8 */ rlwinm r0, r0, 0, 30, 28
/* 800F1E4C 000EDC8C 90 61 00 5C */ stw r3, 0x5c(r1)
/* 800F1E50 000EDC90 90 01 00 18 */ stw r0, 0x18(r1)
/* 800F1E54 000EDC94 A0 1F 00 00 */ lhz r0, 0x0(r31)
/* 800F1E58 000EDC98 2C 00 00 00 */ cmpwi r0, 0x0
/* 800F1E5C 000EDC9C 41 82 00 50 */ beq lbl_800F1EAC
/* 800F1E60 000EDCA0 80 9F 00 04 */ lwz r4, 0x4(r31)
/* 800F1E64 000EDCA4 38 01 00 E4 */ addi r0, r1, 0xe4
/* 800F1E68 000EDCA8 7C 04 00 40 */ cmplw r4, r0
/* 800F1E6C 000EDCAC 41 82 00 1C */ beq lbl_800F1E88
/* 800F1E70 000EDCB0 80 01 00 E4 */ lwz r0, 0xe4(r1)
/* 800F1E74 000EDCB4 38 64 00 04 */ addi r3, r4, 0x4
/* 800F1E78 000EDCB8 90 04 00 00 */ stw r0, 0x0(r4)
/* 800F1E7C 000EDCBC 38 81 00 E8 */ addi r4, r1, 0xe8
/* 800F1E80 000EDCC0 38 A0 00 40 */ li r5, 0x40
/* 800F1E84 000EDCC4 4B FE A9 4D */ bl Copy32ByteBlocks__Q34nw4r3g3d6detailFPvPCvUl
.global lbl_800F1E88
lbl_800F1E88:
/* 800F1E88 000EDCC8 80 7F 00 08 */ lwz r3, 0x8(r31)
/* 800F1E8C 000EDCCC 88 01 00 14 */ lbz r0, 0x14(r1)
/* 800F1E90 000EDCD0 98 03 00 00 */ stb r0, 0x0(r3)
/* 800F1E94 000EDCD4 88 01 00 15 */ lbz r0, 0x15(r1)
/* 800F1E98 000EDCD8 98 03 00 01 */ stb r0, 0x1(r3)
/* 800F1E9C 000EDCDC 88 01 00 16 */ lbz r0, 0x16(r1)
/* 800F1EA0 000EDCE0 98 03 00 02 */ stb r0, 0x2(r3)
/* 800F1EA4 000EDCE4 88 01 00 17 */ lbz r0, 0x17(r1)
/* 800F1EA8 000EDCE8 98 03 00 03 */ stb r0, 0x3(r3)
.global lbl_800F1EAC
lbl_800F1EAC:
/* 800F1EAC 000EDCEC A0 1F 00 00 */ lhz r0, 0x0(r31)
/* 800F1EB0 000EDCF0 28 00 00 01 */ cmplwi r0, 0x1
/* 800F1EB4 000EDCF4 40 81 00 54 */ ble lbl_800F1F08
/* 800F1EB8 000EDCF8 80 7F 00 04 */ lwz r3, 0x4(r31)
/* 800F1EBC 000EDCFC 38 01 00 A0 */ addi r0, r1, 0xa0
/* 800F1EC0 000EDD00 38 83 00 44 */ addi r4, r3, 0x44
/* 800F1EC4 000EDD04 7C 04 00 40 */ cmplw r4, r0
/* 800F1EC8 000EDD08 41 82 00 1C */ beq lbl_800F1EE4
/* 800F1ECC 000EDD0C 80 01 00 A0 */ lwz r0, 0xa0(r1)
/* 800F1ED0 000EDD10 38 64 00 04 */ addi r3, r4, 0x4
/* 800F1ED4 000EDD14 90 04 00 00 */ stw r0, 0x0(r4)
/* 800F1ED8 000EDD18 38 81 00 A4 */ addi r4, r1, 0xa4
/* 800F1EDC 000EDD1C 38 A0 00 40 */ li r5, 0x40
/* 800F1EE0 000EDD20 4B FE A8 F1 */ bl Copy32ByteBlocks__Q34nw4r3g3d6detailFPvPCvUl
.global lbl_800F1EE4
lbl_800F1EE4:
/* 800F1EE4 000EDD24 80 7F 00 08 */ lwz r3, 0x8(r31)
/* 800F1EE8 000EDD28 88 01 00 14 */ lbz r0, 0x14(r1)
/* 800F1EEC 000EDD2C 98 03 00 04 */ stb r0, 0x4(r3)
/* 800F1EF0 000EDD30 88 01 00 15 */ lbz r0, 0x15(r1)
/* 800F1EF4 000EDD34 98 03 00 05 */ stb r0, 0x5(r3)
/* 800F1EF8 000EDD38 88 01 00 16 */ lbz r0, 0x16(r1)
/* 800F1EFC 000EDD3C 98 03 00 06 */ stb r0, 0x6(r3)
/* 800F1F00 000EDD40 88 01 00 17 */ lbz r0, 0x17(r1)
/* 800F1F04 000EDD44 98 03 00 07 */ stb r0, 0x7(r3)
.global lbl_800F1F08
lbl_800F1F08:
/* 800F1F08 000EDD48 A0 1F 00 00 */ lhz r0, 0x0(r31)
/* 800F1F0C 000EDD4C 28 00 00 02 */ cmplwi r0, 0x2
/* 800F1F10 000EDD50 40 81 00 54 */ ble lbl_800F1F64
/* 800F1F14 000EDD54 80 7F 00 04 */ lwz r3, 0x4(r31)
/* 800F1F18 000EDD58 38 01 00 5C */ addi r0, r1, 0x5c
/* 800F1F1C 000EDD5C 38 83 00 88 */ addi r4, r3, 0x88
/* 800F1F20 000EDD60 7C 04 00 40 */ cmplw r4, r0
/* 800F1F24 000EDD64 41 82 00 1C */ beq lbl_800F1F40
/* 800F1F28 000EDD68 80 01 00 5C */ lwz r0, 0x5c(r1)
/* 800F1F2C 000EDD6C 38 64 00 04 */ addi r3, r4, 0x4
/* 800F1F30 000EDD70 90 04 00 00 */ stw r0, 0x0(r4)
/* 800F1F34 000EDD74 38 81 00 60 */ addi r4, r1, 0x60
/* 800F1F38 000EDD78 38 A0 00 40 */ li r5, 0x40
/* 800F1F3C 000EDD7C 4B FE A8 95 */ bl Copy32ByteBlocks__Q34nw4r3g3d6detailFPvPCvUl
.global lbl_800F1F40
lbl_800F1F40:
/* 800F1F40 000EDD80 80 7F 00 08 */ lwz r3, 0x8(r31)
/* 800F1F44 000EDD84 88 01 00 14 */ lbz r0, 0x14(r1)
/* 800F1F48 000EDD88 98 03 00 08 */ stb r0, 0x8(r3)
/* 800F1F4C 000EDD8C 88 01 00 15 */ lbz r0, 0x15(r1)
/* 800F1F50 000EDD90 98 03 00 09 */ stb r0, 0x9(r3)
/* 800F1F54 000EDD94 88 01 00 16 */ lbz r0, 0x16(r1)
/* 800F1F58 000EDD98 98 03 00 0A */ stb r0, 0xa(r3)
/* 800F1F5C 000EDD9C 88 01 00 17 */ lbz r0, 0x17(r1)
/* 800F1F60 000EDDA0 98 03 00 0B */ stb r0, 0xb(r3)
.global lbl_800F1F64
lbl_800F1F64:
/* 800F1F64 000EDDA4 8B 41 00 15 */ lbz r26, 0x15(r1)
/* 800F1F68 000EDDA8 3B A1 00 18 */ addi r29, r1, 0x18
/* 800F1F6C 000EDDAC 8B 21 00 16 */ lbz r25, 0x16(r1)
/* 800F1F70 000EDDB0 3A E0 00 03 */ li r23, 0x3
/* 800F1F74 000EDDB4 8B 01 00 17 */ lbz r24, 0x17(r1)
/* 800F1F78 000EDDB8 3B 80 00 CC */ li r28, 0xcc
/* 800F1F7C 000EDDBC 8B C1 00 14 */ lbz r30, 0x14(r1)
/* 800F1F80 000EDDC0 3B 60 00 0C */ li r27, 0xc
/* 800F1F84 000EDDC4 48 00 00 50 */ b lbl_800F1FD4
.global lbl_800F1F88
lbl_800F1F88:
/* 800F1F88 000EDDC8 80 1F 00 04 */ lwz r0, 0x4(r31)
/* 800F1F8C 000EDDCC 7C 80 E2 14 */ add r4, r0, r28
/* 800F1F90 000EDDD0 7C 04 E8 40 */ cmplw r4, r29
/* 800F1F94 000EDDD4 41 82 00 1C */ beq lbl_800F1FB0
/* 800F1F98 000EDDD8 80 01 00 18 */ lwz r0, 0x18(r1)
/* 800F1F9C 000EDDDC 38 64 00 04 */ addi r3, r4, 0x4
/* 800F1FA0 000EDDE0 90 04 00 00 */ stw r0, 0x0(r4)
/* 800F1FA4 000EDDE4 38 81 00 1C */ addi r4, r1, 0x1c
/* 800F1FA8 000EDDE8 38 A0 00 40 */ li r5, 0x40
/* 800F1FAC 000EDDEC 4B FE A8 25 */ bl Copy32ByteBlocks__Q34nw4r3g3d6detailFPvPCvUl
.global lbl_800F1FB0
lbl_800F1FB0:
/* 800F1FB0 000EDDF0 80 1F 00 08 */ lwz r0, 0x8(r31)
/* 800F1FB4 000EDDF4 3B 9C 00 44 */ addi r28, r28, 0x44
/* 800F1FB8 000EDDF8 3A F7 00 01 */ addi r23, r23, 0x1
/* 800F1FBC 000EDDFC 7F DB 01 AE */ stbx r30, r27, r0
/* 800F1FC0 000EDE00 7C 60 DA 14 */ add r3, r0, r27
/* 800F1FC4 000EDE04 3B 7B 00 04 */ addi r27, r27, 0x4
/* 800F1FC8 000EDE08 9B 43 00 01 */ stb r26, 0x1(r3)
/* 800F1FCC 000EDE0C 9B 23 00 02 */ stb r25, 0x2(r3)
/* 800F1FD0 000EDE10 9B 03 00 03 */ stb r24, 0x3(r3)
.global lbl_800F1FD4
lbl_800F1FD4:
/* 800F1FD4 000EDE14 A0 1F 00 00 */ lhz r0, 0x0(r31)
/* 800F1FD8 000EDE18 7C 17 00 40 */ cmplw r23, r0
/* 800F1FDC 000EDE1C 41 80 FF AC */ blt lbl_800F1F88
/* 800F1FE0 000EDE20 39 61 01 50 */ addi r11, r1, 0x150
/* 800F1FE4 000EDE24 7F E3 FB 78 */ mr r3, r31
/* 800F1FE8 000EDE28 4B F1 53 91 */ bl lbl_80007378
/* 800F1FEC 000EDE2C 80 01 01 54 */ lwz r0, 0x154(r1)
/* 800F1FF0 000EDE30 7C 08 03 A6 */ mtlr r0
/* 800F1FF4 000EDE34 38 21 01 50 */ addi r1, r1, 0x150
/* 800F1FF8 000EDE38 4E 80 00 20 */ blr
/* 800F1FFC 000EDE3C 00 00 00 00 */ .4byte 0x00000000
.global Import__Q34nw4r3g3d12LightSettingFRCQ34nw4r3g3d12LightSetting
Import__Q34nw4r3g3d12LightSettingFRCQ34nw4r3g3d12LightSetting:
/* 800F2000 000EDE40 94 21 FF E0 */ stwu r1, -0x20(r1)
/* 800F2004 000EDE44 7C 08 02 A6 */ mflr r0
/* 800F2008 000EDE48 90 01 00 24 */ stw r0, 0x24(r1)
/* 800F200C 000EDE4C 39 61 00 20 */ addi r11, r1, 0x20
/* 800F2010 000EDE50 4B F1 53 2D */ bl lbl_8000733C
/* 800F2014 000EDE54 A0 A3 00 00 */ lhz r5, 0x0(r3)
/* 800F2018 000EDE58 7C 7B 1B 78 */ mr r27, r3
/* 800F201C 000EDE5C A0 04 00 00 */ lhz r0, 0x0(r4)
/* 800F2020 000EDE60 7C 9C 23 78 */ mr r28, r4
/* 800F2024 000EDE64 7C 05 00 40 */ cmplw r5, r0
/* 800F2028 000EDE68 41 80 00 14 */ blt lbl_800F203C
/* 800F202C 000EDE6C A0 63 00 02 */ lhz r3, 0x2(r3)
/* 800F2030 000EDE70 A0 04 00 02 */ lhz r0, 0x2(r4)
/* 800F2034 000EDE74 7C 03 00 40 */ cmplw r3, r0
/* 800F2038 000EDE78 40 80 00 0C */ bge lbl_800F2044
.global lbl_800F203C
lbl_800F203C:
/* 800F203C 000EDE7C 38 60 00 00 */ li r3, 0x0
/* 800F2040 000EDE80 48 00 01 04 */ b lbl_800F2144
.global lbl_800F2044
lbl_800F2044:
/* 800F2044 000EDE84 3B A0 00 00 */ li r29, 0x0
/* 800F2048 000EDE88 3B E0 00 00 */ li r31, 0x0
/* 800F204C 000EDE8C 3B C0 00 00 */ li r30, 0x0
/* 800F2050 000EDE90 48 00 00 8C */ b lbl_800F20DC
.global lbl_800F2054
lbl_800F2054:
/* 800F2054 000EDE94 80 1C 00 04 */ lwz r0, 0x4(r28)
/* 800F2058 000EDE98 7C 7F 00 2E */ lwzx r3, r31, r0
/* 800F205C 000EDE9C 7C A0 FA 14 */ add r5, r0, r31
/* 800F2060 000EDEA0 54 60 07 7B */ rlwinm. r0, r3, 0, 29, 29
/* 800F2064 000EDEA4 41 82 00 2C */ beq lbl_800F2090
/* 800F2068 000EDEA8 80 1B 00 04 */ lwz r0, 0x4(r27)
/* 800F206C 000EDEAC 7C 80 FA 14 */ add r4, r0, r31
/* 800F2070 000EDEB0 7C 04 28 40 */ cmplw r4, r5
/* 800F2074 000EDEB4 41 82 00 2C */ beq lbl_800F20A0
/* 800F2078 000EDEB8 90 64 00 00 */ stw r3, 0x0(r4)
/* 800F207C 000EDEBC 38 64 00 04 */ addi r3, r4, 0x4
/* 800F2080 000EDEC0 38 85 00 04 */ addi r4, r5, 0x4
/* 800F2084 000EDEC4 38 A0 00 40 */ li r5, 0x40
/* 800F2088 000EDEC8 4B FE A7 49 */ bl Copy32ByteBlocks__Q34nw4r3g3d6detailFPvPCvUl
/* 800F208C 000EDECC 48 00 00 14 */ b lbl_800F20A0
.global lbl_800F2090
lbl_800F2090:
/* 800F2090 000EDED0 80 7B 00 04 */ lwz r3, 0x4(r27)
/* 800F2094 000EDED4 7C 03 F8 2E */ lwzx r0, r3, r31
/* 800F2098 000EDED8 54 00 07 B8 */ rlwinm r0, r0, 0, 30, 28
/* 800F209C 000EDEDC 7C 03 F9 2E */ stwx r0, r3, r31
.global lbl_800F20A0
lbl_800F20A0:
/* 800F20A0 000EDEE0 80 7C 00 08 */ lwz r3, 0x8(r28)
/* 800F20A4 000EDEE4 3B FF 00 44 */ addi r31, r31, 0x44
/* 800F20A8 000EDEE8 80 1B 00 08 */ lwz r0, 0x8(r27)
/* 800F20AC 000EDEEC 3B BD 00 01 */ addi r29, r29, 0x1
/* 800F20B0 000EDEF0 7C 83 F2 14 */ add r4, r3, r30
/* 800F20B4 000EDEF4 7C 60 F2 14 */ add r3, r0, r30
/* 800F20B8 000EDEF8 88 04 00 00 */ lbz r0, 0x0(r4)
/* 800F20BC 000EDEFC 98 03 00 00 */ stb r0, 0x0(r3)
/* 800F20C0 000EDF00 3B DE 00 04 */ addi r30, r30, 0x4
/* 800F20C4 000EDF04 88 04 00 01 */ lbz r0, 0x1(r4)
/* 800F20C8 000EDF08 98 03 00 01 */ stb r0, 0x1(r3)
/* 800F20CC 000EDF0C 88 04 00 02 */ lbz r0, 0x2(r4)
/* 800F20D0 000EDF10 98 03 00 02 */ stb r0, 0x2(r3)
/* 800F20D4 000EDF14 88 04 00 03 */ lbz r0, 0x3(r4)
/* 800F20D8 000EDF18 98 03 00 03 */ stb r0, 0x3(r3)
.global lbl_800F20DC
lbl_800F20DC:
/* 800F20DC 000EDF1C A0 1C 00 00 */ lhz r0, 0x0(r28)
/* 800F20E0 000EDF20 7C 1D 00 40 */ cmplw r29, r0
/* 800F20E4 000EDF24 41 80 FF 70 */ blt lbl_800F2054
/* 800F20E8 000EDF28 38 E0 00 00 */ li r7, 0x0
/* 800F20EC 000EDF2C 38 C0 00 00 */ li r6, 0x0
/* 800F20F0 000EDF30 48 00 00 44 */ b lbl_800F2134
.global lbl_800F20F4
lbl_800F20F4:
/* 800F20F4 000EDF34 80 1C 00 0C */ lwz r0, 0xc(r28)
/* 800F20F8 000EDF38 38 E7 00 01 */ addi r7, r7, 0x1
/* 800F20FC 000EDF3C 80 7B 00 0C */ lwz r3, 0xc(r27)
/* 800F2100 000EDF40 7C A0 32 14 */ add r5, r0, r6
/* 800F2104 000EDF44 80 05 00 04 */ lwz r0, 0x4(r5)
/* 800F2108 000EDF48 7C 83 32 14 */ add r4, r3, r6
/* 800F210C 000EDF4C 80 65 00 00 */ lwz r3, 0x0(r5)
/* 800F2110 000EDF50 38 C6 00 0C */ addi r6, r6, 0xc
/* 800F2114 000EDF54 90 64 00 00 */ stw r3, 0x0(r4)
/* 800F2118 000EDF58 90 04 00 04 */ stw r0, 0x4(r4)
/* 800F211C 000EDF5C 88 05 00 08 */ lbz r0, 0x8(r5)
/* 800F2120 000EDF60 98 04 00 08 */ stb r0, 0x8(r4)
/* 800F2124 000EDF64 A0 05 00 09 */ lhz r0, 0x9(r5)
/* 800F2128 000EDF68 B0 04 00 09 */ sth r0, 0x9(r4)
/* 800F212C 000EDF6C 88 05 00 0B */ lbz r0, 0xb(r5)
/* 800F2130 000EDF70 98 04 00 0B */ stb r0, 0xb(r4)
.global lbl_800F2134
lbl_800F2134:
/* 800F2134 000EDF74 A0 1C 00 02 */ lhz r0, 0x2(r28)
/* 800F2138 000EDF78 7C 07 00 40 */ cmplw r7, r0
/* 800F213C 000EDF7C 41 80 FF B8 */ blt lbl_800F20F4
/* 800F2140 000EDF80 38 60 00 01 */ li r3, 0x1
.global lbl_800F2144
lbl_800F2144:
/* 800F2144 000EDF84 39 61 00 20 */ addi r11, r1, 0x20
/* 800F2148 000EDF88 4B F1 52 41 */ bl lbl_80007388
/* 800F214C 000EDF8C 80 01 00 24 */ lwz r0, 0x24(r1)
/* 800F2150 000EDF90 7C 08 03 A6 */ mtlr r0
/* 800F2154 000EDF94 38 21 00 20 */ addi r1, r1, 0x20
/* 800F2158 000EDF98 4E 80 00 20 */ blr
/* 800F215C 000EDF9C 00 00 00 00 */ .4byte 0x00000000
.global ApplyViewMtx__Q34nw4r3g3d12LightSettingFRCQ34nw4r4math5MTX34Ul
ApplyViewMtx__Q34nw4r3g3d12LightSettingFRCQ34nw4r4math5MTX34Ul:
/* 800F2160 000EDFA0 94 21 FF C0 */ stwu r1, -0x40(r1)
/* 800F2164 000EDFA4 7C 08 02 A6 */ mflr r0
/* 800F2168 000EDFA8 90 01 00 44 */ stw r0, 0x44(r1)
/* 800F216C 000EDFAC 39 61 00 40 */ addi r11, r1, 0x40
/* 800F2170 000EDFB0 4B F1 51 CD */ bl lbl_8000733C
/* 800F2174 000EDFB4 90 A1 00 08 */ stw r5, 0x8(r1)
/* 800F2178 000EDFB8 7C 9C 23 78 */ mr r28, r4
/* 800F217C 000EDFBC 7C 7B 1B 78 */ mr r27, r3
/* 800F2180 000EDFC0 38 81 00 08 */ addi r4, r1, 0x8
/* 800F2184 000EDFC4 A0 03 00 00 */ lhz r0, 0x0(r3)
/* 800F2188 000EDFC8 90 01 00 0C */ stw r0, 0xc(r1)
/* 800F218C 000EDFCC 7C 05 00 40 */ cmplw r5, r0
/* 800F2190 000EDFD0 40 80 00 08 */ bge lbl_800F2198
/* 800F2194 000EDFD4 38 81 00 0C */ addi r4, r1, 0xc
.global lbl_800F2198
lbl_800F2198:
/* 800F2198 000EDFD8 80 04 00 00 */ lwz r0, 0x0(r4)
/* 800F219C 000EDFDC 3B A0 00 00 */ li r29, 0x0
/* 800F21A0 000EDFE0 90 01 00 08 */ stw r0, 0x8(r1)
/* 800F21A4 000EDFE4 3B E0 00 00 */ li r31, 0x0
/* 800F21A8 000EDFE8 48 00 00 B4 */ b lbl_800F225C
.global lbl_800F21AC
lbl_800F21AC:
/* 800F21AC 000EDFEC 80 1B 00 04 */ lwz r0, 0x4(r27)
/* 800F21B0 000EDFF0 7F C0 FA 14 */ add r30, r0, r31
/* 800F21B4 000EDFF4 7C 1F 00 2E */ lwzx r0, r31, r0
/* 800F21B8 000EDFF8 54 00 07 7B */ rlwinm. r0, r0, 0, 29, 29
/* 800F21BC 000EDFFC 41 82 00 98 */ beq lbl_800F2254
/* 800F21C0 000EE000 38 7E 00 04 */ addi r3, r30, 0x4
/* 800F21C4 000EE004 38 81 00 10 */ addi r4, r1, 0x10
/* 800F21C8 000EE008 38 A1 00 14 */ addi r5, r1, 0x14
/* 800F21CC 000EE00C 38 C1 00 18 */ addi r6, r1, 0x18
/* 800F21D0 000EE010 4B F4 3F 81 */ bl GXGetLightDir
/* 800F21D4 000EE014 38 61 00 10 */ addi r3, r1, 0x10
/* 800F21D8 000EE018 7F 84 E3 78 */ mr r4, r28
/* 800F21DC 000EE01C 7C 65 1B 78 */ mr r5, r3
/* 800F21E0 000EE020 48 00 CE F1 */ bl VEC3TransformNormal__Q24nw4r4mathFPQ34nw4r4math4VEC3PCQ34nw4r4math5MTX34PCQ34nw4r4math4VEC3
/* 800F21E4 000EE024 80 1E 00 00 */ lwz r0, 0x0(r30)
/* 800F21E8 000EE028 54 00 07 39 */ rlwinm. r0, r0, 0, 28, 28
/* 800F21EC 000EE02C 41 82 00 1C */ beq lbl_800F2208
/* 800F21F0 000EE030 C0 21 00 10 */ lfs f1, 0x10(r1)
/* 800F21F4 000EE034 38 7E 00 04 */ addi r3, r30, 0x4
/* 800F21F8 000EE038 C0 41 00 14 */ lfs f2, 0x14(r1)
/* 800F21FC 000EE03C C0 61 00 18 */ lfs f3, 0x18(r1)
/* 800F2200 000EE040 4B F4 3F 81 */ bl GXInitSpecularDir
/* 800F2204 000EE044 48 00 00 50 */ b lbl_800F2254
.global lbl_800F2208
lbl_800F2208:
/* 800F2208 000EE048 38 7E 00 04 */ addi r3, r30, 0x4
/* 800F220C 000EE04C 38 81 00 1C */ addi r4, r1, 0x1c
/* 800F2210 000EE050 38 A1 00 20 */ addi r5, r1, 0x20
/* 800F2214 000EE054 38 C1 00 24 */ addi r6, r1, 0x24
/* 800F2218 000EE058 4B F4 3E F9 */ bl GXGetLightPos
/* 800F221C 000EE05C 38 81 00 1C */ addi r4, r1, 0x1c
/* 800F2220 000EE060 7F 83 E3 78 */ mr r3, r28
/* 800F2224 000EE064 7C 85 23 78 */ mr r5, r4
/* 800F2228 000EE068 4B F3 EE C9 */ bl PSMTXMultVec
/* 800F222C 000EE06C C0 21 00 1C */ lfs f1, 0x1c(r1)
/* 800F2230 000EE070 38 7E 00 04 */ addi r3, r30, 0x4
/* 800F2234 000EE074 C0 41 00 20 */ lfs f2, 0x20(r1)
/* 800F2238 000EE078 C0 61 00 24 */ lfs f3, 0x24(r1)
/* 800F223C 000EE07C 4B F4 3E C5 */ bl GXInitLightPos
/* 800F2240 000EE080 C0 21 00 10 */ lfs f1, 0x10(r1)
/* 800F2244 000EE084 38 7E 00 04 */ addi r3, r30, 0x4
/* 800F2248 000EE088 C0 41 00 14 */ lfs f2, 0x14(r1)
/* 800F224C 000EE08C C0 61 00 18 */ lfs f3, 0x18(r1)
/* 800F2250 000EE090 4B F4 3E E1 */ bl GXInitLightDir
.global lbl_800F2254
lbl_800F2254:
/* 800F2254 000EE094 3B FF 00 44 */ addi r31, r31, 0x44
/* 800F2258 000EE098 3B BD 00 01 */ addi r29, r29, 0x1
.global lbl_800F225C
lbl_800F225C:
/* 800F225C 000EE09C 80 01 00 08 */ lwz r0, 0x8(r1)
/* 800F2260 000EE0A0 7C 1D 00 40 */ cmplw r29, r0
/* 800F2264 000EE0A4 41 80 FF 48 */ blt lbl_800F21AC
/* 800F2268 000EE0A8 39 61 00 40 */ addi r11, r1, 0x40
/* 800F226C 000EE0AC 4B F1 51 1D */ bl lbl_80007388
/* 800F2270 000EE0B0 80 01 00 44 */ lwz r0, 0x44(r1)
/* 800F2274 000EE0B4 7C 08 03 A6 */ mtlr r0
/* 800F2278 000EE0B8 38 21 00 40 */ addi r1, r1, 0x40
/* 800F227C 000EE0BC 4E 80 00 20 */ blr
.global GetLightObj__Q34nw4r3g3d8LightSetFUl
GetLightObj__Q34nw4r3g3d8LightSetFUl:
/* 800F2280 000EE0C0 80 C3 00 00 */ lwz r6, 0x0(r3)
/* 800F2284 000EE0C4 38 A0 00 00 */ li r5, 0x0
/* 800F2288 000EE0C8 2C 06 00 00 */ cmpwi r6, 0x0
/* 800F228C 000EE0CC 41 82 00 14 */ beq lbl_800F22A0
/* 800F2290 000EE0D0 80 03 00 04 */ lwz r0, 0x4(r3)
/* 800F2294 000EE0D4 2C 00 00 00 */ cmpwi r0, 0x0
/* 800F2298 000EE0D8 41 82 00 08 */ beq lbl_800F22A0
/* 800F229C 000EE0DC 38 A0 00 01 */ li r5, 0x1
.global lbl_800F22A0
lbl_800F22A0:
/* 800F22A0 000EE0E0 2C 05 00 00 */ cmpwi r5, 0x0
/* 800F22A4 000EE0E4 41 82 00 2C */ beq lbl_800F22D0
/* 800F22A8 000EE0E8 28 04 00 08 */ cmplwi r4, 0x8
/* 800F22AC 000EE0EC 40 80 00 24 */ bge lbl_800F22D0
/* 800F22B0 000EE0F0 80 63 00 04 */ lwz r3, 0x4(r3)
/* 800F22B4 000EE0F4 7C 03 20 AE */ lbzx r0, r3, r4
/* 800F22B8 000EE0F8 7C 00 07 75 */ extsb. r0, r0
/* 800F22BC 000EE0FC 41 80 00 14 */ blt lbl_800F22D0
/* 800F22C0 000EE100 1C 00 00 44 */ mulli r0, r0, 0x44
/* 800F22C4 000EE104 80 66 00 04 */ lwz r3, 0x4(r6)
/* 800F22C8 000EE108 7C 63 02 14 */ add r3, r3, r0
/* 800F22CC 000EE10C 4E 80 00 20 */ blr
.global lbl_800F22D0
lbl_800F22D0:
/* 800F22D0 000EE110 38 60 00 00 */ li r3, 0x0
/* 800F22D4 000EE114 4E 80 00 20 */ blr
/* 800F22D8 000EE118 00 00 00 00 */ .4byte 0x00000000
/* 800F22DC 000EE11C 00 00 00 00 */ .4byte 0x00000000
.global GetAmbLightObj__Q34nw4r3g3d8LightSetFv
GetAmbLightObj__Q34nw4r3g3d8LightSetFv:
/* 800F22E0 000EE120 80 A3 00 00 */ lwz r5, 0x0(r3)
/* 800F22E4 000EE124 38 80 00 00 */ li r4, 0x0
/* 800F22E8 000EE128 2C 05 00 00 */ cmpwi r5, 0x0
/* 800F22EC 000EE12C 41 82 00 14 */ beq lbl_800F2300
/* 800F22F0 000EE130 80 03 00 04 */ lwz r0, 0x4(r3)
/* 800F22F4 000EE134 2C 00 00 00 */ cmpwi r0, 0x0
/* 800F22F8 000EE138 41 82 00 08 */ beq lbl_800F2300
/* 800F22FC 000EE13C 38 80 00 01 */ li r4, 0x1
.global lbl_800F2300
lbl_800F2300:
/* 800F2300 000EE140 2C 04 00 00 */ cmpwi r4, 0x0
/* 800F2304 000EE144 41 82 00 24 */ beq lbl_800F2328
/* 800F2308 000EE148 80 63 00 04 */ lwz r3, 0x4(r3)
/* 800F230C 000EE14C 88 03 00 08 */ lbz r0, 0x8(r3)
/* 800F2310 000EE150 7C 00 07 75 */ extsb. r0, r0
/* 800F2314 000EE154 41 80 00 14 */ blt lbl_800F2328
/* 800F2318 000EE158 80 65 00 08 */ lwz r3, 0x8(r5)
/* 800F231C 000EE15C 54 00 10 3A */ slwi r0, r0, 2
/* 800F2320 000EE160 7C 63 02 14 */ add r3, r3, r0
/* 800F2324 000EE164 4E 80 00 20 */ blr
.global lbl_800F2328
lbl_800F2328:
/* 800F2328 000EE168 38 60 00 00 */ li r3, 0x0
/* 800F232C 000EE16C 4E 80 00 20 */ blr
.global SelectLightObj__Q34nw4r3g3d8LightSetFUli
SelectLightObj__Q34nw4r3g3d8LightSetFUli:
/* 800F2330 000EE170 80 E3 00 00 */ lwz r7, 0x0(r3)
/* 800F2334 000EE174 38 C0 00 00 */ li r6, 0x0
/* 800F2338 000EE178 2C 07 00 00 */ cmpwi r7, 0x0
/* 800F233C 000EE17C 41 82 00 14 */ beq lbl_800F2350
/* 800F2340 000EE180 80 03 00 04 */ lwz r0, 0x4(r3)
/* 800F2344 000EE184 2C 00 00 00 */ cmpwi r0, 0x0
/* 800F2348 000EE188 41 82 00 08 */ beq lbl_800F2350
/* 800F234C 000EE18C 38 C0 00 01 */ li r6, 0x1
.global lbl_800F2350
lbl_800F2350:
/* 800F2350 000EE190 2C 06 00 00 */ cmpwi r6, 0x0
/* 800F2354 000EE194 41 82 00 44 */ beq lbl_800F2398
/* 800F2358 000EE198 28 04 00 08 */ cmplwi r4, 0x8
/* 800F235C 000EE19C 40 80 00 3C */ bge lbl_800F2398
/* 800F2360 000EE1A0 2C 05 00 00 */ cmpwi r5, 0x0
/* 800F2364 000EE1A4 40 80 00 18 */ bge lbl_800F237C
/* 800F2368 000EE1A8 80 A3 00 04 */ lwz r5, 0x4(r3)
/* 800F236C 000EE1AC 38 00 FF FF */ li r0, -0x1
/* 800F2370 000EE1B0 38 60 00 01 */ li r3, 0x1
/* 800F2374 000EE1B4 7C 05 21 AE */ stbx r0, r5, r4
/* 800F2378 000EE1B8 4E 80 00 20 */ blr
.global lbl_800F237C
lbl_800F237C:
/* 800F237C 000EE1BC A0 07 00 00 */ lhz r0, 0x0(r7)
/* 800F2380 000EE1C0 7C 05 00 00 */ cmpw r5, r0
/* 800F2384 000EE1C4 40 80 00 14 */ bge lbl_800F2398
/* 800F2388 000EE1C8 80 C3 00 04 */ lwz r6, 0x4(r3)
/* 800F238C 000EE1CC 38 60 00 01 */ li r3, 0x1
/* 800F2390 000EE1D0 7C A6 21 AE */ stbx r5, r6, r4
/* 800F2394 000EE1D4 4E 80 00 20 */ blr
.global lbl_800F2398
lbl_800F2398:
/* 800F2398 000EE1D8 38 60 00 00 */ li r3, 0x0
/* 800F239C 000EE1DC 4E 80 00 20 */ blr
.global SelectAmbLightObj__Q34nw4r3g3d8LightSetFi
SelectAmbLightObj__Q34nw4r3g3d8LightSetFi:
/* 800F23A0 000EE1E0 80 C3 00 00 */ lwz r6, 0x0(r3)
/* 800F23A4 000EE1E4 38 A0 00 00 */ li r5, 0x0
/* 800F23A8 000EE1E8 2C 06 00 00 */ cmpwi r6, 0x0
/* 800F23AC 000EE1EC 41 82 00 14 */ beq lbl_800F23C0
/* 800F23B0 000EE1F0 80 03 00 04 */ lwz r0, 0x4(r3)
/* 800F23B4 000EE1F4 2C 00 00 00 */ cmpwi r0, 0x0
/* 800F23B8 000EE1F8 41 82 00 08 */ beq lbl_800F23C0
/* 800F23BC 000EE1FC 38 A0 00 01 */ li r5, 0x1
.global lbl_800F23C0
lbl_800F23C0:
/* 800F23C0 000EE200 2C 05 00 00 */ cmpwi r5, 0x0
/* 800F23C4 000EE204 41 82 00 3C */ beq lbl_800F2400
/* 800F23C8 000EE208 2C 04 00 00 */ cmpwi r4, 0x0
/* 800F23CC 000EE20C 40 80 00 18 */ bge lbl_800F23E4
/* 800F23D0 000EE210 80 83 00 04 */ lwz r4, 0x4(r3)
/* 800F23D4 000EE214 38 00 FF FF */ li r0, -0x1
/* 800F23D8 000EE218 38 60 00 01 */ li r3, 0x1
/* 800F23DC 000EE21C 98 04 00 08 */ stb r0, 0x8(r4)
/* 800F23E0 000EE220 4E 80 00 20 */ blr
.global lbl_800F23E4
lbl_800F23E4:
/* 800F23E4 000EE224 A0 06 00 00 */ lhz r0, 0x0(r6)
/* 800F23E8 000EE228 7C 04 00 00 */ cmpw r4, r0
/* 800F23EC 000EE22C 40 80 00 14 */ bge lbl_800F2400
/* 800F23F0 000EE230 80 A3 00 04 */ lwz r5, 0x4(r3)
/* 800F23F4 000EE234 38 60 00 01 */ li r3, 0x1
/* 800F23F8 000EE238 98 85 00 08 */ stb r4, 0x8(r5)
/* 800F23FC 000EE23C 4E 80 00 20 */ blr
.global lbl_800F2400
lbl_800F2400:
/* 800F2400 000EE240 38 60 00 00 */ li r3, 0x0
/* 800F2404 000EE244 4E 80 00 20 */ blr
/* 800F2408 000EE248 00 00 00 00 */ .4byte 0x00000000
/* 800F240C 000EE24C 00 00 00 00 */ .4byte 0x00000000
.include "macros.inc"
.section .sdata2, "wa" # 0x8055DF80 - 0x805643C0 ; 0x00006440
.global "@12220"
"@12220":
.4byte 0
.global "@12221"
"@12221":
.4byte 0x3F800000
.global "@12222"
"@12222":
.4byte 0x3F000000
.global "@11839"
"@11839":
.4byte 0xFFFFFFFF
.global "@11841"
"@11841":
.4byte 0xFFFFFFFF
.global "@12371"
"@12371":
.4byte 0x4A742400
.global "@12372"
"@12372":
.4byte 0xBF800000
.global "@12373"
"@12373":
.4byte 0x42B40000
.global "@12374"
"@12374":
.4byte 0x41200000
.global "@12375"
"@12375":
.4byte 0x41000000
.global "@12376_8055F108"
"@12376_8055F108":
.4byte 0xC0E00000
.4byte 0