Once you installed it, you can extract the package files (.cpk) files easy, using my extraction tool, found here : viewtopic.php?f=21&t=13359&hilit=blood+bowl+II
the static 3D models have the cef extension and here is a max script to import them
be aware, this is just early testing so it will not work for all the models, only thing it support atm is vertices and indices, no uv mapping yet
also I enlarged the model for max purposes, else all models look very tiny
here is the script ( for now)
Code: Select all
ClearListener()
fn SkipBytes stream nBytesToSkip =
(
fseek stream nBytesToSkip #seek_cur
)
fn ReadStringZeroEnded stream =
(
local b = ReadByte stream
local s = bit.IntAsChar(b)
local str = s
while (b != 0x0 ) do
(
b = ReadByte stream
s = bit.IntAsChar(b)
if ( b !=0x0) then str+=s
)
return str
)
file = @"D:\Games\Blood Bowl 2\Extracted\ExtractedModels\ball_0.cef"
bin = fOpen file "rb"
fseek bin 95 #seek_set
modelName = ReadStringZeroEnded bin
SkipBytes bin 120
position = ReadStringZeroEnded bin
SkipBytes bin 35
nVertSize = ReadLong bin
SkipBytes bin 10
nVertexSets = ReadLong bin
nVertices = nVertSize / 16
verts =#()
for v = 1 to nVertices do
(
x = readFloat bin
y = readFloat bin
z = readFloat bin
scaling = 30
append verts [x * scaling,y * scaling,z * scaling]
SkipBytes bin 4
)
ftell bin
SkipBytes bin 24 -- PAK
SkipBytes bin 44 -- NORMAL
SkipBytes bin 44 -- TANGENT
SkipBytes bin 44 -- TEXCOORD
ftell bin
nTexSize = ReadLong bin
print nTexSize
SkipBytes bin 10
SkipBytes bin nTexSize --> TO DO
SkipBytes bin 28
ftell bin
indice = ReadStringZeroEnded bin
SkipBytes bin 37
nIndexSize = ReadLong bin
SkipBytes bin 10
nIndexSets = ReadLong bin
nIndices = nIndexSize / 6
tris = #()
for t = 1 to nIndices do
(
a = readShort bin
b = readShort bin
c = readShort bin
append tris [ a + 1, b + 1, c + 1]
)
theMesh = mesh name:modelName vertices:verts faces:tris
fClose bin