Function at 0x45d9d0
Capabilities:
Check if file exists
Create directory
Get common file path
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x53f376
mov eax, dword fs:[0]
push eax
mov eax, 0x223c
call fcn.0049e320
mov eax, dword [0x59bc84]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [ebp + 8]
push 0x800
mov dword [ebp - 0x2248], eax
lea eax, [ebp - 0x1a10]
push 0
push eax
call fcn.004e3050
add esp, 0xc
lea eax, [ebp - 0x1a10]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
xor eax, eax
mov dword [ebp - 0x2218], 0
mov dword [ebp - 0x2214], 7
mov word [ebp - 0x2228], ax
lea ecx, [ebp - 0x1a10]
mov dword [ebp - 4], eax
mov dword [ebp - 0x2230], eax
lea edx, [ecx + 2]
mov dword [ebp - 0x222c], 7
mov word [ebp - 0x2240], ax
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x45da75
sub ecx, edx
lea eax, [ebp - 0x1a10]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x2240]
call fcn.004125f0
cmp dword [ebp - 0x2230], 0x104
mov ebx, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
mov byte [ebp - 4], 1
jbe 0x45dab4
mov bl, 1
jmp 0x45dbab
push 0x800
lea eax, [ebp - 0x2210]
push 0
push eax
call fcn.004e3050
push 0x800
lea eax, [ebp - 0x1210]
push 0
push eax
call fcn.004e3050
cmp dword [ebp - 0x222c], 8
lea eax, [ebp - 0x2240]
cmovae eax, dword [ebp - 0x2240]
push eax
lea eax, [ebp - 0x2210]
push 0x400
push eax
call fcn.0050e37c
push 0x100
lea eax, [ebp - 0x110]
push 0
push eax
call fcn.004e3050
add esp, 0x30
xor esi, esi
nop dword [eax + eax]
push 0x80
lea eax, [ebp - 0x110]
mov ecx, edi
push eax
call fcn.0045e2f0
lea eax, [ebp - 0x110]
push eax
lea eax, [ebp - 0x2210]
push eax
lea eax, [ebp - 0x1210]
push eax
call dword [sym.imp.SHLWAPI.dll_PathCombineW]
push str..tmp
lea eax, [ebp - 0x1210]
push 0x400
push eax
call fcn.0050e2a7
add esp, 0xc
lea eax, [ebp - 0x1210]
push eax
call ebx
test eax, eax
je 0x45db7e
inc esi
cmp esi, 0xa
jl 0x45db20
mov bl, 1
jmp 0x45dbab
lea ecx, [ebp - 0x1210]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x45db87
sub ecx, edx
lea eax, [ebp - 0x1210]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x2228]
call fcn.004125f0
xor bl, bl
mov edx, dword [ebp - 0x222c]
mov byte [ebp - 4], 0
cmp edx, 8
jb 0x45dbef
mov ecx, dword [ebp - 0x2240]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x45dbe5
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x45de76
push edx
push ecx
call fcn.0049dede
add esp, 8
test bl, bl
jne 0x45de13
cmp dword [ebp - 0x2214], 8
lea eax, [ebp - 0x2228]
cmovae eax, dword [ebp - 0x2228]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x45dc35
cmp dword [ebp - 0x2214], 8
lea eax, [ebp - 0x2228]
push 0
cmovae eax, dword [ebp - 0x2228]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
push 0x100
lea eax, [ebp - 0x210]
push 0
push eax
call fcn.004e3050
push 0x800
lea eax, [ebp - 0xa10]
push 0
push eax
call fcn.004e3050
add esp, 0x18
lea eax, [ebp - 0x210]
mov ecx, edi
push 0x80
push eax
call fcn.0045e2f0
cmp dword [ebp - 0x2214], 8
lea eax, [ebp - 0x2228]
mov esi, dword [sym.imp.SHLWAPI.dll_PathAppendW]
cmovae eax, dword [ebp - 0x2228]
push eax
lea eax, [ebp - 0xa10]
push eax
call esi
lea eax, [ebp - 0x210]
push eax
lea eax, [ebp - 0xa10]
push eax
call esi
push str..tmp
lea eax, [ebp - 0xa10]
push 0x400
push eax
call fcn.0050e2a7
add esp, 0xc
mov dword [ebp - 0x2230], 0
xor eax, eax
mov dword [ebp - 0x222c], 7
lea ecx, [ebp - 0xa10]
mov word [ebp - 0x2240], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x45dce4
sub ecx, edx
lea eax, [ebp - 0xa10]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x2240]
call fcn.004125f0
cmp dword [ebp - 0x222c], 8
lea eax, [ebp - 0x2240]
push 0x55f288
cmovae eax, dword [ebp - 0x2240]
push eax
lea eax, [ebp - 0x2244]
mov dword [ebp - 0x2244], 0
push eax
call fcn.00512314
mov ecx, dword [ebp - 0x2244]
add esp, 0xc
test ecx, ecx
jne 0x45dd4e
call fcn.004ffee9
mov esi, dword [eax]
neg esi
jmp 0x45dd81
mov eax, dword [ebp - 0x2248]
cmp dword [eax + 0x14], 0x10
lea ebx, [eax + 0x10]
jb 0x45dd5f
mov eax, dword [eax]
push ecx
push dword [ebx]
push 1
push eax
call fcn.00513442
push dword [ebp - 0x2244]
mov esi, eax
call fcn.00511e25
xor eax, eax
add esp, 0x14
cmp esi, dword [ebx]
cmovne esi, eax
mov edx, dword [ebp - 0x222c]
cmp edx, 8
jb 0x45ddc1
mov ecx, dword [ebp - 0x2240]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x45ddb7
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x45de7b
push edx
push ecx
call fcn.0049dede
add esp, 8
test esi, esi
jle 0x45de13
cmp dword [ebp - 0x2214], 8
lea eax, [ebp - 0x2228]
cmovae eax, dword [ebp - 0x2228]
push eax
lea eax, [ebp - 0xa10]
push eax
call fcn.004dac30
add esp, 8
test eax, eax
js 0x45de13
lea eax, [ebp - 0x2228]
cmp edi, eax
je 0x45de13
cmp dword [ebp - 0x2214], 8
mov ecx, edi
push dword [ebp - 0x2218]
cmovae eax, dword [ebp - 0x2228]
push eax
call fcn.004125f0
cmp dword [edi + 0x10], 0
mov edx, dword [ebp - 0x2214]
setne bl
cmp edx, 8
jb 0x45de56
mov ecx, dword [ebp - 0x2228]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x45de4c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x45de80
push edx
push ecx
call fcn.0049dede
add esp, 8
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0049dec8
mov esp, ebp
pop ebp
ret 4
call fcn.004ffdd3
call fcn.004ffdd3
call fcn.004ffdd3
int3