Function at 0x40dd80
Capabilities:
Get geographical location

Disassembly:
mov ecx, dword fs:[0x14]
mov ecx, dword [ecx]
cmp esp, dword [ecx + 8]
jbe 0x40e074
sub esp, 0x34
mov eax, dword [esp + 0x3c]
test eax, eax
je 0x40e05b
movzx ecx, byte [eax + 4]
test cl, 4
jne 0x40e045
mov ecx, dword [esp + 0x38]
mov edx, dword [ecx + 0x2c]
mov ebx, dword [eax + 8]
lea ebp, [esp + 0x40]
mov dword [esp], ebp
mov dword [esp + 4], ebx
mov ebx, dword [edx]
call ebx
mov eax, dword [esp + 8]
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x3c]
movzx ebx, byte [ecx + 4]
xor ebx, 4
mov byte [ecx + 4], bl
mov ebx, dword [ecx + 0xc]
test ebx, ebx
je 0x40dfe1
mov edx, dword [esp + 0x38]
jmp 0x40de89
inc eax
mov esi, dword [esp + 0x20]
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x18]
mov eax, dword [esp + 0x14]
cmp eax, 8
jae 0x40df8e
test byte [ebx], al
movzx esi, byte [ebx + eax]
xchg esi, eax
cmp al, 1
xchg esi, eax
ja 0x40df6b
test ecx, ecx
je 0x40df62
xchg esi, eax
test al, al
xchg esi, eax
jne 0x40ddf5
mov dword [esp + 0x10], edi
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x30], ebx
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x40dedc
mov eax, dword [ebp]
inc eax
movzx esi, byte [ebp + 5]
cmp eax, 8
jle 0x40df5b
mov ecx, esi
mov ebx, 1
shl ebx, cl
shr ebx, 1
lea edi, [ebx + ebx*2]
lea ebx, [ebx + edi*4]
cmp eax, ebx
jbe 0x40debf
mov dword [esp], edx
mov dword [esp + 4], ebp
call fcn.0040ce50
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x3c]
mov edx, dword [esp + 0x18]
mov eax, edx
mov edx, dword [esp + 0x38]
movzx ebx, byte [ecx + 5]
mov ebp, ecx
mov ecx, ebx
mov esi, 1
shl esi, cl
lea ebx, [esi - 1]
and ebx, eax
mov esi, dword [ebp + 0x10]
test esi, esi
jne 0x40dfb8
movzx esi, word [edx + 0x32]
mov dword [esp + 0x20], esi
imul ebx, esi
add ebx, dword [ebp + 0xc]
xor ecx, ecx
xor edi, edi
jmp 0x40df9e
movzx eax, word [ebp + 6]
cmp cl, 0xf
jbe 0x40decd
mov ecx, 0xf
and ecx, 0xf
mov ebx, 1
shl ebx, cl
cmp ax, bx
jae 0x40de6b
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x40df37
mov ecx, dword [esp + 0x10]
mov ebx, dword [esp + 0x18]
shr ebx, 0x18
cmp bl, 5
jae 0x40def7
add ebx, 5
test byte [eax], al
mov esi, ecx
and ecx, 7
mov byte [eax + ecx], bl
mov ecx, eax
lea eax, [eax + esi*4 + 8]
nop
mov ebx, dword [esp + 0x40]
mov dword [eax], ebx
inc dword [ebp]
movzx eax, byte [edx + 0x31]
imul esi, eax
movzx eax, byte [ebp + 4]
lea ecx, [esi + ecx + 0x28]
test al, 4
je 0x40e02f
and eax, 0xfffffffb
mov byte [ebp + 4], al
mov dword [esp + 0x44], ecx
add esp, 0x34
ret
mov dword [esp], ebp
mov dword [esp + 4], edx
mov eax, dword [esp + 0x30]
mov dword [esp + 8], eax
call fcn.0040b270
mov eax, dword [esp + 0xc]
mov edx, dword [esp + 0x38]
mov ebp, dword [esp + 0x3c]
xor ecx, ecx
jmp 0x40dee8
mov ecx, esi
jmp 0x40debf
mov ecx, ebx
mov edi, eax
jmp 0x40de28
mov esi, ebx
lea ebx, [ebx + eax*4 + 8]
mov ebp, dword [esp + 0x40]
cmp dword [ebx], ebp
je 0x40df84
mov ebx, esi
mov ebp, dword [esp + 0x3c]
jmp 0x40ddf5
mov ebp, dword [esp + 0x3c]
mov ecx, esi
mov esi, eax
jmp 0x40df11
mov eax, ebx
lea ebx, [ebx + esi - 4]
mov ebx, dword [ebx]
test ebx, ebx
je 0x40dfb1
mov eax, dword [esp + 0x18]
mov dword [esp + 0x24], eax
xor eax, eax
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x24]
jmp 0x40de02
mov ebx, eax
jmp 0x40de2e
mov dword [esp + 0x1c], ebx
mov dword [esp], edx
mov dword [esp + 4], ebp
mov dword [esp + 8], ebx
call fcn.0040e640
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0x38]
mov ebx, dword [esp + 0x1c]
mov ebp, dword [esp + 0x3c]
jmp 0x40dea8
mov eax, dword [esp + 0x38]
mov ecx, dword [eax + 0x28]
mov edx, dword [ecx]
mov dword [esp], edx
mov dword [esp + 4], ecx
mov byte [esp + 8], 1
call fcn.0040a100
mov eax, dword [0xb53500]
mov ecx, dword [esp + 0xc]
test eax, eax
jne 0x40e01d
mov eax, dword [esp + 0x3c]
mov dword [eax + 0xc], ecx
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x3c]
jmp 0x40ddec
mov edx, dword [esp + 0x3c]
lea edi, [edx + 0xc]
mov eax, ecx
call fcn.00459620
mov eax, edx
jmp 0x40e010
lea eax, [0x7ee3a5]
mov dword [esp], eax
mov dword [esp + 4], 0x15
call fcn.00430c90
lea eax, [0x7ee3a5]
mov dword [esp], eax
mov dword [esp + 4], 0x15
call fcn.00430c90
lea eax, [0x7885e0]
mov dword [esp], eax
lea eax, [0x873ca8]
mov dword [esp + 4], eax
call fcn.00430590
nop
call fcn.00457de0
jmp fcn.0040dd80