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

Disassembly:
sub esp, 8
push ebx
push ebp
mov ebp, dword [esp + 0x14]
push esi
push edi
mov edi, ebp
or ecx, 0xffffffff
xor eax, eax
xor ebx, ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov dword [esp + 0x10], ebx
cmp ecx, 0x40
mov dword [esp + 0x14], ebx
jb 0x48a2b7
push ebp
push str.R_CreateImage:___s__is_too_long_n
push 1
call dword [0x1313c44]
add esp, 0xc
push 9
push 0x558d00
push ebp
call fcn.0051bf40
add esp, 0xc
test eax, eax
jne 0x48a2d3
mov dword [esp + 0x10], 1
push 0xa
push str.lightmapD
push ebp
call fcn.0051bf40
add esp, 0xc
test eax, eax
jne 0x48a2ef
mov dword [esp + 0x14], 1
mov ecx, dword [0x132d214]
cmp ebx, ecx
jge 0x48a30f
mov eax, 0x132d218
cmp byte [eax], 0
je 0x48a30d
inc ebx
add eax, 0x84
cmp ebx, ecx
jl 0x48a2fe
cmp ebx, ecx
jne 0x48a332
cmp ecx, 0x600
jne 0x48a32b
push str.R_CreateImage:_MAX_DRAWIMAGES_hit_n
push 1
call dword [0x1313c44]
add esp, 8
jmp 0x48a332
inc ecx
mov dword [0x132d214], ecx
mov eax, ebx
mov ecx, dword [esp + 0x2c]
shl eax, 5
mov edx, dword [esp + 0x14]
add eax, ebx
mov esi, dword [esp + 0x34]
lea edi, [eax*4 + 0x132d218]
mov eax, dword [esp + 0x38]
mov dword [edi + 0x64], ecx
mov cx, word [esp + 0x44]
mov dword [edi + 0x70], eax
mov dword [edi + 0x68], edx
mov dx, word [esp + 0x48]
mov word [edi + 0x74], cx
mov ecx, dword [esp + 0x1c]
mov eax, ebp
mov ebp, edi
mov dword [edi + 0x6c], esi
mov word [edi + 0x76], dx
mov dword [edi + 0x7c], 0
sub ebp, ecx
mov cl, byte [eax]
mov byte [eax + ebp], cl
inc eax
test cl, cl
jne 0x48a37f
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x28]
mov dword [edi + 0x40], eax
mov eax, dword [0x13e6bf8]
add ebx, 0x400
mov dword [edi + 0x44], ecx
test eax, eax
mov dword [edi + 0x50], ebx
je 0x48a3ba
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x48a3ba
mov dword [edi + 0x60], 1
jmp 0x48a3c1
mov dword [edi + 0x60], 0
test eax, eax
je 0x48a3d1
mov edx, dword [edi + 0x60]
push edx
call fcn.00498890
add esp, 4
push edi
call fcn.00498810
mov eax, dword [esp + 0x44]
add esp, 4
test eax, eax
je 0x48a601
mov eax, dword [edi + 0x64]
mov ebp, dword [edi + 0x44]
mov ebx, dword [edi + 0x40]
xor ecx, ecx
test esi, esi
mov dword [esp + 0x3c], eax
je 0x48a411
mov ecx, dword [0x13e4238]
mov ecx, dword [ecx + 0x20]
test ecx, ecx
jle 0x48a411
mov eax, dword [esp + 0x30]
cmp ecx, eax
jl 0x48a411
lea ecx, [eax - 1]
test ecx, ecx
mov eax, ebx
mov edx, ebp
je 0x48a41d
sar eax, cl
sar edx, cl
mov esi, dword [0x13e6ae0]
cmp eax, esi
jg 0x48a42b
cmp edx, esi
jle 0x48a432
sar eax, 1
sar edx, 1
inc ecx
jmp 0x48a423
test ecx, ecx
jle 0x48a449
mov esi, dword [esp + 0x30]
cmp ecx, esi
jl 0x48a449
lea ecx, [esi - 1]
mov eax, ebx
mov edx, ebp
sar eax, cl
sar edx, cl
mov dword [edi + 0x48], eax
mov eax, dword [esp + 0x40]
cmp eax, 0x83f1
mov dword [edi + 0x4c], edx
mov dword [edi + 0x5c], eax
je 0x48a46c
cmp eax, 0x83f0
mov dword [esp + 0x2c], 0x10
jne 0x48a474
mov dword [esp + 0x2c], 8
mov edx, dword [esp + 0x20]
mov dword [esp + 0x20], 0
test ecx, ecx
mov dword [esp + 0x38], edx
jle 0x48a4e1
mov dword [esp + 0x34], ecx
mov dword [esp + 0x20], ecx
lea eax, [ebx + 3]
cdq
and edx, 3
add eax, edx
mov esi, eax
sar esi, 2
cmp esi, 1
jle 0x48a4c0
lea eax, [ebp + 3]
cdq
and edx, 3
add eax, edx
sar eax, 2
cmp eax, 1
jle 0x48a4c0
imul eax, esi
imul eax, dword [esp + 0x2c]
add dword [esp + 0x38], eax
sar ebx, 1
sar ebp, 1
test ebx, ebx
jne 0x48a4cd
mov ebx, 1
test ebp, ebp
jne 0x48a4d6
mov ebp, 1
mov eax, dword [esp + 0x34]
dec eax
mov dword [esp + 0x34], eax
jne 0x48a490
mov eax, dword [esp + 0x20]
mov dword [edi + 0x58], 0
sub eax, ecx
test ebx, ebx
mov dword [esp + 0x34], eax
jne 0x48a503
test ebp, ebp
je 0x48a5a3
mov ebx, 1
test ebp, ebp
jne 0x48a50c
mov ebp, 1
lea eax, [ebp + 3]
cdq
and edx, 3
add eax, edx
mov ecx, eax
lea eax, [ebx + 3]
cdq
and edx, 3
sar ecx, 2
add eax, edx
mov esi, ecx
sar eax, 2
imul esi, eax
imul esi, dword [esp + 0x2c]
cmp eax, 1
mov dword [esp + 0x28], ecx
mov dword [esp + 0x24], eax
jle 0x48a545
cmp ecx, 1
jle 0x48a545
add dword [edi + 0x58], esi
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x34]
push eax
push esi
push 0
push ebp
push ebx
push ecx
push edx
push 0xde1
call dword [0x13e6b58]
call fcn.0048c9f0
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x30]
cmp eax, ecx
jge 0x48a58c
mov ecx, dword [esp + 0x24]
mov eax, 1
cmp ecx, eax
jle 0x48a58c
cmp dword [esp + 0x28], eax
jle 0x48a58c
add dword [esp + 0x38], esi
mov ecx, dword [esp + 0x20]
mov eax, dword [esp + 0x34]
sar ebx, 1
sar ebp, 1
inc ecx
inc eax
mov dword [esp + 0x20], ecx
jmp 0x48a4ee
cmp dword [esp + 0x3c], 1
jle 0x48a5d0
fild dword [0x558994]
push ecx
fstp dword [esp]
push 0x2801
push 0xde1
call dword [0x13e3efc]
fild dword [0x558998]
push ecx
fstp dword [esp]
jmp 0x48a5ea
push 0x46180400
push 0x2801
push 0xde1
call dword [0x13e3efc]
push 0x46180400
push 0x2800
push 0xde1
call dword [0x13e3efc]
call fcn.0048c9f0
jmp 0x48a63e
mov ecx, dword [esp + 0x10]
lea edx, [edi + 0x58]
push ecx
lea eax, [edi + 0x4c]
push edx
lea ecx, [edi + 0x48]
push eax
mov eax, dword [esp + 0x48]
lea edx, [edi + 0x5c]
push ecx
mov ecx, dword [esp + 0x48]
push edx
mov edx, dword [edi + 0x68]
push eax
mov eax, dword [edi + 0x64]
push ecx
mov ecx, dword [edi + 0x44]
push edx
mov edx, dword [edi + 0x40]
push esi
push eax
mov eax, dword [esp + 0x48]
push ecx
push edx
push eax
call fcn.0048a700
add esp, 0x34
fild dword [esp + 0x44]
push ecx
fstp dword [esp]
push 0x2802
push 0xde1
call dword [0x13e3efc]
fild dword [esp + 0x48]
push ecx
fstp dword [esp]
push 0x2803
push 0xde1
call dword [0x13e3efc]
push 0
push 0xde1
call dword [0x13e3ea4]
mov eax, dword [edi + 0x60]
cmp eax, 1
mov dword [eax*4 + 0x13e6ce0], 0xffffffff
jne 0x48a698
push 0
call fcn.00498890
add esp, 4
mov esi, dword [esp + 0x1c]
xor ebx, ebx
cmp byte [esi], 0
je 0x48a6d3
mov ebp, 0x77
sub ebp, esi
movsx ecx, byte [esi]
push ecx
call fcn.0051bd27
add esp, 4
cmp al, 0x2e
je 0x48a6d3
cmp al, 0x5c
jne 0x48a6c0
mov al, 0x2f
movsx eax, al
lea edx, [esi + ebp]
imul edx, eax
mov al, byte [esi + 1]
add ebx, edx
inc esi
test al, al
jne 0x48a6aa
mov edx, dword [0x559000]
and ebx, 0x3ff
mov dword [edi + 0x78], edx
mov eax, edi
mov ecx, dword [ebx*4 + 0x7fee60]
mov dword [ebx*4 + 0x7fee60], edi
mov dword [edi + 0x80], ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret