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

Disassembly:
sub esp, 0x1c
push ebx
push ebp
mov ebx, ecx
mov eax, dword [ebx + 0x60]
xor ebp, ebp
cmp eax, ebp
push esi
push edi
mov dword [esp + 0x1c], ebp
mov dword [esp + 0x18], ebp
jne 0x508b8f
cmp dword [ebx + 0x64], ebp
je 0x508bab
mov eax, dword [ebx + 0x2c]
mov esi, 1
push esi
push eax
mov eax, dword [ebx + 0x28]
mov ecx, dword [eax + 0xc20]
call fcn.00513180
test eax, eax
je 0x508bad
xor esi, esi
mov edi, dword [ebx + 0x68]
push edi
mov dword [esp + 0x24], edi
call dword [0x5f62b4]
mov ecx, dword [ebx + 0x68]
mov edx, dword [ebx + 0x50]
cmp edx, dword [ecx + 0x40]
je 0x508bd6
mov ecx, ebx
call fcn.00508a00
mov eax, dword [ebx + 0x68]
mov ecx, dword [eax + 0x40]
mov dword [ebx + 0x50], ecx
cmp esi, ebp
mov ecx, ebx
je 0x509075
call fcn.00507fb0
mov edx, dword [ebx + 0x68]
push edx
lea ecx, [esp + 0x28]
call fcn.00507060
cmp dword [esp + 0x24], ebp
je 0x50907a
mov eax, dword [ebx + 0x68]
mov ecx, dword [eax + 0x78]
cmp ecx, dword [ebx + 0x3c]
jbe 0x508c5d
cmp dword [eax + 0x7c], ebp
je 0x508c5d
mov dword [ebx + 0x3c], ecx
cmp dword [ebx + 0x60], ebp
je 0x508c19
cmp dword [eax + 0x34], ebp
jne 0x508c79
mov esi, dword [ebx + 0x64]
cmp esi, ebp
mov byte [esp + 0x10], 0
je 0x508c7e
mov eax, dword [esi + 4]
cmp word [eax + 0xc], 2
jne 0x508c55
mov ecx, dword [eax + 0x50]
call fcn.0052ad40
test al, al
jne 0x508c4d
mov ecx, dword [esi + 4]
add ecx, 0x1d0
call fcn.0051f640
test al, al
je 0x508c55
mov eax, dword [esi + 4]
cmp dword [eax + 0x10], ebp
jne 0x508c79
mov esi, dword [esi]
cmp esi, ebp
jne 0x508c25
jmp 0x508c7e
lea ecx, [esp + 0x24]
call fcn.005070c0
push edi
call dword [0x5f62b0]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1c
ret 8
mov byte [esp + 0x10], 1
mov ecx, dword [ebx + 0x68]
mov eax, dword [ecx + 0x28]
mov edi, 0x64
xor esi, esi
cmp eax, edi
je 0x508cc9
mov ecx, dword [ebx + 0x2c]
push str.onActivity
call fcn.004a9e10
mov ecx, dword [ebx + 0x24]
mov esi, eax
neg esi
sbb esi, esi
neg esi
cmp ecx, ebp
je 0x508cc9
mov edx, dword [ecx + 8]
mov eax, dword [edx + 0x18]
mov edx, dword [eax + 0x10]
mov eax, dword [edx + 0x38c]
push eax
call fcn.005386f0
test al, al
je 0x508cc9
mov esi, 1
mov al, byte [esp + 0x10]
test al, al
jne 0x508cd9
cmp esi, ebp
je 0x508f8f
mov ecx, ebx
call fcn.00507340
mov ecx, dword [ebx + 0x68]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x14], 0xffffffff
mov edx, dword [ecx + 0x7c]
mov ecx, dword [ebx + 0x54]
push eax
push edx
call fcn.0049be80
mov esi, dword [ebx + 0x64]
cmp esi, ebp
je 0x508ecc
jmp 0x508d10
mov eax, dword [esi + 4]
cmp word [eax + 0xc], 2
jne 0x508ebd
mov ecx, dword [eax + 0x50]
call fcn.0052ad40
test al, al
jne 0x508d40
mov ecx, dword [esi + 4]
add ecx, 0x1d0
call fcn.0051f640
test al, al
je 0x508ebd
mov eax, dword [esi + 4]
cmp dword [eax + 0x10], ebp
je 0x508ebd
cmp dword [eax + 0xf4], ebp
jne 0x508d76
push 0x50
call fcn.005dd330
add esp, 4
cmp eax, ebp
je 0x508d6b
mov ecx, eax
call fcn.0049be90
jmp 0x508d6d
xor eax, eax
mov ecx, dword [esi + 4]
mov dword [ecx + 0xf4], eax
mov edx, dword [esi + 4]
mov ecx, dword [edx + 0xf4]
mov eax, dword [ecx]
lea edx, [esp + 0x14]
push edx
mov edx, dword [ebx + 0x54]
push edx
call dword [eax + 4]
mov edi, eax
cmp edi, ebp
je 0x508ebd
mov eax, dword [esi + 4]
mov ecx, dword [eax + 0x10]
push ecx
mov ecx, edi
call fcn.0052cb00
movzx eax, byte [edi + 0xd]
movzx ecx, byte [edi + 0xe]
xor edx, edx
mov dh, byte [edi + 0xf]
mov dl, byte [edi + 0xc]
shl edx, 8
or edx, eax
shl edx, 8
or edx, ecx
mov ecx, dword [esi + 4]
push edx
add ecx, 0x32c
call fcn.0051f970
push eax
mov ecx, edi
call fcn.0052cad0
mov eax, dword [esi + 4]
cmp dword [eax + 0xfc], 1
jne 0x508e54
mov ecx, dword [eax + 0xf8]
test ecx, ecx
jle 0x508e47
push 0x18
call fcn.005dd330
add esp, 4
test eax, eax
je 0x508e07
push 1
mov ecx, eax
call fcn.0052ca20
mov ebp, eax
jmp 0x508e09
xor ebp, ebp
push 1
mov ecx, ebp
call fcn.0052cab0
mov ecx, edi
mov byte [ebp + 8], 9
call fcn.00506bd0
mov edx, dword [esi + 4]
add eax, dword [edx + 0xf8]
push eax
mov ecx, ebp
call fcn.0052cad0
mov eax, dword [ebx + 0x68]
mov ecx, dword [ebp + 0x14]
mov dl, byte [eax + 0x38]
mov byte [ecx], dl
mov eax, dword [esi + 4]
mov ecx, dword [eax + 0x10]
push ecx
mov ecx, ebp
call fcn.0052cb00
mov edx, dword [esi + 4]
mov dword [edx + 0xfc], 2
mov ecx, dword [esi + 4]
add ecx, 0x1d0
call fcn.0051f640
test al, al
je 0x508e8a
mov ecx, dword [esi + 4]
push edi
add ecx, 0x1d0
call fcn.00523290
test ebp, ebp
je 0x508eb1
mov ecx, dword [esi + 4]
push ebp
add ecx, 0x1d0
call fcn.00523290
jmp 0x508eb1
mov eax, dword [esi + 4]
mov ecx, dword [eax + 0x50]
call fcn.0052ad20
mov ecx, dword [esi + 4]
push edi
add ecx, 0x50
call fcn.0050ca00
test ebp, ebp
je 0x508eb1
mov ecx, dword [esi + 4]
push ebp
add ecx, 0x50
call fcn.0050ca00
mov ecx, dword [esi + 4]
push 1
call fcn.00520130
xor ebp, ebp
mov esi, dword [esi]
cmp esi, ebp
jne 0x508d10
mov edi, 0x64
cmp dword [ebx + 0x58], ebp
jne 0x508ed8
cmp dword [esp + 0x14], 0xffffffff
jne 0x508f37
cmp dword [ebx + 0x5c], ebp
jne 0x508ef9
push 0x50
call fcn.005dd330
add esp, 4
cmp eax, ebp
je 0x508ef4
mov ecx, eax
call fcn.0049be90
jmp 0x508ef6
xor eax, eax
mov dword [ebx + 0x5c], eax
mov ecx, dword [ebx + 0x5c]
mov edx, dword [ecx]
lea eax, [esp + 0x14]
push eax
mov eax, dword [ebx + 0x54]
push eax
call dword [edx + 4]
mov esi, eax
cmp dword [ebx + 0x58], ebp
je 0x508f23
cmp esi, ebp
mov dword [esp + 0x1c], esi
jne 0x508f37
mov dword [esp + 0x18], 1
jmp 0x508f37
cmp esi, ebp
je 0x508f37
mov ecx, esi
call fcn.0052ca80
push esi
call fcn.005dd350
add esp, 4
mov edx, dword [esp + 0x14]
mov ecx, edi
sub ecx, edx
imul ecx, ecx, 0x64
mov eax, 0x88888889
imul ecx
add edx, ecx
sar edx, 5
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp eax, edi
mov dword [ebx + 0x40], eax
jle 0x508f5f
mov dword [ebx + 0x40], edi
cmp dword [ebx + 0x40], ebp
jge 0x508f67
mov dword [ebx + 0x40], ebp
mov ecx, dword [ebx + 0x68]
cmp dword [ecx + 0x28], edi
je 0x508f8f
mov edx, dword [esp + 0x30]
mov dword [edx], 1
mov eax, dword [ebx + 0x68]
mov esi, dword [eax + 0x28]
mov ecx, dword [ebx + 0x40]
mov eax, dword [esp + 0x34]
xor edx, edx
cmp ecx, esi
setge dl
mov dword [eax], edx
lea esi, [ebx + 0x64]
mov edi, 2
mov eax, dword [esi]
cmp eax, ebp
je 0x508fb1
lea ecx, [ecx]
mov ecx, dword [eax + 4]
cmp dword [ecx + 0xfc], edi
je 0x508fed
mov eax, dword [eax]
cmp eax, ebp
jne 0x508fa0
cmp dword [esp + 0x18], ebp
je 0x509003
mov edi, dword [esp + 0x28]
lea esi, [edi + 0x84]
push esi
call dword [0x5f62b4]
push esi
mov esi, dword [0x5f62b0]
mov dword [edi + 0x9c], ebp
call esi
mov ecx, dword [esp + 0x20]
push ecx
call esi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x1c
ret 8
mov edx, dword [eax + 4]
mov dword [edx + 0xfc], ebp
mov eax, dword [eax + 4]
push eax
mov ecx, esi
call fcn.005093f0
jmp 0x508f97
mov esi, dword [esp + 0x1c]
cmp esi, ebp
je 0x50901e
movzx edx, byte [esi + 0xb]
xor eax, eax
mov ah, byte [esi + 9]
mov al, byte [esi + 0xa]
shl eax, 8
or eax, edx
jmp 0x509023
mov eax, 1
mov ecx, dword [ebx + 0x68]
fld qword [ecx + 0x58]
sub esp, 8
fstp qword [esp]
push eax
lea ecx, [ebx + 0x44]
call fcn.00506c40
push esi
mov ecx, ebx
call fcn.00507af0
mov ebx, dword [esp + 0x28]
lea esi, [ebx + 0x84]
push esi
mov edi, eax
call dword [0x5f62b4]
push esi
mov esi, dword [0x5f62b0]
mov dword [ebx + 0x9c], ebp
call esi
mov edx, dword [esp + 0x20]
push edx
call esi
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1c
ret 8
call fcn.00508a00
push edi
call dword [0x5f62b0]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x1c
ret 8