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

Disassembly:
push 0xffffffffffffffff
push 0x48d2b4
mov eax, dword fs:[0]
push eax
sub esp, 0x270
mov eax, dword [0x4d6394]
xor eax, esp
mov dword [esp + 0x268], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4d6394]
xor eax, esp
push eax
lea eax, [esp + 0x284]
mov dword fs:[0], eax
mov eax, dword [esp + 0x294]
lea ecx, [esp + 0x2c]
push ecx
mov dword [esp + 0x28], eax
call fcn.0040c960
lea edx, [esp + 0x2c]
xor ebx, ebx
push edx
mov dword [esp + 0x290], ebx
call fcn.0045e890
mov edi, dword [esp + 0x3c]
mov ebp, dword [esp + 0x38]
mov ecx, edi
sub ecx, ebp
mov eax, 0x2aaaaaab
imul ecx
sar edx, 5
mov eax, edx
shr eax, 0x1f
add eax, edx
mov ecx, eax
imul ecx, ecx, 0x62
sub ecx, 0x14
mov eax, 0x21c
sub eax, ecx
cdq
sub eax, edx
mov esi, eax
sar esi, 1
mov byte [esp + 0x5c], bl
mov byte [esp + 0x64], bl
mov byte [esp + 0x6c], bl
mov byte [esp + 0x78], bl
mov byte [esp + 0x80], bl
mov byte [esp + 0x88], bl
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebx
mov dword [esp + 0x4c], ebx
mov dword [esp + 0x50], ebx
mov dword [esp + 0x20], ebx
cmp ebp, edi
jbe 0x40a931
call fcn.00473356
mov edi, dword [esp + 0x2c]
mov dword [esp + 0x14], edi
mov dword [esp + 0x18], ebp
lea ecx, [ecx]
mov ebp, dword [esp + 0x3c]
cmp dword [esp + 0x38], ebp
jbe 0x40a94f
call fcn.00473356
cmp edi, ebx
je 0x40a959
cmp edi, dword [esp + 0x2c]
je 0x40a95e
call fcn.00473356
cmp dword [esp + 0x18], ebp
je 0x40ad5e
cmp dword [esp + 0x20], 4
jge 0x40ad5e
mov ecx, dword [0x4dae48]
push str.check_box
call fcn.0041f1f0
mov ebp, eax
mov dword [esp + 0x58], esi
mov byte [esp + 0x5c], 1
mov dword [esp + 0x74], 0x163
mov byte [esp + 0x78], 1
mov dword [esp + 0x68], 0x55
mov byte [esp + 0x6c], 1
mov dword [esp + 0x84], 0xf
mov byte [esp + 0x88], 1
mov byte [esp + 0x64], bl
mov byte [esp + 0x80], bl
mov dword [esp + 0x70], ebx
mov dword [esp + 0x54], ebx
mov edx, dword [ebp]
mov edx, dword [edx + 0xc]
push 1
lea eax, [esp + 0x58]
push eax
mov ecx, ebp
call edx
mov eax, dword [ebp + 0x94]
mov dword [eax + 0x44], 0xff848282
mov esi, dword [ebp]
mov edx, dword [esi + 0x10]
push ebx
lea ecx, [esp + 0x9c]
push ecx
mov ecx, ebp
call edx
push eax
mov eax, dword [esi + 0x60]
mov ecx, ebp
call eax
cmp edi, ebx
jne 0x40aab6
call fcn.00473356
xor edi, edi
mov esi, dword [esp + 0x18]
cmp esi, dword [edi + 0x10]
jb 0x40aa24
call fcn.00473356
lea eax, [esi + 4]
mov edi, 8
cmp dword [eax + 0x14], edi
jb 0x40aa33
mov eax, dword [eax]
xor ecx, ecx
mov word [esp + 0x264], cx
mov ecx, eax
mov dword [esp + 0x278], 7
mov dword [esp + 0x274], ebx
lea esi, [ecx + 2]
mov dx, word [ecx]
add ecx, 2
cmp dx, bx
jne 0x40aa54
sub ecx, esi
sar ecx, 1
push ecx
lea esi, [esp + 0x264]
call fcn.0040c9f0
mov byte [esp + 0x28c], 1
cmp dword [esp + 0x278], edi
mov edi, dword [esp + 0x264]
jae 0x40aa8f
lea edi, [esp + 0x264]
push 4
call fcn.00472292
mov esi, eax
add esp, 4
cmp esi, ebx
je 0x40aabd
mov edx, dword [0x4d9cac]
mov eax, dword [edx + 0xc]
mov ecx, 0x4d9cac
call eax
add eax, 0x10
mov dword [esi], eax
jmp 0x40aabf
mov edi, dword [edi]
jmp 0x40aa16
xor esi, esi
mov dword [esp + 0x1c], esi
cmp edi, ebx
je 0x40aae1
mov eax, edi
lea edx, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x40aad0
sub eax, edx
sar eax, 1
mov ebx, eax
push edi
mov eax, esi
call fcn.0041ab60
mov byte [esp + 0x28c], 2
mov eax, dword [ebp + 0x94]
mov edi, dword [eax + 0x30]
mov ecx, dword [esi]
mov esi, dword [edi]
add eax, 0x30
lea eax, [ecx - 0x10]
sub esi, 0x10
cmp eax, esi
je 0x40ab4f
cmp dword [esi + 0xc], 0
lea ebx, [esi + 0xc]
jl 0x40ab44
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x40ab44
call fcn.00419330
mov dword [esp + 0x28], eax
or eax, 0xffffffff
lock xadd dword [ebx], eax
dec eax
test eax, eax
jg 0x40ab39
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
mov ecx, dword [esp + 0x28]
add ecx, 0x10
mov dword [edi], ecx
jmp 0x40ab4f
mov ebx, dword [ecx - 0xc]
push ecx
mov eax, edi
call fcn.0041ab60
mov ebx, 1
mov byte [esp + 0x28c], bl
mov esi, dword [esp + 0x1c]
mov eax, dword [esi]
sub eax, 0x10
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40ab7d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push esi
call fcn.00472191
mov eax, dword [ebp + 0x94]
add esp, 4
cmp dword [eax + 4], ebx
je 0x40abeb
mov dword [eax + 4], ebx
mov eax, dword [ebp + 0x94]
mov ecx, dword [eax + 8]
cmp dword [eax + 4], ebx
jne 0x40abbd
mov dword [eax + 8], 4
mov edx, dword [ebp + 0x94]
cmp dword [edx + 8], ecx
je 0x40abeb
lea eax, [esp + 0xb8]
jmp 0x40abd6
mov dword [eax + 8], 0
mov edx, dword [ebp + 0x94]
cmp dword [edx + 8], ecx
je 0x40abeb
lea eax, [esp + 0xc8]
mov esi, dword [ebp]
mov edx, dword [esi + 0x10]
push 0
push eax
mov ecx, ebp
call edx
push eax
mov eax, dword [esi + 0x60]
mov ecx, ebp
call eax
mov ecx, dword [esp + 0x24]
push ebp
push ecx
call fcn.00432e2f
mov esi, dword [esp + 0x14]
test esi, esi
jne 0x40ad4c
call fcn.00473356
xor eax, eax
mov edi, dword [esp + 0x18]
cmp edi, dword [eax + 0x10]
jb 0x40ac17
call fcn.00473356
mov edx, dword [ebp]
mov edx, dword [edx + 0x14]
xor eax, eax
cmp byte [edi + 0x54], al
mov ecx, ebp
setne al
push eax
call edx
mov eax, dword [ebp]
mov edx, dword [eax + 0x10]
lea ecx, [esp + 0xa8]
push ecx
mov ecx, ebp
call edx
push eax
lea eax, [esp + 0x48]
push eax
call dword [0x4a43c4]
mov ecx, dword [esp + 0x4c]
add ecx, 0xd
mov dword [esp + 0x1c], ecx
test esi, esi
jne 0x40ad53
call fcn.00473356
cmp edi, dword [esi + 0x10]
jb 0x40ac6a
call fcn.00473356
sub esp, 0xc0
mov edx, esp
mov dword [esp + 0xe8], esp
push edx
call fcn.0040add0
push ebp
lea ebx, [esp + 0x260]
call fcn.0040d9d0
add esp, 0xc4
mov byte [esp + 0x28c], 3
mov ecx, dword [eax]
lea edx, [esp + 0xdc]
lea edi, [eax + 4]
push edx
mov dword [esp + 0xdc], ecx
call fcn.0040add0
mov ebx, dword [esp + 0x24]
lea eax, [esp + 0xd8]
push eax
lea ecx, [esp + 0x90]
push ecx
add ebx, 0x2d8
mov byte [esp + 0x294], 4
call fcn.0040bfa0
lea esi, [esp + 0xdc]
call fcn.0040aee0
lea esi, [esp + 0x1a0]
call fcn.0040aee0
inc dword [esp + 0x20]
mov byte [esp + 0x28c], 0
cmp dword [esp + 0x278], 8
jb 0x40ad18
mov edx, dword [esp + 0x264]
push edx
call fcn.00472191
add esp, 4
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x40ad5a
call fcn.00473356
xor eax, eax
mov ecx, dword [esp + 0x18]
cmp ecx, dword [eax + 0x10]
jb 0x40ad35
call fcn.00473356
add dword [esp + 0x18], 0xc0
mov esi, dword [esp + 0x1c]
mov edi, dword [esp + 0x14]
xor ebx, ebx
jmp 0x40a940
mov eax, dword [esi]
jmp 0x40ac09
mov esi, dword [esi]
jmp 0x40ac60
mov eax, dword [eax]
jmp 0x40ad27
mov esi, dword [esp + 0x38]
cmp esi, ebx
je 0x40ad8c
mov edi, dword [esp + 0x3c]
cmp esi, edi
je 0x40ad7f
mov edi, edi
call fcn.0040aee0
add esi, 0xc0
cmp esi, edi
jne 0x40ad70
mov edx, dword [esp + 0x38]
push edx
call fcn.00472191
add esp, 4
mov eax, dword [esp + 0x2c]
push eax
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
call fcn.00472191
add esp, 4
mov ecx, dword [esp + 0x284]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x268]
xor ecx, esp
call fcn.0047219c
add esp, 0x27c
ret 4