Function at 0x504660
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x53b328
mov eax, dword fs:[0]
push eax
sub esp, 0x654
mov eax, dword [0x59a0a0]
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
cmp dword [edi + 0x9ac], 0
je 0x5046a3
call fcn.005037a0
jmp 0x504d23
push 0x208
lea eax, [ebp - 0x218]
push 0
push eax
call fcn.0049e130
add esp, 0xc
mov dword [edi + 0x994], 0
lea eax, [ebp - 0x218]
push eax
push 0
push 0
push dword [edi + 0x438]
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
je 0x504cfe
lea eax, [ebp - 0x660]
mov dword [ebp - 0x660], 0
push eax
lea eax, [ebp - 0x65c]
lea ebx, [edi + 0x424]
push eax
mov ecx, ebx
call fcn.0042be10
mov ecx, dword [ebp - 0x65c]
lea edx, [ebp - 0x218]
lea esi, [edx + 2]
lea ecx, [ecx + 0x60]
nop dword [eax]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x504720
sub edx, esi
lea eax, [ebp - 0x218]
sar edx, 1
push edx
push eax
call fcn.00402d50
lea eax, [ebp - 0x660]
mov dword [ebp - 0x660], 0
push eax
lea eax, [ebp - 0x65c]
mov ecx, ebx
push eax
call fcn.0042be10
mov eax, dword [ebp - 0x65c]
lea ecx, [edi + 0x480]
add eax, 0x60
push eax
call fcn.00411620
lea ecx, [ebp - 0x310]
call fcn.00428cc0
push 0x2e
push 0x566320
mov dword [ebp - 4], 0
call fcn.00405040
cmp dword [edi + 0x404], 0
je 0x5047a7
push 0x566380
lea ecx, [ebp - 0x310]
call fcn.00405170
cmp dword [ebp - 0x2fc], 8
lea eax, [ebp - 0x660]
push eax
lea eax, [ebp - 0x65c]
mov dword [ebp - 0x660], 0
lea esi, [ebp - 0x310]
mov ecx, ebx
cmovae esi, dword [ebp - 0x310]
push eax
call fcn.0042be10
mov eax, dword [ebp - 0x65c]
add eax, 0x84
mov dword [ebp - 0x654], eax
test esi, esi
jne 0x5047f3
xor ecx, ecx
jmp 0x504815
mov ecx, esi
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x504800
mov eax, dword [ebp - 0x654]
sub ecx, edx
sar ecx, 1
push ecx
push esi
mov ecx, eax
call fcn.00402d50
cmp word [ebp - 0x218], 0
jne 0x50482c
xor ecx, ecx
jmp 0x504844
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x504835
sub ecx, edx
sar ecx, 1
push ecx
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x2f8]
call fcn.00405040
cmp dword [edi + 0x404], 0
mov dword [ebp - 0x268], 0
mov dword [ebp - 0x264], 0
je 0x504888
mov dword [ebp - 0x270], 1
mov dword [ebp - 0x26c], 0
lea eax, [ebp - 0x654]
mov dword [ebp - 0x654], 0
push eax
lea eax, [ebp - 0x65c]
mov ecx, ebx
push eax
call fcn.0042be10
mov eax, dword [ebp - 0x65c]
mov ecx, ebx
inc dword [eax + 0x28]
lea eax, [ebp - 0x654]
push eax
lea eax, [ebp - 0x65c]
mov dword [ebp - 0x654], 0
push eax
call fcn.0042be10
mov eax, dword [ebp - 0x65c]
mov ecx, ebx
mov dword [eax + 0x1c], 0
lea eax, [ebp - 0x654]
push eax
lea eax, [ebp - 0x65c]
mov dword [ebp - 0x654], 0
push eax
call fcn.0042be10
mov esi, dword [ebp - 0x65c]
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [esi + 0x34], eax
lea ecx, [ebp - 0x394]
cmp dword [ebp - 0x2fc], 8
lea eax, [ebp - 0x310]
push 0
cmovae eax, dword [ebp - 0x310]
mov dword [ebp - 0x398], ecx
lea ecx, [ebp - 0x398]
push eax
mov dword [edi + 0x400], 0xa
call fcn.0042ac40
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x248]
push dword [ebp - 0x398]
call fcn.00409230
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x394]
mov eax, dword [ebp - 0x398]
cmp eax, ecx
je 0x504974
push eax
call fcn.004a51fb
add esp, 4
cmp dword [ebp - 0x2e4], 8
lea eax, [ebp - 0x2f8]
lea ecx, [ebp - 0x41c]
cmovae eax, dword [ebp - 0x2f8]
push 0xfde9
mov dword [ebp - 0x420], ecx
lea ecx, [ebp - 0x420]
push eax
call fcn.0042ac40
mov byte [ebp - 4], 4
lea ecx, [ebp - 0x230]
push dword [ebp - 0x420]
call fcn.00409230
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x41c]
mov eax, dword [ebp - 0x420]
cmp eax, ecx
je 0x5049d7
push eax
call fcn.004a51fb
add esp, 4
cmp dword [ebp - 0x21c], 0x10
lea esi, [ebp - 0x230]
mov ecx, dword [edi + 0x420]
lea edx, [ebp - 0x248]
cmovae esi, dword [ebp - 0x230]
cmp dword [ebp - 0x234], 0x10
push esi
cmovae edx, dword [ebp - 0x248]
mov eax, dword [ecx]
push edx
call dword [eax + 0xc]
mov ebx, eax
test ebx, ebx
jne 0x504a5c
cmp dword [ebp - 0x21c], 0x10
lea edx, [ebp - 0x230]
lea ecx, [ebp - 0x248]
cmovae edx, dword [ebp - 0x230]
cmp dword [ebp - 0x234], 0x10
push edx
cmovae ecx, dword [ebp - 0x248]
push ecx
push 0x5661e8
push 0x5662b8
call fcn.004e78a0
push eax
call fcn.004e76a0
add esp, 0x14
lea esi, [edi + 0x424]
jmp 0x504acd
cmp dword [ebp - 0x21c], 0x10
lea ecx, [ebp - 0x230]
lea eax, [ebp - 0x248]
cmovae ecx, dword [ebp - 0x230]
cmp dword [ebp - 0x234], 0x10
push ecx
cmovae eax, dword [ebp - 0x248]
push eax
push ebx
push 0x566590
push 0x566650
call fcn.004e78a0
push eax
call fcn.004e76a0
add esp, 0x18
mov dword [ebp - 0x654], 0
lea eax, [ebp - 0x654]
lea esi, [edi + 0x424]
mov ecx, esi
push eax
lea eax, [ebp - 0x65c]
push eax
call fcn.0042be10
mov eax, dword [ebp - 0x65c]
mov dword [eax + 0x24], ebx
mov ecx, dword [edi + 0x420]
push ebx
mov eax, dword [ecx]
call dword [eax + 0x10]
test eax, eax
je 0x504c44
mov eax, dword [edi]
mov ecx, edi
call dword [eax + 0xbc]
lea ecx, [ebp - 0x650]
call fcn.00429390
mov byte [ebp - 4], 7
mov eax, dword [edi + 0x490]
mov dword [ebp - 0x5b8], eax
mov eax, dword [0x59fadc]
mov dword [ebp - 0x538], eax
mov eax, dword [edi + 0x494]
mov dword [ebp - 0x534], eax
mov eax, dword [edi + 0x498]
mov dword [ebp - 0x530], eax
mov eax, dword [0x59fae0]
mov dword [ebp - 0x520], eax
mov eax, dword [edi + 0x4a0]
mov dword [ebp - 0x51c], eax
lea eax, [edi + 0x4c0]
push eax
mov dword [ebp - 0x650], 0x64
mov dword [ebp - 0x648], 0xc
mov dword [ebp - 0x5c4], 0
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
mov dword [ebp - 0x518], eax
mov eax, dword [edi + 0x478]
test eax, eax
jne 0x504b7f
xor edx, edx
jmp 0x504bbd
mov ecx, eax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x504b84
sub ecx, edx
sar ecx, 1
lea esi, [ecx + 1]
cmp esi, 0x3fffffff
jle 0x504ba2
xor edx, edx
jmp 0x504bbd
add esi, esi
mov eax, esi
call fcn.0049bc00
mov edx, dword [edi + 0x478]
mov ecx, esp
push 3
push esi
call fcn.0042d380
mov edx, eax
cmp byte [edx], 0
jne 0x504bc6
xor ecx, ecx
jmp 0x504bd9
mov ecx, edx
lea esi, [ecx + 1]
nop dword [eax + eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x504bd0
sub ecx, esi
push ecx
push edx
lea ecx, [ebp - 0x5b0]
call fcn.00406560
push ecx
lea eax, [ebp - 0x650]
push eax
call fcn.0044c609
mov ecx, eax
call fcn.0042af00
lea ecx, [ebp - 0x650]
mov byte [ebp - 4], 6
call fcn.0042a2e0
mov eax, dword [edi]
mov ecx, edi
push 0xa
push 2
call dword [eax + 0x1c]
cmp dword [ebp - 0x2e4], 8
lea eax, [ebp - 0x2f8]
cmovae eax, dword [ebp - 0x2f8]
push eax
push ebx
push 0x566498
push 0x56610c
call fcn.004e78a0
push eax
call fcn.004e76a0
add esp, 0x14
jmp 0x504c7f
lea eax, [ebp - 0x654]
mov dword [ebp - 0x654], 0
push eax
lea eax, [ebp - 0x65c]
mov ecx, esi
push eax
call fcn.0042be10
mov eax, dword [ebp - 0x65c]
mov ecx, edi
mov edx, dword [edi]
mov eax, dword [eax + 0x40]
push eax
push 0
mov dword [edi + 0x400], eax
call dword [edx + 0x88]
mov eax, dword [ebp - 0x21c]
cmp eax, 0x10
jb 0x504c9d
inc eax
lea ecx, [ebp - 0x230]
push eax
push dword [ebp - 0x230]
call fcn.00405350
mov eax, dword [ebp - 0x234]
mov dword [ebp - 0x21c], 0xf
mov dword [ebp - 0x220], 0
mov byte [ebp - 0x230], 0
cmp eax, 0x10
jb 0x504cd6
inc eax
lea ecx, [ebp - 0x248]
push eax
push dword [ebp - 0x248]
call fcn.00405350
lea ecx, [ebp - 0x310]
mov dword [ebp - 0x234], 0xf
mov dword [ebp - 0x238], 0
mov byte [ebp - 0x248], 0
call fcn.0042a1a0
jmp 0x504d23
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [edi + 0x438]
push str.GameDownload::CMainUI::StartDownloadComponentXML
push 0x566908
call fcn.004e78a0
push eax
call fcn.004e76a0
add esp, 0x14
lea esp, [ebp - 0x670]
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.0049aa22
mov esp, ebp
pop ebp
ret