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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
mov ecx, dword [ebp + 0x14]
mov eax, dword [0x93d844]
sub esp, 0x154
push ebx
mov ebx, dword [ebp + 8]
push esi
xor esi, esi
cmp ecx, esi
push edi
mov dword [ebx + 0x90], esi
je 0x5067d2
cmp eax, esi
je 0x5067d2
mov edx, dword [0x93d84c]
mov dword [ebx + 0x159f4], edx
mov dword [ebx + 0x159f0], eax
cmp dword [ecx], 7
jne 0x5067d2
mov eax, dword [ebp + 0x18]
mov dword [ebx + 0x567c], eax
cmp dword [0x9d3e94], esi
jne 0x505684
mov dword [esp + 0x3c], esi
jmp 0x5056a6
mov esi, dword [ebp + 0xc]
push 0x843
push 0x6b4a0c
push 0x10
mov edi, 0x890
call fcn.00589980
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0x3c], eax
xor esi, esi
mov dword [ebx + 0x98], ecx
mov ecx, dword [ebp + 0xc]
push 0x9cdce8
mov dword [ebx + 0x15a0c], ecx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov edi, dword [ebp + 0x10]
mov eax, ebx
call fcn.00501380
push edi
push ebx
call fcn.00503020
cmp dword [0xb02bd0], esi
jne 0x5056de
call fcn.00502870
xorps xmm0, xmm0
movss xmm1, dword [0x6cc5e8]
mov dword [ebx + 0x27a0], esi
mov dword [ebx + 0x46c4], esi
movss dword [esp + 0x10], xmm0
mov ecx, dword [esp + 0x10]
movss dword [esp + 0x10], xmm0
mov esi, dword [esp + 0x10]
mov dword [esp + 0x70], esi
movss dword [esp + 0x14], xmm0
mov edx, dword [esp + 0x14]
movss dword [esp + 0x14], xmm0
mov esi, dword [esp + 0x14]
mov dword [esp + 0x74], esi
movss dword [esp + 0x18], xmm0
mov edi, dword [esp + 0x18]
movss dword [esp + 0x18], xmm1
mov esi, dword [esp + 0x18]
mov dword [esp + 0x78], esi
movss dword [esp + 0x10], xmm1
mov esi, dword [esp + 0x10]
mov dword [esp + 0x80], esi
movss dword [esp + 0x14], xmm0
mov esi, dword [esp + 0x14]
mov dword [esp + 0x84], esi
movss dword [esp + 0x18], xmm0
mov esi, dword [esp + 0x18]
mov dword [esp + 0x88], esi
movss dword [esp + 0x10], xmm1
mov esi, dword [esp + 0x10]
mov dword [esp + 0x90], esi
movss dword [esp + 0x14], xmm0
mov esi, dword [esp + 0x14]
mov dword [esp + 0x94], esi
movss dword [esp + 0x18], xmm1
mov esi, dword [esp + 0x18]
mov dword [esp + 0x98], esi
movss dword [esp + 0x10], xmm0
mov esi, dword [esp + 0x10]
mov dword [esp + 0xa0], esi
movss dword [esp + 0x14], xmm1
mov esi, dword [esp + 0x14]
mov dword [esp + 0xa4], esi
movss dword [esp + 0x18], xmm0
mov esi, dword [esp + 0x18]
mov dword [esp + 0xa8], esi
movss dword [esp + 0x10], xmm0
mov esi, dword [esp + 0x10]
mov dword [esp + 0xb0], esi
movss dword [esp + 0x14], xmm1
mov esi, dword [esp + 0x14]
mov dword [esp + 0xb4], esi
movss dword [esp + 0x18], xmm1
mov esi, dword [esp + 0x18]
mov dword [esp + 0xb8], esi
movss dword [esp + 0x10], xmm1
mov esi, dword [esp + 0x10]
mov dword [esp + 0xc0], esi
movss dword [esp + 0x14], xmm1
mov esi, dword [esp + 0x14]
mov dword [esp + 0xc4], esi
movss dword [esp + 0x18], xmm0
mov esi, dword [esp + 0x18]
mov dword [esp + 0xc8], esi
movss dword [esp + 0x10], xmm1
mov esi, dword [esp + 0x10]
movss dword [esp + 0x14], xmm1
mov dword [esp + 0xd0], esi
mov esi, dword [esp + 0x14]
movss dword [esp + 0x18], xmm1
movss xmm1, dword [0x6d54c4]
mov dword [esp + 0xd4], esi
mov esi, dword [esp + 0x18]
movss dword [esp + 0x1c], xmm0
mov eax, dword [esp + 0x1c]
movss dword [ebx + 0x2488], xmm0
movss dword [ebx + 0x2490], xmm0
mov dword [esp + 0xd8], esi
movss dword [esp + 0x10], xmm1
movss dword [esp + 0x14], xmm1
movss dword [esp + 0x18], xmm1
mov esi, dword [esp + 0x10]
movss xmm1, dword [0x6cc5ec]
mov dword [esp + 0xe0], esi
mov esi, dword [esp + 0x14]
mov dword [esp + 0xe4], esi
mov esi, dword [esp + 0x18]
mov dword [esp + 0xe8], esi
movss dword [esp + 0x10], xmm0
mov esi, dword [esp + 0x10]
mov dword [esp + 0xf0], esi
movss dword [esp + 0x14], xmm0
mov esi, dword [esp + 0x14]
mov dword [esp + 0xf4], esi
movss dword [esp + 0x18], xmm1
mov esi, dword [esp + 0x18]
mov dword [esp + 0xf8], esi
movss dword [esp + 0x10], xmm1
mov esi, dword [esp + 0x10]
mov dword [esp + 0x100], esi
movss dword [esp + 0x14], xmm0
mov esi, dword [esp + 0x14]
mov dword [esp + 0x104], esi
movss dword [esp + 0x18], xmm0
mov esi, dword [esp + 0x18]
mov dword [esp + 0x108], esi
movss dword [esp + 0x10], xmm1
mov esi, dword [esp + 0x10]
mov dword [esp + 0x110], esi
movss dword [esp + 0x14], xmm0
mov esi, dword [esp + 0x14]
mov dword [esp + 0x114], esi
movss dword [esp + 0x18], xmm1
mov esi, dword [esp + 0x18]
mov dword [esp + 0x118], esi
movss dword [esp + 0x10], xmm0
mov esi, dword [esp + 0x10]
mov dword [esp + 0x120], esi
movss dword [esp + 0x14], xmm1
mov esi, dword [esp + 0x14]
mov dword [esp + 0x124], esi
movss dword [esp + 0x18], xmm0
mov esi, dword [esp + 0x18]
mov dword [esp + 0x128], esi
movss dword [esp + 0x10], xmm0
mov esi, dword [esp + 0x10]
mov dword [esp + 0x130], esi
movss dword [esp + 0x14], xmm1
mov esi, dword [esp + 0x14]
mov dword [esp + 0x134], esi
movss dword [esp + 0x18], xmm1
mov esi, dword [esp + 0x18]
mov dword [esp + 0x138], esi
movss dword [esp + 0x10], xmm1
mov esi, dword [esp + 0x10]
mov dword [esp + 0x140], esi
movss dword [esp + 0x14], xmm1
mov esi, dword [esp + 0x14]
mov dword [esp + 0x144], esi
movss dword [esp + 0x18], xmm0
mov esi, dword [esp + 0x18]
mov dword [esp + 0x148], esi
mov dword [ebx + 0x2494], ecx
mov dword [ebx + 0x2498], edx
mov esi, eax
mov dword [ebx + 0x249c], edi
mov dword [ebx + 0x24a0], esi
mov esi, dword [esp + 0xe0]
mov dword [ebx + 0x2514], esi
mov esi, dword [esp + 0xe4]
mov dword [ebx + 0x2518], esi
mov esi, dword [esp + 0xe8]
mov dword [ebx + 0x251c], esi
mov dword [ebx + 0x2594], ecx
mov esi, eax
mov dword [ebx + 0x2598], edx
movss dword [esp + 0x10], xmm1
movss dword [esp + 0x14], xmm1
movss dword [esp + 0x18], xmm1
mov dword [ebx + 0x2520], esi
mov dword [ebx + 0x259c], edi
mov ecx, eax
mov edx, dword [esp + 0x70]
mov edi, dword [esp + 0x84]
mov dword [ebx + 0x24a4], edx
mov edx, dword [esp + 0x78]
mov dword [ebx + 0x25a0], ecx
mov ecx, dword [esp + 0x74]
mov dword [ebx + 0x24a8], ecx
mov dword [ebx + 0x24ac], edx
mov edx, dword [esp + 0xf4]
mov ecx, eax
mov dword [ebx + 0x24b0], ecx
mov ecx, dword [esp + 0xf0]
mov dword [ebx + 0x2524], ecx
mov ecx, dword [esp + 0xf8]
mov dword [ebx + 0x2528], edx
mov edx, dword [esp + 0x80]
mov dword [ebx + 0x25a4], edx
mov dword [ebx + 0x24b4], edx
mov edx, dword [esp + 0x88]
mov dword [ebx + 0x252c], ecx
mov ecx, eax
mov dword [ebx + 0x2530], ecx
mov ecx, dword [esp + 0x88]
mov dword [ebx + 0x25a8], edi
mov dword [ebx + 0x25ac], ecx
mov dword [ebx + 0x24b8], edi
mov edi, dword [esp + 0xa0]
mov dword [ebx + 0x24bc], edx
mov edx, dword [esp + 0x104]
mov ecx, eax
mov dword [ebx + 0x25b0], ecx
mov dword [ebx + 0x24c0], ecx
mov ecx, dword [esp + 0x100]
mov dword [ebx + 0x2534], ecx
mov dword [ebx + 0x2538], edx
mov edx, dword [esp + 0xa4]
mov ecx, dword [esp + 0x108]
mov dword [ebx + 0x25b4], edi
mov dword [ebx + 0x25b8], edx
mov edx, dword [esp + 0x90]
mov dword [ebx + 0x24c4], edx
mov edx, dword [esp + 0x94]
mov dword [ebx + 0x24c8], edx
mov edx, dword [esp + 0x98]
mov dword [ebx + 0x24cc], edx
mov edx, eax
mov dword [ebx + 0x24d0], edx
mov edx, dword [esp + 0x110]
mov dword [ebx + 0x2544], edx
mov edx, dword [esp + 0x114]
mov dword [ebx + 0x2548], edx
mov edx, dword [esp + 0x118]
mov dword [ebx + 0x253c], ecx
mov dword [ebx + 0x254c], edx
mov dword [ebx + 0x24d4], edi
mov edi, dword [esp + 0xa4]
mov ecx, eax
mov dword [ebx + 0x2540], ecx
mov ecx, dword [esp + 0xa8]
mov edx, eax
mov dword [ebx + 0x2550], edx
mov edx, dword [esp + 0xc0]
mov dword [ebx + 0x25bc], ecx
mov dword [ebx + 0x25c4], edx
mov edx, dword [esp + 0xc4]
mov dword [ebx + 0x24d8], edi
mov edi, dword [esp + 0xa8]
mov ecx, eax
mov dword [ebx + 0x25c0], ecx
mov dword [ebx + 0x25c8], edx
mov edx, dword [esp + 0xc8]
mov dword [ebx + 0x24dc], edi
mov dword [ebx + 0x24e0], ecx
mov ecx, dword [esp + 0x120]
mov dword [ebx + 0x2554], ecx
mov ecx, dword [esp + 0x124]
mov dword [ebx + 0x25cc], edx
mov edx, eax
mov dword [ebx + 0x2558], ecx
mov ecx, dword [esp + 0x128]
mov dword [ebx + 0x25d0], edx
mov edi, dword [esp + 0xe0]
mov dword [ebx + 0x25d4], edi
mov edi, dword [esp + 0xe4]
mov dword [ebx + 0x25d8], edi
mov edi, dword [esp + 0xe8]
mov dword [ebx + 0x25dc], edi
mov dword [ebx + 0x25e0], esi
mov esi, dword [esp + 0xb0]
mov dword [ebx + 0x24e4], esi
mov esi, dword [esp + 0xb4]
mov dword [ebx + 0x24e8], esi
mov esi, dword [esp + 0xb8]
mov edi, dword [esp + 0x120]
mov dword [ebx + 0x24ec], esi
mov esi, eax
mov dword [ebx + 0x24f0], esi
mov esi, dword [esp + 0x130]
mov dword [ebx + 0x2564], esi
mov esi, dword [esp + 0x134]
mov dword [ebx + 0x2568], esi
mov esi, dword [esp + 0x138]
mov dword [ebx + 0x256c], esi
mov dword [ebx + 0x255c], ecx
mov dword [ebx + 0x25f4], edi
mov edi, dword [esp + 0x124]
mov esi, eax
mov dword [ebx + 0x2570], esi
mov esi, dword [esp + 0x100]
mov dword [ebx + 0x25e4], esi
mov esi, dword [esp + 0x104]
mov dword [ebx + 0x25e8], esi
mov esi, dword [esp + 0x108]
mov dword [ebx + 0x25f8], edi
mov edi, dword [esp + 0x128]
mov ecx, eax
mov dword [ebx + 0x2560], ecx
mov dword [ebx + 0x25ec], esi
mov dword [ebx + 0x25fc], edi
mov dword [ebx + 0x2600], ecx
mov ecx, dword [esp + 0xd0]
mov dword [ebx + 0x2504], ecx
mov ecx, dword [esp + 0xd4]
mov dword [ebx + 0x2508], ecx
mov ecx, dword [esp + 0xd8]
mov esi, eax
mov dword [ebx + 0x25f0], esi
mov esi, dword [esp + 0xc0]
mov dword [ebx + 0x24f4], esi
mov esi, dword [esp + 0xc4]
mov dword [ebx + 0x250c], ecx
mov dword [ebx + 0x24f8], esi
mov esi, dword [esp + 0xc8]
mov ecx, eax
mov dword [ebx + 0x2510], ecx
mov ecx, dword [esp + 0x10]
mov dword [ebx + 0x2584], ecx
mov ecx, dword [esp + 0x14]
mov dword [ebx + 0x24fc], esi
mov esi, dword [esp + 0x140]
mov dword [ebx + 0x2500], edx
mov edx, dword [esp + 0x144]
mov dword [ebx + 0x2574], esi
mov dword [ebx + 0x2578], edx
mov edx, dword [esp + 0x148]
mov dword [ebx + 0x2588], ecx
mov ecx, dword [esp + 0x18]
mov dword [ebx + 0x257c], edx
mov dword [ebx + 0x258c], ecx
mov ecx, dword [esp + 0x148]
mov dword [ebx + 0x2590], eax
mov edx, eax
mov eax, dword [esp + 0x144]
mov dword [ebx + 0x2604], esi
mov dword [ebx + 0x2608], eax
mov dword [ebx + 0x260c], ecx
or eax, 0xffffffff
mov dword [ebx + 0x2580], edx
mov dword [ebx + 0x2610], edx
mov dword [ebx + 0x159b0], eax
mov dword [ebx + 0x159b4], eax
mov dword [ebx + 0x159b8], eax
mov dword [ebx + 0x159bc], eax
mov dword [ebx + 0x159c0], eax
mov dword [ebx + 0x159c4], eax
mov dword [ebx + 0x159c8], eax
mov dword [ebx + 0x159cc], eax
mov dword [ebx + 0x159d0], eax
mov dword [ebx + 0x159d4], eax
mov dword [ebx + 0x159d8], eax
push ebx
mov dword [ebx + 0x159dc], eax
call fcn.00500d10
push 0x9cdce8
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
fld qword [0x6f9af0]
mov eax, dword [ebx + 0x98]
mov edx, dword [eax + 0xd8c]
add eax, 0xd88
mov dword [ebx + 0x2440], edx
mov ecx, dword [eax]
mov dword [ebx + 0x2460], ecx
mov edx, dword [eax + 0xc]
mov dword [ebx + 0x2444], edx
mov ecx, dword [eax + 8]
mov dword [ebx + 0x2464], ecx
mov edx, dword [eax + 0x14]
mov dword [ebx + 0x2448], edx
mov ecx, dword [eax + 0x10]
mov dword [ebx + 0x2468], ecx
mov edx, dword [eax + 0x1c]
mov dword [ebx + 0x244c], edx
mov ecx, dword [eax + 0x18]
mov dword [ebx + 0x246c], ecx
mov edx, dword [eax + 0x24]
xorps xmm0, xmm0
mov dword [ebx + 0x2450], edx
mov ecx, dword [eax + 0x20]
mov dword [ebx + 0x2470], ecx
mov edx, dword [eax + 0x2c]
mov dword [ebx + 0x2454], edx
mov ecx, dword [eax + 0x28]
mov dword [ebx + 0x2474], ecx
mov edx, dword [eax + 0x34]
mov dword [ebx + 0x2458], edx
mov ecx, dword [eax + 0x30]
mov dword [ebx + 0x2478], ecx
mov edx, dword [eax + 0x3c]
mov dword [ebx + 0x245c], edx
mov eax, dword [eax + 0x38]
xor edi, edi
mov dword [ebx + 0x247c], eax
xor edx, edx
lea ecx, [ebx + 0x384]
movss dword [ecx + 0x7c], xmm0
mov eax, dword [ebx + 0x98]
mov eax, dword [eax + edx + 0x9a8]
cmp eax, edi
je 0x505fcc
mov dword [ecx], edi
mov esi, dword [ebx + 0x98]
mov esi, dword [esi + edx + 0x9bc]
or esi, 0x101
mov dword [ecx - 0x2e8], esi
mov esi, dword [ebx + 0x98]
fld dword [esi + edx + 0x9c0]
fld dword [eax + 0x28]
fmul st(2)
fdivp st(1)
fstp dword [ecx - 0x26c]
fld dword [eax + 0x28]
fmul st(1)
fstp dword [ecx - 0x1f0]
mov eax, dword [ebx + 0x98]
movss xmm1, dword [eax + edx + 0x9b4]
lea esi, [eax + edx]
ucomiss xmm1, xmm0
lahf
test ah, 0x44
jnp 0x505fab
movss xmm1, dword [esi + 0x9b8]
ucomiss xmm1, xmm0
lahf
test ah, 0x44
jnp 0x505fab
mov eax, 1
jmp 0x505fad
xor eax, eax
mov dword [ecx + 0x67e4], eax
add dword [ebx + 0x27a0], 1
add edx, 0x20
add ecx, 4
cmp edx, 0x3e0
jl 0x505f1e
mov eax, dword [ebx + 0x98]
fstp st(0)
mov ecx, dword [eax + 0x10]
imul ecx, dword [eax + 0xc]
mov dword [esp + 0x54], ecx
mov ecx, dword [eax + 0x14]
cmp ecx, 2
mov dword [ebx + 0x15b94], ecx
ja 0x505ff7
mov dword [ebx + 0x15b94], 0xf0
mov ecx, 0xff
cmp dword [ebx + 0x15b94], ecx
jbe 0x50600a
mov dword [ebx + 0x15b94], ecx
cmp dword [eax + 8], edi
jne 0x506013
mov dword [esp + 0x54], edi
fld qword [0x6fa600]
lea esi, [eax + 0x48]
mov dword [esp + 0x38], esi
movss dword [ebx + 0x27ac], xmm0
mov dword [esp + 0x4c], edi
call fcn.004ad3a0
fstp dword [esp + 0x58]
xorps xmm1, xmm1
lea ecx, [ebx + 0x264c]
mov dword [esp + 0x2c], ecx
lea edx, [ebx + 0x26f0]
lea ecx, [ebx + 0x2728]
mov dword [esp + 0x30], edx
mov dword [esp + 0x40], ecx
jmp 0x50606c
mov esi, dword [esp + 0x38]
mov edx, dword [esp + 0x30]
mov ecx, dword [esp + 0x40]
cmp dword [esp + 0x4c], 4
jge 0x506089
movss xmm0, dword [esi + 0xc]
movss dword [esp + 0x5c], xmm0
cvttss2si eax, dword [esp + 0x5c]
mov dword [edx + 0x78], eax
jmp 0x506090
mov dword [edx + 0x78], 0x3e7
movss xmm0, dword [esi + 4]
ucomiss xmm0, xmm1
lahf
test ah, 0x44
movss dword [esp + 0x48], xmm1
mov dword [esp + 0x44], edi
jp 0x5060d0
movss xmm0, dword [esi + 8]
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jp 0x5060d0
movss xmm0, dword [0x6fa57c]
movss dword [esi + 4], xmm0
movss xmm0, dword [0x6cac60]
movss dword [esi + 8], xmm0
fld dword [esi + 4]
fstp dword [ecx]
fld dword [esi + 4]
fstp dword [esp + 0x24]
fld dword [ebx + 0x27ac]
fld dword [esp + 0x24]
fcompi st(1)
fstp st(0)
jbe 0x5060fa
movss xmm0, dword [esp + 0x24]
movss dword [ebx + 0x27ac], xmm0
fld dword [esi + 8]
mov edi, dword [esp + 0x2c]
fld1
movss xmm0, dword [esp + 0x58]
fdivrp st(1)
add edi, 0x13484
movss dword [esp + 0x50], xmm1
add esi, 0x34
fchs
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fst dword [ecx - 4]
fchs
mov dword [esp + 0x28], 8
fmul dword [ecx]
fstp dword [ecx - 8]
movss dword [ebx + 0x27a8], xmm0
mov ecx, dword [esi]
cmp ecx, 1
jb 0x50614d
cmp ecx, dword [ebx + 0x27a0]
jbe 0x506160
movss xmm0, dword [esi - 0x20]
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jnp 0x506160
movss dword [esi - 0x20], xmm1
add ecx, 0x3e7
mov dword [edi], ecx
movss xmm0, dword [esi - 0x20]
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jnp 0x506183
mov eax, dword [esi + 4]
cmp dword [esp + 0x44], eax
jae 0x506183
mov dword [esp + 0x44], eax
fld dword [esi - 0xc]
fmul qword [0x6f9c60]
fstp dword [esp + 0x24]
fld dword [esp + 0x24]
call fcn.004ad3a0
fstp dword [esp + 0x24]
mov eax, dword [edi]
fld dword [esp + 0x24]
cmp eax, dword [esp + 0x54]
fstp dword [edi - 0xc0]
jl 0x5061cc
cmp eax, 0x3e8
jl 0x5061c6
mov edx, dword [ebx + 0x27a0]
add edx, 0x3e8
cmp eax, edx
jl 0x5061cc
mov dword [edi], 0x3e8
fld dword [esi - 4]
fld1
fld st(0)
fsubrp st(2)
fxch st(1)
fstp dword [esi - 4]
mov eax, dword [edi]
cmp eax, 0x3e8
fld dword [esi - 0x20]
fadd dword [esp + 0x48]
fstp dword [esp + 0x48]
fld dword [esp + 0x48]
fstp dword [edi - 0x134a0]
fadd dword [esi - 0x14]
fmul dword [esi - 0x1c]
fstp dword [esp + 0x24]
jb 0x50621f
mov ecx, dword [ebx + 0x98]
shl eax, 5
mov edx, dword [eax + ecx - 0x7358]
fld dword [edx + 0x28]
fadd st(0), st(0)
fmul dword [esp + 0x24]
fstp dword [esp + 0x24]
movss xmm0, dword [esi - 0x20]
xorps xmm1, xmm1
ucomiss xmm0, xmm1
lahf
test ah, 0x44
jnp 0x50624a
fld dword [esp + 0x50]
fld dword [esp + 0x24]
fcompi st(1)
fstp st(0)
jbe 0x50624a
movss xmm0, dword [esp + 0x24]
movss dword [esp + 0x50], xmm0
add edi, 4
add esi, 0x30
sub dword [esp + 0x28], 1
jne 0x50613e
mov eax, dword [esp + 0x38]
test byte [eax], 1
mov eax, 0x3e7
jne 0x50626d
mov eax, dword [esp + 0x44]
mov edi, dword [esp + 0x30]
mov ecx, dword [esp + 0x2c]
mov dword [edi + 0x90], eax
fld dword [ecx]
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
call fcn.004ad260
fstp dword [esp + 0x30]
fld dword [esp + 0x30]
mov esi, dword [esp + 0x4c]
fstp dword [edi]
sub esp, 8
fld dword [esp + 0x30]
add esi, 1
fstp qword [esp]
push esi
push str.channel__d_density__f_n
call fcn.00408d10
movss xmm0, dword [edi]
xorps xmm1, xmm1
add esp, 0x10
ucomiss xmm0, xmm1
lahf
test ah, 0x44
movss dword [esp + 0x34], xmm0
jp 0x5062d0
movss dword [edi + 0x18], xmm1
jmp 0x506315
fld dword [esp + 0x34]
fld1
fdivrp st(1)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fld st(0)
fsub dword [esp + 0x50]
fstp dword [esp + 0x30]
fmul qword [0x6fa1a0]
fstp dword [esp + 0x28]
fld dword [esp + 0x30]
fld dword [esp + 0x28]
fcompi st(1)
fstp st(0)
jbe 0x50630a
movss xmm0, dword [esp + 0x28]
jmp 0x506310
movss xmm0, dword [esp + 0x30]
movss dword [edi + 0x18], xmm0
add dword [esp + 0x38], 0x190
add dword [esp + 0x40], 0xc
add dword [esp + 0x2c], 0x20
add edi, 4
mov dword [esp + 0x30], edi
xor edi, edi
cmp esi, 6
mov dword [esp + 0x4c], esi
jl 0x506060
movss xmm0, dword [0x6f99f8]
movaps xmm2, xmm0
mov dword [ebx + 0x27b0], edi
subss xmm2, dword [0x9d3630]
movss dword [0xaadd38], xmm2
mov edx, dword [0xaadd38]
movss dword [0xaadd44], xmm1
movaps xmm2, xmm0
subss xmm0, dword [0x9d3638]
subss xmm2, dword [0x9d3634]
movss dword [0xaadd40], xmm0
movss dword [0xaadd3c], xmm2
mov dword [ebx + 0x2818], edx
mov eax, dword [0xaadd3c]
mov dword [ebx + 0x281c], eax
mov ecx, dword [0xaadd40]
mov eax, dword [0x890338]
sub eax, edi
mov dword [ebx + 0x2820], ecx
movss xmm0, dword [ebx + 0x2818]
movss dword [esp + 0x10], xmm0
movss xmm0, dword [ebx + 0x281c]
movss dword [esp + 0x14], xmm0
movss xmm0, dword [ebx + 0x2820]
movss dword [esp + 0x18], xmm0
movss dword [esp + 0x1c], xmm1
movaps xmm1, xmmword [esp + 0x10]
movaps xmm0, xmm1
mulps xmm0, xmm1
movaps xmm2, xmm0
shufps xmm2, xmm0, 0x55
movaps xmm3, xmm0
shufps xmm3, xmm0, 0
shufps xmm0, xmm0, 0xaa
addps xmm2, xmm3
addps xmm2, xmm0
xorps xmm3, xmm3
sqrtps xmm2, xmm2
divps xmm1, xmm2
movaps xmm0, xmm3
cmpltps xmm0, xmm2
andps xmm1, xmm0
andnps xmm0, xmm3
orps xmm1, xmm0
movss dword [ebx + 0x2818], xmm1
movaps xmm0, xmm1
shufps xmm0, xmm1, 0x55
movss dword [ebx + 0x281c], xmm0
movss xmm0, dword [0x6d54cc]
shufps xmm1, xmm1, 0xaa
movss dword [ebx + 0x2820], xmm1
movss dword [ebx + 0x2798], xmm0
movss xmm0, dword [0x6fa9d8]
movss dword [ebx + 0x6e90], xmm0
movss xmm0, dword [0x6cc5ec]
mov dword [ebx + 0x27f4], edi
mov dword [ebx + 0x27f8], edi
mov dword [ebx + 0x27fc], edi
mov dword [ebx + 0x2800], edi
mov dword [ebx + 0x6e94], 1
mov dword [ebx + 0x27dc], edi
mov dword [ebx + 0x6e7c], edi
movss dword [esp + 0x24], xmm0
je 0x5064be
sub eax, 1
je 0x5064b4
sub eax, 2
jne 0x5064cc
movss xmm0, dword [0x6d54e8]
jmp 0x5064c6
movss xmm0, dword [0x6f9b34]
jmp 0x5064c6
movss xmm0, dword [0x6cc5e8]
movss dword [esp + 0x24], xmm0
fld dword [esp + 0x24]
call fcn.004ad260
fstp dword [esp + 0x34]
fld dword [esp + 0x34]
movss xmm0, dword [0x6cc5e8]
comiss xmm0, dword [esp + 0x24]
fstp dword [esp + 0x34]
fld dword [esp + 0x34]
fst dword [ebx + 0x6e88]
fstp dword [ebx + 0x6e8c]
fld dword [esp + 0x24]
fmul qword [0x6f9d50]
fstp dword [ebx + 0x6e90]
jb 0x506516
mov dword [ebx + 0x6e94], edi
push 0x200
lea eax, [ebx + 0x40c4]
mov dword [ebx + 0x15a00], edi
mov dword [ebx + 0x15a04], edi
mov dword [ebx + 0x159ac], edi
mov dword [ebx + 0x11b28], edi
mov dword [ebx + 0x15b98], edi
lea ecx, [ebx + 0x44c4]
push edi
lea esi, [ebx + 0x42c4]
push eax
mov dword [0xa6f9f4], eax
mov dword [0xa6f9f8], esi
mov dword [0xa6f9fc], ecx
call fcn.004ae0b0
add esp, 0xc
push 0x200
push edi
push esi
call fcn.004ae0b0
add esp, 0xc
push 0x200
lea eax, [ebx + 0x44c4]
push edi
push eax
call fcn.004ae0b0
mov esi, dword [esp + 0x48]
mov dword [ebx + 0x27a4], esi
mov dword [esi + 0x70], edi
mov edx, dword [ebx + 0x98]
mov eax, dword [edx + 0xc]
mov dword [esi + 0x54], eax
fild dword [esi + 0x54]
fld1
mov ecx, dword [ebx + 0x98]
fdivrp st(1)
mov edx, dword [ecx + 0x10]
xorps xmm0, xmm0
mov dword [esi + 0x58], edx
mov dword [esi + 0x64], edi
movss dword [esi + 0x3c], xmm0
movss dword [esi + 0x60], xmm0
add esp, 0xc
fstp dword [esi + 0x5c]
mov eax, dword [ebx + 0x98]
mov eax, dword [eax + 8]
cmp eax, edi
mov dword [esi + 0x50], eax
je 0x5065f3
mov ecx, dword [eax + 0x14]
and ecx, 0xffffff01
or ecx, 1
mov dword [eax + 0x14], ecx
mov ecx, 3
mov dword [eax + 0x18], ecx
mov dword [eax + 0x1c], ecx
movss xmm0, dword [0x6cc5ec]
movss dword [esi + 0x44], xmm0
movss xmm0, dword [0x6fa9d4]
movss dword [esi + 0x48], xmm0
movss xmm0, dword [0x6fa9d0]
movss dword [esi + 0x38], xmm0
movss xmm0, dword [0x6e5b1c]
movss dword [esi + 0x40], xmm0
lea eax, [ebx + 0x2824]
mov dword [0xa6f9e8], eax
mov dword [0xa6f9ec], eax
mov eax, dword [ebp + 0x1c]
cmp eax, edi
lea edx, [ebx + 0x37c4]
mov dword [0xa6f9f0], edx
mov dword [ebx + 0x159e4], edi
je 0x5067d2
mov ecx, dword [0x93d970]
push edi
mov dword [ebx + 0x5680], edi
mov edx, dword [ecx]
push edi
push eax
mov eax, dword [edx + 0x1c]
call eax
cmp eax, edi
mov dword [esp + 0x28], eax
je 0x5067d2
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 8]
call eax
cmp eax, edi
mov dword [esp + 0x34], eax
jbe 0x5067d2
cmp dword [0x9d3e94], edi
jne 0x506699
mov dword [esp + 0x2c], edi
jmp 0x5066bd
mov esi, dword [ebp + 0xc]
push 0x9f8
push 0x6b4a40
push 0x10
mov edi, eax
call fcn.00589980
mov esi, dword [esp + 0x3c]
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x34]
xor edi, edi
mov ecx, dword [esp + 0x28]
mov edx, dword [ecx]
mov edx, dword [edx + 0x10]
push eax
mov eax, dword [esp + 0x30]
push eax
call edx
mov ecx, dword [esp + 0x28]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
call edx
mov eax, dword [ebp + 0x10]
mov ecx, dword [esp + 0x2c]
push eax
push ecx
push ebx
call fcn.005049e0
test eax, eax
je 0x5067d2
mov edx, dword [esi + 0x1c]
mov eax, dword [esi + 0x18]
push edx
push eax
push str.loaded_chunks:_landscape__d_track__d_n
call fcn.00408d10
mov ecx, dword [ebx + 0x159ec]
add esp, 0xc
push ecx
push str.Total_instances:__d_n
call fcn.00408d10
mov eax, dword [ebx + 0x6ea0]
add esp, 8
shl eax, 4
cmp dword [0x9d3e94], edi
jne 0x50672e
xor eax, eax
jmp 0x50674a
mov esi, dword [ebp + 0xc]
push 0xa0d
push 0x6b4a9c
push 0x10
mov edi, eax
call fcn.00589980
mov esi, dword [esp + 0x3c]
xor edi, edi
mov edx, dword [ebx + 0x27a4]
mov dword [ebx + 0x15b90], eax
mov ecx, dword [edx + 0x20]
xor edx, edx
cmp dword [ebx + 0x6ea0], edi
jle 0x50678a
mov edi, dword [ecx]
mov dword [eax], edi
mov edi, dword [ecx + 4]
mov dword [eax + 4], edi
mov edi, dword [ecx + 8]
mov dword [eax + 8], edi
mov edi, dword [ecx + 0xc]
mov dword [eax + 0xc], edi
add edx, 1
add eax, 0x10
add ecx, 0x60
cmp edx, dword [ebx + 0x6ea0]
jl 0x506763
mov eax, dword [esp + 0x2c]
xorps xmm0, xmm0
mov dword [ebx + 0x159e4], eax
mov eax, 1
mov dword [esi + 0x4c], eax
movss dword [esi + 0x28], xmm0
movss dword [esi + 0x2c], xmm0
lea ecx, [esi + 0x80]
mov dword [esi + 0x30], ecx
lea edx, [esi + 0x480]
mov dword [esi + 0x34], edx
mov ecx, dword [ebx + 0x90]
mov dword [ebx + ecx*4 + 0x10], esi
add dword [ebx + 0x90], eax
mov eax, esi
call fcn.00502d70
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0x18