Function at 0x402210
Capabilities:
Capture screenshot

Disassembly:
sub esp, 0x264
push ebx
push ebp
push esi
xor esi, esi
push edi
lea eax, [esp + 0x2c]
push esi
lea ecx, [esp + 0x2c]
push eax
push ecx
mov dword [esp + 0x38], 1
mov dword [esp + 0x3c], esi
mov dword [esp + 0x40], esi
mov dword [esp + 0x44], esi
call sub.gdiplus.dll_GdiplusStartup
push esi
call dword [sym.imp.USER32.dll_GetWindowDC]
mov edi, dword [sym.imp.USER32.dll_GetSystemMetrics]
push 0x4c
mov ebx, eax
call edi
push 0x4d
mov ebp, eax
call edi
push 0x4e
mov dword [esp + 0x18], eax
call edi
mov esi, eax
push 0x4f
mov dword [esp + 0x24], esi
call edi
mov edi, eax
push edi
push esi
push ebx
mov dword [esp + 0x30], edi
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
push ebx
mov dword [esp + 0x1c], eax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov edx, dword [esp + 0x18]
mov dword [esp + 0x1c], eax
push edx
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x14]
push 0xcc0020
push eax
push ebp
push ebx
mov ebx, dword [esp + 0x2c]
push edi
xor ebp, ebp
push esi
push ebp
push ebp
push ebx
call dword [sym.imp.GDI32.dll_BitBlt]
mov ecx, dword [esp + 0x10]
push ecx
push ebx
call dword [sym.imp.GDI32.dll_SelectObject]
mov ebx, dword [esp + 0x27c]
cmp ebx, ebp
jne 0x402327
mov ecx, dword [esp + 0x280]
cmp ecx, ebp
je 0x402317
cmp ecx, 0x64
jge 0x402317
imul esi, ecx
imul edi, ecx
mov eax, 0x51eb851f
imul esi
sar edx, 5
mov eax, edx
shr eax, 0x1f
add edx, eax
mov eax, 0x51eb851f
mov ebx, edx
imul edi
sar edx, 5
mov ecx, edx
mov dword [esp + 0x27c], ebx
shr ecx, 0x1f
add edx, ecx
mov dword [esp + 0x280], edx
jmp 0x402327
mov ebx, esi
mov dword [esp + 0x280], edi
mov dword [esp + 0x27c], ebx
push 0x10
call sub.gdiplus.dll_GdipAlloc
mov esi, eax
cmp esi, ebp
je 0x402364
mov eax, dword [esp + 0x280]
lea edx, [esp + 0x10]
push edx
push ebp
push 0x26200a
push ebp
push eax
push ebx
mov dword [esi], 0x4091d4
mov dword [esp + 0x28], ebp
call sub.gdiplus.dll_GdipCreateBitmapFromScan0
mov ecx, dword [esp + 0x10]
mov dword [esi + 8], eax
mov dword [esi + 4], ecx
jmp 0x402366
xor esi, esi
push 0x10
call sub.gdiplus.dll_GdipAlloc
mov edi, eax
cmp edi, ebp
je 0x40239d
mov eax, dword [esp + 0x18]
lea edx, [esp + 0x10]
push edx
push ebp
push eax
mov dword [edi], 0x4091d4
mov dword [esp + 0x1c], ebp
call sub.gdiplus.dll_GdipCreateBitmapFromHBITMAP
mov ecx, dword [esp + 0x10]
mov dword [edi + 8], eax
mov dword [edi + 4], ecx
mov dword [esp + 0x10], edi
jmp 0x4023a3
mov dword [esp + 0x10], ebp
mov edi, ebp
push 8
call sub.gdiplus.dll_GdipAlloc
mov ebx, eax
cmp ebx, ebp
je 0x4023d1
cmp esi, ebp
mov dword [esp + 0x14], ebp
je 0x4023c9
mov eax, dword [esi + 4]
lea edx, [esp + 0x14]
push edx
push eax
call sub.gdiplus.dll_GdipGetImageGraphicsContext
mov dword [ebx + 4], eax
mov ecx, dword [esp + 0x14]
mov dword [ebx], ecx
jmp 0x4023d3
xor ebx, ebx
fild dword [esp + 0x280]
push ebp
push ecx
mov edx, dword [ebx]
fidiv dword [esp + 0x2c]
fstp dword [esp]
fild dword [esp + 0x284]
push ecx
fidiv dword [esp + 0x2c]
fstp dword [esp]
push edx
call sub.gdiplus.dll_GdipScaleWorldTransform
cmp eax, ebp
je 0x402401
mov dword [ebx + 4], eax
cmp edi, ebp
je 0x40240a
mov eax, dword [edi + 4]
jmp 0x40240c
xor eax, eax
push ebp
push ebp
push eax
mov eax, dword [ebx]
push eax
call sub.gdiplus.dll_GdipDrawImageI
cmp eax, ebp
je 0x40241e
mov dword [ebx + 4], eax
mov ecx, dword [0x4095f0]
mov edx, dword [0x4095f4]
mov dword [esp + 0x40], ecx
mov ecx, dword [0x4095f8]
mov eax, 1
mov dword [esp + 0x48], ecx
lea ecx, [esp + 0x5c]
mov dword [esp + 0x3c], eax
mov dword [esp + 0x44], edx
mov edx, dword [0x4095fc]
mov dword [esp + 0x50], eax
lea eax, [esp + 0x284]
push ecx
push str.image_jpeg
mov dword [esp + 0x54], edx
mov dword [esp + 0x5c], 4
mov dword [esp + 0x60], eax
call fcn.00402150
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 0x76]
mov word [esp + 0x74], bp
rep stosd dword es:[edi], eax
add esp, 8
lea edx, [esp + 0x6c]
stosw word es:[edi], ax
mov eax, dword [esp + 0x278]
push 0x104
push edx
push 0xffffffffffffffff
push eax
push ebp
push ebp
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x5c]
push ecx
mov ecx, dword [esi + 4]
lea eax, [esp + 0x70]
push edx
push eax
push ecx
call sub.gdiplus.dll_GdipSaveImageToFile
cmp eax, ebp
je 0x4024c9
mov dword [esi + 8], eax
jmp 0x4024cb
xor eax, eax
mov edi, dword [sym.imp.GDI32.dll_DeleteObject]
xor edx, edx
cmp eax, ebp
mov eax, dword [esp + 0x18]
sete dl
push eax
mov ebp, edx
call edi
mov ecx, dword [esp + 0x1c]
push ecx
call edi
test ebx, ebx
je 0x4024fa
mov edx, dword [ebx]
push edx
call sub.gdiplus.dll_GdipDeleteGraphics
push ebx
call sub.gdiplus.dll_GdipFree
test esi, esi
je 0x402506
mov eax, dword [esi]
push 1
mov ecx, esi
call dword [eax]
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x402514
mov edx, dword [ecx]
push 1
call dword [edx]
mov eax, dword [esp + 0x28]
push eax
call sub.gdiplus.dll_GdiplusShutdown
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x264
ret