Function at 0x4a2320
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0xd0
push ebx
push ebp
push esi
push edi
mov edi, ecx
movzx eax, byte [edi + 0x502]
movzx ecx, byte [edi + 0x501]
movzx edx, byte [edi + 0x500]
mov dword [esp + 0x10], eax
movzx eax, byte [edi + 0x503]
fild dword [esp + 0x10]
fld qword [0x7a6458]
mov dword [esp + 0x10], ecx
mov ecx, edi
fmul st(1), st(0)
fxch st(1)
fstp dword [esp + 0xa0]
fild dword [esp + 0x10]
mov dword [esp + 0x10], edx
fmul st(1)
fstp dword [esp + 0xa4]
fild dword [esp + 0x10]
mov dword [esp + 0x10], eax
lea eax, [edi + 0x13c]
push eax
fmul st(1)
fstp dword [esp + 0xac]
fild dword [esp + 0x14]
fmulp st(1)
fstp dword [esp + 0xb0]
fldz
fst dword [esp + 0x94]
fst dword [esp + 0x98]
fstp dword [esp + 0x9c]
fld dword [0x79b0b8]
fstp dword [esp + 0xa0]
call fcn.004a2f00
lea ecx, [esp + 0x90]
push ecx
push 0xb53
call dword [sym.imp.OPENGL32.dll_glLightModelfv]
mov ebp, dword [sym.imp.OPENGL32.dll_glLightfv]
lea edx, [edi + 0x4c8]
mov ebx, 0x4000
mov dword [esp + 0x2c], edx
lea esi, [edi + 0x3bd]
mov dword [esp + 0x10], 8
lea esp, [esp]
fldz
lea eax, [esp + 0x90]
push eax
fst dword [esp + 0x20]
fst dword [esp + 0x24]
push 0x1202
fst dword [esp + 0x2c]
push ebx
fstp dword [esp + 0x34]
call ebp
fld dword [esi - 0xd]
cmp dword [esi - 0x11], 0
je 0x4a2465
fstp dword [esp + 0x70]
mov ecx, dword [esp + 0x70]
fld dword [esi - 9]
mov dword [esp + 0x1c], ecx
fstp dword [esp + 0x74]
mov edx, dword [esp + 0x74]
fld dword [esi - 5]
mov dword [esp + 0x20], edx
fstp dword [esp + 0x78]
mov eax, dword [esp + 0x78]
fld1
mov dword [esp + 0x24], eax
fstp dword [esp + 0x7c]
mov ecx, dword [esp + 0x7c]
mov dword [esp + 0x28], ecx
jmp 0x4a24ac
fchs
fstp dword [esp + 0x30]
mov edx, dword [esp + 0x30]
fld dword [esi - 9]
mov dword [esp + 0x1c], edx
fchs
fstp dword [esp + 0x34]
mov eax, dword [esp + 0x34]
fld dword [esi - 5]
mov dword [esp + 0x20], eax
fchs
fstp dword [esp + 0x38]
mov ecx, dword [esp + 0x38]
fldz
mov dword [esp + 0x24], ecx
fstp dword [esp + 0x3c]
lea ecx, [esp + 0x1c]
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x28], edx
call fcn.004a1e20
lea eax, [esp + 0x1c]
push eax
push 0x1203
push ebx
call ebp
cmp dword [esi - 0x15], 0
push ebx
je 0x4a24c8
call dword [sym.imp.OPENGL32.dll_glEnable]
jmp 0x4a24ce
call dword [sym.imp.OPENGL32.dll_glDisable]
fld dword [esi + 7]
movzx ecx, byte [esi + 1]
fmul qword [0x7a6458]
movzx edx, byte [esi]
movzx eax, byte [esi - 1]
fstp dword [esp + 0x18]
mov dword [esp + 0x14], ecx
movzx ecx, byte [esi + 2]
fild dword [esp + 0x14]
mov dword [esp + 0x14], edx
fstp dword [esp + 0x60]
fild dword [esp + 0x14]
mov dword [esp + 0x14], eax
fstp dword [esp + 0x64]
fild dword [esp + 0x14]
mov dword [esp + 0x14], ecx
fstp dword [esp + 0x68]
fild dword [esp + 0x14]
fstp dword [esp + 0x6c]
fld dword [esp + 0x60]
fld dword [esp + 0x18]
fld st(0)
fmulp st(2)
fxch st(1)
fstp dword [esp + 0x80]
mov edx, dword [esp + 0x80]
fld dword [esp + 0x64]
mov dword [esp + 0x1c], edx
fmul st(1)
fstp dword [esp + 0x84]
mov eax, dword [esp + 0x84]
fld dword [esp + 0x68]
mov dword [esp + 0x20], eax
fmul st(1)
lea eax, [esp + 0x1c]
push eax
push 0x1200
fstp dword [esp + 0x90]
mov ecx, dword [esp + 0x90]
push ebx
fmul dword [esp + 0x78]
mov dword [esp + 0x30], ecx
fstp dword [esp + 0x98]
mov edx, dword [esp + 0x98]
mov dword [esp + 0x34], edx
call ebp
fld dword [esi + 0xb]
fmul qword [0x7a6458]
movzx ecx, byte [esi + 5]
movzx edx, byte [esi + 4]
fstp dword [esp + 0x14]
movzx eax, byte [esi + 3]
mov dword [esp + 0x18], ecx
movzx ecx, byte [esi + 6]
fild dword [esp + 0x18]
mov dword [esp + 0x18], edx
fstp dword [esp + 0x40]
fild dword [esp + 0x18]
mov dword [esp + 0x18], eax
fstp dword [esp + 0x44]
fild dword [esp + 0x18]
mov dword [esp + 0x18], ecx
fstp dword [esp + 0x48]
fild dword [esp + 0x18]
fstp dword [esp + 0x4c]
fld dword [esp + 0x40]
fld dword [esp + 0x14]
fld st(0)
fmulp st(2)
fxch st(1)
fstp dword [esp + 0x50]
mov edx, dword [esp + 0x50]
fld dword [esp + 0x44]
mov dword [esp + 0x1c], edx
fmul st(1)
fstp dword [esp + 0x54]
fld dword [esp + 0x48]
fmul st(1)
fstp dword [esp + 0x58]
fmul dword [esp + 0x4c]
fstp dword [esp + 0x5c]
mov eax, dword [esp + 0x54]
mov ecx, dword [esp + 0x58]
mov edx, dword [esp + 0x5c]
mov dword [esp + 0x20], eax
lea eax, [esp + 0x1c]
push eax
push 0x1201
push ebx
mov dword [esp + 0x30], ecx
mov dword [esp + 0x34], edx
call ebp
mov ecx, dword [esp + 0x2c]
push ecx
mov dword [ecx], 1
fld dword [edi + 0x4e8]
fstp dword [esp]
push 0x1208
push ebx
call dword [sym.imp.OPENGL32.dll_glLightf]
fld dword [edi + 0x4ec]
push ecx
fstp dword [esp]
push 0x1209
push ebx
call dword [sym.imp.OPENGL32.dll_glLightf]
add dword [esp + 0x2c], 4
add esi, 0x24
add ebx, 1
sub dword [esp + 0x10], 1
jne 0x4a2400
lea eax, [edi + 0x13c]
push eax
lea edx, [edi + 0x16c]
lea ecx, [esp + 0xb4]
call fcn.006d3ba0
lea edx, [esp + 0xb0]
push edx
mov ecx, edi
call fcn.004a2f00
mov eax, dword [edi + 0x4f0]
mov dword [edi + 0xbe0], 0
mov ecx, dword [eax*4 + 0x83a57c]
push ecx
push 0xb65
call dword [sym.imp.OPENGL32.dll_glFogi]
fld dword [edi + 0x4f4]
mov esi, dword [sym.imp.OPENGL32.dll_glFogf]
push ecx
fstp dword [esp]
push 0xb63
call esi
fld dword [edi + 0x4f8]
push ecx
fstp dword [esp]
push 0xb64
call esi
fld dword [edi + 0x4fc]
push ecx
fstp dword [esp]
push 0xb62
call esi
lea edx, [esp + 0xa0]
push edx
push 0xb66
call dword [sym.imp.OPENGL32.dll_glFogfv]
mov eax, dword [edi + 0x504]
mov edx, dword [edi + 0x508]
push eax
xor ecx, ecx
call fcn.004a1780
test eax, eax
push 0xb50
je 0x4a2745
mov ebx, dword [sym.imp.OPENGL32.dll_glEnable]
call ebx
mov ebp, dword [sym.imp.OPENGL32.dll_glDisable]
jmp 0x4a2753
mov ebp, dword [sym.imp.OPENGL32.dll_glDisable]
call ebp
mov ebx, dword [sym.imp.OPENGL32.dll_glEnable]
mov ecx, dword [edi + 0x504]
mov edx, dword [edi + 0x508]
push ecx
mov ecx, 1
call fcn.004a1780
mov esi, eax
call fcn.004a17e0
test eax, eax
push 0xb60
je 0x4a277e
call ebx
jmp 0x4a2780
call ebp
mov edx, dword [edi + 0x504]
push edx
mov edx, dword [edi + 0x508]
mov ecx, 2
call fcn.004a1780
neg eax
sbb eax, eax
and eax, 0xfffffffc
add eax, 0x207
push eax
call dword [sym.imp.OPENGL32.dll_glDepthFunc]
movzx eax, byte [edi + 0x574]
push eax
call dword [sym.imp.OPENGL32.dll_glDepthMask]
mov ecx, dword [edi + 0x504]
mov edx, dword [edi + 0x508]
push ecx
mov ecx, 4
call fcn.004a1780
test eax, eax
push 0xb44
je 0x4a27dc
call ebx
jmp 0x4a27de
call ebp
mov edx, dword [edi + 0x504]
push edx
mov ecx, 5
xor edx, edx
call fcn.004a1780
neg eax
sbb eax, eax
neg eax
add eax, 0x404
push eax
call dword [sym.imp.OPENGL32.dll_glDrawBuffer]
push 0xb71
call ebx
push 0x8074
call dword [sym.imp.OPENGL32.dll_glEnableClientState]
mov esi, dword [sym.imp.OPENGL32.dll_glTexGeni]
push 0x2402
push 0x2500
push 0x2000
call esi
push 0x2402
push 0x2500
push 0x2001
call esi
push 0xb57
call ebx
push 0x1602
push 0x408
call dword [sym.imp.OPENGL32.dll_glColorMaterial]
push 0xc11
call ebx
push 0x8037
call ebx
mov ecx, edi
mov dword [edi + 0x520], 1
call fcn.00498c70
mov ecx, edi
call fcn.00498d20
mov ecx, edi
call fcn.004a2ad0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xd0
ret