mirror of https://github.com/AxioDL/metaforce.git
MP2/3 MREA extract fix
This commit is contained in:
parent
3d91bb4e6a
commit
b4a3d2b902
|
@ -7,6 +7,8 @@
|
||||||
|
|
||||||
namespace DataSpec
|
namespace DataSpec
|
||||||
{
|
{
|
||||||
|
extern hecl::Database::DataSpecEntry SpecEntMP2ORIG;
|
||||||
|
|
||||||
namespace DNAMP2
|
namespace DNAMP2
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -179,7 +181,9 @@ bool MREA::Extract(const SpecBase& dataSpec,
|
||||||
|
|
||||||
/* MREA decompression stream */
|
/* MREA decompression stream */
|
||||||
StreamReader drs(rs, head.compressedBlockCount);
|
StreamReader drs(rs, head.compressedBlockCount);
|
||||||
athena::io::FileWriter mreaDecompOut(pakRouter.getCooked(&entry).getWithExtension(_S(".decomp")).getAbsolutePath());
|
hecl::ProjectPath decompPath = outPath.getCookedPath(SpecEntMP2ORIG).getWithExtension(_S(".decomp"));
|
||||||
|
decompPath.makeDirChain(false);
|
||||||
|
athena::io::FileWriter mreaDecompOut(decompPath.getAbsolutePath());
|
||||||
head.write(mreaDecompOut);
|
head.write(mreaDecompOut);
|
||||||
mreaDecompOut.seekAlign32();
|
mreaDecompOut.seekAlign32();
|
||||||
drs.writeDecompInfos(mreaDecompOut);
|
drs.writeDecompInfos(mreaDecompOut);
|
||||||
|
|
|
@ -5,6 +5,8 @@
|
||||||
|
|
||||||
namespace DataSpec
|
namespace DataSpec
|
||||||
{
|
{
|
||||||
|
extern hecl::Database::DataSpecEntry SpecEntMP3ORIG;
|
||||||
|
|
||||||
namespace DNAMP3
|
namespace DNAMP3
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -88,7 +90,9 @@ bool MREA::Extract(const SpecBase& dataSpec,
|
||||||
|
|
||||||
/* MREA decompression stream */
|
/* MREA decompression stream */
|
||||||
StreamReader drs(rs, head.compressedBlockCount, head.secIndexCount);
|
StreamReader drs(rs, head.compressedBlockCount, head.secIndexCount);
|
||||||
athena::io::FileWriter mreaDecompOut(pakRouter.getCooked(&entry).getWithExtension(_S(".decomp")).getAbsolutePath());
|
hecl::ProjectPath decompPath = outPath.getCookedPath(SpecEntMP3ORIG).getWithExtension(_S(".decomp"));
|
||||||
|
decompPath.makeDirChain(false);
|
||||||
|
athena::io::FileWriter mreaDecompOut(decompPath.getAbsolutePath());
|
||||||
head.write(mreaDecompOut);
|
head.write(mreaDecompOut);
|
||||||
mreaDecompOut.seekAlign32();
|
mreaDecompOut.seekAlign32();
|
||||||
drs.writeDecompInfos(mreaDecompOut);
|
drs.writeDecompInfos(mreaDecompOut);
|
||||||
|
|
|
@ -13,7 +13,7 @@ CPreFrontEnd::CPreFrontEnd()
|
||||||
|
|
||||||
CIOWin::EMessageReturn CPreFrontEnd::OnMessage(const CArchitectureMessage&, CArchitectureQueue&)
|
CIOWin::EMessageReturn CPreFrontEnd::OnMessage(const CArchitectureMessage&, CArchitectureQueue&)
|
||||||
{
|
{
|
||||||
return EMessageReturn::Normal;
|
return EMessageReturn::Exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue