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

Disassembly:
mov ecx, dword [0x1313d40]
xor eax, eax
sub esp, 0x98
cmp dword [ecx + 0x40c], eax
jle 0x4a6978
mov dword [0x131437c], 0x200000
mov edx, dword [ecx + 0x40c]
cmp edx, eax
mov dword [esp + 0x24], eax
jle 0x4a696e
push ebx
push ebp
push esi
push edi
mov dword [esp + 0x30], eax
mov ebp, dword [ecx + 0x410]
mov esi, dword [esp + 0x30]
mov edx, dword [0x1313d24]
add ebp, esi
mov dword [esp + 0x14], ebp
mov ecx, dword [ebp + 0xd4]
cmp ecx, edx
jne 0x4a693f
mov esi, dword [ebp + 0xd8]
test esi, esi
mov dword [esp + 0x1c], esi
je 0x4a693f
mov dword [0x1314370], eax
push 0x13145c0
shl eax, 8
push 0x1314384
push ebp
mov dword [0x1314378], eax
call fcn.0049b580
fld dword [ebp + 0xc8]
fmul dword [esi + 0x14]
lea edx, [esp + 0x48]
lea eax, [esp + 0x60]
push edx
push eax
xor ebx, ebx
fst dword [esp + 0x24]
fmul dword [esi + 0x2c]
fstp dword [esp + 0x68]
fld dword [esp + 0x24]
fmul dword [esi + 0x30]
fstp dword [esp + 0x6c]
fld dword [esp + 0x24]
fmul dword [esi + 0x34]
fstp dword [esp + 0x70]
call fcn.0049ae50
mov ecx, dword [ebp + 0x2e4]
lea edx, [esp + 0x50]
push ecx
push edx
call fcn.0049aba0
mov ecx, dword [0x13e41fc]
add esp, 0x1c
test byte [ecx + 0x20], 8
je 0x4a6506
mov ecx, eax
sub ecx, ebx
je 0x4a64d4
sub ecx, 2
jne 0x4a6506
fld dword [ebp + 0x2e4]
fmul dword [0x536314]
push ebx
push 0x3f000000
push 0x3e4ccccd
push 0x3e4ccccd
fadd dword [0x535748]
push 0x3f800000
push ecx
lea edx, [esp + 0x54]
fstp dword [esp]
push edx
call fcn.0049a360
add esp, 0x1c
jmp 0x4a693f
fld dword [ebp + 0x2e4]
fmul dword [0x536310]
push 0
push 0x3f000000
push 0
push 0x3f800000
push 0
push ecx
lea eax, [esp + 0x54]
fstp dword [esp]
push eax
call fcn.0049a360
add esp, 0x1c
jmp 0x4a6636
cmp eax, 2
je 0x4a693f
cmp eax, 1
jne 0x4a6636
mov ecx, dword [esi + 4]
add ecx, 0x30
xor eax, eax
fld dword [esp + 0x10]
fmul dword [ecx - 0xc]
add eax, 4
add ecx, 4
cmp eax, 0xc
fadd dword [esp + eax + 0x50]
fstp dword [esp + eax + 0x64]
fld dword [esp + 0x10]
fmul dword [ecx - 4]
fadd dword [esp + eax + 0x50]
fstp dword [esp + eax + 0x70]
jl 0x4a6520
lea ecx, [esp + 0x68]
push ecx
call fcn.0049aa60
mov edx, dword [0x13e41fc]
mov edi, eax
add esp, 4
test byte [edx + 0x20], 4
je 0x4a6613
mov eax, edi
sub eax, 0
je 0x4a65b0
dec eax
mov dword [esp + 0x18], 0x3f800000
je 0x4a65b8
mov dword [esp + 0x2c], 0x3e4ccccd
mov dword [esp + 0x24], 0x3e4ccccd
xor eax, eax
fld dword [esp + eax*4 + 0x68]
fsub dword [0x535748]
inc eax
cmp eax, 3
fstp dword [esp + eax*4 + 0x64]
fld dword [esp + eax*4 + 0x70]
fadd dword [0x535748]
fstp dword [esp + eax*4 + 0x70]
jl 0x4a658c
jmp 0x4a65c8
mov dword [esp + 0x18], 0
mov dword [esp + 0x2c], 0x3f800000
mov dword [esp + 0x24], 0
lea eax, [esp + 0x84]
push eax
push 0x13145cc
call fcn.00463770
mov ecx, dword [esp + 0x2c]
mov edx, dword [esp + 0x34]
mov eax, dword [esp + 0x20]
push 0x3f000000
push ecx
push edx
lea ecx, [esp + 0x88]
push eax
lea edx, [esp + 0x80]
push ecx
lea eax, [esp + 0xa0]
push edx
push eax
push 0x13145c0
call fcn.004b95c0
add esp, 0x28
mov eax, edi
sub eax, 0
je 0x4a6630
dec eax
je 0x4a6628
inc dword [0x1314834]
jmp 0x4a693f
inc dword [0x1314830]
jmp 0x4a6636
inc dword [0x131482c]
fld dword [ebp + 0x2e4]
fdiv dword [ebp + 0xc8]
mov eax, dword [0x1314488]
push ecx
test eax, eax
fstp dword [esp]
je 0x4a6661
lea ecx, [esp + 0x40]
push ecx
call fcn.004cc790
fstp dword [ebp + 0x2f0]
jmp 0x4a6671
lea edx, [esp + 0x40]
push edx
call fcn.004cc790
fstp dword [ebp + 0x2ec]
mov eax, dword [esi + 0x10]
add esp, 8
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x1d4]
test eax, eax
mov dword [esp + 0x20], 0
jle 0x4a6808
lea ecx, [esi + 0x1d8]
mov dword [esp + 0x28], ecx
mov edx, dword [esp + 0x28]
movsx eax, word [edx]
push eax
call fcn.005163d0
add esp, 4
mov dword [esp + 0x64], eax
test eax, eax
je 0x4a67e6
mov ecx, dword [eax + 0x44]
mov edi, dword [eax + 0x50]
test ecx, ecx
mov dword [esp + 0x38], 0
jle 0x4a67e6
mov eax, dword [0x82a240]
cmp eax, 0x2000
jl 0x4a66f4
mov ecx, dword [esi + 4]
mov edx, dword [ecx]
push edx
push str._ERROR:_MAX_STATIC_MODELS_SURFS_exceeded___surface_of__s_skipped_n
push 1
call dword [0x1313c40]
add esp, 0xc
jmp 0x4a67ce
mov esi, eax
mov ecx, dword [esp + 0x10]
shl esi, 4
add esi, 0x80a240
inc eax
mov dword [0x82a240], eax
mov eax, dword [esp + 0x20]
mov dword [esi], 9
mov dword [esi + 4], ebx
mov dword [esi + 8], edi
mov dword [esi + 0xc], eax
mov edx, dword [ecx + 0x140]
mov ebp, dword [edx*4 + 0x135ea1c]
cmp dword [ebp + 0x170], 1
jne 0x4a679a
mov eax, dword [ebp + 0x174]
mov eax, dword [eax + 0x2ac]
cmp eax, 0x12
jne 0x4a6772
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x3c]
fld dword [ebp + 0xb0]
mov edx, dword [ecx + 0x2e4]
fadd dword [ebp + 0xac]
push edx
push eax
push ecx
fstp dword [esp]
call fcn.0049ad50
add esp, 0xc
cmp eax, 2
jne 0x4a679a
jmp 0x4a67b1
cmp eax, 0x13
jne 0x4a679a
mov ecx, dword [esp + 0x14]
lea eax, [esp + 0x3c]
mov edx, dword [ecx + 0x2e4]
mov ecx, dword [ebp + 0xb0]
push edx
push eax
push ecx
call fcn.0049ad50
add esp, 0xc
test eax, eax
je 0x4a67b1
mov edx, dword [esp + 0x14]
push 0
push ebp
push esi
mov dword [edx + 8], 1
call fcn.0049cd10
add esp, 0xc
mov ecx, dword [edi + 0x48]
mov eax, dword [esp + 0x10]
mov edi, dword [edi + 0x64]
mov esi, dword [esp + 0x1c]
mov ebp, dword [esp + 0x14]
add ebx, ecx
add eax, 0x15c
mov dword [esp + 0x10], eax
mov ecx, dword [esp + 0x64]
mov eax, dword [esp + 0x38]
inc eax
mov edx, dword [ecx + 0x44]
mov dword [esp + 0x38], eax
cmp eax, edx
jl 0x4a66cd
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x28]
mov ecx, dword [esi + 0x1d4]
inc eax
add edx, 2
cmp eax, ecx
mov dword [esp + 0x20], eax
mov dword [esp + 0x28], edx
jl 0x4a669b
mov eax, dword [0x13e6c60]
mov ecx, dword [eax + 0x20]
test ecx, ecx
je 0x4a68c3
fld dword [ebp + 0x94]
mov edx, dword [ebp + 0x8c]
mov ecx, dword [ebp + 0x90]
fadd qword [0x536308]
mov dword [esp + 0x48], edx
mov edx, dword [ebp + 0x2ec]
mov dword [esp + 0x4c], ecx
push 3
push 0
push 0x3f800000
fstp dword [esp + 0x5c]
fld dword [eax + 0x1c]
fadd st(0), st(0)
push 0x3f800000
push ecx
lea eax, [esp + 0x5c]
fstp dword [esp]
push edx
push eax
call fcn.004b9290
fld dword [esp + 0x6c]
fadd qword [0x536300]
mov eax, dword [ebp + 0x2ec]
lea ecx, [esp + 0x9c]
lea edx, [esp + 0x7c]
push ecx
push edx
push eax
fstp dword [esp + 0x78]
push esi
call fcn.004cc980
mov ecx, dword [0x13e6c60]
add esp, 0x2c
lea edx, [esp + 0x48]
fld dword [ecx + 0x1c]
push 0
push 0
push 0x3f800000
push 0x3f800000
fadd st(0), st(0)
sub esp, 8
fstp dword [esp + 4]
fild dword [esp + 0x78]
fstp dword [esp]
push edx
call fcn.004b9290
add esp, 0x1c
mov eax, dword [0x13e41f4]
mov ecx, dword [eax + 0x20]
test ecx, ecx
je 0x4a693f
mov ecx, dword [esi + 4]
add ecx, 0x30
xor eax, eax
fld dword [ecx - 0xc]
fmul dword [ebp + 0xc8]
add eax, 4
add ecx, 4
cmp eax, 0xc
fmul dword [esi + 0x14]
fstp dword [esp + eax + 0x8c]
fld dword [ebp + 0xc8]
fmul dword [ecx - 4]
fmul dword [esi + 0x14]
fstp dword [esp + eax + 0x98]
jl 0x4a68d7
push 0x3f400000
push 0x3f800000
push 0
lea ecx, [esp + 0xa8]
push 0x3f800000
lea edx, [esp + 0xa0]
push ecx
lea eax, [ebp + 0x98]
push edx
add ebp, 0x8c
push eax
push ebp
call fcn.004b95c0
add esp, 0x20
mov ecx, dword [0x1313d40]
mov eax, dword [esp + 0x34]
mov esi, dword [esp + 0x30]
inc eax
mov edx, dword [ecx + 0x40c]
add esi, 0x2f4
cmp eax, edx
mov dword [esp + 0x34], eax
mov dword [esp + 0x30], esi
jl 0x4a63de
pop edi
pop esi
pop ebp
pop ebx
mov dword [0x131437c], 0
add esp, 0x98
ret