Function at 0x412110
Capabilities:
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x45d799
mov eax, dword fs:[0]
push eax
sub esp, 0x87c
mov eax, dword [0x4713c0]
xor eax, esp
mov dword [esp + 0x878], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4713c0]
xor eax, esp
push eax
lea eax, [esp + 0x890]
mov dword fs:[0], eax
mov eax, dword [esp + 0x8a0]
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x8a4]
xor edi, edi
push eax
mov dword [esp + 0x38], edi
call fcn.0041e3a0
mov ebx, eax
add esp, 4
cmp ebx, 4
jne 0x41217b
mov dword [esp + 0x34], 1
push ebx
push str.type____d__r_n
lea ecx, [esp + 0x94]
push 0x200
push ecx
call fcn.004414db
add esp, 0x10
lea ecx, [esp + 0x38]
mov word [esp + 0x48a], di
call fcn.0042bd40
mov dword [esp + 0x898], edi
mov ebp, 7
lea eax, [esp + 0x8c]
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
lea edx, [eax + 2]
lea ebx, [ebx]
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x4121d0
sub eax, edx
sar eax, 1
push eax
lea edx, [esp + 0x90]
push edx
lea esi, [esp + 0x1c]
call fcn.00406f80
mov eax, esi
push edi
push eax
or eax, 0xffffffff
lea esi, [esp + 0x40]
mov byte [esp + 0x8a0], 1
call fcn.00406df0
mov esi, 8
cmp dword [esp + 0x2c], esi
jb 0x412221
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004415cb
add esp, 4
cmp dword [esp + 0x50], esi
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
jae 0x41223c
lea edx, [esp + 0x3c]
mov ebp, dword [0x474bb0]
cmp ebp, edi
je 0x41227a
mov eax, edx
lea esi, [eax + 2]
jmp 0x412250
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x412250
sub eax, esi
sar eax, 1
push ebp
add eax, eax
push eax
push 1
push edx
call fcn.004422ed
mov ecx, dword [0x474bb0]
push ecx
call fcn.004428a9
add esp, 0x14
mov dword [esp + 0x898], 0xffffffff
cmp dword [esp + 0x50], 8
jb 0x412299
mov edx, dword [esp + 0x3c]
push edx
call fcn.004415cb
add esp, 4
add ebx, 0xfffffffe
cmp ebx, 4
ja 0x412805
cmp dword [esp + 0x34], edi
jne 0x412347
mov esi, dword [0x475010]
xor eax, eax
cmp eax, dword [0x47500c]
jl 0x412347
jg 0x4122cd
cmp esi, dword [0x475008]
jb 0x412347
push 0x206
lea eax, [esp + 0x92]
push edi
push eax
mov word [esp + 0x98], di
call fcn.00446fa0
test esi, esi
mov dword [esp + 0x40], esi
fild dword [esp + 0x40]
jge 0x4122fa
fadd dword [0x468758]
fld qword [0x468798]
add esp, 4
fmul st(1), st(0)
lea ecx, [esp + 0x94]
fmulp st(1)
fstp qword [esp]
push 0x4639a0
push 0x208
push 0x104
push ecx
call fcn.004415ac
mov edx, dword [esp + 0x48]
add esp, 0x18
push 0x30
push 0x462334
push edx
push ecx
call fcn.00406c70
lea ecx, [esp + 0x9c]
jmp 0x41281c
push 0x4750e8
call fcn.0041e020
add esp, 4
test eax, eax
jne 0x412374
mov eax, dword [esp + 0x30]
push 0x10
push 0x462334
push eax
push ecx
call fcn.00406c70
mov ecx, 0x4639ec
jmp 0x41281c
lea ecx, [esp + 0x54]
call fcn.0041e9d0
mov dword [esp + 0x898], 2
mov eax, dword [esp + 0x58]
mov ebp, 8
cmp dword [esp + 0x6c], ebp
jae 0x41239b
lea eax, [esp + 0x58]
push eax
push str.strUserSavePath____s__r_n
lea ecx, [esp + 0x94]
push 0x200
push ecx
call fcn.004414db
add esp, 0x10
lea ecx, [esp + 0x38]
mov word [esp + 0x48a], di
call fcn.0042bd40
mov byte [esp + 0x898], 3
mov ebx, 7
lea eax, [esp + 0x8c]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
lea edx, [eax + 2]
jmp 0x4123f0
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x4123f0
sub eax, edx
sar eax, 1
push eax
lea edx, [esp + 0x90]
push edx
lea esi, [esp + 0x1c]
call fcn.00406f80
mov eax, esi
push edi
push eax
or eax, 0xffffffff
lea esi, [esp + 0x40]
mov byte [esp + 0x8a0], 4
call fcn.00406df0
cmp dword [esp + 0x2c], ebp
jb 0x41243c
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004415cb
add esp, 4
cmp dword [esp + 0x50], ebp
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
jae 0x412457
lea edx, [esp + 0x3c]
mov ebp, dword [0x474bb0]
cmp ebp, edi
je 0x412490
mov eax, edx
lea esi, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x412466
sub eax, esi
sar eax, 1
push ebp
add eax, eax
push eax
push 1
push edx
call fcn.004422ed
mov ecx, dword [0x474bb0]
push ecx
call fcn.004428a9
add esp, 0x14
mov byte [esp + 0x898], 2
cmp dword [esp + 0x50], 8
jb 0x4124ac
mov edx, dword [esp + 0x3c]
push edx
call fcn.004415cb
add esp, 4
cmp dword [esp + 0x68], edi
jne 0x4125c7
push str.strUserSavePath__NULL__r_n
lea eax, [esp + 0x90]
push 0x200
push eax
call fcn.004414db
add esp, 0xc
lea ecx, [esp + 0x38]
mov word [esp + 0x48a], di
call fcn.0042bd40
mov byte [esp + 0x898], 5
lea eax, [esp + 0x8c]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x412500
sub eax, edx
sar eax, 1
push eax
lea ecx, [esp + 0x90]
push ecx
lea esi, [esp + 0x1c]
call fcn.00406f80
mov edx, esi
push edi
push edx
or eax, 0xffffffff
lea esi, [esp + 0x40]
mov byte [esp + 0x8a0], 6
call fcn.00406df0
mov esi, 8
cmp dword [esp + 0x2c], esi
jb 0x412551
mov eax, dword [esp + 0x18]
push eax
call fcn.004415cb
add esp, 4
cmp dword [esp + 0x50], esi
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
jae 0x41256c
lea edx, [esp + 0x3c]
mov ebp, dword [0x474bb0]
cmp ebp, edi
je 0x4125ab
mov eax, edx
lea esi, [eax + 2]
jmp 0x412580
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x412580
sub eax, esi
sar eax, 1
push ebp
lea ecx, [eax + eax]
push ecx
push 1
push edx
call fcn.004422ed
mov edx, dword [0x474bb0]
push edx
call fcn.004428a9
add esp, 0x14
mov byte [esp + 0x898], 2
cmp dword [esp + 0x50], 8
jb 0x4125c7
mov eax, dword [esp + 0x3c]
push eax
call fcn.004415cb
add esp, 4
cmp dword [esp + 0x6c], 8
mov ecx, dword [esp + 0x58]
jae 0x4125d6
lea ecx, [esp + 0x58]
mov edx, 0x475174
jmp 0x4125e0
movzx eax, word [ecx]
mov word [edx], ax
add ecx, 2
add edx, 2
cmp ax, di
jne 0x4125e0
mov esi, dword [esp + 0x30]
push esi
call fcn.00413ae0
add esp, 4
test eax, eax
jne 0x41271c
push str.IsValidUserDataPath__FALSE__r_n
lea ecx, [esp + 0x90]
push 0x200
push ecx
call fcn.004414db
add esp, 0xc
lea ecx, [esp + 0x38]
mov word [esp + 0x48a], di
call fcn.0042bd40
mov byte [esp + 0x898], 7
lea eax, [esp + 0x8c]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x412650
sub eax, edx
sar eax, 1
push eax
lea edx, [esp + 0x90]
push edx
lea esi, [esp + 0x1c]
call fcn.00406f80
mov eax, esi
push edi
push eax
or eax, 0xffffffff
lea esi, [esp + 0x40]
mov byte [esp + 0x8a0], 8
call fcn.00406df0
mov esi, 8
cmp dword [esp + 0x2c], esi
jb 0x4126a1
mov ecx, dword [esp + 0x18]
push ecx
call fcn.004415cb
add esp, 4
cmp dword [esp + 0x50], esi
mov edx, dword [esp + 0x3c]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
jae 0x4126bc
lea edx, [esp + 0x3c]
mov ebp, dword [0x474bb0]
cmp ebp, edi
je 0x4126fa
mov eax, edx
lea esi, [eax + 2]
jmp 0x4126d0
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x4126d0
sub eax, esi
sar eax, 1
push ebp
add eax, eax
push eax
push 1
push edx
call fcn.004422ed
mov ecx, dword [0x474bb0]
push ecx
call fcn.004428a9
add esp, 0x14
cmp dword [esp + 0x50], 8
jb 0x41270e
mov edx, dword [esp + 0x3c]
push edx
call fcn.004415cb
add esp, 4
lea ecx, [esp + 0x54]
call fcn.00406b10
jmp 0x412826
push esi
call fcn.00413de0
add esp, 4
test eax, eax
jne 0x4127f5
push str.CheckUserDataDiskSpace__FALSE__r_n
lea eax, [esp + 0x490]
push 0x200
push eax
call fcn.004414db
add esp, 0xc
lea ecx, [esp + 0x70]
mov word [esp + 0x88a], di
call fcn.0042bd40
mov byte [esp + 0x898], 9
lea eax, [esp + 0x48c]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x28], edi
mov word [esp + 0x18], di
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, di
jne 0x412777
sub eax, edx
sar eax, 1
push eax
lea ecx, [esp + 0x490]
push ecx
lea esi, [esp + 0x1c]
call fcn.00406f80
mov edx, esi
push edi
push edx
or eax, 0xffffffff
lea esi, [esp + 0x78]
mov byte [esp + 0x8a0], 0xa
call fcn.00406df0
mov edi, 8
cmp dword [esp + 0x2c], edi
jb 0x4127c8
mov eax, dword [esp + 0x18]
push eax
call fcn.004415cb
add esp, 4
cmp dword [esp + 0x88], edi
mov esi, dword [esp + 0x74]
jae 0x4127d9
lea esi, [esp + 0x74]
call fcn.0041a470
cmp dword [esp + 0x88], edi
jb 0x41270e
mov ecx, dword [esp + 0x74]
push ecx
jmp 0x412706
lea ecx, [esp + 0x54]
call fcn.00406b10
mov eax, 1
jmp 0x412828
mov edx, dword [esp + 0x30]
push 0x10
push 0x462334
push edx
push ecx
call fcn.00406c70
mov ecx, 0x463978
add esp, 4
mov edx, eax
call fcn.00410000
xor eax, eax
mov ecx, dword [esp + 0x890]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x878]
xor ecx, esp
call fcn.004414cc
add esp, 0x888
ret