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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x198
mov eax, dword [0x5de040]
xor eax, esp
mov dword [esp + 0x194], eax
mov eax, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 0x18]
push edi
mov edi, ecx
mov dword [esp + 0x2c], eax
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0x24], edi
mov dword [esp + 0x28], ecx
mov edx, dword [edi + 0x78]
test edx, edx
je 0x40ef82
mov ecx, dword [edi + 0x7c]
test ecx, ecx
je 0x40ef82
push esi
push edx
push eax
call fcn.004ccc40
movss xmm0, dword [edi + 8]
lea eax, [esp + 0x158]
push ecx
movss dword [esp], xmm0
push eax
call dword [0x5a4984]
lea eax, [esp + 0x44]
mov dword [esp + 0x44], 0
push eax
lea eax, [edi + 0x20]
mov dword [esp + 0x4c], 0x3f800000
push eax
lea eax, [edi + 0x14]
mov dword [esp + 0x54], 0
push eax
lea eax, [esp + 0xa4]
push eax
call dword [0x5a496c]
mov eax, dword [edi + 0x78]
lea edx, [esp + 0x98]
push edx
push str.g_viewing
push eax
mov ecx, dword [eax]
call dword [ecx + 0x98]
movss xmm1, dword [edi + 0x28]
xor ecx, ecx
subss xmm1, dword [edi + 0x1c]
mov eax, dword [edi + 0x84]
sub eax, dword [edi + 0x80]
sar eax, 2
mov dword [esp + 0x1c], eax
mulss xmm1, dword [0x5c70f4]
mov dword [esp + 0x14], ecx
addss xmm1, dword [edi + 0x1c]
movss dword [esp + 0x10], xmm1
test eax, eax
je 0x40edd4
mov eax, dword [edi + 0x80]
sub esp, 0xc
mov esi, dword [eax + ecx*4]
lea eax, [esp + 0x5c]
movss xmm0, dword [esi + 0x30]
movss dword [esp + 8], xmm0
movss dword [esp + 4], xmm0
movss dword [esp], xmm0
push eax
call dword [0x5a4968]
movss xmm0, dword [esi + 0x20]
lea eax, [esp + 0xd8]
sub esp, 0xc
movss dword [esp + 8], xmm0
movss xmm0, dword [esi + 0x1c]
movss dword [esp + 4], xmm0
movss xmm0, dword [esi + 0x18]
movss dword [esp], xmm0
push eax
call dword [0x5a4978]
movss xmm0, dword [esi + 8]
lea eax, [esp + 0x118]
sub esp, 0xc
movss dword [esp + 8], xmm0
movss xmm0, dword [esi + 4]
movss dword [esp + 4], xmm0
movss xmm0, dword [esi]
movss dword [esp], xmm0
push eax
call dword [0x5a495c]
lea eax, [esp + 0xd8]
push eax
lea eax, [esp + 0x54]
push eax
push eax
call dword [0x5a4964]
lea eax, [esp + 0x118]
push eax
lea eax, [esp + 0x54]
push eax
push eax
call dword [0x5a4964]
lea eax, [esp + 0x158]
push eax
lea eax, [esp + 0x54]
push eax
push eax
call dword [0x5a4964]
movaps xmm0, xmmword [0x5c7650]
lea eax, [esp + 0x50]
push eax
lea eax, [esp + 0x34]
movaps xmmword [esp + 0x34], xmm0
push eax
push eax
call dword [0x5a4980]
movups xmm0, xmmword [esp + 0x50]
mov ecx, dword [esp + 0x14]
inc ecx
movups xmmword [esi + 0x5c], xmm0
mov dword [esp + 0x14], ecx
movups xmm0, xmmword [esp + 0x60]
movups xmmword [esi + 0x6c], xmm0
movups xmm0, xmmword [esp + 0x70]
movups xmmword [esi + 0x7c], xmm0
movups xmm0, xmmword [esp + 0x80]
movups xmmword [esi + 0x8c], xmm0
movups xmm0, xmmword [esp + 0x30]
movups xmmword [esi + 0x9c], xmm0
cmp ecx, dword [esp + 0x1c]
jb 0x40eca4
mov edx, dword [edi + 0x84]
mov eax, edx
mov ecx, dword [edi + 0x80]
sub eax, ecx
push dword [esp + 0x28]
sar eax, 2
push eax
call fcn.0040f330
xor esi, esi
add esp, 8
mov dword [esp + 0x20], esi
cmp dword [esp + 0x1c], esi
jbe 0x40ef57
mov ecx, dword [ebp + 0x20]
xorps xmm2, xmm2
movss xmm3, dword [0x5c7710]
movss xmm1, dword [esp + 0x10]
nop dword [eax + eax]
comiss xmm2, xmm1
mov eax, dword [edi + 0x80]
mov esi, dword [eax + esi*4]
mov eax, dword [esp + 0x24]
movss xmm0, dword [edi + 0x10]
mov edi, dword [edi + 0x78]
mov eax, dword [eax + 0x7c]
movss dword [esp + 0x14], xmm0
mov dword [esp + 0x18], eax
jbe 0x40ee7c
cmp ecx, 1
jne 0x40ee62
movss xmm0, dword [esi + 0xa4]
xorps xmm1, xmm3
comiss xmm0, xmm1
jae 0x40ef3a
jmp 0x40eea6
cmp ecx, 2
jne 0x40eea6
movaps xmm0, xmm1
xorps xmm0, xmm3
comiss xmm0, dword [esi + 0xa4]
ja 0x40ef40
jmp 0x40eea6
cmp ecx, 1
jne 0x40ee90
comiss xmm1, dword [esi + 0xa4]
ja 0x40ef40
jmp 0x40eea6
cmp ecx, 2
jne 0x40eea6
movss xmm0, dword [esi + 0xa4]
comiss xmm0, xmm1
jae 0x40ef40
mov ecx, dword [edi]
lea eax, [esi + 0x5c]
push eax
push str.g_world
push edi
call dword [ecx + 0x98]
xorps xmm0, xmm0
comiss xmm0, dword [esi + 0x3c]
jbe 0x40eeed
comiss xmm0, dword [esi + 0x40]
jbe 0x40eeed
movss xmm3, dword [esi + 4]
movsd xmm1, qword [0x5c7170]
cvtps2pd xmm0, xmm3
push edi
push ecx
mov ecx, dword [esp + 0x20]
comisd xmm1, xmm0
jbe 0x40ef21
mulss xmm3, dword [0x5c7410]
jmp 0x40ef27
movss xmm3, dword [esi + 0x48]
movss xmm1, dword [esi + 4]
movaps xmm0, xmm3
subss xmm0, dword [0x5c70d4]
push edi
push ecx
mov ecx, dword [esp + 0x20]
comiss xmm1, xmm0
jbe 0x40ef21
subss xmm3, xmm1
mulss xmm3, dword [0x5c7410]
mulss xmm3, dword [esp + 0x1c]
jmp 0x40ef27
movss xmm3, dword [esp + 0x1c]
call fcn.004cd050
mov ecx, dword [ebp + 0x20]
xorps xmm2, xmm2
movss xmm3, dword [0x5c7710]
movss xmm1, dword [esp + 0x10]
mov esi, dword [esp + 0x20]
mov edi, dword [esp + 0x24]
inc esi
mov dword [esp + 0x20], esi
cmp esi, dword [esp + 0x1c]
jb 0x40ee20
mov esi, dword [esp + 0x2c]
push 1
push 0x16
push esi
mov eax, dword [esi]
call dword [eax + 0xe4]
mov eax, dword [esi]
push 0
push 7
push esi
call dword [eax + 0xe4]
push dword [esp + 0x28]
mov eax, dword [esi]
push esi
call dword [eax + 0x15c]
mov ecx, dword [esp + 0x19c]
pop edi
pop esi
xor ecx, esp
call fcn.0052d235
mov esp, ebp
pop ebp
ret 0x1c