Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
manavortex committed May 26, 2024
2 parents 3173b9b + c2dee3d commit 479e680
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions Scripts/Export_Ent.wscript
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ function convertEmbedded(embeddedFile) {
let jsonString = TypeHelper.JsonStringify(data);

let cr2w = wkit.JsonToCR2W(jsonString);
wkit.SaveToProject(embeddedFile["FileName"], cr2w);
wkit.SaveToProject(embeddedFile["FileName"].value, cr2w);
}

// Parse a CR2W file
Expand All @@ -125,7 +125,7 @@ function ParseFile(fileName, parentFile) {
if (extension !== 'unknown') {
if (parentFile != null && parentFile["Data"]["EmbeddedFiles"].length > 0) {
for (let embeddedFile of parentFile["Data"]["EmbeddedFiles"]) {
if (embeddedFile["FileName"] === fileName) {
if (embeddedFile["FileName"].value === fileName) {
convertEmbedded(embeddedFile);

if (jsonExtensions.includes(extension)) {
Expand Down
4 changes: 2 additions & 2 deletions Scripts/Export_Ent_w_Rig.wscript
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ function convertEmbedded(embeddedFile) {
let jsonString = TypeHelper.JsonStringify(data);

let cr2w = wkit.JsonToCR2W(jsonString);
wkit.SaveToProject(embeddedFile["FileName"], cr2w);
wkit.SaveToProject(embeddedFile["FileName"].value, cr2w);
}

// Parse a CR2W file
Expand All @@ -191,7 +191,7 @@ function ParseFile(fileName, parentFile) {

if (parentFile != null && parentFile["Data"]["EmbeddedFiles"].length > 0) {
for (let embeddedFile of parentFile["Data"]["EmbeddedFiles"]) {
if (embeddedFile["FileName"] === fileName) {
if (embeddedFile["FileName"].value === fileName) {
convertEmbedded(embeddedFile);

if (jsonExtensions.includes(extension)) {
Expand Down
6 changes: 3 additions & 3 deletions Scripts/Export_Mesh.wscript
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ function convertEmbedded(embeddedFile) {
let jsonString = TypeHelper.JsonStringify(data);

let cr2w = wkit.JsonToCR2W(jsonString);
wkit.SaveToProject(embeddedFile["FileName"], cr2w);
wkit.SaveToProject(embeddedFile["FileName"].value, cr2w);
}

// Parse a CR2W file
Expand All @@ -113,7 +113,7 @@ function ParseFile(fileName, parentFile) {
if (extension !== 'unknown') {
const embeddedFiles = parentFile?.Data?.EmbeddedFiles || [];
for (let embeddedFile of embeddedFiles) {
if (embeddedFile["FileName"] === fileName) {
if (embeddedFile["FileName"].value === fileName) {
convertEmbedded(embeddedFile);

if (jsonExtensions.includes(extension)) {
Expand Down Expand Up @@ -174,4 +174,4 @@ function ParseFile(fileName, parentFile) {
}
}

//#endregion
//#endregion
4 changes: 2 additions & 2 deletions Scripts/Export_Vehicle_Ent.wscript
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ function convertEmbedded(embeddedFile) {
let jsonString = TypeHelper.JsonStringify(data);

let cr2w = wkit.JsonToCR2W(jsonString);
wkit.SaveToProject(embeddedFile["FileName"], cr2w);
wkit.SaveToProject(embeddedFile["FileName"].value, cr2w);
}

// Parse a CR2W file
Expand All @@ -152,7 +152,7 @@ function ParseFile(fileName, parentFile) {

if (parentFile != null && parentFile["Data"]["EmbeddedFiles"].length > 0) {
for (let embeddedFile of parentFile["Data"]["EmbeddedFiles"]) {
if (embeddedFile["FileName"] === fileName) {
if (embeddedFile["FileName"].value === fileName) {
convertEmbedded(embeddedFile);

if (jsonExtensions.includes(extension)) {
Expand Down

0 comments on commit 479e680

Please sign in to comment.