Function at 0x41e030
Capabilities:
Set current directory

Disassembly:
sub esp, 0x108
push esi
push edi
mov esi, ecx
call sub.MFC42.DLL_AfxGetThread
test eax, eax
je 0x41e04c
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0x7c]
jmp 0x41e04e
xor eax, eax
mov eax, dword [eax + 0x20]
mov ecx, 0x41
mov dword [esi + 0x148], eax
xor eax, eax
lea edi, [esp + 0xc]
push ebx
rep stosd dword es:[edi], eax
lea ecx, [esp + 0xc]
push ebp
push ecx
call fcn.00457a50
mov edx, dword [eax]
add esp, 4
lea eax, [esp + 0x14]
push edx
push 0x48c060
push 0x103
push eax
call dword [sym.imp.MSVCRT.dll__snprintf]
add esp, 0x10
lea ecx, [esp + 0x10]
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
mov ebp, 0xa0
mov eax, 0xffffff10
xor edi, edi
sub ebp, esi
sub eax, esi
lea ecx, [esi + 0xf0]
mov dword [esp + 0x10], eax
jmp 0x41e0c2
mov eax, dword [esp + 0x10]
mov edx, dword [0x4b6684]
add eax, ecx
lea ebx, [ecx + ebp]
add edi, 0x10
mov eax, dword [eax + edx + 0x18c]
add ecx, 8
mov ebx, dword [ebx + edx]
sub eax, dword [edi + edx + 0x20]
sub ebx, dword [edi + edx + 0x24]
cdq
idiv dword [esi + 0x98]
mov dword [ecx - 0xc], eax
mov eax, ebx
cdq
idiv dword [esi + 0x98]
cmp edi, 0x60
mov dword [ecx - 8], eax
jl 0x41e0be
xor edi, edi
push edi
call fcn.0045bd40
add esp, 4
cmp eax, edi
mov dword [esi + 0x163c], eax
pop ebp
pop ebx
jne 0x41e130
push edi
push edi
push str.CxImage::CreateDisplay_2D_D3D8__Failed_
call sub.MFC42.DLL_AfxMessageBox
pop edi
xor eax, eax
pop esi
add esp, 0x108
ret 8
call sub.MFC42.DLL_AfxGetThread
cmp eax, edi
je 0x41e140
mov edx, dword [eax]
mov ecx, eax
call dword [edx + 0x7c]
mov eax, dword [esi + 0x1600]
mov ecx, esi
cmp eax, edi
je 0x41e170
call fcn.004215f0
cmp eax, edi
jne 0x41e159
xor eax, eax
jmp 0x41e15c
mov eax, dword [eax + 0x20]
mov ecx, dword [esi + 0x163c]
push 0x2e2
push 0x400
mov edx, dword [ecx]
jmp 0x41e192
call fcn.004215f0
cmp eax, edi
jne 0x41e17d
xor eax, eax
jmp 0x41e180
mov eax, dword [eax + 0x20]
mov ecx, dword [esi + 0x163c]
push 0x23a
push 0x320
mov edx, dword [ecx]
push eax
call dword [edx + 0xc]
cmp eax, edi
je 0x41e217
call fcn.0045bdd0
push 0x48e7d8
call fcn.0045bd40
add esp, 4
cmp eax, edi
mov dword [esi + 0x163c], eax
jne 0x41e1cf
push edi
push edi
push str.2_CxImage::CreateDisplay_2D__Failed_
call sub.MFC42.DLL_AfxMessageBox
pop edi
xor eax, eax
pop esi
add esp, 0x108
ret 8
mov ecx, esi
call fcn.004215f0
cmp eax, edi
jne 0x41e1de
xor eax, eax
jmp 0x41e1e1
mov eax, dword [eax + 0x20]
mov ecx, dword [esi + 0x163c]
push 0x23a
push 0x320
push eax
mov edx, dword [ecx]
call dword [edx + 0xc]
test eax, eax
je 0x41e217
push edi
push edi
push str.2_Create_DirectDraw_Failed_
call sub.MFC42.DLL_AfxMessageBox
pop edi
mov eax, 1
pop esi
add esp, 0x108
ret 8
call fcn.0045cc80
mov ecx, esi
call fcn.0041eb40
mov ecx, esi
call fcn.0041ec00
mov ecx, esi
call fcn.0041fcb0
mov eax, dword [0x4b6684]
mov ecx, dword [eax + 0x150]
add ecx, 0xb44
push ecx
call fcn.00451740
mov edx, dword [0x4b6684]
mov eax, dword [edx + 0x150]
add eax, 0xcf4
push eax
call fcn.004517d0
mov ecx, dword [0x4b6684]
mov edx, dword [ecx + 0x150]
add edx, 0xcd0
push edx
call fcn.004517d0
mov eax, dword [0x4b6684]
add esp, 0xc
mov ecx, dword [eax + 0x150]
push edi
add ecx, 0xa24
call fcn.0045cd50
mov ecx, dword [0x4b6684]
push edi
mov ecx, dword [ecx + 0x150]
add ecx, 0xa24
call fcn.0045cd50
mov edx, dword [0x4b6680]
cmp dword [edx + 0x2c50], edi
je 0x41e2ce
mov eax, dword [0x4b6688]
mov dword [eax + 0x2ac], edi
mov ecx, dword [0x4b6688]
mov dword [ecx + 0x2b0], edi
pop edi
mov eax, 1
pop esi
add esp, 0x108
ret 8