mirror of
https://github.com/open-goal/jak-project
synced 2026-07-07 06:05:15 -04:00
ckernel: fix file paths for art groups and tpages (#2932)
This commit is contained in:
@@ -92,12 +92,12 @@ char* MakeFileName(int type, const char* name, int new_string) {
|
||||
// GOAL object file, but containing data instead of code.
|
||||
// likely packed by a tool that isn't the GOAL compiler.
|
||||
// sprintf(buf, "%sdata/%s.go", prefix, name);
|
||||
sprintf(buf, "%sout/obj/%s.go", prefix, name);
|
||||
sprintf(buf, "%sout/jak1/obj/%s.go", prefix, name);
|
||||
} else if (type == TX_PAGE_FILE_TYPE) {
|
||||
// Texture Page
|
||||
// part of level files, so it has a version number.
|
||||
// sprintf(buf, "%sdata/texture-page%d/%s.go", prefix, TX_PAGE_VERSION, name);
|
||||
sprintf(buf, "%sout/obj/%s.go", prefix, name);
|
||||
sprintf(buf, "%sout/jak1/obj/%s.go", prefix, name);
|
||||
} else if (type == JA_FILE_TYPE) {
|
||||
// Art JA (joint animation? no idea)
|
||||
// part of level files, so it has a version number
|
||||
|
||||
@@ -96,12 +96,12 @@ char* MakeFileName(int type, const char* name, int new_string) {
|
||||
// GOAL object file, but containing data instead of code.
|
||||
// likely packed by a tool that isn't the GOAL compiler.
|
||||
// sprintf(buf, "%sfinal/%s.go", prefix, name);
|
||||
sprintf(buf, "%sout/obj/%s.go", prefix, name);
|
||||
sprintf(buf, "%sout/jak2/obj/%s.go", prefix, name);
|
||||
} else if (type == TX_PAGE_FILE_TYPE) {
|
||||
// Texture Page
|
||||
// part of level files, so it has a version number.
|
||||
// sprintf(buf, "%sdata/texture-page%d/%s.go", prefix, TX_PAGE_VERSION, name);
|
||||
sprintf(buf, "%sout/obj/%s.go", prefix, name);
|
||||
sprintf(buf, "%sout/jak2/obj/%s.go", prefix, name);
|
||||
} else if (type == JA_FILE_TYPE) {
|
||||
// Art JA (joint animation? no idea)
|
||||
// part of level files, so it has a version number
|
||||
|
||||
@@ -115,7 +115,7 @@ TEST(Kernel, basename) {
|
||||
TEST(Kernel, DecodeFileName) {
|
||||
std::string x;
|
||||
x = DecodeFileName("$TEXTURE/beans");
|
||||
EXPECT_EQ(x, "out/obj/beans.go");
|
||||
EXPECT_EQ(x, "out/jak1/obj/beans.go");
|
||||
|
||||
x = DecodeFileName("$ART_GROUP/stuff");
|
||||
EXPECT_EQ(x, "data/art-group6/stuff-ag.go");
|
||||
@@ -127,7 +127,7 @@ TEST(Kernel, DecodeFileName) {
|
||||
EXPECT_EQ(x, "data/level30/my-level.123");
|
||||
|
||||
x = DecodeFileName("$DATA/my-data");
|
||||
EXPECT_EQ(x, "out/obj/my-data.go");
|
||||
EXPECT_EQ(x, "out/jak1/obj/my-data.go");
|
||||
|
||||
x = DecodeFileName("$CODE/my-code");
|
||||
EXPECT_EQ(x, "game/obj/my-code.o");
|
||||
|
||||
Reference in New Issue
Block a user