Function at 0x40fd40
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x7c
mov eax, dword [0x47f228]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, ecx
lea edx, [ebp - 0x62]
mov dword [ebp - 0x74], edi
xor ebx, ebx
mov ax, word [edi]
lea esi, [edi + 0x12]
mov word [ebp - 0x70], ax
movzx eax, byte [edi + 2]
mov byte [ebp - 0x6e], al
movzx eax, byte [edi + 3]
mov byte [ebp - 0x6d], al
mov eax, dword [edi + 8]
mov dword [ebp - 0x6c], eax
mov eax, dword [edi + 0xc]
mov dword [ebp - 0x68], eax
mov ax, word [esi - 2]
xor ecx, ecx
mov word [edx - 2], ax
movzx eax, byte [esi]
mov byte [edx], al
movzx eax, byte [esi + 1]
mov byte [edx + 1], al
movsx eax, bl
add eax, 2
lea eax, [eax + eax*2]
mov eax, dword [edi + eax*4]
test eax, eax
je 0x40fdaf
mov eax, dword [eax + 4]
inc ecx
test eax, eax
jne 0x40fda7
mov word [edx + 2], cx
inc ebx
add esi, 0xc
add edx, 6
cmp ebx, 0x10
jl 0x40fd81
push 0x46e1a0
push 0x480200
call fcn.004265b5
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x40fdfd
push eax
push 0x13
push 0x2e
push dword [0x482a94]
call fcn.00413000
add esp, 0x10
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00418a55
mov esp, ebp
pop ebp
ret
mov ecx, 2
lea eax, [ebp - 0x32]
mov esi, 3
lea edx, [ecx + 5]
nop dword [eax]
cmp byte [eax], 0xc
lea eax, [eax + 6]
cmovae ecx, esi
sub edx, 1
jne 0x40fe10
push ebx
cmp ecx, 2
mov edx, str.Org_02
push 6
mov eax, str.Org_03
cmove eax, edx
push 1
push eax
call fcn.004461f5
push ebx
push 1
lea eax, [ebp - 0x70]
push 0x6c
push eax
call fcn.004461f5
mov esi, dword [ebp - 0x74]
lea edi, [ebp - 0x60]
add esp, 0x20
mov eax, 0x10
add esi, 0x18
mov dword [ebp - 0x7c], eax
mov dword [ebp - 0x78], esi
nop
mov esi, dword [esi]
test esi, esi
je 0x40ff95
movzx eax, word [edi]
xor ecx, ecx
mov dword [ebp - 0x74], 0
cmp cx, ax
jae 0x40fea9
nop dword [eax + eax]
push ebx
push 1
lea eax, [esi + 8]
push 4
push eax
call fcn.004461f5
mov ecx, dword [ebp - 0x74]
add esp, 0x10
movzx edx, word [edi]
inc ecx
mov esi, dword [esi + 4]
mov dword [ebp - 0x74], ecx
cmp ecx, edx
jl 0x40fe80
mov esi, dword [ebp - 0x78]
mov eax, edx
mov esi, dword [esi]
xor edx, edx
mov dword [ebp - 0x74], 0
movzx ecx, ax
cmp dx, ax
jae 0x40fee9
nop word [eax + eax]
push ebx
push 1
lea eax, [esi + 0xd]
push 1
push eax
call fcn.004461f5
mov ecx, dword [ebp - 0x74]
add esp, 0x10
movzx edx, word [edi]
inc ecx
mov esi, dword [esi + 4]
mov dword [ebp - 0x74], ecx
cmp ecx, edx
jl 0x40fec0
mov eax, dword [ebp - 0x78]
mov ecx, edx
mov esi, dword [eax]
xor eax, eax
mov dword [ebp - 0x74], 0
movzx edx, cx
cmp ax, cx
jae 0x40ff27
nop word [eax + eax]
push ebx
push 1
lea eax, [esi + 0xc]
push 1
push eax
call fcn.004461f5
mov ecx, dword [ebp - 0x74]
add esp, 0x10
movzx edx, word [edi]
inc ecx
mov esi, dword [esi + 4]
mov dword [ebp - 0x74], ecx
cmp ecx, edx
jl 0x40ff00
mov eax, dword [ebp - 0x78]
mov esi, dword [eax]
xor eax, eax
mov dword [ebp - 0x74], 0
movzx ecx, dx
cmp ax, dx
jae 0x40ff61
push ebx
push 1
lea eax, [esi + 0xe]
push 1
push eax
call fcn.004461f5
mov ecx, dword [ebp - 0x74]
add esp, 0x10
movzx edx, word [edi]
inc ecx
mov esi, dword [esi + 4]
mov dword [ebp - 0x74], ecx
cmp ecx, edx
jl 0x40ff38
mov eax, dword [ebp - 0x78]
mov ecx, edx
mov esi, dword [eax]
xor eax, eax
mov dword [ebp - 0x74], 0
cmp ax, cx
jae 0x40ff92
nop
push ebx
push 1
lea eax, [esi + 0xf]
push 1
push eax
call fcn.004461f5
mov ecx, dword [ebp - 0x74]
add esp, 0x10
movzx eax, word [edi]
inc ecx
mov esi, dword [esi + 4]
mov dword [ebp - 0x74], ecx
cmp ecx, eax
jl 0x40ff70
mov eax, dword [ebp - 0x7c]
mov esi, dword [ebp - 0x78]
add edi, 6
add esi, 0xc
sub eax, 1
mov dword [ebp - 0x78], esi
mov dword [ebp - 0x7c], eax
jne 0x40fe60
push ebx
call fcn.00426273
push 0x480200
call fcn.00412750
add esp, 8
cmp dword [0x47fe80], 0
je 0x40ffce
call fcn.004118f0
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00418a55
mov esp, ebp
pop ebp
ret