I've extracted from the game Dragons Crown, the .CPK file, inside of this archive was a lot of different folders for characters, environments etc, however 3 specific formats popped up commonly:
- .bsb
.ftx
.mbs
.mcb
I'm not sure what the other files contain however, but its all in the graphics/stages folder, so it should be graphics I imagine.
I've uploaded the files to dropbox here: https://www.dropbox.com/sh/azf19y7homu8qnj/u-JOQibN1q
The Noesis script is here:
Code: Select all
from inc_noesis import *
def registerNoesisTypes():
handle = noesis.register("FTX Texture Bundle", ".ftx")
noesis.setHandlerTypeCheck(handle, ftxCheckType)
noesis.setHandlerLoadModel(handle, ftxLoad)
return 1
class FtxFile:
def __init__(self, bs):
self.bs = bs
def loadImageInfo(self):
if self.bs.dataSize < 32:
return 0
self.texInfos = []
hdrInfo = noeUnpack("<iiii", self.bs.readBytes(32)[:16])
if hdrInfo[0] != 0x58455446 or hdrInfo[3] <= 0 or 32+hdrInfo[3]*48+32+4 >= self.bs.dataSize:
return 0
for i in range(0, hdrInfo[3]):
self.texInfos.append( (noeStrFromBytes(self.bs.readBytes(32)), self.bs.readBytes(16)) )
self.bs.seek(32, NOESEEK_REL)
return 1
def loadImages(self, texList = []):
for texInfo in self.texInfos:
texHdr = noeUnpack("<iii", self.bs.readBytes(12))
self.bs.seek(texHdr[2]-12, NOESEEK_REL)
tex = rapi.loadTexByHandler(self.bs.readBytes(texHdr[1]), ".gim")
tex.name = texInfo[0]
texList.append(tex)
return texList
def ftxCheckType(data):
ftx = FtxFile(NoeBitStream(data))
if ftx.loadImageInfo() == 0:
return 0
return 1
def ftxLoad(data, mdlList):
ftx = FtxFile(NoeBitStream(data))
if ftx.loadImageInfo() == 0:
return 0
mdlList.append(NoeModel([], [], [], NoeModelMaterials(ftx.loadImages(), [])))
return 1
Thankyou