Function at 0x402980
Capabilities:
Move file

Disassembly:
sub esp, 0x118
mov eax, dword [0x422f80]
xor eax, esp
mov dword [esp + 0x114], eax
cmp dword [0x4244bc], 6
mov eax, dword [esp + 0x120]
push ebx
push ebp
push esi
push edi
mov esi, ecx
mov dword [esp + 0x20], eax
jne 0x4029be
mov ebx, str.Devs6.out
mov dword [esp + 0x1c], ebx
mov eax, str.Devs6.cfg
jmp 0x4029cc
mov ebx, str.Devs1x8.out
mov dword [esp + 0x1c], ebx
mov eax, str.Devs1x8.cfg
push 0x41d618
push eax
call fcn.0040b381
mov ebp, eax
push 0x41d614
push ebx
mov dword [esp + 0x24], ebp
call fcn.0040b381
add esp, 0x10
test ebp, ebp
mov edi, eax
mov dword [esp + 0x18], edi
je 0x4031d7
test edi, edi
je 0x4031d7
mov eax, 0xa
cmp dword [esi + 0x49c], eax
jae 0x402a14
mov dword [esi + 0x49c], eax
mov ecx, 0x14
cmp dword [esi + 0x4a0], ecx
jge 0x402a27
mov dword [esi + 0x4a0], ecx
mov eax, 0x7d00
cmp dword [esi + 0x4a0], eax
jle 0x402a3a
mov dword [esi + 0x4a0], eax
cmp dword [esi + 0x4a4], ecx
jge 0x402a48
mov dword [esi + 0x4a4], ecx
mov ecx, dword [esp + 0x14]
push ecx
lea ebx, [esi + 8]
push 0xff
push ebx
mov dword [esp + 0x1c], 0
call fcn.0040b136
add esp, 0xc
test eax, eax
mov ebp, 1
je 0x4030d7
push 0xd
push ebx
call fcn.0040aca0
add esp, 8
test eax, eax
je 0x402a85
mov byte [eax], 0
push 0xa
push ebx
call fcn.0040aca0
add esp, 8
test eax, eax
je 0x402a97
mov byte [eax], 0
mov eax, ebx
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x402aa0
sub eax, edx
cmp eax, 1
jb 0x4030b1
push 0x41d53c
push ebx
call fcn.0040b0f0
add esp, 8
test eax, eax
je 0x402adc
add eax, ebx
mov edx, ebx
sub edx, eax
lea esp, [esp]
mov cl, byte [eax]
mov byte [eax + edx], cl
add eax, 1
test cl, cl
jne 0x402ad0
push 0x3d
push ebx
call fcn.0040aca0
push 7
push str.Xwindow
push ebx
mov ebp, eax
call fcn.0040b02b
add esp, 0x14
test eax, eax
jne 0x402b12
mov edx, dword [esi + 0xa58]
push edx
lea eax, [ebp + 1]
push 0x41d4cc
push eax
call fcn.0040a5ea
add esp, 0xc
push 7
push str.Ywindow
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402b3e
mov ecx, dword [esi + 0xa5c]
push ecx
lea edx, [ebp + 1]
push 0x41d4cc
push edx
call fcn.0040a5ea
add esp, 0xc
cmp dword [esp + 0x12c], 0
jne 0x402b89
push 7
push str.Xwindow
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
je 0x402b89
push 7
push str.Ywindow
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
je 0x402b89
push ebx
push 0x41d610
push edi
mov dword [esp + 0x1c], 1
call fcn.0040b3c3
jmp 0x4030ae
mov eax, 1
mov dword [esi + 4], eax
cmp dword [0x4244bc], eax
jl 0x402c10
mov edi, eax
jmp 0x402ba0
mov eax, dword [esi + 4]
push eax
lea ecx, [esp + 0x28]
push str.Color_d
push ecx
call fcn.0040a5ea
lea eax, [esp + 0x30]
add esp, 0xc
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x402bc0
sub eax, edx
push eax
lea edx, [esp + 0x28]
push edx
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
je 0x402bee
add dword [esi + 4], edi
mov eax, dword [esi + 4]
cmp eax, dword [0x4244bc]
jle 0x402ba0
jmp 0x402c0e
mov ecx, dword [esi + 4]
mov edx, dword [esi + ecx*4 + 0xa0c]
push edx
lea eax, [ebp + 1]
push str.___08x
push eax
call fcn.0040a5ea
add esp, 0xc
mov dword [esp + 0x10], edi
mov eax, edi
mov dword [esi + 4], eax
cmp dword [0x4244bc], eax
jl 0x402c91
mov edi, 1
mov ecx, dword [esi + 4]
push ecx
lea edx, [esp + 0x28]
push str.Scale_d
push edx
call fcn.0040a5ea
lea eax, [esp + 0x30]
add esp, 0xc
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x402c40
sub eax, edx
push eax
lea eax, [esp + 0x28]
push eax
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
je 0x402c6e
add dword [esi + 4], edi
mov ecx, dword [esi + 4]
cmp ecx, dword [0x4244bc]
jle 0x402c20
jmp 0x402c8f
mov edx, dword [esi + 4]
fld dword [esi + edx*4 + 0x4cc]
sub esp, 8
fstp qword [esp]
lea eax, [ebp + 1]
push 0x41d604
push eax
call fcn.0040a5ea
add esp, 0x10
mov eax, edi
mov dword [esi + 4], eax
cmp dword [0x4244bc], eax
jl 0x402d11
mov edi, 1
mov ecx, dword [esi + 4]
push ecx
lea edx, [esp + 0x28]
push str.StartRecordLevel_d
push edx
call fcn.0040a5ea
lea eax, [esp + 0x30]
add esp, 0xc
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x402cc0
sub eax, edx
push eax
lea eax, [esp + 0x28]
push eax
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
je 0x402cee
add dword [esi + 4], edi
mov ecx, dword [esi + 4]
cmp ecx, dword [0x4244bc]
jle 0x402ca1
jmp 0x402d0f
mov edx, dword [esi + 4]
fld dword [esi + edx*4 + 0x414]
sub esp, 8
fstp qword [esp]
lea eax, [ebp + 1]
push 0x41d604
push eax
call fcn.0040a5ea
add esp, 0x10
mov eax, edi
mov dword [esi + 4], eax
cmp dword [0x4244bc], eax
jl 0x402da1
mov edi, 1
mov ecx, dword [esi + 4]
push ecx
lea edx, [esp + 0x28]
push str.AverageNumber_d
push edx
call fcn.0040a5ea
lea eax, [esp + 0x30]
add esp, 0xc
lea edx, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x402d42
sub eax, edx
push eax
lea eax, [esp + 0x28]
push eax
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
je 0x402d70
add dword [esi + 4], edi
mov ecx, dword [esi + 4]
cmp ecx, dword [0x4244bc]
jle 0x402d25
jmp 0x402da1
mov edx, dword [esi + 4]
cmp dword [esi + edx*4 + 0x4ac], edi
lea eax, [esi + edx*4 + 0x4ac]
jae 0x402d85
mov dword [eax], edi
mov eax, dword [esi + 4]
mov ecx, dword [esi + eax*4 + 0x4ac]
push ecx
lea edx, [ebp + 1]
push 0x41d600
push edx
call fcn.0040a5ea
add esp, 0xc
push 9
push str.COMNumber
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402dce
lea eax, [esi + 0x108]
mov ecx, ebp
sub ecx, eax
lea edx, [ecx + 1]
mov cl, byte [eax]
mov byte [edx + eax], cl
add eax, 1
test cl, cl
jne 0x402dc2
push 7
push str.DevName
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402e24
push 0x22
push ebp
call fcn.0040aca0
lea edi, [eax + 1]
lea ecx, [esi + 0x114]
mov edx, edi
add esp, 8
sub edx, ecx
lea ebx, [ebx]
mov al, byte [ecx]
mov byte [edx + ecx], al
add ecx, 1
test al, al
jne 0x402e00
add edi, 0xffffffff
nop
mov al, byte [edi + 1]
add edi, 1
test al, al
jne 0x402e10
mov dx, word [0x41d5fc]
mov word [edi], dx
push 6
push str.Folder
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402e5c
push 0x3a
push ebp
lea edi, [esi + 0x314]
call fcn.0040aca0
add esp, 8
sub eax, edi
lea ecx, [eax - 1]
mov edi, edi
mov al, byte [edi]
mov byte [ecx + edi], al
add edi, 1
test al, al
jne 0x402e50
push 0x10
push str.StartMeasureType
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402e88
mov eax, dword [esi + 0x414]
push eax
lea ecx, [ebp + 1]
push 0x41d5f8
push ecx
call fcn.0040a5ea
add esp, 0xc
push 0xd
push str.MaxFileLength
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402eb4
mov edx, dword [esi + 0x49c]
push edx
lea eax, [ebp + 1]
push 0x41d5f8
push eax
call fcn.0040a5ea
add esp, 0xc
push 0x12
push str.StartRecordPrequel
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402ee0
mov ecx, dword [esi + 0x4a0]
push ecx
lea edx, [ebp + 1]
push 0x41d5f8
push edx
call fcn.0040a5ea
add esp, 0xc
push 0x10
push str.DelayRecordAfter
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402f0c
mov eax, dword [esi + 0x4a4]
push eax
lea ecx, [ebp + 1]
push 0x41d5f8
push ecx
call fcn.0040a5ea
add esp, 0xc
push 0xf
push str.StartRecordTime
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402f3d
fld qword [esi + 0x4a8]
sub esp, 8
fstp qword [esp]
lea edx, [ebp + 1]
push str.__lg
push edx
call fcn.0040a5ea
add esp, 0x10
push 8
push str.ICPstate
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402f69
mov eax, dword [esi + 0xa50]
push eax
lea ecx, [ebp + 1]
push 0x41d5f8
push ecx
call fcn.0040a5ea
add esp, 0xc
push 0xc
push str.ReadChannels
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x402fbd
push 0x5b
push ebp
call fcn.0040aca0
push 0x5d
push ebp
mov edi, eax
call fcn.0040aca0
add esp, 0x10
test edi, edi
je 0x402fbd
test eax, eax
je 0x402fbd
mov ecx, dword [0x4244bc]
sub eax, edi
lea edx, [ecx + 1]
cmp eax, edx
jne 0x402fbd
push ecx
lea eax, [esi + 0x438]
push eax
add edi, 1
push edi
call fcn.0040ae80
add esp, 0xc
push 0xf
push str.AnalyzeChannels
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x403011
push 0x5b
push ebp
call fcn.0040aca0
push 0x5d
push ebp
mov edi, eax
call fcn.0040aca0
add esp, 0x10
test edi, edi
je 0x403011
test eax, eax
je 0x403011
mov ecx, dword [0x4244bc]
sub eax, edi
lea edx, [ecx + 1]
cmp eax, edx
jne 0x403011
push ecx
lea eax, [esi + 0x458]
push eax
add edi, 1
push edi
call fcn.0040ae80
add esp, 0xc
push 0xe
push str.RecordChannels
push ebx
call fcn.0040b02b
add esp, 0xc
test eax, eax
jne 0x40309a
push 0x5b
push ebp
call fcn.0040aca0
push 0x5d
push ebp
mov edi, eax
call fcn.0040aca0
add esp, 0x10
test edi, edi
je 0x403065
test eax, eax
je 0x403065
mov ecx, dword [0x4244bc]
sub eax, edi
lea edx, [ecx + 1]
cmp eax, edx
jne 0x403065
push ecx
lea eax, [esi + 0x478]
push eax
add edi, 1
push edi
call fcn.0040ae80
add esp, 0xc
xor eax, eax
mov dword [esi + 0x498], eax
cmp dword [0x4244bc], eax
jle 0x40309a
mov ecx, 1
lea ebx, [ebx]
cmp byte [esi + eax + 0x478], 0x2b
jne 0x403090
add dword [esi + 0x498], ecx
add eax, ecx
cmp eax, dword [0x4244bc]
jl 0x403080
mov ecx, dword [esp + 0x18]
push ebx
push 0x41d610
push ecx
call fcn.0040b3c3
mov edi, dword [esp + 0x24]
add esp, 0xc
mov edx, dword [esp + 0x14]
push edx
push 0xff
push ebx
call fcn.0040b136
add esp, 0xc
test eax, eax
jne 0x402a73
cmp dword [esp + 0x10], eax
jne 0x403138
mov ebp, 1
push 0x41d5ec
push edi
call fcn.0040b3c3
push 0x41d5cc
push edi
call fcn.0040b3c3
push 0x41d5ec
push edi
call fcn.0040b3c3
add esp, 0x18
mov dword [esi + 4], ebp
cmp dword [0x4244bc], ebp
jl 0x403138
jmp 0x403110
mov eax, dword [esi + 4]
mov ecx, dword [esi + eax*4 + 0xa0c]
push ecx
push eax
push str.Color_d____08x_n
push edi
call fcn.0040b3c3
add dword [esi + 4], ebp
mov edx, dword [esi + 4]
add esp, 0x10
cmp edx, dword [0x4244bc]
jle 0x403110
push edi
call fcn.0040ae00
mov eax, dword [esp + 0x18]
push eax
call fcn.0040ae00
mov edi, dword [esp + 0x28]
add esp, 8
test edi, edi
je 0x403157
mov eax, edi
jmp 0x40316a
cmp dword [0x4244bc], 6
mov eax, str.Devs6.cfg
je 0x40316a
mov eax, str.Devs1x8.cfg
push eax
call fcn.0040b3be
add esp, 4
test edi, edi
je 0x40317b
mov eax, edi
jmp 0x40318e
cmp dword [0x4244bc], 6
mov eax, str.Devs6.cfg
je 0x40318e
mov eax, str.Devs1x8.cfg
mov ecx, dword [esp + 0x1c]
push 9
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_MoveFileExA]
xor edi, edi
mov dword [esi + 0xa54], 0
cmp dword [0x4244bc], edi
jle 0x4031d7
mov ebp, dword [sym.imp.GDI32.dll_DeleteObject]
add esi, 0xa30
lea esp, [esp]
mov eax, dword [esi]
test eax, eax
je 0x4031c9
push eax
call ebp
add edi, 1
add esi, 4
cmp edi, dword [0x4244bc]
jl 0x4031c0
mov ecx, dword [esp + 0x124]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0040a665
add esp, 0x118
ret 8