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

Disassembly:
sub esp, 0xc0
mov eax, dword [0x851c30]
mov ecx, dword [eax + 0x34]
mov eax, ebx
and eax, 0xffff
lea edx, [eax + eax*2]
push ebp
mov ebp, dword [ecx + edx*4 + 8]
mov eax, dword [ebp]
mov edx, dword [0x86cff4]
and eax, 0xffff
shl eax, 5
push esi
push edi
mov edi, dword [eax + edx + 0x14]
mov dword [esp + 0x18], 0x65016c
mov dword [esp + 0x1c], str.gravity
mov eax, dword [edi + 0x1b8]
mov dword [esp + 0x14], eax
test byte [edi + 0x17c], 8
mov dword [esp + 0xc], edi
je 0x4befa1
test byte [ebp + 0x22c], 0x40
jne 0x4befa1
mov eax, dword [ebp + 0x11c]
or esi, 0xffffffff
cmp eax, esi
je 0x4befa4
and eax, 0xffff
lea edx, [eax + eax*2]
mov edx, dword [ecx + edx*4 + 8]
mov eax, dword [edx + 0x118]
cmp eax, esi
mov dword [esp + 0x10], 0
mov dword [esp + 0x20], eax
je 0x4bee7e
nop
mov edi, dword [ebp]
and eax, 0xffff
lea eax, [eax + eax*2]
mov eax, dword [ecx + eax*4 + 8]
cmp dword [eax], edi
jne 0x4bee70
test byte [eax + 0x22c], 0x40
jne 0x4bee70
inc dword [esp + 0x10]
mov eax, dword [eax + 0x114]
cmp eax, esi
jne 0x4bee50
mov eax, dword [esp + 0x20]
mov edi, dword [esp + 0xc]
xor ecx, ecx
cmp word [edx + 0xb4], cx
jne 0x4befa4
cmp dword [edx + 0x218], esi
je 0x4beea5
cmp dword [0x6eb3c0], ecx
je 0x4befa4
cmp word [esp + 0x10], 6
jle 0x4befa4
mov esi, eax
cmp esi, 0xffffffff
je 0x4bef35
jmp 0x4beec0
mov eax, dword [0x851c30]
mov eax, dword [eax + 0x34]
and esi, 0xffff
lea edx, [esi + esi*2]
mov esi, dword [eax + edx*4 + 8]
mov edx, dword [esi]
cmp edx, dword [ebp]
jne 0x4bef2a
test byte [esi + 0x22c], 0x40
jne 0x4bef2a
cmp word [esp + 0x10], 6
jg 0x4bef1a
or dword [esi + 0x22c], 0x40
call fcn.004019f0
fmul dword [esi + 0x240]
fstp dword [esi + 0x240]
call fcn.004019f0
fmul dword [esi + 0x248]
xor ecx, ecx
fstp dword [esi + 0x248]
jmp 0x4bef26
mov dword [esi + 0x240], ecx
mov dword [esi + 0x248], ecx
dec dword [esp + 0x10]
mov esi, dword [esi + 0x114]
cmp esi, 0xffffffff
jne 0x4beec0
mov eax, dword [esp + 0xc]
mov ecx, dword [eax + 0x198]
mov dword [esp + 0x14], ecx
mov ecx, dword [ebp + 0x11c]
lea eax, [esp + 0xa4]
call fcn.004f24e0
push ebx
call fcn.004f21f0
lea edx, [ebp + 0x5c]
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov edx, dword [edx + 8]
add esp, 4
push 0
lea esi, [esp + 0xa8]
mov edi, ebx
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], ecx
mov dword [esp + 0x48], edx
call fcn.004f0f30
add esp, 4
push 0xffffffffffffffff
push ebx
lea ecx, [esp + 0x44]
call fcn.004f3750
push ebx
call fcn.004f3e90
mov edi, dword [esp + 0x18]
add esp, 0xc
or esi, 0xffffffff
mov al, byte [esp + 0xd0]
test al, al
je 0x4beff9
mov eax, dword [ebp + 0x23c]
cmp eax, esi
je 0x4beff9
cmp dword [ebp + eax*4 + 0x14c], esi
je 0x4beff9
push ebx
call fcn.004f3ef0
fld dword [0x66c410]
fsub dword [esp + 0xd8]
mov eax, dword [ebp + 0x23c]
mov edi, dword [ebp + eax*4 + 0x14c]
fmul dword [0x66c418]
fstp dword [esp]
push 0
call fcn.0044cae0
mov edi, dword [esp + 0x14]
add esp, 8
lea eax, [esp + 0x24]
mov ecx, ebx
call fcn.004f24e0
lea ecx, [esp + 0xa4]
push ecx
lea eax, [esp + 0xb4]
mov ecx, ebx
call fcn.004f2550
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0x30]
add esp, 4
push 1
push 0
mov dword [esp + 0x38], edx
mov edx, dword [0x69051c]
mov dword [esp + 0x40], ecx
push 0
mov dword [esp + 0x40], eax
mov eax, dword [edx]
push 0
mov dword [esp + 0xcc], eax
mov ecx, dword [edx + 4]
push 0
mov dword [esp + 0xd4], ecx
mov edx, dword [edx + 8]
lea eax, [esp + 0xc4]
push eax
mov dword [esp + 0xdc], edx
mov eax, dword [ebp + 0xc4]
lea ecx, [esp + 0x3c]
push ecx
mov ecx, dword [esp + 0x30]
lea edx, [esp + 0x34]
push edx
push 2
push 0
push eax
push ecx
call fcn.00450a00
mov eax, dword [ebp + 0x11c]
add esp, 0x30
cmp eax, esi
je 0x4bf169
mov edx, dword [edi + 0x220]
cmp edx, esi
je 0x4bf169
xor eax, eax
mov ecx, 0x15
lea edi, [esp + 0x48]
rep stosd dword es:[edi], eax
mov dword [esp + 0x48], edx
mov edx, dword [esp + 0x4c]
or edx, 8
push eax
lea eax, [esp + 0x80]
mov ecx, ebx
mov word [esp + 0x98], si
mov dword [esp + 0x54], esi
mov dword [esp + 0x58], esi
mov word [esp + 0x5c], si
mov word [esp + 0x64], si
mov dword [esp + 0x8c], 0x3f800000
mov dword [esp + 0x90], 0x3f800000
mov dword [esp + 0x50], edx
call fcn.004f2550
add esp, 4
lea eax, [esp + 0x64]
mov ecx, ebx
call fcn.004f24e0
mov edx, dword [esp + 0x64]
mov eax, dword [esp + 0x68]
mov ecx, dword [esp + 0x6c]
push 0
push esi
mov dword [esp + 0x78], edx
mov edx, dword [ebp + 0xc4]
mov dword [esp + 0x7c], eax
mov eax, dword [ebp + 0xc0]
push esi
mov dword [esp + 0x60], edx
mov edx, dword [ebp + 0x11c]
push esi
mov dword [esp + 0x60], eax
mov dword [esp + 0x88], ecx
mov cx, word [ebp + 0xb8]
push edx
lea eax, [esp + 0x5c]
push eax
mov word [esp + 0x70], cx
call fcn.004ea1a0
mov edi, dword [esp + 0x24]
add esp, 0x18
mov ax, word [ebp + 0x232]
cmp ax, si
je 0x4bf1cf
test ax, ax
jl 0x4bf197
mov ecx, dword [edi + 0x240]
movsx eax, ax
cmp eax, ecx
jge 0x4bf197
mov ecx, dword [edi + 0x244]
lea eax, [eax + eax*4]
shl eax, 5
add eax, ecx
jmp 0x4bf19c
mov eax, 0x68fcf0
mov eax, dword [eax + 0x74]
push 1
push 0
push 0
push 0
push 0
lea ecx, [esp + 0xc4]
push ecx
lea edx, [esp + 0x3c]
push edx
mov edx, dword [ebp + 0xc4]
lea ecx, [esp + 0x34]
push ecx
push 2
push 0
push edx
push eax
call fcn.00450a00
add esp, 0x30
xor ecx, ecx
mov cx, word [edi + 0x1f0]
push 1
lea edx, [esp + 0x28]
push ecx
push 2
push edx
push ebx
call fcn.0042c620
add esp, 0x14
pop edi
pop esi
pop ebp
add esp, 0xc0
ret