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

Disassembly:
push 0xffffffffffffffff
push 0x458ec0
mov eax, dword fs:[0]
push eax
sub esp, 0x54
push ebx
push ebp
push esi
push edi
mov eax, dword [0x477c1c]
xor eax, esp
push eax
lea eax, [esp + 0x68]
mov dword fs:[0], eax
mov esi, ecx
mov eax, dword [esi + 0x9fc]
push str.download
push str.anonymous
lea edi, [esi + 0x79c]
push eax
mov ecx, edi
call fcn.00403dd0
push 2
mov ecx, edi
call fcn.00404610
test al, al
jne 0x409dd0
push 0
call dword [sym.imp.USER32.dll_PostQuitMessage]
mov ecx, dword [esp + 0x68]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret
mov eax, dword [esi + 0x55c]
mov edi, dword [sym.imp.USER32.dll_SendMessageA]
push 0x640000
xor ebx, ebx
push ebx
push 0x401
push eax
call edi
mov ecx, dword [esi + 0x55c]
push ebx
push ebx
push 0x402
push ecx
call edi
lea ecx, [esp + 0x1c]
call fcn.00403280
mov dword [esp + 0x70], ebx
lea ecx, [esp + 0x18]
call fcn.00403280
mov byte [esp + 0x70], 1
cmp dword [esi + 0xa04], ebx
mov byte [esp + 0x15], 1
mov dword [esp + 0x28], ebx
jle 0x40a1e4
lea ebp, [esi + 0xa08]
lea eax, [esi + 0xa00]
push eax
lea ecx, [esp + 0x20]
call fcn.00407890
push 1
push 0x45fb98
lea ecx, [esp + 0x24]
call fcn.004076c0
mov eax, dword [ebp]
mov ecx, dword [eax - 0xc]
push ecx
push eax
lea ecx, [esp + 0x24]
call fcn.004076c0
mov eax, dword [ebp]
mov edx, dword [esp + 0x1c]
push 2
push eax
push edx
lea ecx, [esi + 0x79c]
call fcn.00404bc0
cmp al, bl
jne 0x409f94
cmp dword [esi + 0xca4], ebx
jne 0x40a1e0
xor edi, edi
nop
lea ecx, [esp + 0x20]
call fcn.00403280
mov byte [esp + 0x70], 2
push 0x69
call fcn.0042be72
cmp eax, ebx
je 0x409eb5
push 0x69
push eax
lea ecx, [esp + 0x28]
call fcn.004041d0
mov eax, dword [esp + 0x20]
inc edi
push edi
push eax
lea ecx, [esp + 0x28]
push str._s__d_
push ecx
mov dword [esp + 0x3c], edi
call fcn.00403430
mov ecx, dword [esp + 0x30]
mov eax, ecx
add esp, 0x10
mov dword [esp + 0x64], 0xf
mov dword [esp + 0x60], ebx
mov byte [esp + 0x50], bl
lea edi, [eax + 1]
jmp 0x409ef0
mov dl, byte [eax]
inc eax
cmp dl, bl
jne 0x409ef0
sub eax, edi
push eax
push ecx
lea ecx, [esp + 0x54]
call fcn.00401da0
mov byte [esp + 0x70], 3
lea edx, [esp + 0x4c]
push edx
mov ecx, esi
call fcn.00406ec0
mov byte [esp + 0x70], 2
cmp dword [esp + 0x64], 0x10
jb 0x409f2e
mov eax, dword [esp + 0x50]
push eax
call fcn.00421b49
add esp, 4
mov eax, dword [ebp]
mov ecx, dword [esp + 0x1c]
push 2
push eax
push ecx
lea ecx, [esi + 0x79c]
mov dword [esp + 0x70], 0xf
mov dword [esp + 0x6c], ebx
mov byte [esp + 0x5c], bl
call fcn.00404bc0
mov byte [esp + 0x17], al
mov byte [esp + 0x70], 1
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x409f7d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov edi, dword [esp + 0x2c]
cmp edi, 6
jl 0x409e90
cmp byte [esp + 0x17], bl
je 0x40a1aa
lea edi, [esi + 0x9f4]
push edi
lea ecx, [esp + 0x1c]
call fcn.00407890
push 1
push 0x45ecf4
lea ecx, [esp + 0x20]
call fcn.004076c0
mov eax, dword [ebp]
mov ecx, dword [eax - 0xc]
push ecx
push eax
lea ecx, [esp + 0x20]
call fcn.004076c0
push 0x68
mov ecx, esi
call fcn.00407910
mov ecx, esi
mov byte [esp + 0x16], bl
call fcn.00406190
test al, al
je 0x40a1e0
push ecx
lea edx, [esp + 0x1c]
mov ecx, esp
mov dword [esp + 0x30], esp
push edx
call fcn.00404170
mov byte [esp + 0x74], 5
mov byte [esp + 0x74], 1
mov ecx, esi
call fcn.00407120
cmp al, bl
je 0x40a1e0
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x48], esp
push 0x10
mov dword [ecx + 0x18], 0xf
mov dword [ecx + 0x14], ebx
push str.knightonline.exe
mov byte [ecx + 4], bl
call fcn.00401da0
mov byte [esp + 0x8c], 6
lea eax, [esp + 0x32]
push eax
push ecx
mov ecx, esp
mov dword [esp + 0x5c], esp
push edi
call fcn.00404170
mov byte [esp + 0x94], 7
mov byte [esp + 0x94], 1
mov ecx, esi
call fcn.00407e50
cmp al, bl
je 0x40a1e0
mov ecx, esi
call fcn.00406190
test al, al
je 0x40a1e0
lea ecx, [esp + 0x3c]
call fcn.00429834
mov byte [esp + 0x70], 8
mov ecx, dword [esp + 0x18]
push ebx
push 0x40
push ecx
lea ecx, [esp + 0x48]
call fcn.00429c2f
test eax, eax
je 0x40a196
lea ecx, [esp + 0x3c]
call fcn.004297ce
mov edx, dword [esp + 0x18]
push edx
call fcn.004294c6
lea ecx, [esp + 0x24]
call fcn.00403280
mov byte [esp + 0x70], 9
mov eax, dword [ebp + 0x80]
push eax
lea ecx, [esp + 0x28]
push 0x45fb78
push ecx
call fcn.00403430
push str.Server.ini
lea edx, [esp + 0x40]
push edi
push edx
call fcn.00404740
add esp, 0x18
mov byte [esp + 0x70], 0xa
mov eax, dword [eax]
push eax
mov eax, dword [esp + 0x28]
push eax
push str.Files
push str.Version
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov byte [esp + 0x70], 9
lea ecx, [esp + 0x30]
call fcn.004032f0
cmp byte [esp + 0x16], bl
je 0x40a155
push str.Server.ini
lea ecx, [esp + 0x38]
push edi
push ecx
call fcn.00404740
add esp, 0xc
mov byte [esp + 0x70], 0xb
mov eax, dword [eax]
mov edx, dword [esp + 0x24]
push eax
push edx
push str.Last
push str.IncludeExe
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov byte [esp + 0x70], 9
lea ecx, [esp + 0x34]
call fcn.004032f0
mov byte [esp + 0x70], 8
lea ecx, [esp + 0x24]
call fcn.004032f0
mov byte [esp + 0x70], 1
lea ecx, [esp + 0x3c]
call fcn.0042990f
lea ecx, [esi + 0x53c]
call fcn.00403950
mov eax, dword [esp + 0x28]
inc eax
add ebp, 4
cmp eax, dword [esi + 0xa04]
mov dword [esp + 0x28], eax
jl 0x409e32
jmp 0x40a1e4
mov byte [esp + 0x15], bl
mov byte [esp + 0x70], 1
lea ecx, [esp + 0x3c]
call fcn.0042990f
jmp 0x40a1e4
cmp dword [esi + 0xca4], ebx
jne 0x40a1e0
lea ecx, [esi + 0x79c]
call fcn.00403e20
push 0x67
mov ecx, esi
call fcn.00407910
push 1
lea ecx, [esi + 0xec]
call fcn.0042ab52
push 1
lea ecx, [esi + 0x160]
call fcn.0042ab52
mov byte [esp + 0x15], bl
lea ecx, [esi + 0x79c]
call fcn.00403e20
cmp byte [esp + 0x15], 1
jne 0x40a31e
lea ecx, [esp + 0x24]
call fcn.00403280
mov byte [esp + 0x70], 0xc
mov eax, dword [esi + 0x9f8]
push eax
lea ecx, [esp + 0x28]
push 0x45fb78
push ecx
call fcn.00403430
push str.Server.ini
lea edx, [esi + 0x9f4]
push edx
lea eax, [esp + 0x48]
push eax
call fcn.00404740
add esp, 0x18
mov byte [esp + 0x70], 0xd
mov eax, dword [eax]
mov ecx, dword [esp + 0x24]
push eax
push ecx
push str.Files
push str.Version
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov byte [esp + 0x70], 0xc
mov eax, dword [esp + 0x34]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40a279
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 0x7c
mov ecx, esi
call fcn.00407910
mov ecx, dword [esi + 0x55c]
push ebx
push 0x64
push 0x402
push ecx
call dword [sym.imp.USER32.dll_SendMessageA]
cmp dword [esi + 0xcf4], ebx
jne 0x40a2c3
push 1
lea ecx, [esi + 0x78]
call fcn.0042ab52
push 1
lea ecx, [esi + 0xec]
call fcn.0042ab52
push 1
lea ecx, [esi + 0x160]
call fcn.0042ab52
cmp byte [esi + 0xecd], bl
je 0x40a2d2
mov ecx, esi
call fcn.00408570
cmp dword [esi + 0xcf4], ebx
je 0x40a2f7
push 0x8a
mov ecx, esi
call fcn.00407910
mov edx, dword [esi + 0x20]
push ebx
push ebx
push 0x403
push edx
call dword [sym.imp.USER32.dll_PostMessageA]
mov byte [esp + 0x70], 1
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a349
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
jmp 0x40a349
cmp dword [esi + 0xca4], ebx
jne 0x40a349
push 0x67
mov ecx, esi
call fcn.00407910
push 1
lea ecx, [esi + 0xec]
call fcn.0042ab52
push 1
lea ecx, [esi + 0x160]
call fcn.0042ab52
mov byte [esp + 0x70], bl
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a36d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x70], 0xffffffff
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a395
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x68]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret