Function at 0x40c2b0
Capabilities:
Check os version

Disassembly:
push 0xffffffffffffffff
push 0x449bbc
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x200
push ebx
mov ebx, dword [esp + 0x220]
xor eax, eax
push ebp
push esi
mov esi, dword [esp + 0x224]
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x28], eax
lea eax, [esp + 0x50]
push edi
mov dword [esp + 0x10], eax
mov dword [0x461984], esi
mov dword [0x461988], ebx
call sub.MSVFW32.dll_Ordinal_2
shr eax, 0x10
cmp ax, 0x10a
jae 0x40c326
push 0x10
push 0xf04b
push 0xf29e
call fcn.0040eb90
add esp, 0xc
jmp 0x40ce4d
mov ecx, dword [esp + 0x220]
mov edi, dword [esp + 0x224]
push 1
push ebx
push esi
push ecx
push edi
call fcn.0040ce70
mov ebp, eax
mov eax, dword [0x45e8e8]
add esp, 0x14
test eax, eax
jle 0x40c52d
lea edx, [eax + eax*8]
push 4
shl edx, 3
sub edx, eax
mov eax, dword [0x461958]
mov ecx, dword [eax + edx*8 + 8]
lea eax, [eax + edx*8]
push ecx
mov edx, dword [eax + 4]
push edx
call sub.MSVFW32.dll_ICOpen
test eax, eax
mov dword [esp + 0x18], eax
je 0x40c4eb
push 0
push ebp
push 0x4006
push eax
mov ebx, 1
call sub.MSVFW32.dll_ICSendMessage
test eax, eax
je 0x40c4ca
mov esi, dword [esp + 0x24]
mov edi, dword [esp + 0x24]
add ebx, ebx
cmp ebx, 8
jg 0x40c44c
mov ecx, dword [esp + 0x220]
mov eax, dword [esp + 0x224]
mov dword [esp + 0x20], ecx
mov ecx, dword [esp + 0x228]
mov dword [esp + 0x14], eax
mov eax, ecx
cdq
idiv ebx
test edx, edx
jle 0x40c3e4
mov eax, dword [0x4618a4]
mov esi, ebx
sub esi, edx
add esi, ecx
cmp esi, eax
jle 0x40c3e4
mov esi, ecx
sub esi, edx
mov ecx, dword [esp + 0x22c]
mov eax, ecx
cdq
idiv ebx
test edx, edx
jle 0x40c407
mov eax, dword [0x461804]
mov edi, ebx
sub edi, edx
add edi, ecx
cmp edi, eax
jle 0x40c407
mov esi, ecx
sub esi, edx
test ebp, ebp
je 0x40c414
push ebp
call fcn.0040d170
add esp, 4
mov edx, dword [esp + 0x220]
mov eax, dword [esp + 0x224]
push 1
push edi
push esi
push edx
push eax
call fcn.0040ce70
mov ecx, dword [esp + 0x2c]
add esp, 0x14
mov ebp, eax
push 0
push ebp
push 0x4006
push ecx
call sub.MSVFW32.dll_ICSendMessage
test eax, eax
jne 0x40c3a0
cmp ebx, 1
je 0x40c4ca
cmp ebx, 8
jg 0x40c488
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x20]
mov dword [esp + 0x224], edx
mov dword [esp + 0x220], eax
mov dword [esp + 0x228], esi
mov dword [esp + 0x22c], edi
mov dword [0x461984], esi
mov dword [0x461988], edi
jmp 0x40c4ca
push str.MS_Video_1
lea ecx, [esp + 0x18]
mov dword [0x461954], 0x4356534d
call fcn.0042f4f9
push eax
mov ecx, 0x461808
mov dword [esp + 0x21c], 0
call fcn.0042f5c4
lea ecx, [esp + 0x14]
mov dword [esp + 0x218], 0xffffffff
call fcn.0042f48b
mov ecx, dword [esp + 0x18]
push ecx
call sub.MSVFW32.dll_ICClose
mov edi, dword [esp + 0x224]
mov esi, dword [esp + 0x228]
mov ebx, dword [esp + 0x22c]
jmp 0x40c52d
push str.MS_Video_1
lea ecx, [esp + 0x18]
mov dword [0x461954], 0x4356534d
call fcn.0042f4f9
push eax
mov ecx, 0x461808
mov dword [esp + 0x21c], 1
call fcn.0042f5c4
lea ecx, [esp + 0x14]
mov dword [esp + 0x218], 0xffffffff
call fcn.0042f48b
cmp dword [0x461954], 0x30355649
jne 0x40c57b
push str.MS_Video_1
lea ecx, [esp + 0x18]
mov dword [0x461954], 0x4356534d
call fcn.0042f4f9
push eax
mov ecx, 0x461808
mov dword [esp + 0x21c], 2
call fcn.0042f5c4
lea ecx, [esp + 0x14]
mov dword [esp + 0x218], 0xffffffff
call fcn.0042f48b
mov eax, dword [0x45e8c8]
test eax, eax
je 0x40c5c0
mov eax, dword [0x4619a4]
test eax, eax
je 0x40c59b
mov edx, dword [esp + 0x220]
push 1
push ebx
push esi
push edx
jmp 0x40c5a7
mov eax, dword [esp + 0x220]
push 0
push ebx
push esi
push eax
mov ecx, dword [0x461924]
push edi
call fcn.004058d0
mov ecx, dword [0x461924]
push 5
call fcn.0042eb46
call sub.AVIFIL32.dll_AVIFileInit
mov edi, str.AVI_Movie
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x10c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x30]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x234]
xor esi, esi
push esi
push 0x1001
push ecx
push edx
call sub.AVIFIL32.dll_AVIFileOpenA
cmp eax, esi
mov dword [esp + 0x28], eax
jne 0x40ccde
mov ecx, 0x23
xor eax, eax
lea edi, [esp + 0x80]
mov ebx, 1
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x230]
mov dword [esp + 0x80], 0x73646976
mov dword [esp + 0x84], esi
mov dword [esp + 0x94], ebx
mov dword [esp + 0x98], eax
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0xa8], ecx
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 4]
push edx
push eax
push esi
lea ecx, [esp + 0xc0]
push esi
push ecx
call dword [sym.imp.USER32.dll_SetRect]
mov ecx, dword [esp + 0x30]
lea edx, [esp + 0x80]
lea eax, [esp + 0x34]
push edx
push eax
push ecx
call sub.AVIFIL32.dll_AVIFileCreateStreamA
cmp eax, esi
mov dword [esp + 0x28], eax
jne 0x40ccde
mov edx, dword [esp + 0x10]
mov ecx, 0xb
xor eax, eax
lea edi, [esp + 0x54]
rep stosd dword es:[edi], eax
mov dword [edx], 0x73646976
mov eax, dword [esp + 0x10]
mov ecx, dword [0x461954]
mov dword [eax + 4], ecx
mov edx, dword [esp + 0x10]
mov eax, dword [0x45e8e0]
mov dword [edx + 8], eax
mov ecx, dword [esp + 0x10]
mov edx, dword [0x45e8e4]
mov dword [ecx + 0xc], edx
mov eax, dword [esp + 0x10]
mov dword [eax + 0x10], esi
mov ecx, dword [esp + 0x10]
mov dword [ecx + 0x14], 0xc
mov edx, dword [esp + 0x10]
mov dword [edx + 0x18], esi
mov eax, dword [esp + 0x10]
mov dword [eax + 0x1c], esi
mov ecx, dword [esp + 0x10]
mov dword [ecx + 0x28], esi
mov eax, dword [0x461954]
cmp eax, dword [0x461964]
jne 0x40c73d
cmp eax, esi
je 0x40c73d
mov edx, dword [0x461960]
mov eax, dword [0x461968]
push edx
push eax
call fcn.00410680
add esp, 8
test eax, eax
je 0x40c73d
mov ecx, dword [esp + 0x10]
mov edx, dword [0x46196c]
mov dword [ecx + 0x20], edx
mov eax, dword [esp + 0x10]
mov ecx, dword [0x461968]
mov dword [eax + 0x24], ecx
mov eax, dword [esp + 0x34]
lea edx, [esp + 0x54]
push esi
push edx
lea ecx, [esp + 0x34]
push eax
push ecx
call sub.AVIFIL32.dll_AVIMakeCompressedStream
cmp eax, esi
mov dword [esp + 0x28], eax
jne 0x40ccde
mov edx, dword [ebp + 0x20]
mov eax, dword [ebp]
lea ecx, [eax + edx*4]
mov edx, dword [esp + 0x2c]
push ecx
push ebp
push esi
push edx
call sub.AVIFIL32.dll_AVIStreamSetFormat
cmp eax, esi
mov dword [esp + 0x28], eax
jne 0x40ccde
push ebp
call fcn.0040d170
add esp, 4
call dword [sym.imp.WINMM.dll_timeGetTime]
mov dword [0x461938], eax
mov eax, dword [0x4619a4]
cmp eax, esi
mov dword [0x46193c], ebx
mov dword [esp + 0x14], esi
mov dword [0x461974], esi
mov dword [0x461970], esi
je 0x40c7ec
mov eax, dword [esp + 0x224]
mov edx, dword [esp + 0x228]
mov ecx, dword [esp + 0x220]
mov dword [0x4617d0], eax
lea eax, [eax + edx - 1]
mov edx, dword [esp + 0x22c]
mov dword [0x4617d8], eax
mov dword [0x4617d4], ecx
lea eax, [ecx + edx - 1]
mov dword [0x4617dc], eax
cmp dword [0x4619a8], esi
je 0x40c806
call fcn.0040ed00
push 0x461848
call fcn.0040f080
add esp, 4
mov eax, dword [0x461928]
mov dword [esp + 0x20], esi
cmp eax, esi
je 0x40ccde
mov eax, dword [0x46193c]
xor esi, esi
cmp eax, esi
jne 0x40c834
call dword [sym.imp.WINMM.dll_timeGetTime]
sub eax, dword [0x461938]
mov dword [esp + 0x18], eax
jmp 0x40c83c
mov dword [esp + 0x1c], esi
mov dword [esp + 0x18], esi
cmp dword [0x4619a4], esi
je 0x40ca83
mov ecx, dword [esp + 0x228]
mov eax, dword [0x4618a4]
cmp ecx, eax
jge 0x40ca83
mov edx, dword [esp + 0x22c]
mov eax, dword [0x461804]
cmp edx, eax
jge 0x40ca83
lea eax, [esp + 0x3c]
push eax
call dword [sym.imp.USER32.dll_GetCursorPos]
mov ecx, dword [0x4617d8]
mov ebx, dword [0x4617d0]
sub ecx, ebx
mov eax, ecx
cdq
and edx, 3
add eax, edx
mov esi, eax
lea eax, [ecx + ecx*2]
cdq
and edx, 3
mov ecx, dword [0x4617dc]
add eax, edx
mov edi, eax
sar esi, 2
sar edi, 2
add esi, ebx
add edi, ebx
mov ebx, dword [0x4617d4]
sub ecx, ebx
mov eax, ecx
cdq
and edx, 3
add eax, edx
mov ebp, eax
lea eax, [ecx + ecx*2]
cdq
and edx, 3
add eax, edx
mov ecx, eax
sar ebp, 2
sar ecx, 2
add ebp, ebx
add ecx, ebx
mov ebx, dword [esp + 0x3c]
cmp ebx, esi
jge 0x40c910
mov esi, dword [esp + 0x228]
mov eax, esi
cdq
sub eax, edx
sar eax, 1
sub ebx, eax
lea eax, [esi - 1]
mov dword [0x461838], ebx
lea edx, [ebx + eax]
mov dword [0x461840], edx
jns 0x40c961
xor ebx, ebx
mov dword [0x461840], eax
mov dword [0x461838], ebx
jmp 0x40c961
cmp ebx, edi
jle 0x40c94b
mov esi, dword [esp + 0x228]
mov eax, esi
cdq
sub eax, edx
mov edx, dword [0x4618a4]
sar eax, 1
sub ebx, eax
mov dword [0x461838], ebx
lea eax, [ebx + esi - 1]
cmp eax, edx
mov dword [0x461840], eax
jl 0x40c961
lea ebx, [edx - 1]
mov dword [0x461840], ebx
sub ebx, esi
inc ebx
jmp 0x40c95b
mov eax, dword [0x4617d8]
mov ebx, dword [0x4617d0]
mov dword [0x461840], eax
mov dword [0x461838], ebx
mov esi, dword [esp + 0x40]
cmp esi, ebp
jge 0x40c99d
mov ecx, dword [esp + 0x22c]
mov eax, ecx
cdq
sub eax, edx
lea edx, [ecx - 1]
sar eax, 1
sub esi, eax
mov eax, esi
mov dword [0x46183c], eax
lea esi, [eax + edx]
mov dword [0x461844], esi
jns 0x40c9fb
xor eax, eax
mov dword [0x461844], edx
mov dword [0x46183c], eax
jmp 0x40c9fb
cmp esi, ecx
jle 0x40c9de
mov ecx, dword [esp + 0x22c]
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
sub esi, eax
mov eax, esi
mov esi, dword [0x461804]
mov dword [0x46183c], eax
lea edx, [eax + ecx - 1]
cmp edx, esi
mov dword [0x461844], edx
jl 0x40c9fb
lea eax, [esi - 1]
mov dword [0x461844], eax
sub eax, ecx
inc eax
mov dword [0x46183c], eax
jmp 0x40c9fb
mov ecx, dword [0x4617dc]
mov eax, dword [0x4617d4]
mov dword [0x461844], ecx
mov ecx, dword [esp + 0x22c]
mov dword [0x46183c], eax
mov ebp, dword [0x4617d4]
mov esi, dword [0x4617d0]
sub eax, ebp
sub ebx, esi
mov ebp, eax
mov edi, dword [0x45e8fc]
mov eax, ebx
cdq
xor eax, edx
sub eax, edx
cmp eax, edi
jge 0x40ca22
add esi, ebx
jmp 0x40ca2c
test ebx, ebx
jge 0x40ca2a
sub esi, edi
jmp 0x40ca2c
add esi, edi
mov eax, ebp
mov dword [0x4617d0], esi
cdq
xor eax, edx
sub eax, edx
cmp eax, edi
jge 0x40ca46
mov eax, dword [0x4617d4]
add eax, ebp
jmp 0x40ca55
mov eax, dword [0x4617d4]
test ebp, ebp
jge 0x40ca53
sub eax, edi
jmp 0x40ca55
add eax, edi
mov dword [0x4617d4], eax
mov eax, dword [esp + 0x228]
push 0
push ecx
lea edx, [esi + eax - 1]
push eax
mov dword [0x4617d8], edx
mov edx, dword [0x4617d4]
push edx
push esi
lea edi, [edx + ecx - 1]
mov dword [0x4617dc], edi
jmp 0x40caa4
mov eax, dword [esp + 0x22c]
mov ecx, dword [esp + 0x228]
mov edx, dword [esp + 0x220]
push esi
push eax
mov eax, dword [esp + 0x22c]
push ecx
push edx
push eax
call fcn.0040ce70
mov edi, dword [0x45e8d8]
mov esi, eax
mov eax, dword [0x46193c]
xor ebx, ebx
add esp, 0x14
cmp eax, ebx
jne 0x40cb01
cmp edi, 0x3e8
jle 0x40cad2
mov eax, dword [esp + 0x1c]
inc eax
mov dword [esp + 0x1c], eax
jmp 0x40cb0b
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x48], ebx
mov dword [esp + 0x44], ecx
fild qword [esp + 0x44]
fmul qword [0x44e318]
fild dword [0x45e8d8]
fdivr qword [0x44e310]
fmulp st(1)
call fcn.0041a0e0
mov dword [esp + 0x1c], eax
jmp 0x40cb0b
mov eax, dword [esp + 0x1c]
mov dword [0x46193c], ebx
mov edx, dword [esp + 0x18]
mov dword [esp + 0x50], ebx
mov dword [esp + 0x4c], edx
cmp eax, ebx
fild qword [esp + 0x4c]
fmul dword [0x44e308]
fstp dword [0x461980]
je 0x40cb35
cmp eax, dword [esp + 0x14]
jbe 0x40cbd5
mov ecx, dword [esi + 0x14]
mov edx, dword [esi + 0x20]
push ebx
push ebx
push ebx
push ecx
mov ecx, dword [esi]
lea edx, [ecx + edx*4]
add edx, esi
push edx
push 1
push eax
mov eax, dword [esp + 0x48]
push eax
call sub.AVIFIL32.dll_AVIStreamWrite
cmp eax, ebx
mov dword [esp + 0x28], eax
jne 0x40ccde
fild dword [esp + 0x1c]
mov edx, dword [0x461970]
mov eax, 0x10624dd3
inc edx
mov edi, dword [esp + 0x1c]
fdiv dword [0x461980]
mov dword [0x461970], edx
mov dword [0x461974], edi
fstp dword [0x461978]
mul dword [esp + 0x18]
fild dword [0x461970]
fdiv dword [0x461980]
mov eax, dword [esp + 0x20]
shr edx, 5
cmp edx, eax
fstp dword [0x46197c]
je 0x40cbc2
mov ecx, dword [0x461944]
push 0
push 0
push ecx
mov dword [esp + 0x2c], edx
call dword [sym.imp.USER32.dll_InvalidateRect]
push esi
call fcn.0040d170
mov dword [esp + 0x18], edi
mov edi, dword [0x45e8d8]
add esp, 4
mov ecx, dword [0x46192c]
xor ebx, ebx
xor eax, eax
cmp ecx, ebx
mov dword [esp + 0x18], ebx
mov esi, 1
je 0x40cc8c
mov ebp, dword [sym.imp.WINMM.dll_timeGetTime]
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
mov ebx, dword [esp + 0x24]
test eax, eax
jne 0x40cc08
call ebp
mov ebx, eax
mov eax, dword [esp + 0x18]
inc eax
mov dword [esp + 0x18], eax
and eax, reloc.OLEAUT32.dll_VariantInit
jns 0x40cc1d
dec eax
or eax, 0xfffffff8
inc eax
jne 0x40cc61
test esi, esi
push ecx
je 0x40cc40
mov ecx, esp
mov dword [esp + 0x3c], esp
push 0x4616bc
call fcn.0042f4f9
call fcn.004104d0
add esp, 4
xor esi, esi
jmp 0x40cc61
mov edx, esp
mov dword [esp + 0x3c], esp
push 0xf049
push edx
call fcn.0040eb10
add esp, 8
call fcn.004104d0
add esp, 4
mov esi, 1
push 0x32
call edi
mov ecx, dword [0x46192c]
mov eax, 1
test ecx, ecx
jne 0x40cc00
mov dword [esp + 0x24], ebx
call ebp
mov ecx, dword [0x461938]
sub eax, ebx
add ecx, eax
mov dword [0x461938], ecx
jmp 0x40ccd1
mov eax, 0x51eb851f
mov ebp, dword [sym.imp.KERNEL32.dll_Sleep]
imul edi
sar edx, 4
mov eax, edx
shr eax, 0x1f
add edx, eax
mov esi, edx
lea eax, [esi + esi*4]
lea ecx, [eax + eax*4]
shl ecx, 1
sub edi, ecx
test esi, esi
jle 0x40ccc5
push 0x32
call ebp
mov eax, dword [0x461928]
test eax, eax
je 0x40ccc5
inc ebx
cmp ebx, esi
jl 0x40ccb3
cmp dword [0x461928], 1
jne 0x40ccd1
push edi
call ebp
mov eax, dword [0x461928]
test eax, eax
jne 0x40c817
mov eax, dword [0x45e8c8]
xor ebx, ebx
cmp eax, ebx
je 0x40ccf5
mov ecx, dword [0x461924]
push ebx
call fcn.0042eb46
mov eax, dword [0x461954]
mov ecx, dword [0x461964]
cmp eax, ecx
jne 0x40cd16
cmp eax, ebx
je 0x40cd16
mov edx, dword [esp + 0x10]
mov dword [edx + 0x20], ebx
mov eax, dword [esp + 0x10]
mov dword [eax + 0x24], ebx
lea ecx, [esp + 0x10]
push ecx
push 1
call sub.AVIFIL32.dll_AVISaveOptionsFree
cmp dword [0x4619a8], ebx
je 0x40cd34
call fcn.0040f220
call fcn.0040f060
mov eax, dword [esp + 0x30]
cmp eax, ebx
je 0x40cd42
push eax
call sub.AVIFIL32.dll_AVIFileRelease
mov eax, dword [esp + 0x34]
cmp eax, ebx
je 0x40cd50
push eax
call sub.AVIFIL32.dll_AVIStreamRelease
mov eax, dword [esp + 0x2c]
cmp eax, ebx
je 0x40cd5e
push eax
call sub.AVIFIL32.dll_AVIStreamRelease
call sub.AVIFIL32.dll_AVIFileExit
mov eax, dword [esp + 0x28]
push ebx
cmp eax, ebx
push ebx
je 0x40ce3a
mov edx, dword [0x4617e4]
mov eax, dword [0x461944]
mov edi, dword [sym.imp.USER32.dll_PostMessageA]
push edx
push eax
call edi
mov eax, dword [0x461954]
mov ebp, 0x4356534d
cmp eax, ebp
je 0x40ce24
lea ecx, [esp + 0x20]
push 0xf04a
push ecx
call fcn.0040eb10
mov esi, dword [eax]
lea edx, [esp + 0x2c]
push 0xf2b3
push edx
mov dword [esp + 0x228], 3
call fcn.0040eb10
mov eax, dword [eax]
add esp, 0x10
push 0x34
push esi
push eax
push ebx
call dword [sym.imp.USER32.dll_MessageBoxA]
cmp eax, 6
lea ecx, [esp + 0x24]
sete bl
call fcn.0042f48b
lea ecx, [esp + 0x20]
mov dword [esp + 0x218], 0xffffffff
call fcn.0042f48b
test bl, bl
je 0x40ce4d
push str.MS_Video_1
mov ecx, 0x461808
mov dword [0x461954], ebp
call fcn.0042f614
mov eax, dword [0x4618a8]
mov ecx, dword [0x461944]
push 0
push 0
push eax
push ecx
call edi
jmp 0x40ce4d
push 0x30
push 0xf04b
push 0xf2b4
call fcn.0040eb90
add esp, 0xc
jmp 0x40ce4d
mov edx, dword [0x461860]
mov eax, dword [0x461944]
push edx
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
mov ecx, dword [esp + 0x210]
pop edi
pop esi
pop ebp
xor eax, eax
mov dword fs:[0], ecx
pop ebx
add esp, 0x20c
ret