Function at 0x415080
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x828
mov eax, dword [0x551aa8]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
push 0x104
lea eax, [ebp - 0x80c]
mov esi, ecx
mov edi, edx
push eax
mov dword [ebp - 0x810], esi
mov dword [ebp - 0x81c], edi
mov dword [ebp - 0x814], ebx
mov dword [ebp - 0x818], 0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x415d00
xor ecx, ecx
lea eax, [ebp - 0x40c]
mov word [ebp - 0x606], cx
lea esi, [ebp - 0x80c]
mov ecx, eax
mov edx, 0x200
sub esi, ecx
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x41510f
movzx ecx, word [esi + eax]
test cx, cx
je 0x41510f
mov word [eax], cx
add eax, 2
dec edx
jne 0x4150f1
jmp 0x415113
test edx, edx
jne 0x415116
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
cmp word [eax], 0
je 0x415134
add eax, 2
dec edx
jne 0x415126
jmp 0x41515c
test edx, edx
je 0x41515c
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push str.ddraw.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415264
mov eax, dword [ebp - 0x820]
mov ecx, dword [ebp - 0x824]
cmp eax, 0x40002
ja 0x415191
jb 0x4151d5
cmp ecx, 0x5f
ja 0x415191
jb 0x4151d5
mov edi, dword [ebp - 0x810]
test edi, edi
je 0x4151a1
mov dword [edi], 1
mov edx, dword [ebp - 0x81c]
test edx, edx
je 0x4151b1
mov dword [edx], 0
mov ebx, dword [ebp - 0x814]
test ebx, ebx
je 0x4151c9
mov edi, 0x20
mov word [ebx], di
mov edi, dword [ebp - 0x810]
mov dword [ebp - 0x818], 1
jmp 0x4151e7
mov ebx, dword [ebp - 0x814]
mov edx, dword [ebp - 0x81c]
mov edi, dword [ebp - 0x810]
cmp eax, 0x40003
ja 0x4151fa
jb 0x41522a
cmp ecx, 0x448
ja 0x4151fa
jb 0x41522a
test edi, edi
je 0x415204
mov dword [edi], 2
test edx, edx
je 0x41520e
mov dword [edx], 0
test ebx, ebx
je 0x415220
mov edi, 0x20
mov word [ebx], di
mov edi, dword [ebp - 0x810]
mov dword [ebp - 0x818], 1
cmp eax, 0x40004
ja 0x41523a
jb 0x415264
cmp ecx, 0x44
ja 0x41523a
jb 0x415264
test edi, edi
je 0x415244
mov dword [edi], 3
test edx, edx
je 0x41524e
mov dword [edx], 0
test ebx, ebx
je 0x41525a
mov eax, 0x20
mov word [ebx], ax
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
nop
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x41528e
movzx ecx, word [esi + eax]
test cx, cx
je 0x41528e
mov word [eax], cx
add eax, 2
dec edx
jne 0x415270
jmp 0x415292
test edx, edx
jne 0x415295
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
cmp word [eax], 0
je 0x4152b3
add eax, 2
dec edx
jne 0x4152a5
jmp 0x4152db
test edx, edx
je 0x4152db
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push str.d3drg8x.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415348
mov eax, dword [ebp - 0x820]
cmp eax, 0x40004
ja 0x41530c
jb 0x415348
mov eax, dword [ebp - 0x824]
cmp eax, 0x46
ja 0x41530c
jb 0x415348
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x41531c
mov dword [eax], 3
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x41532c
mov dword [eax], 0
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x41533e
mov ecx, 0x61
mov word [eax], cx
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x415371
movzx ecx, word [esi + eax]
test cx, cx
je 0x415371
mov word [eax], cx
add eax, 2
dec edx
jne 0x415353
jmp 0x415375
test edx, edx
jne 0x415378
sub eax, 2
xor edx, edx
mov word [eax], dx
mov eax, 0x200
lea ecx, [ebp - 0x40c]
cmp word [ecx], dx
je 0x415395
add ecx, 2
dec eax
jne 0x415388
jmp 0x4153bd
test eax, eax
je 0x4153bd
mov ecx, 0x200
sub ecx, eax
mov eax, 0x200
sub eax, ecx
push str.ddraw.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x4154cb
mov eax, dword [ebp - 0x820]
mov ecx, dword [ebp - 0x824]
cmp eax, 0x40005
ja 0x4153f5
jb 0x415439
cmp ecx, 0x9b
ja 0x4153f5
jb 0x415439
mov edi, dword [ebp - 0x810]
test edi, edi
je 0x415405
mov dword [edi], 5
mov edx, dword [ebp - 0x81c]
test edx, edx
je 0x415415
mov dword [edx], 0
mov ebx, dword [ebp - 0x814]
test ebx, ebx
je 0x41542d
mov edi, 0x20
mov word [ebx], di
mov edi, dword [ebp - 0x810]
mov dword [ebp - 0x818], 1
jmp 0x41544b
mov ebx, dword [ebp - 0x814]
mov edx, dword [ebp - 0x81c]
mov edi, dword [ebp - 0x810]
cmp eax, 0x40006
ja 0x41545e
jb 0x4154cb
cmp ecx, 0x13e
ja 0x41545e
jb 0x41548e
test edi, edi
je 0x415468
mov dword [edi], 6
test edx, edx
je 0x415472
mov dword [edx], 0
test ebx, ebx
je 0x415484
mov edi, 0x20
mov word [ebx], di
mov edi, dword [ebp - 0x810]
mov dword [ebp - 0x818], 1
cmp eax, 0x40006
ja 0x4154a1
jb 0x4154cb
cmp ecx, 0x1b4
ja 0x4154a1
jb 0x4154cb
test edi, edi
je 0x4154ab
mov dword [edi], 6
test edx, edx
je 0x4154b5
mov dword [edx], 1
test ebx, ebx
je 0x4154c1
mov eax, 0x20
mov word [ebx], ax
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x4154f4
movzx ecx, word [esi + eax]
test cx, cx
je 0x4154f4
mov word [eax], cx
add eax, 2
dec edx
jne 0x4154d6
jmp 0x4154f8
test edx, edx
jne 0x4154fb
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
jmp 0x415510
cmp word [eax], 0
je 0x41551e
add eax, 2
dec edx
jne 0x415510
jmp 0x415546
test edx, edx
je 0x415546
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push str.dplayx.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x4155b5
mov eax, dword [ebp - 0x820]
cmp eax, 0x40006
ja 0x415579
jb 0x4155b5
mov eax, dword [ebp - 0x824]
cmp eax, 0x30206
ja 0x415579
jb 0x4155b5
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x415589
mov dword [eax], 6
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x415599
mov dword [eax], 1
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x4155ab
mov ecx, 0x61
mov word [eax], cx
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x4155de
movzx ecx, word [esi + eax]
test cx, cx
je 0x4155de
mov word [eax], cx
add eax, 2
dec edx
jne 0x4155c0
jmp 0x4155e2
test edx, edx
jne 0x4155e5
sub eax, 2
xor edx, edx
mov word [eax], dx
mov eax, 0x200
lea ecx, [ebp - 0x40c]
cmp word [ecx], dx
je 0x415602
add ecx, 2
dec eax
jne 0x4155f5
jmp 0x41562a
test eax, eax
je 0x41562a
mov ecx, 0x200
sub ecx, eax
mov eax, 0x200
sub eax, ecx
push str.ddraw.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415699
mov eax, dword [ebp - 0x820]
cmp eax, 0x40007
ja 0x41565d
jb 0x415699
mov eax, dword [ebp - 0x824]
cmp eax, 0x2bc
ja 0x41565d
jb 0x415699
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x41566d
mov dword [eax], 7
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x41567d
mov dword [eax], 0
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x41568f
mov ecx, 0x20
mov word [eax], cx
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x4156c2
movzx ecx, word [esi + eax]
test cx, cx
je 0x4156c2
mov word [eax], cx
add eax, 2
dec edx
jne 0x4156a4
jmp 0x4156c6
test edx, edx
jne 0x4156c9
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea esp, [esp]
cmp word [eax], 0
je 0x4156ee
add eax, 2
dec edx
jne 0x4156e0
jmp 0x415716
test edx, edx
je 0x415716
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push str.dinput.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415785
mov eax, dword [ebp - 0x820]
cmp eax, 0x40007
ja 0x415749
jb 0x415785
mov eax, dword [ebp - 0x824]
cmp eax, 0x2cc
ja 0x415749
jb 0x415785
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x415759
mov dword [eax], 7
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x415769
mov dword [eax], 0
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x41577b
mov ecx, 0x61
mov word [eax], cx
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x4157ae
movzx ecx, word [esi + eax]
test cx, cx
je 0x4157ae
mov word [eax], cx
add eax, 2
dec edx
jne 0x415790
jmp 0x4157b2
test edx, edx
jne 0x4157b5
sub eax, 2
xor edx, edx
mov word [eax], dx
mov eax, 0x200
lea ecx, [ebp - 0x40c]
cmp word [ecx], dx
je 0x4157d2
add ecx, 2
dec eax
jne 0x4157c5
jmp 0x4157fa
test eax, eax
je 0x4157fa
mov ecx, 0x200
sub ecx, eax
mov eax, 0x200
sub eax, ecx
push str.ddraw.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415892
mov ecx, dword [ebp - 0x820]
mov edx, dword [ebp - 0x824]
mov eax, ecx
shr eax, 0x10
cmp ax, 4
jne 0x41583c
cmp ecx, 0x40008
ja 0x415856
jb 0x41583c
cmp edx, 0x190
jae 0x415856
cmp ax, 5
jne 0x415892
cmp ecx, 0x50001
ja 0x415856
jb 0x415892
cmp edx, 0x8d20190
ja 0x415856
jb 0x415892
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x415866
mov dword [eax], 8
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x415876
mov dword [eax], 0
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x415888
mov ecx, 0x20
mov word [eax], cx
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ecx, [ecx]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x4158be
movzx ecx, word [esi + eax]
test cx, cx
je 0x4158be
mov word [eax], cx
add eax, 2
dec edx
jne 0x4158a0
jmp 0x4158c2
test edx, edx
jne 0x4158c5
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
cmp word [eax], 0
je 0x4158e3
add eax, 2
dec edx
jne 0x4158d5
jmp 0x41590b
test edx, edx
je 0x41590b
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push str.d3d8.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415a0f
mov eax, dword [ebp - 0x820]
mov edx, dword [ebp - 0x824]
mov ecx, eax
shr ecx, 0x10
cmp cx, 4
jne 0x41594c
cmp eax, 0x40008
ja 0x415965
jb 0x41594c
cmp edx, 0x10371
jae 0x415965
cmp cx, 5
jne 0x4159a3
cmp eax, 0x50001
ja 0x415965
jb 0x4159a3
cmp edx, 0xa280371
ja 0x415965
jb 0x4159a3
mov edi, dword [ebp - 0x810]
test edi, edi
je 0x415975
mov dword [edi], 8
mov edi, dword [ebp - 0x81c]
test edi, edi
je 0x415985
mov dword [edi], 1
mov edi, dword [ebp - 0x814]
test edi, edi
je 0x415997
mov ebx, 0x20
mov word [edi], bx
mov dword [ebp - 0x818], 1
jmp 0x4159a9
mov edi, dword [ebp - 0x814]
cmp cx, 4
jne 0x4159c0
cmp eax, 0x40008
ja 0x4159d9
jb 0x4159c0
cmp edx, 0x10385
jae 0x4159d9
cmp cx, 5
jne 0x415a0f
cmp eax, 0x50001
ja 0x4159d9
jb 0x415a0f
cmp edx, 0xa280385
ja 0x4159d9
jb 0x415a0f
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x4159e9
mov dword [eax], 8
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x4159f9
mov dword [eax], 1
test edi, edi
je 0x415a05
mov eax, 0x61
mov word [edi], ax
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ebx, [ebx]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x415a3e
movzx ecx, word [esi + eax]
test cx, cx
je 0x415a3e
mov word [eax], cx
add eax, 2
dec edx
jne 0x415a20
jmp 0x415a42
test edx, edx
jne 0x415a45
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
cmp word [eax], 0
je 0x415a63
add eax, 2
dec edx
jne 0x415a55
jmp 0x415a8b
test edx, edx
je 0x415a8b
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push str.mpg2splt.ax
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415afa
mov eax, dword [ebp - 0x820]
cmp eax, 0x60003
ja 0x415abe
jb 0x415afa
mov eax, dword [ebp - 0x824]
cmp eax, 0x10375
ja 0x415abe
jb 0x415afa
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x415ace
mov dword [eax], 8
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x415ade
mov dword [eax], 1
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x415af0
mov ecx, 0x62
mov word [eax], cx
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x415b23
movzx ecx, word [esi + eax]
test cx, cx
je 0x415b23
mov word [eax], cx
add eax, 2
dec edx
jne 0x415b05
jmp 0x415b27
test edx, edx
jne 0x415b2a
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea ebx, [ebx]
cmp word [eax], 0
je 0x415b4e
add eax, 2
dec edx
jne 0x415b40
jmp 0x415b76
test edx, edx
je 0x415b76
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push str.dpnet.dll
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415c0e
mov ecx, dword [ebp - 0x820]
mov edx, dword [ebp - 0x824]
mov eax, ecx
shr eax, 0x10
cmp ax, 4
jne 0x415bb8
cmp ecx, 0x40009
ja 0x415bd2
jb 0x415bb8
cmp edx, 0x86
jae 0x415bd2
cmp ax, 5
jne 0x415c0e
cmp ecx, 0x50002
ja 0x415bd2
jb 0x415c0e
cmp edx, 0xe5d0086
ja 0x415bd2
jb 0x415c0e
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x415be2
mov dword [eax], 8
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x415bf2
mov dword [eax], 2
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x415c04
mov ecx, 0x20
mov word [eax], cx
mov dword [ebp - 0x818], 1
mov edx, 0x200
lea eax, [ebp - 0x40c]
lea esp, [esp]
lea ecx, [edx + 0x7ffffdfe]
test ecx, ecx
je 0x415c3e
movzx ecx, word [esi + eax]
test cx, cx
je 0x415c3e
mov word [eax], cx
add eax, 2
dec edx
jne 0x415c20
jmp 0x415c42
test edx, edx
jne 0x415c45
sub eax, 2
xor edx, edx
mov word [eax], dx
mov edx, 0x200
lea eax, [ebp - 0x40c]
cmp word [eax], 0
je 0x415c63
add eax, 2
dec edx
jne 0x415c55
jmp 0x415c8b
test edx, edx
je 0x415c8b
mov ecx, 0x200
sub ecx, edx
mov eax, 0x200
sub eax, ecx
push 0x5458e4
lea ecx, [ebp + ecx*2 - 0x40c]
mov edx, 0x7fffffff
call fcn.00414520
lea ebx, [ebp - 0x824]
lea edi, [ebp - 0x40c]
call fcn.00415d40
test eax, eax
js 0x415ce5
mov eax, dword [ebp - 0x810]
test eax, eax
je 0x415cb0
mov dword [eax], 9
mov eax, dword [ebp - 0x81c]
test eax, eax
je 0x415cc0
mov dword [eax], 0
mov eax, dword [ebp - 0x814]
test eax, eax
je 0x415cd2
mov ecx, 0x20
mov word [eax], cx
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0050bf32
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x818], 0
jne 0x415cd2
mov ebx, dword [ebp - 0x814]
mov edi, dword [ebp - 0x81c]
mov esi, dword [ebp - 0x810]
test esi, esi
je 0x415d0a
mov dword [esi], 0
test edi, edi
je 0x415d14
mov dword [edi], 0
xor eax, eax
test ebx, ebx
je 0x415cd4
mov ecx, dword [ebp - 8]
pop edi
mov edx, 0x20
pop esi
mov word [ebx], dx
xor ecx, ebp
pop ebx
call fcn.0050bf32
mov esp, ebp
pop ebp
ret