Function at 0x40d71f
Capabilities:
Check os version
Resolve function by parsing pe exports

Disassembly:
jmp 0x615c40
push 0xffffffffffffffff
push 0x66930b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0xd4
push ebx
push ebp
push esi
push edi
mov esi, ecx
call fcn.0041093d
lea ecx, [esp + 0x90]
mov dword [esp + 0x58], eax
call dword [sym.imp.zmathdll.dll_public:_void___thiscall_ZData::constructor_void_]
xor ebx, ebx
push 0xffffffffffffffff
lea ecx, [esi + 0x1c4]
push ebx
mov dword [esp + 0xf4], ebx
mov dword [esp + 0x34], ebx
call sub.MFC42.DLL_CPtrArray::SetSize
mov eax, 0x6725e4
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x38], eax
mov dword [esp + 0x34], ebx
mov dword [esp + 0x30], eax
mov dword [esp + 0x44], ebx
mov dword [esp + 0x40], eax
mov ecx, dword [esp + 0xf4]
mov byte [esp + 0xec], 3
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
mov edi, eax
lea eax, [edi*8]
push eax
call sub.MFC42.DLL_operatornew
add esp, 4
cmp eax, ebx
je 0x615ce7
lea ecx, [edi - 1]
mov dword [esp + 0x10], eax
mov dword [esp + 0x28], ecx
jmp 0x615ceb
mov dword [esp + 0x10], ebx
mov ebp, dword [sym.imp.zmathdll.dll_public:_class_CPoint____thiscall_ZPointArray::operator___int_]
cmp edi, ebx
jle 0x615d4b
mov edx, dword [esp + 0x10]
mov dword [esp + 0x14], edx
mov eax, dword [esp + 0xf4]
push ebx
lea ecx, [eax + 4]
call ebp
fild dword [eax]
fmul qword [0x66e928]
call sub.MSVCRT.dll__ftol
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0xf4]
push ebx
mov dword [ecx], eax
lea ecx, [edx + 4]
call ebp
fild dword [eax + 4]
fmul qword [0x66e928]
call sub.MSVCRT.dll__ftol
mov ecx, dword [esp + 0x14]
inc ebx
mov dword [ecx + 4], eax
add ecx, 8
cmp ebx, edi
mov dword [esp + 0x14], ecx
jl 0x615cfd
mov eax, dword [esp + 0x10]
push 1
push edi
push eax
call dword [sym.imp.GDI32.dll_CreatePolygonRgn]
push eax
lea ecx, [esp + 0x3c]
call sub.MFC42.DLL_CGdiObject::Attach
mov ecx, dword [esp + 0x10]
push ecx
call sub.MFC42.DLL_operatordelete
mov ecx, dword [esp + 0xf8]
mov ebx, dword [esi + 0x1a4]
add esp, 4
lea eax, [esp + 0x70]
mov edx, dword [ecx]
push eax
call dword [edx]
mov ecx, dword [eax]
push 0x78
mov dword [esp + 0x64], ecx
push 0x78
mov edx, dword [eax + 4]
push 0x78
mov dword [esp + 0x70], edx
push 0x78
mov ecx, dword [eax + 8]
mov dword [esp + 0x78], ecx
lea ecx, [esp + 0x70]
mov edx, dword [eax + 0xc]
mov dword [esp + 0x7c], edx
call sub.MFC42.DLL_CRect::DeflateRect
test ebx, ebx
jle 0x6163ba
xor edi, edi
mov dword [esp + 0x5c], ebx
mov eax, dword [esi + 0x1a0]
mov edx, dword [esp + 0xf4]
add eax, edi
mov ecx, dword [eax]
cmp ecx, edx
je 0x6163a8
cmp dword [ecx + 0x1f0], 1
je 0x6163a8
mov edx, dword [ecx]
lea eax, [esp + 0xb4]
push eax
call dword [edx]
mov ecx, eax
mov edx, dword [ecx]
mov ebx, dword [ecx + 4]
mov eax, dword [ecx + 8]
cmp dword [esp + 0x60], eax
mov ecx, dword [ecx + 0xc]
jge 0x6163a8
cmp dword [esp + 0x64], ecx
jge 0x6163a8
cmp dword [esp + 0x68], edx
jle 0x6163a8
cmp dword [esp + 0x6c], ebx
jle 0x6163a8
mov edx, dword [esi + 0x1a0]
mov ecx, dword [edi + edx]
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
mov ebx, eax
mov dword [esp + 0x1c], ebx
lea eax, [ebx*8]
push eax
call sub.MFC42.DLL_operatornew
add esp, 4
test eax, eax
je 0x615e5b
dec ebx
mov dword [esp + 0x10], eax
mov dword [esp + 0x28], ebx
jmp 0x615e63
mov dword [esp + 0x10], 0
mov eax, dword [esp + 0x1c]
xor ebx, ebx
test eax, eax
jle 0x615ecb
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x14], ecx
mov edx, dword [esi + 0x1a0]
push ebx
mov ecx, dword [edi + edx]
add ecx, 4
call ebp
fild dword [eax]
fmul qword [0x66e928]
call sub.MSVCRT.dll__ftol
mov ecx, dword [esp + 0x14]
push ebx
mov dword [ecx], eax
mov edx, dword [esi + 0x1a0]
mov ecx, dword [edi + edx]
add ecx, 4
call ebp
fild dword [eax + 4]
fmul qword [0x66e928]
call sub.MSVCRT.dll__ftol
mov ecx, dword [esp + 0x14]
inc ebx
mov dword [ecx + 4], eax
mov eax, dword [esp + 0x1c]
add ecx, 8
cmp ebx, eax
mov dword [esp + 0x14], ecx
jl 0x615e75
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x10]
push 1
push eax
push ecx
call dword [sym.imp.GDI32.dll_CreatePolygonRgn]
push eax
lea ecx, [esp + 0x34]
call sub.MFC42.DLL_CGdiObject::Attach
mov edx, dword [esp + 0x10]
push edx
call sub.MFC42.DLL_operatordelete
add esp, 4
push 0
push 0
push 0
push 0
call dword [sym.imp.GDI32.dll_CreateRectRgn]
push eax
lea ecx, [esp + 0x44]
call sub.MFC42.DLL_CGdiObject::Attach
mov ecx, dword [esp + 0x34]
lea eax, [esp + 0x30]
neg eax
mov edx, dword [esp + 0x3c]
push 1
sbb eax, eax
and eax, ecx
lea ecx, [esp + 0x3c]
neg ecx
sbb ecx, ecx
push eax
mov eax, dword [esp + 0x4c]
and ecx, edx
push ecx
push eax
call dword [sym.imp.GDI32.dll_CombineRgn]
mov edx, dword [esp + 0x44]
lea ecx, [esp + 0x70]
push ecx
push edx
mov ebx, eax
call dword [sym.imp.GDI32.dll_GetRgnBox]
lea ecx, [esp + 0x40]
call sub.MFC42.DLL_CGdiObject::DeleteObject
lea ecx, [esp + 0x30]
call sub.MFC42.DLL_CGdiObject::DeleteObject
cmp ebx, 1
je 0x6163a8
mov eax, dword [esp + 0x78]
mov edx, dword [esp + 0x70]
sub eax, edx
cmp eax, 3
jl 0x6163a8
mov ecx, dword [esp + 0x7c]
mov edx, dword [esp + 0x74]
sub ecx, edx
cmp ecx, 3
jl 0x6163a8
mov ebx, dword [esp + 0xf4]
mov ecx, ebx
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
cmp eax, 5
je 0x616371
mov edx, dword [esi + 0x1a0]
mov ecx, dword [edi + edx]
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
cmp eax, 5
je 0x616371
mov eax, dword [ebx]
lea ecx, [esp + 0xd4]
push ecx
mov ecx, ebx
mov dword [esp + 0x14], 0
call dword [eax]
mov edx, dword [eax]
mov dword [esp + 0x48], edx
mov ecx, dword [eax + 4]
mov dword [esp + 0x4c], ecx
mov ecx, dword [esi + 0x1a0]
mov edx, dword [eax + 8]
mov ecx, dword [edi + ecx]
mov dword [esp + 0x50], edx
mov eax, dword [eax + 0xc]
mov dword [esp + 0x54], eax
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
test eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], 0
jle 0x616087
mov eax, dword [esi + 0x1a0]
mov edx, dword [esp + 0x14]
push edx
mov ecx, dword [edi + eax]
add ecx, 4
call ebp
mov edx, dword [esp + 0x48]
mov ecx, eax
mov eax, dword [ecx]
mov dword [esp + 0x20], eax
cmp eax, edx
mov ecx, dword [ecx + 4]
mov dword [esp + 0x24], ecx
jle 0x616076
cmp eax, dword [esp + 0x50]
jge 0x616076
cmp ecx, dword [esp + 0x4c]
jle 0x616076
cmp ecx, dword [esp + 0x54]
jge 0x616076
mov edx, dword [ebx]
lea eax, [esp + 0x20]
push eax
mov ecx, ebx
call dword [edx + 0xc]
test eax, eax
je 0x616076
lea ecx, [esp + 0x20]
push 0
push ecx
mov ecx, ebx
call dword [sym.imp.zmathdll.dll_public:_double___thiscall_ZPolyline::OffPoint_class_CPoint_const___int__const]
fabs
call sub.MSVCRT.dll__ftol
cmp eax, dword [esp + 0x10]
jle 0x616076
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x1c]
inc eax
cmp eax, ecx
mov dword [esp + 0x14], eax
jl 0x61600a
mov edx, dword [esi + 0x1a0]
mov ecx, dword [edi + edx]
lea edx, [esp + 0xc4]
push edx
mov eax, dword [ecx]
call dword [eax]
mov ecx, dword [eax]
mov dword [esp + 0x48], ecx
mov edx, dword [eax + 4]
mov dword [esp + 0x4c], edx
mov ecx, dword [eax + 8]
mov dword [esp + 0x50], ecx
mov ecx, ebx
mov edx, dword [eax + 0xc]
mov dword [esp + 0x54], edx
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
test eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], 0
jle 0x61615b
add ebx, 4
mov eax, dword [esp + 0x14]
mov ecx, ebx
push eax
call ebp
mov edx, dword [esp + 0x48]
mov ecx, eax
mov eax, dword [ecx]
mov dword [esp + 0x20], eax
cmp eax, edx
mov ecx, dword [ecx + 4]
mov dword [esp + 0x24], ecx
jle 0x616146
cmp eax, dword [esp + 0x50]
jge 0x616146
cmp ecx, dword [esp + 0x4c]
jle 0x616146
cmp ecx, dword [esp + 0x54]
jge 0x616146
mov edx, dword [esi + 0x1a0]
mov ecx, dword [edi + edx]
lea edx, [esp + 0x20]
push edx
mov eax, dword [ecx]
call dword [eax + 0xc]
test eax, eax
je 0x616146
mov ecx, dword [esi + 0x1a0]
lea eax, [esp + 0x20]
push 0
push eax
mov ecx, dword [edi + ecx]
call dword [sym.imp.zmathdll.dll_public:_double___thiscall_ZPolyline::OffPoint_class_CPoint_const___int__const]
fabs
call sub.MSVCRT.dll__ftol
cmp eax, dword [esp + 0x10]
jle 0x616146
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x1c]
inc eax
cmp eax, ecx
mov dword [esp + 0x14], eax
jl 0x6160d6
mov eax, dword [esp + 0x10]
cmp eax, 0x82
jg 0x616353
test eax, eax
jne 0x6163a8
mov ecx, dword [esp + 0xf4]
mov dword [esp + 0x10], eax
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
mov ebx, eax
mov eax, dword [esi + 0x1a0]
mov dword [esp + 0x28], ebx
mov ecx, dword [edi + eax]
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZPolyline::GetPointNum_void_const]
cmp ebx, 1
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], 1
jle 0x6163a8
mov eax, dword [esi + 0x1a0]
mov edx, dword [esp + 0x14]
mov ebx, edi
lea ecx, [esp + 0x1b]
add ebx, eax
mov eax, dword [esp + 0xf4]
push ecx
push edx
lea ecx, [eax + 4]
call ebp
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0xf8]
push eax
lea eax, [ecx - 1]
lea ecx, [edx + 4]
push eax
call ebp
mov ecx, dword [ebx]
push eax
lea eax, [esp + 0x94]
push eax
call dword [sym.imp.zmathdll.dll_public:_class_CPoint___thiscall_ZPolyline::GetXPoint_class_CPoint_const___class_CPoint_const___char__]
mov ecx, dword [eax]
mov dword [esp + 0x20], ecx
mov edx, dword [eax + 4]
mov al, byte [esp + 0x1b]
test al, al
mov dword [esp + 0x24], edx
je 0x61625b
mov ecx, dword [esp + 0xf4]
mov eax, dword [esp + 0x14]
push eax
lea ebx, [ecx + 4]
mov ecx, ebx
call ebp
mov edx, dword [eax + 4]
mov ecx, dword [esp + 0x14]
push edx
mov eax, dword [eax]
push eax
lea eax, [ecx - 1]
push eax
mov ecx, ebx
call ebp
mov edx, dword [eax + 4]
mov ecx, dword [esp + 0x2c]
push edx
mov edx, dword [esp + 0x2c]
mov eax, dword [eax]
push eax
push ecx
push edx
lea ecx, [esp + 0xa8]
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZData::M_IsInLineRgn_class_CPoint__class_CPoint__class_CPoint_]
test eax, eax
je 0x616254
inc dword [esp + 0x10]
cmp dword [esp + 0x10], 1
jg 0x616270
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x28]
inc eax
cmp eax, ecx
mov dword [esp + 0x14], eax
jl 0x6161ad
cmp dword [esp + 0x10], 2
jl 0x6163a8
mov eax, dword [esp + 0x1c]
mov ebx, 1
cmp eax, ebx
mov dword [esp + 0x10], 0
jle 0x6163a8
mov eax, dword [esi + 0x1a0]
lea ecx, [esp + 0x1b]
add eax, edi
push ecx
push ebx
mov dword [esp + 0x30], eax
mov ecx, dword [eax]
add ecx, 4
call ebp
mov edx, dword [esp + 0x2c]
push eax
lea eax, [ebx - 1]
mov ecx, dword [edx]
push eax
add ecx, 4
call ebp
mov ecx, dword [esp + 0xfc]
push eax
lea eax, [esp + 0x8c]
push eax
call dword [sym.imp.zmathdll.dll_public:_class_CPoint___thiscall_ZPolyline::GetXPoint_class_CPoint_const___class_CPoint_const___char__]
mov ecx, dword [eax]
mov dword [esp + 0x20], ecx
mov edx, dword [eax + 4]
mov al, byte [esp + 0x1b]
test al, al
mov dword [esp + 0x24], edx
je 0x61633f
mov eax, dword [esi + 0x1a0]
push ebx
add eax, edi
mov dword [esp + 0x2c], eax
mov ecx, dword [eax]
add ecx, 4
call ebp
mov ecx, dword [eax + 4]
push ecx
mov edx, dword [eax]
lea eax, [ebx - 1]
push edx
push eax
mov eax, dword [esp + 0x34]
mov ecx, dword [eax]
add ecx, 4
call ebp
mov ecx, dword [eax + 4]
push ecx
mov ecx, dword [esp + 0x2c]
mov edx, dword [eax]
mov eax, dword [esp + 0x30]
push edx
push eax
push ecx
lea ecx, [esp + 0xa8]
call dword [sym.imp.zmathdll.dll_public:_int___thiscall_ZData::M_IsInLineRgn_class_CPoint__class_CPoint__class_CPoint_]
test eax, eax
je 0x616338
inc dword [esp + 0x10]
cmp dword [esp + 0x10], 1
jg 0x616353
mov eax, dword [esp + 0x1c]
inc ebx
cmp ebx, eax
jl 0x616294
cmp dword [esp + 0x10], 1
jle 0x6163a8
mov edx, dword [esi + 0x1a0]
mov ecx, dword [esp + 0x58]
mov eax, dword [edi + edx]
mov dword [ecx + 0x1a15], eax
mov edx, dword [esi + 0x1a0]
mov eax, dword [edi + edx]
jmp 0x61638d
mov eax, dword [esi + 0x1a0]
mov edx, dword [esp + 0x58]
mov ecx, dword [edi + eax]
mov dword [edx + 0x1a15], ecx
mov eax, dword [esi + 0x1a0]
mov eax, dword [edi + eax]
mov edx, dword [esi + 0x1cc]
lea ecx, [esi + 0x1c4]
push eax
push edx
call sub.MFC42.DLL_CPtrArray::SetAtGrow
mov dword [esp + 0x2c], 1
mov eax, dword [esp + 0x5c]
add edi, 4
dec eax
mov dword [esp + 0x5c], eax
jne 0x615dc0
lea ecx, [esp + 0x38]
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov edi, 0x66ea90
mov dword [esp + 0x40], edi
lea ecx, [esp + 0x40]
mov byte [esp + 0xec], 4
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov esi, 0x66e8a8
mov dword [esp + 0x30], edi
mov dword [esp + 0x40], esi
lea ecx, [esp + 0x30]
mov byte [esp + 0xec], 5
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov dword [esp + 0x30], esi
mov dword [esp + 0x38], edi
lea ecx, [esp + 0x38]
mov byte [esp + 0xec], 6
call sub.MFC42.DLL_CGdiObject::DeleteObject
mov ecx, dword [esp + 0x98]
mov dword [esp + 0x38], esi
pop edi
pop esi
pop ebp
mov dword [esp + 0xe0], 0xffffffff
test ecx, ecx
pop ebx
je 0x616438
mov edx, dword [ecx]
push 1
call dword [edx]
mov ecx, dword [esp + 0xd4]
mov eax, dword [esp + 0x1c]
mov dword fs:[0], ecx
add esp, 0xe0
ret 4