Function at 0x404d80
Capabilities:
Create directory
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x4356ab
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x2a8
mov eax, dword [0x44be60]
push ebx
push 0
mov dword [esp + 0x2ac], eax
push 5
lea eax, [esp + 0xa8]
push eax
push 0
mov ebx, ecx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
test eax, eax
je 0x404ee5
push edi
lea edi, [esp + 0xa4]
dec edi
nop
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x404dd0
push esi
mov ecx, 6
mov esi, str.KOEIShin_Sangokumusou_3_
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
xor eax, eax
pop esi
jmp 0x404df0
mov cl, byte [esp + eax + 0xa4]
mov byte [esp + eax + 0x1a8], cl
inc eax
test cl, cl
jne 0x404df0
lea edi, [esp + 0x1a8]
dec edi
jmp 0x404e10
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x404e10
mov ecx, dword [str.graphics.cfg]
mov edx, dword [0x437d2c]
mov eax, dword [0x437d30]
mov dword [edi], ecx
mov cl, byte [0x437d34]
mov dword [edi + 4], edx
push 0
lea edx, [esp + 0xa8]
push edx
mov dword [edi + 8], eax
push 0
mov byte [edi + 0xc], cl
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExA]
test eax, eax
pop edi
je 0x404e61
cmp eax, 0xb7
je 0x404e61
cmp eax, 0x50
jne 0x404ee5
push 1
lea ecx, [esp + 8]
call fcn.00403910
push 0x1b6
push 0x32
lea eax, [esp + 0x1ac]
push eax
lea ecx, [esp + 0x1c]
mov dword [esp + 0x2c0], 0
call fcn.00402dd0
test eax, eax
jne 0x404eb8
mov ecx, dword [esp + 4]
mov ecx, dword [ecx + 4]
mov eax, dword [esp + ecx + 0xc]
mov edx, dword [esp + ecx + 0x2c]
lea ecx, [esp + ecx + 4]
or eax, 2
test edx, edx
jne 0x404eb0
or eax, 4
push 0
push eax
call fcn.004266b9
mov eax, dword [esp + 0x68]
test eax, eax
jne 0x404eec
lea ecx, [esp + 0x6c]
mov dword [esp + 0x2b4], 0xffffffff
call fcn.004039d0
lea ecx, [esp + 0x6c]
mov dword [esp + 0x6c], 0x4375a0
call fcn.004265cf
xor al, al
jmp 0x405023
push 4
push ebx
lea ecx, [esp + 0x14]
mov dword [ebx], 0x3fd9999a
call fcn.00402af0
push 4
lea edx, [ebx + 4]
push edx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea eax, [ebx + 8]
push eax
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea ecx, [ebx + 0xc]
push ecx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea edx, [ebx + 0x10]
push edx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea eax, [ebx + 0x14]
push eax
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea ecx, [ebx + 0x18]
push ecx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea edx, [ebx + 0x1c]
push edx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea eax, [ebx + 0x20]
push eax
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea ecx, [ebx + 0x24]
push ecx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea edx, [ebx + 0x28]
push edx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea eax, [ebx + 0x2c]
push eax
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
lea ecx, [ebx + 0x30]
push ecx
lea ecx, [esp + 0x14]
call fcn.00402af0
push 4
add ebx, 0x34
push ebx
lea ecx, [esp + 0x14]
call fcn.00402af0
lea ecx, [esp + 0xc]
call fcn.00402060
lea ecx, [esp + 0x10]
call fcn.004037c0
test eax, eax
jne 0x404ffc
mov edx, dword [esp + 4]
mov ecx, dword [edx + 4]
mov eax, dword [esp + ecx + 0xc]
mov edx, dword [esp + ecx + 0x2c]
lea ecx, [esp + ecx + 4]
or eax, 2
test edx, edx
jne 0x404ff4
or eax, 4
push 0
push eax
call fcn.004266b9
lea ecx, [esp + 0x6c]
mov dword [esp + 0x2b4], 0xffffffff
call fcn.004039d0
lea ecx, [esp + 0x6c]
mov dword [esp + 0x6c], 0x4375a0
call fcn.004265cf
mov al, 1
mov ecx, dword [esp + 0x2ac]
mov dword fs:[0], ecx
mov ecx, dword [esp + 0x2a8]
pop ebx
call fcn.00418291
add esp, 0x2b4
ret