From 48a0d13926fce5a8f6a313456b1249a9f48023bd Mon Sep 17 00:00:00 2001 From: Marcus Huderle Date: Tue, 8 Jan 2019 08:59:43 -0600 Subject: [PATCH] Only create new map text.inc file in pokeruby projects --- src/project.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/project.cpp b/src/project.cpp index 1bfe30d4..047fe54e 100644 --- a/src/project.cpp +++ b/src/project.cpp @@ -865,12 +865,16 @@ void Project::saveMap(Map *map) { QString text = QString("%1_MapScripts::\n\t.byte 0\n").arg(map->name); saveTextFile(root + "/data/maps/" + map->name + "/scripts.inc", text); - // Create file data/maps//text.inc - saveTextFile(root + "/data/maps/" + map->name + "/text.inc", "\n"); + if (projectConfig.getBaseGameVersion() == BaseGameVersion::pokeruby) { + // Create file data/maps//text.inc + saveTextFile(root + "/data/maps/" + map->name + "/text.inc", "\n"); + } // Simply append to data/event_scripts.s. text = QString("\n\t.include \"data/maps/%1/scripts.inc\"\n").arg(map->name); - text += QString("\t.include \"data/maps/%1/text.inc\"\n").arg(map->name); + if (projectConfig.getBaseGameVersion() == BaseGameVersion::pokeruby) { + text += QString("\t.include \"data/maps/%1/text.inc\"\n").arg(map->name); + } appendTextFile(root + "/data/event_scripts.s", text); // Simply append to data/map_events.s.