Function at 0x411cd0
Capabilities:
Check if file exists
Check os version
Create thread
Get file attributes
Link many functions at runtime
Query environment variable
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x640
push ebx
push esi
push edi
xor eax, eax
mov ecx, 0x25
lea edi, [ebp - 0x240]
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x240]
push eax
mov dword [ebp - 0x240], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov eax, dword [ebp - 0x230]
mov ecx, 2
cmp eax, ecx
jne 0x411d31
mov eax, dword [ebp - 0x23c]
cmp eax, 6
ja 0x411d26
jne 0x411d31
cmp dword [ebp - 0x238], ecx
jb 0x411d31
mov byte [0x5138a9], 1
xor ebx, ebx
jmp 0x411d39
xor ebx, ebx
mov byte [0x5138a9], bl
push str.mz2200
push str._s.ini
call fcn.0049c650
push eax
call fcn.0049cfb0
mov eax, dword [ebp + 8]
add esp, 0xc
push 0x66
push eax
mov dword [ebp - 0x54], 3
mov dword [ebp - 0x50], 0x412b30
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x44], eax
call dword [sym.imp.USER32.dll_LoadIconA]
push 0x7f00
push ebx
mov dword [ebp - 0x40], eax
call dword [sym.imp.USER32.dll_LoadCursorA]
push 4
mov dword [ebp - 0x3c], eax
call dword [sym.imp.GDI32.dll_GetStockObject]
lea ecx, [ebp - 0x54]
push ecx
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], 0x65
mov dword [ebp - 0x30], str.CWINDOW
call dword [sym.imp.USER32.dll_RegisterClassA]
push 1
push 0x10ca0000
lea edx, [ebp - 0x1c]
push edx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], 0x280
mov dword [ebp - 0x10], 0x190
call dword [sym.imp.USER32.dll_AdjustWindowRect]
push ebx
call dword [sym.imp.USER32.dll_GetDC]
mov edi, dword [sym.imp.GDI32.dll_GetDeviceCaps]
mov esi, eax
push 8
push esi
call edi
push 0xa
push esi
mov dword [0x51344c], eax
call edi
push 0xc
push esi
mov dword [0x513048], eax
call edi
push esi
push ebx
mov dword [0x513648], eax
call dword [sym.imp.USER32.dll_ReleaseDC]
mov edi, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x14]
mov edx, dword [0x51344c]
mov esi, dword [ebp - 0x10]
mov eax, edi
sub eax, ecx
add eax, edx
cdq
sub eax, edx
mov edx, dword [0x513048]
sar eax, 1
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x18]
sub eax, esi
add eax, edx
cdq
sub eax, edx
mov edx, dword [0x9096c0]
sar eax, 1
cmp edx, ebx
jl 0x411e44
mov eax, dword [0x9096c4]
mov dword [ebp - 4], edx
xor edx, edx
cmp eax, ebx
setl dl
push ebx
sub ecx, edi
dec edx
and eax, edx
mov edx, dword [ebp + 8]
push edx
mov edx, dword [ebp - 0x18]
push ebx
push ebx
sub esi, edx
push esi
push ecx
push eax
mov dword [ebp - 8], eax
mov eax, dword [ebp - 4]
push eax
push 0x10ca0000
push str.SHARP_MZ_2200
push str.CWINDOW
push ebx
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov ecx, dword [ebp + 0x14]
mov esi, eax
push ecx
push esi
mov dword [ebp - 0xc], esi
call dword [sym.imp.USER32.dll_ShowWindow]
push esi
call dword [sym.imp.USER32.dll_UpdateWindow]
push esi
call fcn.00417ed0
mov al, byte [0x9097d5]
add esp, 4
cmp al, bl
je 0x411ef2
push 4
call fcn.004a98ab
add esp, 4
cmp eax, ebx
mov dword [ebp + 0x14], eax
je 0x411ee0
push ebx
push ebx
push str.PATH
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
mov edi, eax
inc edi
push edi
call fcn.004a98ab
mov ecx, dword [ebp + 0x14]
add esp, 4
push edi
push eax
mov dword [ecx], eax
call fcn.00412a10
mov ecx, dword [ebp + 0x14]
jmp 0x411ee2
xor ecx, ecx
push 0x9097d5
mov dword [0x5138c0], ecx
call fcn.00412a30
push 0x40
call fcn.004a98ab
mov edi, eax
add esp, 4
cmp edi, ebx
je 0x412051
push str.keyemudi.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
cmp eax, ebx
mov dword [edi], eax
je 0x412018
push str.ked_create
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edx, dword [edi]
push str.ked_create_did8
push edx
mov dword [edi + 4], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [edi + 8], eax
mov eax, dword [edi]
push str.ked_release
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [edi]
push str.ked_reset
push ecx
mov dword [edi + 0xc], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edx, dword [edi]
push str.ked_clear
push edx
mov dword [edi + 0x10], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [edi + 0x14], eax
mov eax, dword [edi]
push str.ked_acquire
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [edi]
push str.ked_get
push ecx
mov dword [edi + 0x18], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edx, dword [edi]
push str.ked_setdelay
push edx
mov dword [edi + 0x1c], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [edi + 0x20], eax
mov eax, dword [edi]
push str.ked_usemmtimer
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [edi]
push str.ked_updatecounter
push ecx
mov dword [edi + 0x24], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edx, dword [edi]
push str.ked_setconverttable
push edx
mov dword [edi + 0x28], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [edi + 0x30], eax
mov eax, dword [edi]
push str.ked_getconverttable
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [edi]
push str.ked_getdevicestate
push ecx
mov dword [edi + 0x2c], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edx, dword [edi]
push str.ked_setnumlock
push edx
mov dword [edi + 0x34], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [edi + 0x38], eax
mov eax, dword [edi]
push str.ked_setkeyboardstate
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [edi + 0x3c], eax
cmp dword [edi], ebx
je 0x412039
mov ecx, dword [0x513894]
push str.Use_DirectInput__keyemudi_
push 0xa0fa
push ebx
push 0xa0fa
push ecx
call dword [sym.imp.USER32.dll_ModifyMenuA]
mov eax, dword [edi]
cmp eax, ebx
je 0x412048
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [edi], ebx
push edi
call fcn.0049fdf6
add esp, 4
mov eax, dword [0x5138c0]
cmp eax, ebx
je 0x4120a0
mov edi, dword [eax]
cmp edi, ebx
je 0x41207c
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
test eax, eax
je 0x412077
push edi
push str.PATH
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
mov eax, dword [0x5138c0]
cmp eax, ebx
mov edi, eax
je 0x41209a
mov eax, dword [eax]
cmp eax, ebx
je 0x412091
push eax
call fcn.0049fdf6
add esp, 4
push edi
call fcn.0049fdf6
add esp, 4
mov dword [0x5138c0], ebx
cmp byte [0x9096b5], bl
je 0x4120f5
cmp dword [0x51389c], ebx
jne 0x4120df
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
push 0x3e9
push esi
push ebx
push 0x50000003
call dword [sym.imp.COMCTL32.dll_CreateStatusWindowA]
push ebx
push 0x1000
push 0x401
push eax
mov dword [0x51389c], eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov edx, dword [0x51389c]
push 5
push edx
call dword [sym.imp.USER32.dll_ShowWindow]
mov byte [0x5138a0], 1
mov edi, dword [ebp + 8]
push 5
mov dword [0x513884], esi
mov dword [ebp - 0x54], ebx
mov dword [ebp - 0x50], 0x416700
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 0x48], ebx
mov dword [ebp - 0x44], edi
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x3c], ebx
call dword [sym.imp.GDI32.dll_GetStockObject]
mov dword [ebp - 0x38], eax
lea eax, [ebp - 0x54]
push eax
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x30], str.Child
call dword [sym.imp.USER32.dll_RegisterClassA]
push ebx
push edi
push ebx
push esi
push ebx
push ebx
push ebx
push ebx
push 0x52000000
push str.Child
push str.Child
push ebx
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [0x513888], eax
mov eax, dword [0x51389c]
cmp eax, ebx
je 0x41217d
cmp byte [0x5138a0], bl
je 0x41217d
lea ecx, [ebp - 0x2c]
push ecx
push eax
call dword [sym.imp.USER32.dll_GetWindowRect]
mov edi, dword [ebp - 0x20]
sub edi, dword [ebp - 0x28]
jmp 0x41217f
xor edi, edi
lea edx, [ebp - 0xa8]
push edx
push esi
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [ebp - 0x9c]
lea ecx, [edi + 0x190]
cmp eax, ecx
je 0x4121cd
mov edx, dword [ebp - 0x10]
mov ecx, dword [ebp - 0x18]
sub edi, eax
lea eax, [edx + edi + 0x190]
mov edx, dword [ebp - 0x1c]
push 4
mov dword [ebp - 0x10], eax
sub eax, ecx
mov ecx, dword [ebp - 8]
push eax
mov eax, dword [ebp - 0x14]
sub eax, edx
mov edx, dword [ebp - 4]
push eax
push ecx
push edx
push ebx
push esi
call dword [sym.imp.USER32.dll_SetWindowPos]
call fcn.0041aad0
mov eax, dword [0x909334]
cmp eax, ebx
jl 0x4121e9
cmp eax, 0xa
jge 0x4121ee
push ebx
add eax, 0xa155
push eax
jmp 0x412210
cmp eax, 0xa
jl 0x412204
mov ecx, dword [0x513638]
add ecx, 0xa
cmp eax, ecx
jge 0x412204
push ebx
add eax, 0xa155
push eax
jmp 0x412210
push ebx
mov dword [0x909334], ebx
push 0xa155
push 0x111
push esi
call dword [sym.imp.USER32.dll_PostMessageA]
mov edx, dword [ebp + 8]
push 0x67
push edx
call dword [sym.imp.USER32.dll_LoadAcceleratorsA]
push ebx
push ebx
push eax
mov dword [ebp + 0x14], eax
call dword [sym.imp.USER32.dll_CopyAcceleratorTableA]
lea edi, [eax + 1]
mov dword [ebp - 0x58], eax
lea eax, [edi + edi*2]
shl eax, 1
push eax
call fcn.004a98ab
add esp, 4
cmp eax, ebx
mov dword [ebp - 4], eax
mov dword [ebp - 8], ebx
je 0x41228f
mov edx, dword [ebp + 0x14]
push edi
mov ecx, eax
push ecx
push edx
call dword [sym.imp.USER32.dll_CopyAcceleratorTableA]
mov eax, dword [ebp - 0x58]
mov ecx, dword [ebp - 4]
lea eax, [eax + eax*2]
lea eax, [ecx + eax*2]
mov byte [eax], 0x1b
push edi
mov word [eax + 2], 0x5d
push ecx
mov word [eax + 4], 0x6c
call dword [sym.imp.USER32.dll_CreateAcceleratorTableA]
cmp eax, ebx
mov dword [ebp - 8], eax
je 0x41228f
mov ecx, eax
mov dword [ebp + 0x14], ecx
xor edx, edx
pushfd
pop eax
xor eax, 0x200000
push eax
popfd
pushfd
pop ebx
cmp eax, ebx
jne 0x4122ad
mov eax, 1
cpuid
and edx, 0x4000000
mov dword [0x51388c], edx
mov eax, edx
push 0x8f00
call fcn.004a98ab
add esp, 4
test eax, eax
je 0x4122d4
mov edx, dword [ebp + 8]
push edx
push esi
mov ecx, eax
call fcn.00407ad0
jmp 0x4122d6
xor eax, eax
push 1
push 0x190
push 0x280
mov ecx, eax
mov dword [0x513890], eax
call fcn.00408b70
mov eax, dword [0x513878]
test eax, eax
je 0x4123ba
lea eax, [ebp - 0x2c]
push eax
push esi
call dword [sym.imp.USER32.dll_GetWindowRect]
xor eax, eax
push str.mz2200
mov ecx, 7
mov edi, 0x513450
push str._s.ini
rep stosd dword es:[edi], eax
mov dword [ebp + 8], eax
call fcn.0049c650
mov ecx, dword [0x513874]
mov edi, dword [ecx]
mov edx, dword [0x513878]
add esp, 8
test edi, edi
je 0x41236c
mov ecx, dword [ecx + 0x44]
test ecx, ecx
je 0x41236c
push 0x513450
push eax
push edx
call ecx
add esp, 0xc
test eax, eax
je 0x41236c
mov ecx, dword [0x513454]
mov edx, dword [0x513458]
mov eax, dword [0x51345c]
mov dword [ebp - 0x2c], ecx
mov dword [ebp - 0x20], edx
mov dword [ebp + 8], eax
test byte [0x513468], 1
je 0x4123ba
mov edi, dword [ebp - 0x20]
mov ebx, dword [ebp - 0x2c]
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov ecx, dword [0x513874]
cmp dword [ecx], 0
je 0x4123a8
mov ecx, dword [ecx + 0x1c]
test ecx, ecx
je 0x4123a8
mov edx, dword [ebp + 8]
push edx
push edi
push ebx
push eax
mov eax, dword [0x513878]
push esi
push eax
call ecx
add esp, 0x18
mov ecx, dword [ebp - 0x2c]
mov edx, dword [ebp - 0x28]
mov dword [0x513644], ecx
mov dword [0x513640], edx
mov al, byte [0x9096b3]
mov byte [0x513718], al
mov eax, dword [0x4ee6d8]
test eax, eax
je 0x4123f6
cmp dword [eax], 0
je 0x4123f6
mov bl, byte [0x9096c8]
push 1
push 0xa0fd
test bl, bl
push 0x111
sete cl
push esi
mov byte [0x9096c8], cl
call dword [sym.imp.USER32.dll_PostMessageA]
mov eax, dword [0x4ee6dc]
test eax, eax
je 0x412416
cmp dword [eax], 0
je 0x412416
mov al, byte [0x9096c9]
test al, al
sete dl
mov byte [0x9096c9], dl
jmp 0x41241d
mov byte [0x9096c9], 1
push 0
push 0xa0fe
push 0x111
push esi
call dword [sym.imp.USER32.dll_PostMessageA]
mov eax, dword [0x9096bc]
mov ecx, dword [0x513890]
mov ecx, dword [ecx + 4]
push eax
call fcn.00411620
mov edx, dword [0x513890]
mov eax, dword [edx + 4]
add eax, 0x25
lea esi, [eax + 0x100]
mov ecx, 0x40
mov edi, eax
rep movsd dword es:[edi], dword [esi]
mov cl, byte [0x9098da]
test cl, cl
je 0x412479
mov byte [eax + 0x25], 0
mov byte [eax + 0x26], 0
mov byte [eax + 0x27], 0
mov byte [eax + 0x28], 0
mov cl, byte [0x9098d9]
test cl, cl
je 0x412493
mov byte [eax + 0x25], 0x64
mov byte [eax + 0x26], 0x68
mov byte [eax + 0x27], 0x66
mov byte [eax + 0x28], 0x62
mov eax, dword [0x513894]
mov ecx, dword [ebp - 0xc]
push eax
push ecx
call fcn.004177a0
mov edx, dword [ebp + 0x10]
mov al, byte [edx]
add esp, 8
test al, al
je 0x4127c7
mov al, byte [0x9097d5]
xor ebx, ebx
test al, al
je 0x4124e7
push 4
call fcn.004a98ab
add esp, 4
test eax, eax
je 0x4124d4
mov ecx, eax
call fcn.004129d0
jmp 0x4124d6
xor eax, eax
push 0x9097d5
mov ecx, eax
mov dword [0x5138c0], eax
call fcn.00412a30
push 0x1c
call fcn.004a98ab
mov esi, eax
add esp, 4
test esi, esi
je 0x41255c
push str.cmdline.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
test eax, eax
mov dword [esi], eax
je 0x41255e
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.cmd_tsplit
push eax
call edi
mov dword [esi + 4], eax
mov eax, dword [esi]
push str.cmd_split
push eax
call edi
mov ecx, dword [esi]
push str.cmd_splitd
push ecx
mov dword [esi + 8], eax
call edi
mov edx, dword [esi]
push str.cmd_getargc
push edx
mov dword [esi + 0xc], eax
call edi
mov dword [esi + 0x10], eax
mov eax, dword [esi]
push str.cmd_getargv
push eax
call edi
mov ecx, dword [esi]
push str.cmd_checkoption
push ecx
mov dword [esi + 0x14], eax
call edi
mov dword [esi + 0x18], eax
jmp 0x41255e
xor esi, esi
cmp dword [esi], 0
je 0x41276f
mov eax, dword [esi + 4]
test eax, eax
je 0x412577
mov edx, dword [ebp + 0x10]
push edx
call eax
add esp, 4
cmp dword [esi], 0
je 0x41258a
mov eax, dword [esi + 0x10]
test eax, eax
je 0x41258a
call eax
mov dword [ebp + 8], eax
jmp 0x412591
mov dword [ebp + 8], 0
xor eax, eax
mov ecx, 9
lea edi, [ebp - 0x7c]
rep stosd dword es:[edi], eax
mov eax, dword [ebp + 8]
xor ebx, ebx
test eax, eax
jle 0x41276a
mov edi, dword [sym.imp.USER32.dll_CharLowerA]
cmp dword [esi], 0
je 0x4125c4
mov eax, dword [esi + 0x14]
test eax, eax
je 0x4125c4
push ebx
call eax
add esp, 4
jmp 0x4125c6
xor eax, eax
push 0x104
lea ecx, [ebp - 0x1ac]
push ecx
push eax
call fcn.0049cad0
add esp, 0xc
lea edx, [ebp - 0x1ac]
push edx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x41275e
lea eax, [ebp - 0x340]
push eax
push 0
push 0
lea ecx, [ebp - 0x1ac]
push 0
push ecx
call fcn.004aa655
add esp, 0x14
lea edx, [ebp - 0x340]
push edx
call edi
push eax
push str..d88.d77.1dd.td0.imd.dsk.nfd.fdi.hdm.hd5.hd4.hdb.dd9.dd6.tfd.xdf.2d.sf7.img.ima.vfd
call fcn.004a9268
add esp, 8
test eax, eax
je 0x412647
mov ecx, dword [ebp - 0x78]
lea eax, [ebp - 0x1ac]
push eax
push ecx
call fcn.00419740
mov eax, dword [ebp - 0x78]
add esp, 8
inc eax
mov dword [ebp - 0x78], eax
jmp 0x41275e
lea edx, [ebp - 0x640]
push edx
push 0
push 0
lea eax, [ebp - 0x1ac]
push 0
push eax
call fcn.004aa655
add esp, 0x14
lea ecx, [ebp - 0x640]
push ecx
call edi
push eax
push str..mzt.q20.qdf
call fcn.004a9268
add esp, 8
test eax, eax
je 0x41269d
mov eax, dword [ebp - 0x74]
lea edx, [ebp - 0x1ac]
push edx
push eax
call fcn.00419ac0
mov eax, dword [ebp - 0x74]
add esp, 8
inc eax
mov dword [ebp - 0x74], eax
jmp 0x41275e
lea ecx, [ebp - 0x540]
push ecx
push 0
push 0
lea edx, [ebp - 0x1ac]
push 0
push edx
call fcn.004aa655
add esp, 0x14
lea eax, [ebp - 0x540]
push eax
call edi
push eax
push str..wav.cas.p6.p6t.gz.cmt.n80.t88.mzt.mzf.m12.mti.tap.t77.bin
call fcn.004a9268
add esp, 8
test eax, eax
je 0x4126f2
mov edx, dword [ebp - 0x6c]
push 1
lea ecx, [ebp - 0x1ac]
push ecx
push edx
call fcn.00419e90
mov eax, dword [ebp - 0x6c]
add esp, 0xc
inc eax
mov dword [ebp - 0x6c], eax
jmp 0x41275e
lea eax, [ebp - 0x440]
push eax
push 0
push 0
lea ecx, [ebp - 0x1ac]
push 0
push ecx
call fcn.004aa655
add esp, 0x14
lea edx, [ebp - 0x440]
push edx
call edi
push eax
push str..n88
call fcn.004a9268
add esp, 8
test eax, eax
je 0x412737
lea eax, [ebp - 0x1ac]
push eax
call fcn.0041a070
jmp 0x41275b
lea ecx, [ebp - 0x1ac]
push ecx
push 0x4beb30
call fcn.00412ae0
add esp, 8
test al, al
je 0x41275e
lea edx, [ebp - 0x1ac]
push edx
call fcn.0041a270
add esp, 4
mov eax, dword [ebp + 8]
inc ebx
cmp ebx, eax
jl 0x4125b0
mov ebx, 1
test esi, esi
je 0x41277c
push 1
mov ecx, esi
call fcn.0041b300
call fcn.00411c70
test ebx, ebx
jne 0x4127c7
mov eax, dword [ebp + 0x10]
cmp byte [eax], 0x22
jne 0x4127a3
mov edx, eax
or ecx, 0xffffffff
xor eax, eax
mov edi, edx
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov byte [ecx + edx - 1], al
inc edx
mov dword [ebp + 0x10], edx
mov edx, dword [ebp + 0x10]
push 0x104
lea ecx, [ebp - 0x1ac]
push ecx
push edx
call fcn.0049cad0
lea eax, [ebp - 0x1ac]
push eax
call fcn.0041a340
add esp, 0x10
mov ecx, dword [0x513890]
test ecx, ecx
je 0x4128bd
mov al, byte [0x9096cb]
test al, al
je 0x4128bd
push 0x63
call fcn.00409e40
mov ecx, dword [0x513890]
push eax
call fcn.00409aa0
mov ecx, dword [0x513890]
lea eax, [ecx + 0x38]
cmp byte [eax], 0
je 0x4128bd
mov edx, dword [0x51375c]
cmp dword [edx], 0
je 0x4128bd
lea ecx, [ebp - 0x540]
push ecx
lea edx, [ebp - 0x340]
push edx
lea ecx, [ebp - 0x440]
push ecx
lea edx, [ebp + 0x10]
push edx
push eax
call fcn.004aa655
push 0x4beb30
lea eax, [ebp - 0x340]
push eax
lea ecx, [ebp - 0x440]
push ecx
lea edx, [ebp + 0x10]
push edx
lea eax, [ebp - 0x1ac]
push eax
call fcn.004aa5c4
mov ecx, dword [0x513890]
mov byte [0x513760], 0
mov ecx, dword [ecx + 4]
add esp, 0x28
call fcn.00409f60
mov eax, dword [0x51375c]
cmp dword [eax], 0
je 0x4128af
mov eax, dword [eax + 0xc]
test eax, eax
je 0x4128af
lea edx, [ebp - 0x1ac]
push edx
call eax
add esp, 4
test eax, eax
je 0x4128af
lea eax, [ebp - 0x340]
push eax
push str.Pat:__s
push 0x104
push 0x513760
call fcn.0049c560
add esp, 0x10
mov ecx, dword [0x513890]
mov ecx, dword [ecx + 4]
call fcn.00409f70
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
test eax, eax
mov dword [0x51364c], eax
je 0x412909
mov eax, dword [ebp - 0xc]
lea edx, [ebp + 0x10]
push edx
push 0
push eax
push 0x4117a0
push 0
push 0
mov dword [0x5138ac], 1
call fcn.004a9473
add esp, 0x18
test eax, eax
mov dword [0x5138b0], eax
je 0x412912
push 1
push eax
call dword [sym.imp.KERNEL32.dll_SetThreadPriority]
mov eax, dword [0x5138b0]
test eax, eax
jne 0x412928
mov ecx, dword [ebp - 0xc]
push ecx
mov dword [0x5138ac], 0
call dword [sym.imp.USER32.dll_DestroyWindow]
jmp 0x41299d
push 0
push 0
push 0
lea edx, [ebp - 0x98]
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
je 0x41299d
mov edi, dword [sym.imp.USER32.dll_IsWindow]
mov esi, dword [sym.imp.USER32.dll_TranslateAcceleratorA]
mov ebx, dword [sym.imp.USER32.dll_TranslateMessage]
mov eax, dword [ebp - 0xc]
push eax
call edi
test eax, eax
je 0x412986
mov edx, dword [ebp + 0x14]
mov eax, dword [ebp - 0xc]
lea ecx, [ebp - 0x98]
push ecx
push edx
push eax
call esi
test eax, eax
jne 0x412986
lea ecx, [ebp - 0x98]
push ecx
call ebx
lea edx, [ebp - 0x98]
push edx
call dword [sym.imp.USER32.dll_DispatchMessageA]
push 0
push 0
push 0
lea eax, [ebp - 0x98]
push eax
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
jne 0x412951
mov eax, dword [ebp - 4]
test eax, eax
je 0x4129ad
push eax
call fcn.0049fdf6
add esp, 4
mov eax, dword [ebp - 8]
test eax, eax
je 0x4129bb
push eax
call dword [sym.imp.USER32.dll_DestroyAcceleratorTable]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0x10