Function at 0x41a350
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x442560
mov eax, dword fs:[0]
push eax
sub esp, 0x224
mov eax, dword [0x456040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
lea ecx, [esi + 0x200]
mov byte [esi + 0xc84], 1
call fcn.0041ee40
mov edi, eax
test edi, edi
je 0x41a44e
lea eax, [esi + 0x434]
push eax
mov ecx, edi
call fcn.0041e9e0
test al, al
je 0x41a433
mov ebx, dword [edi + 0x218]
lea ecx, [esi + 0x10c8]
push ebx
add edi, 0x10
push edi
call fcn.00418400
cmp byte [esi + 0x13a4], 0
je 0x41a40c
push ebx
push edi
lea eax, [ebp - 0x22c]
push str.IN
push eax
call fcn.0041c740
add esp, 0x10
push eax
lea ecx, [esi + 0x1398]
mov dword [ebp - 4], 0
call fcn.00416d30
lea ecx, [ebp - 0x22c]
mov dword [ebp - 4], 0xffffffff
call fcn.004169b0
push ebx
push edi
mov ecx, esi
call fcn.0041b6f0
inc dword [esi + 0x1490]
call fcn.00401230
cmp byte [esi + 0x12e0], 0
mov dword [esi + 0xc80], eax
jne 0x41ac68
lea ecx, [esi + 0x200]
call fcn.0041ee40
mov edi, eax
lea eax, [esi + 0x434]
test edi, edi
jne 0x41a3a2
call fcn.00401230
mov ebx, eax
mov ecx, ebx
mov dword [ebp - 0x230], ebx
sub ecx, dword [esi + 0x12e4]
cmp ecx, 0x32
jb 0x41a482
lea ecx, [ecx + ecx*4]
add ecx, ecx
push ecx
push str.Slow_iteration_warning:__ims
push esi
call fcn.0041bf10
add esp, 0xc
mov dword [esi + 0xc80], ebx
mov eax, ebx
mov dword [esi + 0x12e4], ebx
sub eax, dword [esi + 0xc80]
cmp eax, 0xfa0
jbe 0x41a4c1
push str.Automatically_reconnecting_on_timeout...
push esi
call fcn.0041bf10
add esp, 8
mov ecx, esi
call fcn.0041cfd0
mov ecx, esi
call fcn.0041ce70
push 0
mov ecx, esi
call fcn.0041a090
jmp 0x41ac68
cmp byte [esi + 0xc87], 0
je 0x41a4f6
mov eax, dword [esi + 0x149c]
mov ecx, ebx
sub ecx, dword [esi + 0xc88]
shl eax, 4
cmp ecx, eax
jbe 0x41a4f6
push str.Retrying_connection...
push esi
call fcn.0041bf10
add esp, 8
mov ecx, esi
push 1
call fcn.0041a090
cmp byte [esi + 0x41ae7], 0
je 0x41a536
cmp byte [esi + 0xc8c], 0
je 0x41a51d
mov ecx, dword [esi + 0x149c]
mov eax, ebx
sub eax, dword [esi + 0xc90]
add ecx, 0xa
cmp eax, ecx
jmp 0x41a52d
call fcn.00401230
sub eax, dword [esi + 0xc90]
cmp eax, 0x7d0
jbe 0x41a536
mov ecx, esi
call fcn.0041d9c0
mov ecx, esi
call fcn.0041d590
cmp byte [esi + 0x41aec], 0
je 0x41a6df
mov ecx, dword [esi + 0x41510]
test ecx, ecx
je 0x41a6df
cmp byte [esi + 0x41aed], 0
je 0x41a594
movzx eax, word [esi + 0x141ff4]
mov ecx, ebx
sub ecx, dword [esi + 0x41afc]
cmp ecx, eax
jbe 0x41a6df
sub esp, 0x28
push esp
call fcn.00418020
mov ecx, dword [esi + 0x14b8]
add esp, 4
call fcn.00408b60
jmp 0x41a6df
cmp byte [ecx + 0x9d], 8
mov eax, dword [esi + 0x41afc]
movzx edx, word [esi + 0x141ff4]
jne 0x41a77d
mov ecx, ebx
sub ecx, eax
cmp ecx, edx
jbe 0x41a6df
cmp dword [esi + 0x41514], 0
jne 0x41a5d7
mov eax, dword [esi + 0x14fc]
mov dword [esi + 0x41514], eax
test eax, eax
je 0x41a6d6
mov ecx, dword [esi + 0x1500]
mov eax, dword [esi + 0x14fc]
mov dword [ecx + 4], eax
mov edi, dword [esi + 0x41514]
call fcn.00401230
mov edx, dword [esi + 0x41514]
mov ebx, eax
nop dword [eax]
mov edi, dword [edi + 4]
cmp edi, edx
je 0x41a618
mov ecx, dword [edi]
cmp byte [ecx + 0x9d], 8
je 0x41a600
mov dword [esi + 0x41514], edi
mov eax, dword [esi + 0x41514]
mov ecx, dword [eax]
cmp byte [ecx + 0x9d], 8
je 0x41a6af
mov eax, dword [esi + 0x418e8]
cmp byte [eax + 0x9a0], 0
je 0x41a6af
mov eax, ebx
sub eax, dword [ecx + 0x10]
cmp eax, 0x64
jbe 0x41a6af
mov eax, ebx
sub eax, dword [esi + 0x4151c]
cmp eax, 0x14
jbe 0x41a6af
test ecx, ecx
mov dword [ecx + 0x10], ebx
setne al
mov byte [esi + 0x41518], al
test ecx, ecx
je 0x41a66a
movzx eax, word [ecx]
jmp 0x41a66f
mov eax, 0xffff
push eax
call fcn.0040c280
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x41a6a4
push 0
push dword [ebx + 4]
mov ecx, esi
push dword [ebx]
call fcn.0041c920
push dword [ebx]
call fcn.0041fd9e
push 8
push ebx
mov dword [ebx], 0
call fcn.0041fd90
add esp, 0xc
call fcn.00401230
mov dword [esi + 0x4151c], eax
push dword [edi]
mov ecx, dword [esi + 0x41510]
call fcn.0041e5e0
mov eax, dword [esi + 0x41510]
mov byte [eax + 0x9e], 0
mov eax, dword [esi + 0x1500]
mov dword [eax + 4], 0
push 0
mov ecx, esi
call fcn.0041d300
mov ecx, esi
call fcn.0041a1f0
mov ecx, dword [ebp - 0x230]
mov eax, ecx
sub eax, dword [esi + 0x14b4]
cmp eax, 0x64
jb 0x41a716
sub esp, 0x28
mov dword [esi + 0x14b4], ecx
push esp
call fcn.004182a0
mov ecx, dword [esi + 0x14b8]
add esp, 4
call fcn.00408b60
mov eax, dword [esi + 0x10b8]
xor ecx, ecx
mov byte [esi + 0xc84], 0
mov ebx, 2
mov dword [ebp - 0x220], eax
mov word [ebp - 0x218], 0xe00
mov dword [ebp - 0x21c], ecx
test eax, eax
je 0x41aa28
nop word [eax + eax]
mov edx, dword [eax]
mov dword [ebp - 0x228], edx
mov eax, dword [edx + 0x208]
cmp eax, 0xff
jbe 0x41a976
push eax
push edx
mov ecx, esi
call fcn.0041d1e0
mov ecx, dword [ebp - 0x21c]
jmp 0x41a9ed
cmp dword [esi + 0x41514], 0
mov edi, edx
je 0x41a7a0
mov ecx, ebx
sub ecx, eax
lea eax, [edi*8]
cmp ecx, eax
jbe 0x41a6df
jmp 0x41a6d6
mov edx, ebx
sub edx, eax
lea eax, [edi + edi]
cmp edx, eax
jbe 0x41a6df
push edx
call fcn.0041e700
mov eax, dword [esi + 0x41510]
movzx eax, byte [eax + 0x9d]
lea eax, [eax + eax*8]
add eax, eax
test dword [esi + eax*8 + 0x141b8c], 0x300000
jbe 0x41a6d6
movzx eax, word [esi + 0x41acc]
xor edx, edx
mov ebx, dword [esi + 0x14fc]
shr eax, 1
mov dword [ebp - 0x21c], edx
mov dword [ebp - 0x220], eax
test ebx, ebx
je 0x41a6d6
nop dword [eax]
mov edi, dword [ebx]
mov ecx, dword [esi + 0x41510]
mov ebx, dword [ebx + 4]
cmp edi, ecx
je 0x41a842
cmp byte [edi + 0x9d], 8
je 0x41a842
cmp byte [esi + 0x41aef], 0
movzx eax, word [ecx + 0xd8]
movzx edx, word [edi + 0xd8]
jne 0x41a93c
cmp ax, dx
jne 0x41a945
mov edx, dword [ebp - 0x21c]
test ebx, ebx
jne 0x41a800
test edx, edx
je 0x41a6d6
mov edi, dword [esi + 0x41510]
movzx eax, byte [edi + 0x9d]
lea eax, [eax + eax*8]
add eax, eax
movzx ecx, word [esi + eax*8 + 0x141b2a]
mov eax, 0x10624dd3
mul ecx
lea eax, [edi + 0xc0]
mov edi, dword [ebp - 0x21c]
shr edx, 6
push edx
push eax
lea eax, [ebp - 0x22c]
push eax
lea ecx, [edi + 0xc0]
call fcn.00416b20
mov ecx, dword [esi + 0x41510]
push eax
lea eax, [edi + 0xb8]
add ecx, 0xb8
push eax
lea eax, [ebp - 0x224]
push eax
call fcn.00416b20
push eax
call fcn.00418690
mov ecx, dword [esi + 0x41510]
add esp, 0xc
mov byte [ecx + 0x9e], al
cmp byte [esi + 0x41aef], 1
jne 0x41a8f2
mov eax, dword [esi + 0x41510]
movzx eax, byte [eax + 0x9e]
push eax
call fcn.00418830
mov ecx, dword [esi + 0x41510]
add esp, 4
mov byte [ecx + 0x9e], al
call fcn.00401230
mov ecx, dword [esi + 0x41510]
mov edx, eax
add edx, dword [esi + 0x1498]
push 1
push 0
movzx ecx, byte [ecx + 0x9d]
push 0
push 0
lea eax, [ecx + ecx*8]
mov ecx, esi
add eax, eax
mov eax, dword [esi + eax*8 + 0x141b8c]
shr eax, 0x14
and al, 3
dec al
movzx eax, al
push eax
push 1
push edx
push 0
call fcn.0041d330
jmp 0x41a6df
cmp ax, dx
jne 0x41a83c
lea eax, [edi + 0xb0]
add ecx, 0xb0
push eax
call fcn.00417070
cmp eax, dword [ebp - 0x220]
jae 0x41a83c
mov edx, edi
mov dword [ebp - 0x220], eax
mov dword [ebp - 0x21c], edx
jmp 0x41a842
add eax, ebx
cmp eax, 0x1fc
jbe 0x41a9b7
cmp ecx, 1
jne 0x41a987
add ebx, 0xfffffffd
cmp ecx, 1
lea edx, [ebp - 0x215]
lea eax, [ebp - 0x218]
mov ecx, esi
push ebx
cmove eax, edx
push eax
call fcn.0041d1e0
mov edx, dword [ebp - 0x228]
mov ebx, 2
mov dword [ebp - 0x21c], 0
mov al, byte [edx + 0x208]
mov edi, dword [edx + 0x208]
mov byte [ebp + ebx - 0x218], al
inc ebx
push edi
lea eax, [ebp - 0x218]
push edx
add eax, ebx
push eax
call fcn.00421b00
mov ecx, dword [ebp - 0x21c]
add esp, 0xc
add ebx, edi
inc ecx
mov dword [ebp - 0x21c], ecx
mov eax, dword [ebp - 0x220]
mov eax, dword [eax + 4]
mov dword [ebp - 0x220], eax
test eax, eax
jne 0x41a750
sub ecx, eax
je 0x41aa28
sub ecx, 1
mov ecx, esi
je 0x41aa18
push ebx
lea eax, [ebp - 0x218]
jmp 0x41aa22
lea eax, [ebx - 3]
push eax
lea eax, [ebp - 0x215]
push eax
call fcn.0041d1e0
lea ecx, [esi + 0x10b8]
call fcn.00419ef0
mov eax, dword [esi + 0x14bc]
test eax, eax
je 0x41ab3a
mov ebx, dword [eax]
mov eax, dword [eax + 4]
mov dword [ebp - 0x228], eax
call fcn.00401230
cmp eax, dword [ebx + 4]
jb 0x41ab2c
movzx eax, word [ebx + 2]
push eax
movzx eax, word [ebx]
push eax
call fcn.0041e430
add esp, 8
mov byte [eax + esi + 0x41b09], 0
mov edi, dword [esi + 0x14bc]
test edi, edi
je 0x41ab2c
mov eax, edi
cmp dword [edi], ebx
je 0x41aa9b
mov edi, dword [edi + 4]
cmp edi, eax
je 0x41ab2c
test edi, edi
jne 0x41aa83
jmp 0x41ab2c
mov eax, dword [esi + 0x14c0]
cmp eax, edi
jne 0x41aabb
mov eax, dword [eax + 8]
mov dword [esi + 0x14c0], eax
test eax, eax
je 0x41aac8
mov dword [eax + 4], 0
jmp 0x41aac8
mov ecx, dword [edi + 8]
test ecx, ecx
je 0x41aac8
mov eax, dword [edi + 4]
mov dword [ecx + 4], eax
mov eax, dword [esi + 0x14bc]
cmp eax, edi
jne 0x41aae8
mov eax, dword [eax + 4]
mov dword [esi + 0x14bc], eax
test eax, eax
je 0x41aaf5
mov dword [eax + 8], 0
jmp 0x41aaf5
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x41aaf5
mov eax, dword [edi + 8]
mov dword [ecx + 8], eax
cmp byte [esi + 0x14c8], 0
je 0x41ab04
mov dword [edi], 0
mov eax, dword [edi]
test eax, eax
je 0x41ab1b
push 0xc
push eax
call fcn.0041fd90
add esp, 8
mov dword [edi], 0
push 0xc
push edi
call fcn.0041fd90
add esp, 8
dec dword [esi + 0x14c4]
mov eax, dword [ebp - 0x228]
test eax, eax
jne 0x41aa41
mov ebx, dword [esi + 0x14dc]
call fcn.00401230
mov dword [ebp - 0x21c], eax
test ebx, ebx
je 0x41ac3d
mov edx, dword [ebx]
mov ebx, dword [ebx + 4]
cmp dword [edx + 0x14], 0
je 0x41ac35
mov ecx, eax
movzx eax, word [esi + 0x142052]
sub ecx, dword [edx + 0x18]
cmp ecx, eax
jbe 0x41ac2f
mov edi, dword [esi + 0x14dc]
test edi, edi
je 0x41ac2f
mov eax, edi
cmp dword [edi], edx
je 0x41ab9e
mov edi, dword [edi + 4]
cmp edi, eax
je 0x41ac2f
test edi, edi
jne 0x41ab86
jmp 0x41ac2f
mov eax, dword [esi + 0x14e0]
cmp eax, edi
jne 0x41abbe
mov eax, dword [eax + 8]
mov dword [esi + 0x14e0], eax
test eax, eax
je 0x41abcb
mov dword [eax + 4], 0
jmp 0x41abcb
mov ecx, dword [edi + 8]
test ecx, ecx
je 0x41abcb
mov eax, dword [edi + 4]
mov dword [ecx + 4], eax
mov eax, dword [esi + 0x14dc]
cmp eax, edi
jne 0x41abeb
mov eax, dword [eax + 4]
mov dword [esi + 0x14dc], eax
test eax, eax
je 0x41abf8
mov dword [eax + 8], 0
jmp 0x41abf8
mov ecx, dword [edi + 4]
test ecx, ecx
je 0x41abf8
mov eax, dword [edi + 8]
mov dword [ecx + 8], eax
cmp byte [esi + 0x14e8], 0
je 0x41ac07
mov dword [edi], 0
mov eax, dword [edi]
test eax, eax
je 0x41ac1e
push 0x1c
push eax
call fcn.0041fd90
add esp, 8
mov dword [edi], 0
push 0xc
push edi
call fcn.0041fd90
add esp, 8
dec dword [esi + 0x14e4]
mov eax, dword [ebp - 0x21c]
test ebx, ebx
jne 0x41ab53
cmp byte [esi + 0x13a4], 0
je 0x41ac68
mov edi, dword [ebp - 0x230]
mov eax, edi
sub eax, dword [esi + 0x13a0]
cmp eax, 0x3e8
jbe 0x41ac68
mov ecx, esi
call fcn.0041dba0
mov dword [esi + 0x13a0], edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0041fd52
mov esp, ebp
pop ebp
ret