Function at 0x30040662
Capabilities:
Print debug messages

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x68
cmp dword [ebp + 0x10], 0
jne 0x30040681
push 0x3000660c
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call dword [sym.imp.KERNEL32.dll_DebugBreak]
cmp dword [ebp + 0xc], 0
jne 0x30040698
push 0x3000660c
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
call dword [sym.imp.KERNEL32.dll_DebugBreak]
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax + 0x2c]
mov dword [ebp - 0x50], ecx
push 4
lea edx, [ebp - 0x50]
push edx
mov eax, dword [ebp + 0xc]
mov ecx, dword [eax + 0x2c]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.3003ff4e
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
je 0x300406c8
mov eax, dword [ebp - 0x4c]
jmp 0x3004092e
mov eax, dword [ebp + 0xc]
mov ecx, dword [eax + 0x34]
add ecx, 4
mov edx, dword [ebp + 0xc]
mov dword [edx + 0x34], ecx
mov eax, dword [ebp + 0x10]
mov ecx, dword [eax + 0x4c]
mov dword [ebp - 4], ecx
mov edx, dword [ebp + 0x10]
add edx, 0x4c
cmp dword [ebp - 4], edx
je 0x3004092c
mov eax, dword [ebp + 8]
push eax
call fcn.30045272
test eax, eax
je 0x30040706
mov eax, 0x800704c7
jmp 0x3004092e
mov ecx, dword [ebp - 4]
sub ecx, 0x9c
mov dword [ebp - 0x54], ecx
mov edx, dword [ebp - 4]
mov eax, dword [edx]
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + 0x98]
and edx, 1
jne 0x3004072a
jmp 0x300406e0
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax + 0x98]
and ecx, 4
je 0x30040768
lea edx, [ebp - 0x5c]
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x48]
push ecx
mov edx, dword [ebp - 0x54]
mov eax, dword [edx + 0x64]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.3003fffd
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
je 0x3004076f
mov eax, dword [ebp - 0x4c]
jmp 0x3004092e
mov dword [ebp - 0x5c], 0
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax + 0x98]
and ecx, 2
je 0x300407f3
mov edx, dword [ebp - 0x54]
mov eax, dword [ebp - 0x54]
mov ecx, dword [edx + 0x70]
sub ecx, dword [eax + 0x78]
mov edx, dword [edx + 0x74]
sbb edx, dword [eax + 0x7c]
mov dword [ebp - 0x68], ecx
mov dword [ebp - 0x64], edx
jne 0x3004079d
cmp dword [ebp - 0x68], 0
jbe 0x300407f3
lea eax, [ebp - 0x60]
push eax
push 2
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x18]
and edx, 8
neg edx
sbb edx, edx
neg edx
push edx
mov eax, dword [ebp - 0x54]
mov ecx, dword [ebp - 0x54]
mov edx, dword [eax + 0x70]
sub edx, dword [ecx + 0x78]
mov eax, dword [eax + 0x74]
sbb eax, dword [ecx + 0x7c]
push edx
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + 0x7c]
push edx
mov eax, dword [ecx + 0x78]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.30040180
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
je 0x300407fa
mov eax, dword [ebp - 0x4c]
jmp 0x3004092e
mov dword [ebp - 0x60], 0
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + 0x98]
and edx, 8
je 0x30040867
mov eax, dword [ebp - 0x54]
cmp dword [eax + 0x88], 0
je 0x30040867
lea ecx, [ebp - 0x58]
push ecx
push 3
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x18]
and eax, 8
neg eax
sbb eax, eax
neg eax
push eax
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + 0x88]
push edx
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax + 0x84]
push ecx
mov edx, dword [eax + 0x80]
push edx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.30040180
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
je 0x3004086e
mov eax, dword [ebp - 0x4c]
jmp 0x3004092e
mov dword [ebp - 0x58], 0
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax]
mov dword [ebp - 0x48], ecx
mov edx, dword [ebp - 0x54]
mov eax, dword [edx + 0x10]
mov dword [ebp - 0x44], eax
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + 0x1c]
mov dword [ebp - 0x40], edx
mov eax, dword [ebp - 0x54]
mov ecx, dword [eax + 0x20]
mov dword [ebp - 0x3c], ecx
mov edx, dword [ebp - 0x54]
mov eax, dword [edx + 0x58]
mov dword [ebp - 0x38], eax
mov ecx, dword [edx + 0x5c]
mov dword [ebp - 0x34], ecx
mov edx, dword [ebp - 0x54]
mov eax, dword [edx + 0x78]
mov dword [ebp - 0x30], eax
mov ecx, dword [edx + 0x7c]
mov dword [ebp - 0x2c], ecx
mov edx, dword [ebp - 0x54]
mov eax, dword [ebp - 0x54]
mov ecx, dword [edx + 0x70]
sub ecx, dword [eax + 0x78]
mov edx, dword [edx + 0x74]
sbb edx, dword [eax + 0x7c]
mov dword [ebp - 0x28], ecx
mov eax, dword [ebp - 0x60]
mov dword [ebp - 0x24], eax
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + 0x80]
mov dword [ebp - 0x18], edx
mov eax, dword [ecx + 0x84]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x54]
mov edx, dword [ecx + 0x88]
mov dword [ebp - 0x10], edx
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x48]
mov dword [ebp - 0x20], edx
mov eax, dword [ebp - 0x5c]
mov dword [ebp - 0x1c], eax
push 0
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx + 0x38]
push edx
lea eax, [ebp - 0x48]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.300402e1
mov dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0
je 0x300406e0
mov eax, dword [ebp - 0x4c]
jmp 0x3004092e
xor eax, eax
mov esp, ebp
pop ebp
ret 0xc