Function at 0x4bc160
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x541e16
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x114
push ebx
push esi
mov esi, ecx
push edi
lea ebx, [esi + 0x3c]
push ebx
mov dword [ebp - 0x10], ebx
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov al, byte [ebp + 0xf]
xor edi, edi
lea ecx, [ebp - 0x1c]
mov dword [ebp - 4], edi
mov byte [esi + 0xc88], 0
mov byte [ebp - 0x1c], al
call fcn.0043fff0
mov dword [ebp - 0x18], eax
mov byte [eax + 0x11], 1
mov eax, dword [ebp - 0x18]
mov dword [eax + 4], eax
mov eax, dword [ebp - 0x18]
mov dword [eax], eax
mov eax, dword [ebp - 0x18]
mov dword [eax + 8], eax
mov dword [ebp - 0x14], edi
mov eax, dword [esi + 0xc9c]
mov edi, dword [eax]
cmp edi, eax
mov byte [ebp - 4], 1
je 0x4bc266
lea esp, [esp]
mov ecx, dword [edi + 0xc]
mov eax, dword [ecx + 0x4c]
test eax, eax
mov dword [ebp - 0x20], ecx
jne 0x4bc1fb
mov al, byte [ecx + 0x53]
test al, al
jne 0x4bc1fb
mov al, byte [ecx + 0x54]
test al, al
je 0x4bc213
call fcn.004964b0
lea ecx, [ebp - 0x20]
push ecx
lea edx, [ebp - 0x110]
push edx
lea ecx, [ebp - 0x1c]
call fcn.004ade00
mov al, byte [edi + 0x11]
test al, al
jne 0x4bc25a
mov eax, dword [edi + 8]
mov cl, byte [eax + 0x11]
test cl, cl
jne 0x4bc23d
mov edi, eax
mov eax, dword [edi]
mov cl, byte [eax + 0x11]
test cl, cl
jne 0x4bc25a
nop
mov edi, eax
mov eax, dword [edi]
mov cl, byte [eax + 0x11]
test cl, cl
je 0x4bc230
jmp 0x4bc25a
mov eax, dword [edi + 4]
mov cl, byte [eax + 0x11]
test cl, cl
jne 0x4bc258
cmp edi, dword [eax + 8]
jne 0x4bc258
mov edi, eax
mov eax, dword [eax + 4]
mov cl, byte [eax + 0x11]
test cl, cl
je 0x4bc247
mov edi, eax
cmp edi, dword [esi + 0xc9c]
jne 0x4bc1e0
mov ecx, esi
call fcn.004b0e00
mov eax, dword [0x58f51c]
test eax, eax
push 0
je 0x4bc351
push 0x55aab4
lea edi, [esi + 0x58]
push edi
push 0
call eax
push str.DirectDrawCreateEx
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc2e4
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
push eax
push ecx
lea eax, [ebp + 0xc]
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004aae90
mov ecx, dword [ebp - 0x18]
push ecx
call fcn.00527b8e
add esp, 4
xor eax, eax
push ebx
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 2
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov eax, dword [edi]
mov edx, dword [eax]
lea ebx, [esi + 0x54]
push ebx
push 0x55aac4
push eax
call dword [edx]
mov edi, eax
push str.QueryrInterface_IID_IDirectDraw
push edi
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc335
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 2
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [ebp + 8]
push ecx
mov ecx, esi
call fcn.004b0d30
test al, al
je 0x4bc35f
mov ecx, dword [esi + 0x2c]
mov edx, dword [ecx]
call dword [edx + 0x11c]
jmp 0x4bc35f
lea ebx, [esi + 0x54]
push ebx
push 0
call dword [0x58f518]
mov edi, eax
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x120]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [esi + 0x2c]
mov edx, dword [ebp + 8]
mov dword [esi + 0xc8c], edx
mov ecx, dword [eax + 0x68]
mov dword [esi + 0x68], ecx
mov edx, dword [eax + 0x6c]
mov cl, byte [ebp + 0xc]
mov dword [esi + 0x6c], edx
mov eax, dword [eax + 0x70]
push str.DirectDrawCreate
mov byte [esi + 0xc90], cl
push edi
mov ecx, esi
mov dword [esi + 0x70], eax
mov byte [esi + 0xcc0], 0
call fcn.004ab4e0
test al, al
je 0x4bc3fc
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
push eax
push ecx
lea edx, [ebp + 0xc]
push edx
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004aae90
mov eax, dword [ebp - 0x18]
push eax
call fcn.00527b8e
mov ecx, dword [ebp - 0x10]
add esp, 4
xor eax, eax
push ecx
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 2
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov eax, dword [ebx]
mov edx, dword [eax]
lea edi, [esi + 0x74]
push edi
push eax
call dword [edx + 0x3c]
test eax, eax
jl 0x4bc411
cmp dword [edi], 0x3c
jae 0x4bc417
mov dword [edi], 0x3c
xor edx, edx
mov eax, 0x3e8
div dword [edi]
mov edx, dword [ebp + 8]
mov dword [esi + 0x78], eax
mov al, byte [ebp + 0xc]
test al, al
mov eax, dword [ebx]
mov ecx, dword [eax]
je 0x4bc5cc
push 8
push edx
push eax
call dword [ecx + 0x50]
xor eax, eax
mov ecx, 0x1f
lea edi, [ebp - 0x9c]
rep stosd dword es:[edi], eax
mov al, byte [esi + 0x38]
test al, al
mov dword [ebp - 0x9c], 0x7c
mov dword [ebp - 0x98], 1
mov dword [ebp - 0x34], 0x200
je 0x4bc474
mov dword [ebp - 0x34], 0x2200
push 0
lea eax, [esi + 0x5c]
push eax
lea eax, [ebp - 0x9c]
push eax
mov ecx, esi
mov dword [ebp - 0x88], 1
call fcn.00494d20
cmp eax, 0x88760091
jne 0x4bc4c7
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 6
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
push str.CreateSurface_Windowed_Primary
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
jne 0x4bc87b
xor eax, eax
mov ecx, 0x1f
lea edi, [ebp - 0x9c]
rep stosd dword es:[edi], eax
mov al, byte [esi + 0x38]
test al, al
mov dword [ebp - 0x9c], 0x7c
mov dword [ebp - 0x98], 7
mov dword [ebp - 0x34], 0x840
je 0x4bc514
mov dword [ebp - 0x34], 0x6040
mov eax, dword [esi + 0x68]
mov ecx, dword [esi + 0x6c]
push 0
lea edx, [esi + 0x64]
mov dword [ebp - 0x90], eax
push edx
lea eax, [ebp - 0x9c]
mov dword [ebp - 0x94], ecx
push eax
mov ecx, esi
call fcn.00494d20
push str.CreateSurface_Windowed_DrawSurface
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
jne 0x4bc8d1
mov ebx, dword [ebx]
mov edx, dword [ebx]
push 0
lea eax, [ebp + 0xc]
push eax
push 0
push ebx
call dword [edx + 0x10]
push str.CreateClipper_Windowed
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc59e
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov edx, dword [eax]
push ecx
push 0
push eax
call dword [edx + 0x20]
test eax, eax
jl 0x4bc5be
mov ecx, dword [ebp + 0xc]
mov eax, dword [esi + 0x5c]
mov edx, dword [eax]
push ecx
push eax
call dword [edx + 0x70]
mov eax, dword [ebp + 0xc]
mov edx, dword [eax]
push eax
call dword [edx + 8]
jmp 0x4bc811
push 0x11
push edx
push eax
call dword [ecx + 0x50]
push str.SetCooperativeLevel_FullScreen
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc612
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 4
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov edx, dword [esi + 0x70]
mov eax, dword [ebx]
mov ecx, dword [eax]
push edx
mov edx, dword [esi + 0x6c]
push edx
mov edx, dword [esi + 0x68]
push edx
push eax
call dword [ecx + 0x54]
push str.SetDisplayMode_FullScreen
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc665
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 5
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
xor eax, eax
mov ecx, 0x1f
lea edi, [ebp - 0x9c]
rep stosd dword es:[edi], eax
mov al, byte [esi + 0x38]
test al, al
mov dword [ebp - 0x9c], 0x7c
mov dword [ebp - 0x98], 0x21
mov dword [ebp - 0x34], 0x218
mov dword [ebp - 0x88], 1
je 0x4bc6a7
mov dword [ebp - 0x34], 0x2218
push 0
lea edi, [esi + 0x5c]
push edi
lea ecx, [ebp - 0x9c]
push ecx
mov ecx, esi
call fcn.00494d20
push str.CreateSurface_FullScreen_Primary
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
jne 0x4bc87b
mov eax, dword [edi]
lea edx, [esi + 0x60]
push edx
lea edx, [ebp - 0x20]
push edx
mov dword [ebp - 0x20], 4
mov ecx, dword [eax]
push eax
call dword [ecx + 0x30]
push str.GetAttachedSurface
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc726
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 3
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
xor eax, eax
mov ecx, 0x1f
lea edi, [ebp - 0x9c]
rep stosd dword es:[edi], eax
mov al, byte [esi + 0x38]
test al, al
mov dword [ebp - 0x9c], 0x7c
mov dword [ebp - 0x98], 7
mov dword [ebp - 0x34], 0x840
je 0x4bc75e
mov dword [ebp - 0x34], 0x6040
mov ecx, dword [esi + 0x68]
mov edx, dword [esi + 0x6c]
push 0
mov dword [ebp - 0x90], ecx
lea eax, [esi + 0x64]
push eax
lea ecx, [ebp - 0x9c]
push ecx
mov ecx, esi
mov dword [ebp - 0x94], edx
call fcn.00494d20
push str.CreateSurface_FullScreen_DrawSurface
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
jne 0x4bc87b
mov ebx, dword [ebx]
mov eax, dword [ebx]
push 0
lea ecx, [ebp + 0xc]
push ecx
push 0
push ebx
call dword [eax + 0x10]
push str.CreateClipper_FullScreen
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc7e8
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov ecx, dword [eax]
push edx
push 0
push eax
call dword [ecx + 0x20]
test eax, eax
jl 0x4bc808
mov edx, dword [ebp + 0xc]
mov eax, dword [esi + 0x5c]
mov ecx, dword [eax]
push edx
push eax
call dword [ecx + 0x70]
mov eax, dword [ebp + 0xc]
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov edx, dword [esi + 0xcac]
xor eax, eax
mov ecx, 0x1f
lea edi, [ebp - 0x9c]
rep stosd dword es:[edi], eax
mov eax, dword [esi + 0xcb0]
push 0
lea edi, [esi + 0xcc4]
push edi
lea ecx, [ebp - 0x9c]
push ecx
mov ecx, esi
mov dword [ebp - 0x9c], 0x7c
mov dword [ebp - 0x98], 7
mov dword [ebp - 0x34], 0x840
mov dword [ebp - 0x90], edx
mov dword [ebp - 0x94], eax
call fcn.00494d20
push str.CreateSurface_OldCursorArea
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc8a9
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 3
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
push 0
lea ebx, [esi + 0xcc8]
push ebx
lea eax, [ebp - 0x9c]
push eax
mov ecx, esi
call fcn.00494d20
push str.CreateSurface_NewCursorArea
push eax
mov ecx, esi
call fcn.004ab4e0
test al, al
je 0x4bc8ff
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 3
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
push 0xc8
call fcn.005183e0
add esp, 4
mov dword [ebp + 0xc], eax
test eax, eax
mov byte [ebp - 4], 2
je 0x4bc921
push esi
mov ecx, eax
call fcn.004b2960
jmp 0x4bc923
xor eax, eax
mov ecx, dword [edi]
mov dword [esi + 0xccc], eax
mov edx, dword [eax]
push ecx
mov ecx, eax
mov byte [ebp - 4], 1
call dword [edx + 0xa4]
mov ecx, dword [esi + 0xccc]
mov edx, dword [ecx]
push 0
push 0
call dword [edx + 0x68]
push 0xc8
call fcn.005183e0
add esp, 4
mov dword [ebp + 0xc], eax
test eax, eax
mov byte [ebp - 4], 3
je 0x4bc96b
push esi
mov ecx, eax
call fcn.004b2960
jmp 0x4bc96d
xor eax, eax
mov ecx, dword [ebx]
mov dword [esi + 0xcd0], eax
mov edx, dword [eax]
push ecx
mov ecx, eax
mov byte [ebp - 4], 1
call dword [edx + 0xa4]
mov ecx, dword [esi + 0xcd0]
mov edx, dword [ecx]
push 0
push 0
call dword [edx + 0x68]
mov edx, dword [esi + 0x5c]
test edx, edx
je 0x4bcf80
xor eax, eax
mov ecx, 0x1b
lea edi, [ebp - 0x108]
rep stosd dword es:[edi], eax
lea ecx, [ebp - 0x108]
push ecx
mov dword [ebp - 0x108], 0x6c
mov dword [ebp - 0x104], 0x1006
mov eax, dword [edx]
push edx
call dword [eax + 0x58]
mov eax, dword [ebp - 0xb4]
cmp eax, 0x10
je 0x4bca0c
cmp eax, 0x20
je 0x4bca0c
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004b0cf0
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 6
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov ebx, dword [ebp - 0xb0]
mov edi, dword [ebp - 0xa8]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0xac]
mov dword [esi + 8], ebx
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], edi
mov ecx, 0x20
nop
mov edx, ebx
shr edx, cl
test dl, 1
je 0x4bca3c
mov dword [esi + 0x20], ecx
mov edx, eax
shr edx, cl
test dl, 1
je 0x4bca48
mov dword [esi + 0x24], ecx
mov edx, edi
shr edx, cl
test dl, 1
je 0x4bca54
mov dword [esi + 0x28], ecx
dec ecx
jns 0x4bca30
mov ecx, dword [esi + 0x28]
mov edi, dword [esi + 0x24]
mov edx, dword [esi + 0x20]
mov eax, 2
add ecx, eax
add edi, eax
mov dword [ebp + 0xc], ecx
add edx, eax
mov dword [ebp + 8], 8
jmp 0x4bca80
mov ebx, dword [ebp - 0xb0]
lea ecx, [ecx]
lea ecx, [edx - 2]
cmp ecx, 0x20
jge 0x4bca97
lea ecx, [edx - 2]
shr ebx, cl
test ebx, ebx
je 0x4bca97
lea ecx, [eax - 1]
mov dword [esi + 0x14], ecx
lea ecx, [edi - 2]
cmp ecx, 0x20
jge 0x4bcab4
mov ebx, dword [ebp - 0xac]
lea ecx, [edi - 2]
shr ebx, cl
test ebx, ebx
je 0x4bcab4
lea ecx, [eax - 1]
mov dword [esi + 0x18], ecx
mov ecx, dword [ebp + 0xc]
lea ebx, [ecx - 2]
cmp ebx, 0x20
jge 0x4bcad4
mov ebx, dword [ebp - 0xa8]
add ecx, 0xfffffffe
shr ebx, cl
test ebx, ebx
je 0x4bcad4
lea ecx, [eax - 1]
mov dword [esi + 0x1c], ecx
lea ecx, [edx - 1]
cmp ecx, 0x20
jge 0x4bcaee
mov ebx, dword [ebp - 0xb0]
lea ecx, [edx - 1]
shr ebx, cl
test ebx, ebx
je 0x4bcaee
mov dword [esi + 0x14], eax
lea ecx, [edi - 1]
cmp ecx, 0x20
jge 0x4bcb08
mov ebx, dword [ebp - 0xac]
lea ecx, [edi - 1]
shr ebx, cl
test ebx, ebx
je 0x4bcb08
mov dword [esi + 0x18], eax
mov ecx, dword [ebp + 0xc]
lea ebx, [ecx - 1]
cmp ebx, 0x20
jge 0x4bcb23
mov ebx, dword [ebp - 0xa8]
dec ecx
shr ebx, cl
test ebx, ebx
je 0x4bcb23
mov dword [esi + 0x1c], eax
cmp edx, 0x20
jge 0x4bcb3c
mov ebx, dword [ebp - 0xb0]
mov ecx, edx
shr ebx, cl
test ebx, ebx
je 0x4bcb3c
lea ecx, [eax + 1]
mov dword [esi + 0x14], ecx
cmp edi, 0x20
jge 0x4bcb55
mov ebx, dword [ebp - 0xac]
mov ecx, edi
shr ebx, cl
test ebx, ebx
je 0x4bcb55
lea ecx, [eax + 1]
mov dword [esi + 0x18], ecx
mov ecx, dword [ebp + 0xc]
cmp ecx, 0x20
jge 0x4bcb6f
mov ebx, dword [ebp - 0xa8]
shr ebx, cl
test ebx, ebx
je 0x4bcb6f
lea ecx, [eax + 1]
mov dword [esi + 0x1c], ecx
lea ecx, [edx + 1]
cmp ecx, 0x20
jge 0x4bcb89
mov ebx, dword [ebp - 0xb0]
shr ebx, cl
test ebx, ebx
je 0x4bcb89
lea ecx, [eax + 2]
mov dword [esi + 0x14], ecx
lea ecx, [edi + 1]
cmp ecx, 0x20
jge 0x4bcba3
mov ebx, dword [ebp - 0xac]
shr ebx, cl
test ebx, ebx
je 0x4bcba3
lea ecx, [eax + 2]
mov dword [esi + 0x18], ecx
mov ecx, dword [ebp + 0xc]
inc ecx
cmp ecx, 0x20
jge 0x4bcbbe
mov ebx, dword [ebp - 0xa8]
shr ebx, cl
test ebx, ebx
je 0x4bcbbe
lea ecx, [eax + 2]
mov dword [esi + 0x1c], ecx
mov ebx, dword [ebp + 0xc]
mov ecx, dword [ebp + 8]
add ebx, 4
add eax, 4
add edx, 4
add edi, 4
dec ecx
mov dword [ebp + 0xc], ebx
mov dword [ebp + 8], ecx
jne 0x4bca77
mov eax, dword [esi + 0x7c]
push eax
call fcn.00528249
mov eax, dword [esi + 0x80]
push eax
call fcn.00528249
mov eax, dword [esi + 0x84]
push eax
call fcn.00528249
mov ecx, dword [esi + 0x14]
mov edi, 1
shl edi, cl
mov ecx, dword [esi + 0x18]
mov ebx, 1
shl ebx, cl
mov ecx, dword [esi + 0x1c]
mov eax, 1
shl eax, cl
dec edi
lea edx, [edi*8 + 4]
dec ebx
dec eax
push edx
mov dword [ebp + 0xc], eax
call fcn.00518484
mov dword [esi + 0x7c], eax
lea eax, [ebx*8 + 4]
push eax
call fcn.00518484
mov ecx, dword [ebp + 0xc]
lea edx, [ecx*8 + 4]
push edx
mov dword [esi + 0x80], eax
call fcn.00518484
mov dword [esi + 0x84], eax
lea ecx, [edi + edi + 1]
add esp, 0x18
xor eax, eax
test ecx, ecx
jle 0x4bcc7f
cmp eax, edi
mov ecx, eax
jl 0x4bcc70
mov ecx, edi
mov edx, dword [esi + 0x7c]
mov dword [edx + eax*4], ecx
inc eax
lea ecx, [edi + edi + 1]
cmp eax, ecx
jl 0x4bcc68
lea edx, [ebx + ebx + 1]
xor eax, eax
test edx, edx
jle 0x4bcca6
lea esp, [esp]
cmp eax, ebx
mov ecx, eax
jl 0x4bcc98
mov ecx, ebx
mov edi, dword [esi + 0x80]
mov dword [edi + eax*4], ecx
inc eax
cmp eax, edx
jl 0x4bcc90
mov edi, dword [ebp + 0xc]
lea edx, [edi + edi + 1]
xor eax, eax
test edx, edx
jle 0x4bccc9
cmp eax, edi
mov ecx, eax
jl 0x4bccbb
mov ecx, edi
mov ebx, dword [esi + 0x84]
mov dword [ebx + eax*4], ecx
inc eax
cmp eax, edx
jl 0x4bccb3
mov edi, 2
lea ecx, [esi + 0x488]
mov dword [ebp + 0xc], 0x20
jmp 0x4bcce0
mov eax, dword [esi + 8]
mov edx, eax
lea ebx, [edi - 2]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 8]
shr edx, 7
and edx, eax
mov dword [ecx - 0x400], edx
mov edx, dword [esi + 0xc]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0xc]
shr edx, 7
and edx, eax
mov dword [ecx], edx
mov edx, dword [esi + 0x10]
imul edx, ebx
mov ebx, dword [esi + 0x10]
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx + 0x400], edx
mov eax, dword [esi + 8]
lea ebx, [edi - 1]
mov edx, ebx
imul edx, eax
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 8]
shr edx, 7
and edx, eax
mov dword [ecx - 0x3fc], edx
mov eax, dword [esi + 0xc]
mov edx, ebx
imul edx, eax
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0xc]
shr edx, 7
and edx, eax
mov dword [ecx + 4], edx
imul ebx, dword [esi + 0x10]
mov eax, 0x80808081
mul ebx
mov ebx, dword [esi + 0x10]
shr edx, 7
and edx, ebx
mov dword [ecx + 0x404], edx
mov ebx, dword [esi + 8]
mov edx, edi
imul edx, ebx
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx - 0x3f8], edx
mov ebx, dword [esi + 0xc]
mov edx, edi
imul edx, ebx
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx + 8], edx
mov ebx, dword [esi + 0x10]
mov edx, edi
imul edx, ebx
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx + 0x408], edx
mov eax, dword [esi + 8]
mov edx, eax
lea ebx, [edi + 1]
imul edx, ebx
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, dword [esi + 8]
mov dword [ecx - 0x3f4], edx
mov edx, dword [esi + 0xc]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0xc]
shr edx, 7
and edx, eax
mov dword [ecx + 0xc], edx
mov edx, dword [esi + 0x10]
imul edx, ebx
mov ebx, dword [esi + 0x10]
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx + 0x40c], edx
mov eax, dword [esi + 8]
mov edx, eax
lea ebx, [edi + 2]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 8]
shr edx, 7
and edx, eax
mov dword [ecx - 0x3f0], edx
mov edx, dword [esi + 0xc]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0xc]
shr edx, 7
and edx, eax
mov dword [ecx + 0x10], edx
mov edx, dword [esi + 0x10]
imul edx, ebx
mov ebx, dword [esi + 0x10]
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx + 0x410], edx
mov eax, dword [esi + 8]
mov edx, eax
lea ebx, [edi + 3]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 8]
shr edx, 7
and edx, eax
mov dword [ecx - 0x3ec], edx
mov edx, dword [esi + 0xc]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0xc]
shr edx, 7
and edx, eax
mov dword [ecx + 0x14], edx
mov edx, dword [esi + 0x10]
imul edx, ebx
mov ebx, dword [esi + 0x10]
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx + 0x414], edx
mov eax, dword [esi + 8]
mov edx, eax
lea ebx, [edi + 4]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 8]
shr edx, 7
and edx, eax
mov dword [ecx - 0x3e8], edx
mov edx, dword [esi + 0xc]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0xc]
shr edx, 7
and edx, eax
mov dword [ecx + 0x18], edx
mov edx, dword [esi + 0x10]
imul edx, ebx
mov ebx, dword [esi + 0x10]
mov eax, 0x80808081
mul edx
shr edx, 7
and edx, ebx
mov dword [ecx + 0x418], edx
mov eax, dword [esi + 8]
mov edx, eax
lea ebx, [edi + 5]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 8]
shr edx, 7
and edx, eax
mov dword [ecx - 0x3e4], edx
mov edx, dword [esi + 0xc]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0xc]
shr edx, 7
and edx, eax
mov dword [ecx + 0x1c], edx
mov edx, dword [esi + 0x10]
imul edx, ebx
mov eax, 0x80808081
mul edx
mov eax, dword [esi + 0x10]
shr edx, 7
and edx, eax
mov eax, dword [ebp + 0xc]
mov dword [ecx + 0x41c], edx
add ecx, 0x20
add edi, 8
dec eax
mov dword [ebp + 0xc], eax
jne 0x4bcce0
mov eax, dword [ebp - 0x18]
mov edi, dword [eax]
cmp edi, eax
je 0x4bd03c
lea ecx, [ecx]
mov ebx, dword [edi + 0xc]
lea eax, [ebp + 0xc]
push eax
lea ecx, [ebp + 8]
push ecx
lea ecx, [esi + 0xc98]
mov dword [ebp + 0xc], ebx
call fcn.004ce080
mov eax, dword [esi + 0xc9c]
cmp dword [ebp + 8], eax
je 0x4bcfec
mov al, byte [esi + 0x38]
test al, al
je 0x4bcfce
mov al, byte [ebx + 0x55]
test al, al
je 0x4bcfec
mov edx, dword [ebx]
mov ecx, ebx
call dword [edx + 0x70]
mov byte [ebx + 0x55], al
jmp 0x4bcfec
mov al, byte [ebx + 0x54]
test al, al
je 0x4bcfde
mov ecx, ebx
call fcn.004a05d0
jmp 0x4bcfec
mov al, byte [ebx + 0x53]
test al, al
je 0x4bcfec
mov ecx, ebx
call fcn.00495bc0
mov al, byte [edi + 0x11]
test al, al
jne 0x4bd033
mov eax, dword [edi + 8]
mov cl, byte [eax + 0x11]
test cl, cl
jne 0x4bd015
mov edi, eax
mov eax, dword [edi]
mov cl, byte [eax + 0x11]
test cl, cl
jne 0x4bd033
mov edi, eax
mov eax, dword [edi]
mov cl, byte [eax + 0x11]
test cl, cl
je 0x4bd008
jmp 0x4bd033
mov eax, dword [edi + 4]
mov cl, byte [eax + 0x11]
test cl, cl
jne 0x4bd031
nop
cmp edi, dword [eax + 8]
jne 0x4bd031
mov edi, eax
mov eax, dword [eax + 4]
mov cl, byte [eax + 0x11]
test cl, cl
je 0x4bd020
mov edi, eax
cmp edi, dword [ebp - 0x18]
jne 0x4bcf90
xor eax, eax
mov al, byte [esi + 0xca4]
mov ecx, esi
push eax
call fcn.004b4210
mov al, byte [esi + 0x38]
test al, al
je 0x4bd0e8
mov ecx, dword [esi + 0x30]
push esi
call fcn.004abb80
test al, al
jne 0x4bd0e8
mov eax, str.3D_init_error:
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4bd070
sub eax, edx
push eax
add esi, 0xcd4
push str.3D_init_error:
mov ecx, esi
call fcn.0041af60
push 0xffffffffffffffff
xor edi, edi
push edi
push 0x589244
mov ecx, esi
call fcn.00416d70
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax]
push eax
push ecx
lea ecx, [ebp + 0xc]
push ecx
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004aae90
mov edx, dword [ebp - 0x18]
push edx
call fcn.00527b8e
mov eax, dword [ebp - 0x10]
add esp, 4
push eax
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x14], edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
pop edi
pop esi
mov eax, 7
pop ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8
mov edi, dword [esi + 0xca8]
mov eax, dword [ebp - 0x18]
inc edi
mov dword [esi + 0xca8], edi
mov byte [esi + 0xc88], 1
mov ecx, dword [eax]
push eax
push ecx
lea ecx, [ebp + 0xc]
push ecx
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0
call fcn.004aae90
mov edx, dword [ebp - 0x18]
push edx
call fcn.00527b8e
xor eax, eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x10]
add esp, 4
push eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
xor eax, eax
pop ebx
mov dword fs:[0], ecx
mov esp, ebp
pop ebp
ret 8