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

Disassembly:
sub esp, 0x74
mov eax, dword [0x426120]
xor eax, esp
mov dword [esp + 0x70], eax
push ebx
xor ebx, ebx
mov dword [esp + 0xc], ebx
xor eax, eax
mov word [esp + 0x18], ax
push ebp
mov dword [esp + 8], ebx
xor ecx, ecx
xor edx, edx
push esi
mov word [esp + 0x10], cx
push edi
mov word [esp + 0x20], dx
mov byte [esp + 0x7f], bl
add dword [esp + 0x10], 0xd64ca764
lea edi, [ebx + 1]
movzx eax, word [esp + 0x20]
movzx edx, word [esp + 0x14]
lea eax, [eax + edx - 0x74179d64]
mov word [esp + 0x14], ax
movsx eax, byte [ecx + 0x424058]
cdq
mov esi, 0x1a
idiv esi
add dl, 0x61
mov byte [esp + ecx + 0x78], dl
dec dword [esp + 0x14]
movzx edx, word [esp + 0x14]
add ecx, edi
mov word [esp + 0x14], dx
cmp ecx, 7
jne 0x406080
push 0xbb6
push 0x424058
call fcn.00402a00
add dword [esp + 0x28], edi
fld qword [0x425ae8]
mov esi, eax
movzx eax, word [esp + 0x28]
movzx edx, word [esp + 0x2c]
movsx ecx, ax
movsx eax, dx
sub eax, ecx
mov ecx, dword [esp + 0x18]
sub eax, ecx
mov dword [esp + 0x2c], eax
add esp, 8
push ebx
fild dword [esp + 0x28]
fsubp st(1)
fstp qword [0x425ae8]
add dword [esp + 0x14], edi
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
fldz
mov dword [0x427918], eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x2c], 0x30
mov dword [esp + 0x30], 3
mov dword [esp + 0x34], 0x4042e0
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], ebx
fstp qword [esp + 0x24]
movzx edx, byte [esi + 0x17]
fldz
movzx ecx, byte [esi + 0x16]
fstp dword [esp + 0x24]
mov eax, dword [esi + 0x22]
push ebx
push edx
mov edx, dword [esi + 0x1e]
push ecx
push 0x30000
push edi
add eax, esi
push edx
push eax
call dword [sym.imp.USER32.dll_CreateIconFromResourceEx]
mov dword [esp + 0x44], eax
fld qword [0x423810]
mov eax, dword [esp + 0x18]
movzx ecx, word [esp + 0x14]
fadd qword [0x41f710]
mov dword [esp + 0x24], eax
movsx edx, cx
fild dword [esp + 0x24]
mov dword [esp + 0x24], edx
faddp st(1)
fild dword [esp + 0x24]
fmulp st(1)
call fcn.0040aee0
mov word [esp + 0x14], ax
add dword [esp + 0x18], edi
fld qword [0x423810]
fsub qword [0x41f360]
push 0x7f00
push ebx
fstp qword [0x423810]
call dword [sym.imp.USER32.dll_LoadCursorA]
mov dword [esp + 0x48], eax
lea eax, [esp + 0x78]
mov dword [esp + 0x54], eax
mov dword [esp + 0x4c], 6
mov dword [esp + 0x50], ebx
dec dword [esp + 0x10]
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x18], ecx
fild dword [esp + 0x18]
fadd qword [0x4237d0]
movzx edx, word [0x425fb8]
movsx eax, dx
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
faddp st(1)
call fcn.0040aee0
mov word [0x425fb8], ax
fld qword [0x4237d0]
fadd qword [0x41f360]
push edi
mov dword [esp + 0x5c], ebx
fstp qword [0x4237d0]
call dword [sym.imp.GDI32.dll_GetStockObject]
fld qword [0x425e80]
mov dword [esp + 0x4c], eax
fadd qword [0x41f708]
fsub qword [0x41f700]
call fcn.0040aee0
lea ecx, [esp + 0x2c]
mov word [esp + 0x14], ax
push ecx
call dword [sym.imp.USER32.dll_RegisterClassExA]
fldz
push 0xbb6
fstp dword [esp + 0x1c]
fldz
push ebx
fstp qword [esp + 0x20]
push esi
call fcn.0040b4b0
push esi
call fcn.0040af8b
push 0x15
push 0x4238b8
call fcn.00402a00
mov edx, dword [0x427918]
add esp, 0x18
push ebx
push edx
push ebx
push ebx
push ebx
push connect
push ebx
push connect
push 0xc80000
mov esi, eax
push esi
lea eax, [esp + 0xa0]
push eax
push ebx
call dword [sym.imp.USER32.dll_CreateWindowExA]
fldz
mov ebp, eax
fstp dword [esp + 0x18]
fldz
xor eax, eax
mov dword [esi], eax
fstp qword [esp + 0x18]
mov dword [esi + 4], eax
mov dword [esi + 8], eax
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], eax
push esi
mov byte [esi + 0x14], al
call fcn.0040af8b
movzx ecx, word [esp + 0x24]
movsx edx, cx
mov dword [esp + 0x1c], edx
add esp, 4
fild dword [esp + 0x18]
fadd qword [0x423a48]
movzx eax, word [esp + 0x14]
mov edx, dword [0x42600c]
add dword [0x42600c], edi
movsx ecx, ax
lea eax, [ecx + edx - 0x10311519]
mov dword [esp + 0x18], eax
fild dword [esp + 0x18]
fucompp
fnstsw ax
test ah, 0x44
jp 0x406342
mov ecx, dword [esp + 0x10]
mov edx, 0xbccdb4f3
sub edx, ecx
mov dword [esp + 0x18], edx
fild dword [esp + 0x18]
fmul qword [0x425fe8]
fstp qword [0x425fe8]
dec dword [esp + 0x10]
cmp ebp, ebx
je 0x4063ba
push edi
push ebp
call dword [sym.imp.USER32.dll_ShowWindow]
push ebp
call dword [sym.imp.USER32.dll_UpdateWindow]
mov esi, dword [sym.imp.USER32.dll_GetMessageA]
push ebx
push ebx
push ebx
lea eax, [esp + 0x68]
push eax
call esi
test eax, eax
je 0x406391
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
mov ebp, dword [sym.imp.USER32.dll_DispatchMessageA]
lea ecx, [esp + 0x5c]
push ecx
call edi
lea edx, [esp + 0x5c]
push edx
call ebp
push ebx
push ebx
push ebx
lea eax, [esp + 0x68]
push eax
call esi
test eax, eax
jne 0x406375
fld dword [0x42317c]
mov eax, dword [esp + 0x64]
fadd qword [0x41f6f8]
pop edi
pop esi
pop ebp
fstp dword [0x42317c]
pop ebx
mov ecx, dword [esp + 0x70]
xor ecx, esp
call fcn.0040b52a
add esp, 0x74
ret
mov ecx, dword [esp + 0x80]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
xor eax, eax
call fcn.0040b52a
add esp, 0x74
ret