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

Disassembly:
push 0xffffffffffffffff
push 0x4effed
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xa8
push ebx
push ebp
mov ebp, ecx
push esi
push edi
push 0xffffffffffffffff
mov eax, dword [ebp + 0x40]
lea edi, [ebp + 0xcc4]
push 0
mov ecx, edi
mov dword [esp + 0x24], eax
call fcn.004163d0
push 0xffffffffffffffff
lea ecx, [ebp + 0xcd8]
push 0
call fcn.00417070
mov eax, dword [ebp + 0xbbc]
mov ecx, 1
test eax, eax
mov word [ebp + 0xc88], cx
je 0x4a1089
mov word [ebp + 0xc8a], 2
jmp 0x4a10c3
mov al, byte [ebp + 0x14f]
cmp al, 0x95
jne 0x4a109e
mov word [ebp + 0xc8a], 0x1e
jmp 0x4a10c3
cmp al, 0x96
jne 0x4a10ad
mov word [ebp + 0xc8a], 3
jmp 0x4a10c3
cmp al, 0x97
jne 0x4a10bc
mov word [ebp + 0xc8a], 4
jmp 0x4a10c3
mov word [ebp + 0xc8a], cx
mov esi, dword [esp + 0xc8]
mov ebx, dword [esi + 8]
test ebx, ebx
jne 0x4a111a
mov ebx, dword [edi + 4]
test ebx, ebx
je 0x4a110d
mov edi, dword [edi + 8]
mov ecx, edi
dec edi
test ecx, ecx
je 0x4a10f1
inc edi
mov edx, dword [ebx]
push 0
mov ecx, ebx
call dword [edx]
add ebx, 0x14
dec edi
jne 0x4a10e3
mov eax, dword [ebp + 0xcc8]
lea edi, [ebp + 0xcc4]
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov dword [edi + 4], 0
xor eax, eax
mov dword [edi + 0xc], eax
mov dword [edi + 8], eax
jmp 0x4a12af
mov edx, dword [edi + 4]
test edx, edx
jne 0x4a1193
lea esi, [ebx + ebx*4]
shl esi, 2
push esi
call sub.MFC42.DLL_operatornew
mov edx, eax
mov ecx, esi
mov dword [edi + 4], edx
mov dword [esp + 0x14], edx
mov edi, edx
mov edx, ecx
xor eax, eax
mov esi, dword [esp + 0x14]
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
add esp, 4
and ecx, 3
rep stosb byte es:[edi], al
lea edi, [ebx]
mov dword [esp + 0x14], esi
test esi, esi
mov dword [esp + 0xc0], 0
je 0x4a116d
mov ecx, esi
call fcn.004ba030
add esi, 0x14
dec edi
mov dword [esp + 0xc0], 0xffffffff
mov dword [esp + 0x10], esi
jne 0x4a1153
mov dword [ebp + 0xcd0], ebx
mov dword [ebp + 0xccc], ebx
jmp 0x4a12a8
mov ecx, dword [edi + 0xc]
cmp ebx, ecx
jg 0x4a11f6
mov edi, dword [edi + 8]
cmp edi, ebx
jge 0x4a11bd
mov eax, ebx
lea ecx, [edi + edi*4]
sub eax, edi
lea edx, [edx + ecx*4]
push eax
push edx
call fcn.00416ff0
mov dword [ebp + 0xccc], ebx
jmp 0x4a12af
jle 0x4a11eb
sub edi, ebx
lea ecx, [ebx + ebx*4]
mov eax, edi
lea edi, [edx + ecx*4]
mov edx, eax
dec eax
test edx, edx
je 0x4a11eb
inc eax
mov dword [esp + 0x10], eax
mov eax, dword [edi]
push 0
mov ecx, edi
call dword [eax]
mov eax, dword [esp + 0x10]
add edi, 0x14
dec eax
mov dword [esp + 0x10], eax
jne 0x4a11d5
mov dword [ebp + 0xccc], ebx
jmp 0x4a12af
mov eax, dword [edi + 0x10]
test eax, eax
jne 0x4a1221
mov eax, dword [edi + 8]
cdq
and edx, 7
add eax, edx
sar eax, 3
cmp eax, 4
jge 0x4a1215
mov eax, 4
jmp 0x4a1221
cmp eax, 0x400
jle 0x4a1221
mov eax, 0x400
add eax, ecx
cmp ebx, eax
mov dword [esp + 0x10], eax
jl 0x4a122f
mov dword [esp + 0x10], ebx
mov eax, dword [esp + 0x10]
lea ecx, [eax + eax*4]
shl ecx, 2
push ecx
call sub.MFC42.DLL_operatornew
mov ecx, dword [ebp + 0xccc]
mov esi, dword [ebp + 0xcc8]
mov edi, eax
add esp, 4
lea ecx, [ecx + ecx*4]
mov dword [esp + 0x14], eax
shl ecx, 2
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
mov edx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp + 0xccc]
sub edx, ecx
lea ecx, [ecx + ecx*4]
push edx
lea edx, [eax + ecx*4]
push edx
call fcn.00416ff0
mov eax, dword [ebp + 0xcc8]
push eax
call sub.MFC42.DLL_operatordelete
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x14]
add esp, 4
mov dword [ebp + 0xcc8], eax
mov dword [ebp + 0xccc], ebx
mov dword [ebp + 0xcd0], ecx
mov esi, dword [esp + 0xc8]
mov eax, dword [esi + 8]
xor edi, edi
test eax, eax
mov ebx, 0xa
jle 0x4a135e
lea edx, [esp + 0x20]
push edi
push edx
mov ecx, esi
call fcn.00416560
mov eax, dword [esp + 0x2c]
mov dword [esp + 0xc0], 1
cmp eax, ebx
je 0x4a12fc
lea eax, [esp + 0x20]
lea ecx, [esp + 0x24]
neg eax
sbb eax, eax
and eax, ecx
mov ecx, dword [eax]
mov eax, dword [eax + 4]
mov dword [esp + 0x24], ecx
mov dword [esp + 0x28], eax
lea eax, [esp + 0x20]
sub esp, 0x14
neg eax
sbb eax, eax
lea edx, [esp + 0x38]
and eax, edx
mov ecx, esp
mov dword [esp + 0x28], esp
push edi
mov edx, dword [eax]
mov dword [ecx + 4], edx
mov eax, dword [eax + 4]
mov dword [ecx + 8], eax
mov edx, dword [esp + 0x44]
mov dword [ecx + 0xc], edx
mov eax, dword [esp + 0x48]
mov dword [ecx + 0x10], eax
mov dword [ecx], 0x4f57e8
lea ecx, [ebp + 0xcc4]
call fcn.004165b0
lea ecx, [esp + 0x20]
mov dword [esp + 0xc0], 0xffffffff
call fcn.004ba050
mov eax, dword [esi + 8]
inc edi
cmp edi, eax
jl 0x4a12c1
mov ax, word [ebp + 0xc8a]
cmp ax, 2
jne 0x4a13bd
mov word [ebp + 0xc90], 0
mov ecx, dword [esi + 8]
dec ecx
lea edx, [esp + 0x20]
push ecx
push edx
mov ecx, esi
call fcn.00416560
cmp dword [esp + 0x2c], ebx
jne 0x4a13a5
mov ax, word [esi + 8]
lea ecx, [esp + 0x20]
sub ax, 2
mov word [ebp + 0xc92], ax
call fcn.004ba050
jmp 0x4a13ec
mov cx, word [esi + 8]
dec cx
mov word [ebp + 0xc92], cx
lea ecx, [esp + 0x20]
call fcn.004ba050
jmp 0x4a13ec
cmp ax, 1
je 0x4a13dc
cmp ax, 0x1e
je 0x4a13dc
cmp ax, 3
je 0x4a13d5
cmp ax, 4
jne 0x4a13ec
mov eax, 1
jmp 0x4a13de
xor eax, eax
mov word [ebp + 0xc92], ax
mov word [ebp + 0xc90], ax
lea edi, [ebp + 0xc84]
mov ecx, edi
call fcn.0045afe0
lea edx, [esp + 0x34]
push 0
push edx
mov ecx, edi
mov esi, 1
call fcn.0045c9d0
mov eax, dword [esp + 0x40]
mov ebx, dword [esp + 0x38]
mov ecx, dword [esp + 0x3c]
mov dx, word [ebp + 0xc8a]
sub eax, ebx
mov ebx, dword [esp + 0x34]
sub ecx, ebx
cmp dx, 2
je 0x4a1432
cmp dx, si
jne 0x4a1447
test ecx, ecx
jne 0x4a143c
test eax, eax
je 0x4a1447
jmp 0x4a1452
test eax, eax
jne 0x4a1447
cmp ecx, 0x32
jge 0x4a1465
jmp 0x4a1463
cmp dx, 4
jne 0x4a1459
cmp ecx, 0x32
jl 0x4a1463
cmp eax, 0x32
jge 0x4a1465
jmp 0x4a1463
cmp ecx, 0x32
jge 0x4a1465
cmp eax, 0x32
jge 0x4a1465
xor esi, esi
push ebx
call fcn.00434750
add esp, 4
test eax, eax
je 0x4a14a9
mov eax, dword [esp + 0x38]
push eax
call fcn.00434750
add esp, 4
test eax, eax
je 0x4a14a9
mov ecx, dword [esp + 0x3c]
push ecx
call fcn.00434750
add esp, 4
test eax, eax
je 0x4a14a9
mov edx, dword [esp + 0x40]
push edx
call fcn.00434750
add esp, 4
test eax, eax
je 0x4a14a9
test esi, esi
jne 0x4a14ca
push 0x30
call dword [sym.imp.USER32.dll_MessageBeep]
mov ecx, edi
call fcn.0045b010
push 0
lea ecx, [ebp + 0x184]
call fcn.004d5a30
jmp 0x4a1885
mov eax, dword [ebp + 0x134]
mov esi, dword [esp + 0x1c]
test eax, eax
je 0x4a1553
mov eax, dword [esi + 0x5c]
mov ecx, dword [esi + 0x58]
mov edx, dword [esi + 0xd4]
push eax
mov eax, dword [esi + 0xd0]
push ecx
mov ecx, dword [esi + 0xcc]
push edx
mov edx, dword [esi + 0xc8]
push eax
push ecx
push edx
mov ecx, edi
call fcn.0045b0e0
test ax, ax
jge 0x4a154c
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CString::CString
push 0xa293
lea ecx, [esp + 0x14]
mov dword [esp + 0xc4], 2
call sub.MFC42.DLL_CString::LoadStringA
mov eax, dword [esp + 0x10]
push 0
push 0
push eax
call sub.MFC42.DLL_AfxMessageBox
lea ecx, [esp + 0x10]
mov dword [esp + 0xc0], 0xffffffff
call fcn.004e2712
mov ecx, edi
call fcn.0045afe0
mov ecx, esi
xor ebx, ebx
call fcn.0048a7d0
test eax, eax
jne 0x4a1565
mov ebx, 1
mov eax, dword [ebp + 0xbc4]
test eax, eax
jne 0x4a1885
push 1
push edi
mov ecx, esi
call fcn.0048b500
push ebp
lea ecx, [esp + 0x48]
call fcn.004e2538
mov edx, dword [ebp]
lea eax, [esp + 0x44]
push 0
push eax
mov ecx, ebp
mov dword [esp + 0xc8], 3
call dword [edx + 0xe4]
mov eax, dword [ebp + 0x140]
test eax, eax
jne 0x4a1794
test ebx, ebx
jne 0x4a1794
mov eax, dword [ebp + 0xdc]
test eax, eax
jne 0x4a15d7
push 0xd
lea ecx, [esp + 0x48]
push 0xaaaaaa
push ecx
mov ecx, edi
call fcn.0045dee0
mov eax, dword [ebp + 0xe0]
test eax, eax
je 0x4a15eb
mov ecx, dword [ebp + 0xe4]
test ecx, ecx
jne 0x4a15ff
mov edx, dword [ebp + 0xe4]
mov ecx, edi
push edx
push eax
lea eax, [esp + 0x4c]
push eax
call fcn.0045e0a0
mov eax, dword [ebp + 0xdc]
test eax, eax
je 0x4a1619
lea ecx, [esi + 0x78]
lea edx, [esp + 0x44]
push ecx
push edx
mov ecx, edi
call fcn.0045dec0
fld qword [esi + 0x58]
fmul qword [0x4f67f8]
fld qword [esi + 0xd0]
mov eax, dword [ebp + 0xec]
mov ecx, dword [ebp + 0xe4]
fdiv st(1)
mov edx, dword [ebp + 0xe0]
push eax
push ecx
push edx
sub esp, 8
lea eax, [esi + 0x78]
sub esp, 8
lea ecx, [esp + 0x60]
fstp qword [esp + 8]
fld qword [esi + 0xc8]
fdiv st(1)
fstp qword [esp]
push eax
push ecx
mov ecx, edi
fstp st(0)
call fcn.0045e050
mov eax, dword [ebp + 0xe8]
test eax, eax
je 0x4a1752
cmp dword [ebp + 0xce0], 1
jle 0x4a1752
mov edx, dword [esi + 0xb8]
mov ebx, dword [esi + 0xb4]
mov ecx, esi
mov dword [esp + 0x18], edx
call fcn.0048a7d0
test eax, eax
je 0x4a16ef
mov eax, dword [esi + 0xe8]
sub eax, 2
js 0x4a16ef
mov ecx, dword [esi + 0xe4]
lea edx, [ecx + eax*4]
mov ecx, dword [edx]
cmp dword [ecx + 0x5c], 1
jg 0x4a16c2
dec eax
sub edx, 4
test eax, eax
jge 0x4a16b0
jmp 0x4a16ef
lea edx, [esp + 0x88]
push edx
call fcn.0045c720
test eax, eax
je 0x4a16d8
add eax, 4
jmp 0x4a16da
xor eax, eax
mov ebx, dword [eax]
mov eax, dword [eax + 4]
lea ecx, [esp + 0x88]
mov dword [esp + 0x18], eax
call fcn.00456e80
lea ecx, [esp + 0x58]
push ecx
mov ecx, edi
call fcn.0045c5f0
mov ecx, dword [esi + 0x5c]
lea eax, [esp + 0x58]
neg eax
sbb eax, eax
lea edx, [esp + 0x5c]
and eax, edx
mov edx, dword [esi + 0x58]
push 0
push ecx
mov ecx, dword [eax + 4]
push edx
mov edx, dword [eax]
mov eax, dword [esp + 0x24]
push ecx
push edx
movsx ecx, word [ebp + 0xc8e]
push eax
push ebx
push ecx
lea edx, [esp + 0x64]
push 0xff0000
push edx
mov ecx, ebp
mov byte [esp + 0xe8], 4
call fcn.00490df0
lea ecx, [esp + 0x58]
mov byte [esp + 0xc0], 3
call fcn.00456e80
mov eax, dword [ebp + 0xf4]
test eax, eax
je 0x4a17a2
mov eax, dword [ebp + 0xdc]
test eax, eax
je 0x4a1772
lea eax, [esp + 0x44]
mov ecx, edi
push eax
call fcn.0045ecd0
mov eax, dword [ebp + 0xe0]
test eax, eax
jne 0x4a1786
mov eax, dword [ebp + 0xe4]
test eax, eax
je 0x4a17a2
lea ecx, [esp + 0x44]
push ecx
mov ecx, edi
call fcn.0045edb0
jmp 0x4a17a2
mov edx, dword [ebp + 0x20]
push 1
push 0
push edx
call dword [sym.imp.USER32.dll_InvalidateRect]
mov word [ebp + 0xc88], 1
mov word [ebp + 0xc8a], 2
mov edi, dword [ebp + 0xcc8]
test edi, edi
je 0x4a17f5
mov eax, dword [ebp + 0xccc]
mov ecx, eax
dec eax
test ecx, ecx
je 0x4a17dc
lea ebx, [eax + 1]
mov edx, dword [edi]
push 0
mov ecx, edi
call dword [edx]
add edi, 0x14
dec ebx
jne 0x4a17ce
mov eax, dword [ebp + 0xcc8]
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov dword [ebp + 0xcc8], 0
xor eax, eax
mov dword [ebp + 0xcd0], eax
mov dword [ebp + 0xccc], eax
mov edi, dword [ebp + 0xcdc]
cmp edi, eax
je 0x4a1844
mov eax, dword [ebp + 0xce0]
mov ecx, eax
dec eax
test ecx, ecx
je 0x4a182b
lea ebx, [eax + 1]
mov edx, dword [edi]
push 0
mov ecx, edi
call dword [edx]
add edi, 0x30
dec ebx
jne 0x4a181d
mov eax, dword [ebp + 0xcdc]
push eax
call sub.MFC42.DLL_operatordelete
add esp, 4
mov dword [ebp + 0xcdc], 0
xor eax, eax
mov ecx, esi
mov dword [ebp + 0xce4], eax
mov dword [ebp + 0xce0], eax
call fcn.00489c30
mov eax, dword [esi]
push 1
mov ecx, esi
call dword [eax + 0x64]
mov ecx, ebp
call fcn.004a9170
push ebp
mov ecx, eax
call fcn.004461a0
lea ecx, [esp + 0x44]
mov dword [esp + 0xc0], 0xffffffff
call sub.MFC42.DLL_CClientDC::CClientDC
mov ecx, dword [esp + 0xb8]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0xb4
ret 4