Function at 0x403ca0
Capabilities:
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, 0xb384
call fcn.00451ab0
mov eax, dword [0x4a8f7c]
xor eax, esp
mov dword [esp + 0xb380], eax
cmp dword [ebp + 0xc], 1
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov ebx, ecx
mov dword [esp + 0xc], eax
jne 0x403d11
push 0
push 0x20
push 3
push 0
push 0
push DirectSoundCreate
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
je 0x403d11
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebx + 8]
push 1
push 0x4833a8
push 0x483374
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
cmp eax, 2
je 0x403f69
mov dword [esp + 0x888], 0x78766173
mov dword [esp + 0x88c], 0xade98f20
lea esi, [ebx + 0x2c]
mov ecx, 0x40
lea edi, [esp + 0x890]
rep movsd dword es:[edi], dword [esi]
lea esi, [ebx + 0x12c]
mov ecx, 0x40
lea edi, [esp + 0x990]
rep movsd dword es:[edi], dword [esi]
xor eax, eax
lea ecx, [esp + 0xa90]
push ecx
mov dword [esp + 0xa94], eax
mov dword [esp + 0xa98], eax
mov dword [esp + 0xa9c], eax
mov dword [esp + 0xaa0], eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
lea edx, [esp + 0xac8]
push edx
push 0x5a
push 0x78
mov ecx, ebx
call fcn.00401df0
test eax, eax
jne 0x403da5
push 0xa8c0
push eax
lea eax, [esp + 0xad0]
push eax
call fcn.00451810
add esp, 0xc
lea ecx, [esp + 0x128]
lea esi, [ebx + 0x83e4]
push ecx
mov ecx, esi
call fcn.00418420
mov ecx, esi
call fcn.00418410
mov edx, dword [ebx + 0x1784]
mov ecx, ebx
mov dword [esp + 0x174], eax
mov dword [esp + 0x178], edx
call fcn.00401670
mov dword [esp + 0x17c], eax
lea esi, [ebx + 0x22c]
mov ecx, 0x100
lea edi, [esp + 0x180]
rep movsd dword es:[edi], dword [esi]
lea esi, [ebx + 0x1cb8]
mov ecx, 0x80
lea edi, [esp + 0x580]
rep movsd dword es:[edi], dword [esi]
lea ecx, [ebx + 0x1790]
call fcn.0040fed0
mov esi, eax
mov ecx, 0x41
lea edi, [esp + 0x780]
rep movsd dword es:[edi], dword [esi]
lea ecx, [ebx + 0x1790]
call fcn.0040feb0
mov esi, dword [esp + 0xc]
push 0x20
push esi
mov dword [esp + 0x88c], eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0
push 0x20
push 2
push 0
push 0
push 0x40000000
push esi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
mov dword [esp + 0xc], esi
cmp esi, 0xffffffff
jne 0x403e7f
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0xb380]
xor ecx, esp
call fcn.00451800
mov esp, ebp
pop ebp
ret 8
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
push 0
lea eax, [esp + 0x14]
push eax
push 0xab00
lea ecx, [esp + 0x894]
push ecx
push esi
call edi
push 0
lea edx, [esp + 0x14]
push edx
push 0x760
lea eax, [esp + 0x134]
push eax
push esi
call edi
cmp dword [esp + 0x884], 0
mov dword [esp + 0x14], 0
jbe 0x403f3e
mov ecx, dword [esp + 0x14]
push ecx
lea ecx, [ebx + 0x1790]
call fcn.0040fe80
mov edx, dword [eax]
mov dword [esp + 0x11c], edx
mov ecx, dword [eax + 0x128]
mov dword [esp + 0x120], ecx
mov edx, dword [eax + 0x12c]
push 0
lea esi, [eax + 4]
lea eax, [esp + 0x14]
push eax
mov dword [esp + 0x12c], edx
mov edx, dword [esp + 0x14]
mov ecx, 0x41
lea edi, [esp + 0x20]
rep movsd dword es:[edi], dword [esi]
push 0x110
lea ecx, [esp + 0x24]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [esp + 0x14]
inc eax
mov dword [esp + 0x14], eax
cmp eax, dword [esp + 0x884]
jb 0x403ec5
mov esi, dword [esp + 0xc]
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
mov ebx, dword [ebx + 0x1788]
test ebx, ebx
je 0x403f62
push 0
lea eax, [esp + 0x14]
push eax
push 0x154
push ebx
push esi
call edi
mov ebx, dword [ebx + 0x154]
test ebx, ebx
jne 0x403f48
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esp + 0xb38c]
pop edi
pop esi
pop ebx
xor ecx, esp
mov eax, 1
call fcn.00451800
mov esp, ebp
pop ebp
ret 8