Function at 0x40efb0
Capabilities:
Print debug messages

Disassembly:
mov eax, dword [0x5d5758]
sub esp, 0x60
test eax, eax
push ebx
push ebp
push esi
push edi
jne 0x40efca
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x60
ret
mov eax, dword [0x5d5764]
test eax, eax
jne 0x40efdd
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x60
ret
mov eax, dword [0x5c4320]
test eax, eax
jne 0x40f04e
mov eax, dword [esp + 0xa4]
mov ecx, dword [esp + 0xa0]
mov edx, dword [esp + 0x9c]
push eax
mov eax, dword [esp + 0x9c]
push ecx
mov ecx, dword [esp + 0x94]
push edx
mov edx, dword [esp + 0x94]
push eax
mov eax, dword [esp + 0x94]
push ecx
mov ecx, dword [esp + 0x94]
push edx
mov edx, dword [esp + 0x94]
push eax
mov eax, dword [esp + 0x94]
push ecx
mov ecx, dword [esp + 0x94]
push edx
push eax
push ecx
call fcn.0040eca0
add esp, 0x2c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret
mov eax, dword [0x5d57ac]
mov edi, 1
test eax, eax
je 0x40f063
mov edi, dword [esp + 0x94]
mov ebp, dword [esp + 0x88]
test ebp, ebp
jne 0x40f0cf
mov edx, dword [esp + 0xa4]
mov eax, dword [esp + 0xa0]
mov ecx, dword [esp + 0x9c]
push edx
mov edx, dword [esp + 0x9c]
push eax
mov eax, dword [esp + 0x94]
push ecx
mov ecx, dword [esp + 0x90]
push edx
mov edx, dword [esp + 0x90]
push eax
mov eax, dword [esp + 0x90]
push ebp
push ecx
mov ecx, dword [esp + 0x94]
push edx
mov edx, dword [esp + 0x94]
push eax
push ecx
push edx
call fcn.0040eca0
add esp, 0x2c
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret
mov eax, dword [esp + 0x90]
test eax, eax
jge 0x40f0e5
mov dword [esp + 0x90], 0
test edi, edi
jge 0x40f0ed
xor edi, edi
jmp 0x40f0f7
cmp edi, 8
jle 0x40f0f7
mov edi, 8
cmp dword [esp + 0x90], 8
jl 0x40f10c
mov dword [esp + 0x90], 7
push 0x40
call fcn.0050a4f5
push 0xc
mov esi, eax
call fcn.0050a4f5
mov ecx, dword [esp + 0x7c]
mov dword [esi + 4], eax
push 0xc
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [esi + 4]
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov eax, dword [esi + 4]
mov ecx, dword [ecx + 8]
mov dword [eax + 8], ecx
call fcn.0050a4f5
mov ecx, dword [esp + 0x84]
mov dword [esi + 8], eax
push 0xc
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [esi + 8]
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov eax, dword [esi + 8]
mov ecx, dword [ecx + 8]
mov dword [eax + 8], ecx
call fcn.0050a4f5
mov ecx, dword [esp + 0x8c]
mov dword [esi + 0xc], eax
push 0xc
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [esi + 0xc]
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov eax, dword [esi + 0xc]
mov ecx, dword [ecx + 8]
mov dword [eax + 8], ecx
call fcn.0050a4f5
mov ecx, dword [esp + 0x94]
mov dword [esi + 0x10], eax
mov ebx, dword [esp + 0xa0]
add esp, 0x14
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [esi + 0x10]
mov edx, dword [ecx + 4]
mov dword [eax + 4], edx
mov eax, dword [esi + 0x10]
mov ecx, dword [ecx + 8]
mov edx, dword [esp + 0x84]
mov dword [eax + 8], ecx
mov dword [esi + 0x14], edx
lea edx, [esi + 0x1c]
xor eax, eax
sub edx, ebp
cmp ebx, eax
jne 0x40f234
mov eax, ebp
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x40f1cf
mov eax, dword [esp + 0xa4]
mov ecx, dword [esp + 0xa0]
mov ebx, dword [esp + 0x9c]
mov ebp, dword [esp + 0x98]
mov edx, dword [esp + 0x90]
push eax
mov eax, dword [esp + 0x8c]
push ecx
push ebx
push ebp
push edi
push edx
push eax
call fcn.0042ad70
add esp, 0x1c
mov dword [esi + 0x34], eax
test eax, eax
mov dword [esi + 0x38], eax
je 0x40f228
mov dword [esi + 0x18], 1
jmp 0x40f33b
mov dword [esi + 0x18], 0
jmp 0x40f33b
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], eax
mov eax, ebp
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x40f23e
mov ebp, dword [esp + 0x98]
mov dword [esp + 0x94], 0
test ebx, ebx
mov ebx, dword [esp + 0x9c]
jle 0x40f325
mov ecx, dword [esp + 0x94]
mov edx, dword [esp + 0x88]
push ecx
push edx
lea eax, [esp + 0x38]
push str._s_02d
push eax
call fcn.005099e1
mov eax, dword [esp + 0xa4]
add esp, 0x10
test eax, eax
jne 0x40f2c7
mov ecx, dword [esp + 0xa4]
mov edx, dword [esp + 0xa0]
mov eax, dword [esp + 0x90]
push ecx
push edx
push ebx
push ebp
push edi
lea ecx, [esp + 0x44]
push eax
push ecx
call fcn.0042ad70
add esp, 0x1c
mov dword [esi + 0x38], eax
test eax, eax
je 0x40f325
jmp 0x40f2fa
mov edx, dword [esp + 0xa4]
mov eax, dword [esp + 0xa0]
mov ecx, dword [esp + 0x90]
push edx
push eax
push ebx
push ebp
push edi
lea edx, [esp + 0x44]
push ecx
push edx
call fcn.0042ad70
add esp, 0x1c
test eax, eax
je 0x40f325
mov ecx, dword [esp + 0x10]
mov dword [ecx + 0x64], eax
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x8c]
inc eax
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x94]
inc eax
cmp eax, ecx
mov dword [esp + 0x94], eax
jl 0x40f269
mov eax, dword [esi + 0x38]
test eax, eax
jne 0x40f331
mov dword [esi + 0x18], eax
jmp 0x40f338
mov edx, dword [esp + 0x14]
mov dword [esi + 0x18], edx
mov dword [esi + 0x34], eax
mov eax, dword [esi + 0x18]
test eax, eax
jne 0x40f3f7
lea edi, [esi + 0x1c]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0x18
jbe 0x40f363
push str.Texture_name_too_long____should_be___24___n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
lea eax, [esi + 0x1c]
lea edx, [esp + 0x18]
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x40f36c
mov eax, dword [esi + 4]
push eax
call fcn.0050a62f
mov ecx, dword [esi + 8]
push ecx
call fcn.0050a62f
mov edx, dword [esi + 0xc]
push edx
call fcn.0050a62f
mov eax, dword [esi + 0x10]
push eax
call fcn.0050a62f
push esi
call fcn.0050a62f
mov ecx, dword [esp + 0xb8]
mov edx, dword [esp + 0xb4]
mov eax, dword [esp + 0xa0]
push ecx
push edx
mov edx, dword [esp + 0xa0]
push ebx
push ebp
lea ecx, [esp + 0x3c]
push eax
mov eax, dword [esp + 0xa8]
push ecx
mov ecx, dword [esp + 0xa8]
push edx
mov edx, dword [esp + 0xa8]
push eax
mov eax, dword [esp + 0xa8]
push ecx
push edx
push eax
call fcn.0040eca0
add esp, 0x40
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret
mov ecx, dword [0x5d5764]
push esi
push ecx
call fcn.0041bf50
mov dword [esi + 0x3c], eax
mov ecx, dword [0x7eff80]
add esp, 8
xor eax, eax
test ecx, ecx
jle 0x40f426
mov edx, dword [eax*4 + 0x7e5980]
test edx, edx
je 0x40f426
inc eax
cmp eax, ecx
jl 0x40f416
cmp eax, ecx
jne 0x40f450
cmp ecx, 0x1400
jl 0x40f449
push str.No_more_material_available.__MAT01_
call fcn.00410b40
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret
inc ecx
mov dword [0x7eff80], ecx
mov dword [eax*4 + 0x7e5980], esi
mov dword [esi], eax
pop edi
pop esi
pop ebp
or eax, 0x3000000
pop ebx
add esp, 0x60
ret