Adding Eras to shipped maps

Post everything from general questions, to modding questions, to map WIPs to releases. (SWBF1 only)

Moderator: Moderators

Post Reply
Ty294
Sergeant Major
Sergeant Major
Posts: 247
Joined: Thu Mar 12, 2009 10:28 pm
Projects :: Various
Location: Minnesota

Adding Eras to shipped maps

Post by Ty294 »

Okay guys, I'm pretty sure it's been done before, but I'm not sure how, and I thought I heard it had something to do with "Mission.lua", which I don't have a clue where that is. But anyway, how would you add the eras to shipped maps that normally only have one era? AKA: Adding GCW to Kamino or CW to Hoth.

Okay, I said that really stupidly, but I hope you guys get my point.
User avatar
giftheck
Droid Pilot Assassin
Droid Pilot Assassin
Posts: 2218
Joined: Mon Jan 19, 2009 5:58 pm
Projects :: Star Wars Battlefront Anniversary

Re: Adding Eras to shipped maps

Post by giftheck »

Here's the code you can use in addme.lua to enable those eras (needs to be copied entirely, I think - haven't yet implemented it into my mod):
Hidden/Spoiler:
-- List of missions presented to the user for IA/MP/splitscreen/etc.
-- This list is kept in alphabetical order (in English, anyhow).
--
-- Each entry should be in the following form:
-- { -- starts a table entry
-- mapluafile = "END1", -- base name of map, w/o attacking side, no ".lua" either
-- showstr = "planets.endor.name1", -- localization key in DB of item to show
-- side_a = 1, -- [OPTIONAL] Put this in the table if there is a "a" version of the map
-- side_c = 1, -- [OPTIONAL] Put this in the table if there is a "c" version of the map
-- side_i = 1, -- [OPTIONAL] Put this in the table if there is a "i" version of the map
-- side_r = 1, -- [OPTIONAL] Put this in the table if there is a "r" version of the map
-- side_a_team1 = "common.sides.all.name" -- [OPTIONAL] -- localized name of team1 in an 'a' version of this map
-- side_a_team2 = "common.sides.imp.name" -- [OPTIONAL] -- localized name of team2 in an 'a' version of this map
-- -- Note, there's also OPTIONAL side_c_team1, side_i_team1, side_r_team1,
-- -- side_c_team2, side_i_team2, side_r_team2 fields.
--
-- }, -- ends a table entry
--
-- Below, things are in one-entry-per-line format to make it easier to
-- comment in/out maps by commenting in/out a single line

sp_missionselect_listbox_contents = {
{ mapluafile = "BES1", showstr = "planets.bespin.mapname1", side_r = 1, side_a = 1},
{ mapluafile = "BES2", showstr = "planets.bespin.mapname2", side_r = 1, side_a = 1},

{ mapluafile = "END1", showstr = "planets.endor.mapname1", side_a = 1, side_c = 1,},

{ mapluafile = "GEO1", showstr = "planets.geonosis.mapname1", side_i = 1, side_r = 1},

{ mapluafile = "HOT1", showstr = "planets.hoth.mapname1", side_r = 1, side_i = 1,},

{ mapluafile = "KAM1", showstr = "planets.kamino.mapname1", side_c = 1, side_a = 1,},

{ mapluafile = "KAS1", showstr = "planets.kashyyyk.mapname1", side_c = 1, side_i = 1},
{ mapluafile = "KAS2", showstr = "planets.kashyyyk.mapname2", side_c = 1, side_i = 1},

{ mapluafile = "NAB1", showstr = "planets.naboo.mapname1", side_c = 1, side_i = 1},
{ mapluafile = "NAB2", showstr = "planets.naboo.mapname2", side_c = 1, side_a = 1},

{ mapluafile = "RHN1", showstr = "planets.rhenvar.mapname1", side_r = 1, side_i = 1},
{ mapluafile = "RHN2", showstr = "planets.rhenvar.mapname2", side_c = 1, side_a = 1},

{ mapluafile = "TAT1", showstr = "planets.tatooine.mapname1", side_r = 1, side_i = 1},
{ mapluafile = "TAT2", showstr = "planets.tatooine.mapname2", side_r = 1, side_i = 1},

{ mapluafile = "YAV1", showstr = "planets.yavin.mapname1", side_c = 1, side_i = 1},
{ mapluafile = "YAV2", showstr = "planets.yavin.mapname2", side_r = 1, side_i = 1},

}

mp_missionselect_listbox_contents = {
{ mapluafile = "BES1", showstr = "planets.bespin.mapname1", side_r = 1, side_a = 1},
{ mapluafile = "BES2", showstr = "planets.bespin.mapname2", side_r = 1, side_a = 1},

{ mapluafile = "END1", showstr = "planets.endor.mapname1", side_a = 1, side_c = 1,},

{ mapluafile = "GEO1", showstr = "planets.geonosis.mapname1", side_i = 1, side_r = 1},

{ mapluafile = "HOT1", showstr = "planets.hoth.mapname1", side_r = 1, side_i = 1,},

{ mapluafile = "KAM1", showstr = "planets.kamino.mapname1", side_c = 1, side_a = 1,},

{ mapluafile = "KAS1", showstr = "planets.kashyyyk.mapname1", side_c = 1, side_i = 1},
{ mapluafile = "KAS2", showstr = "planets.kashyyyk.mapname2", side_c = 1, side_i = 1},

{ mapluafile = "NAB1", showstr = "planets.naboo.mapname1", side_c = 1, side_i = 1},
{ mapluafile = "NAB2", showstr = "planets.naboo.mapname2", side_c = 1, side_a = 1},

{ mapluafile = "RHN1", showstr = "planets.rhenvar.mapname1", side_r = 1, side_i = 1},
{ mapluafile = "RHN2", showstr = "planets.rhenvar.mapname2", side_c = 1, side_a = 1},

{ mapluafile = "TAT1", showstr = "planets.tatooine.mapname1", side_r = 1, side_i = 1},
{ mapluafile = "TAT2", showstr = "planets.tatooine.mapname2", side_r = 1, side_i = 1},

{ mapluafile = "YAV1", showstr = "planets.yavin.mapname1", side_c = 1, side_i = 1},
{ mapluafile = "YAV2", showstr = "planets.yavin.mapname2", side_r = 1, side_i = 1},
}

-- List of maps usable in attract mode. These should be the raw lua
-- filenames (without ".lua"), and one per line, so we can turn them
-- on/off easily. Historical missions could go in here if desired.
attract_mode_maps = {
"bes1a",
"bes1r",
"bes2a",
"bes2r",
"end1a",
"end1c",
"geo1i",
"geo1r",
"hot1i",
"hot1r",
"kam1a",
"kam1c",
"kas1c",
"kas1i",
"kas2c",
"kas2i",
"nab1c",
"nab1i",
"nab2a",
"nab2c",
"rhn1i",
"rhn1r",
"tat1i",
"tat1r",
"tat2i",
"tat2r",
"yav1c",
"yav1i",
"yav2i",
"yav2r",

-- Historical maps, off by default
"nab1c_h",
"nab2c_h",
"kas1c_h",
"geo1r_h",
"kam1c_h",
"rhn1r_h",
"kas2c_h",
"tat1i_h",
"tat2i_h",
"rhn2a_h",
"yav2i_h",
"yav1i_h",
"hot1i_h",
"bes2a_h",
"bes1a_h",
"end1a_h",
}


-- Singleplayer campaigns. Each of these tables has a set of
-- sub-tables, one sub-table per mission. These are run through in
-- order. Note: there is a max of 255 missions in a campaign. Todo:
-- add in listings for VOs, backgrounds, etc.
--
-- Optional params per line:
-- side = 2, -- forces the user to team 2 (defender). If omitted, team 1 (attacker) is forced
-- intromovie = "", --movie played before yoda
-- outtromovie = "", --movie played after yoda, before mission
-- exitmovie = "", --movie played after mission is done (and you win)
-- [More will be coming, which refer to text to print, voiceover, etc.]

SPCampaign_CW = {
--Player is CIS
{
mapluafile = "nab1c_h",
side = 1,
showstr = "ifs.sp.cw.map1name",
description = "ifs.sp.cw.map1descr",
movie = "nab1fly",
voiceover = "cis_missionbriefing_nab1",
intromovie = "nab1h01",
outtromovie = "tutorial01cw",
outtromovie_left = 90,
outtromovie_top = 60,
outtromovie_width = 460,
outtromovie_height = 350,
outtromovielocalized = 1,
briefingmusic = "shell_droidinvasion",
iconmodel = "com_icon_CIS"
}, --Player is CIS
{
mapluafile = "nab2c_h",
side = 1,
showstr = "ifs.sp.cw.map2name",
description = "ifs.sp.cw.map2descr",
movie = "nab2fly",
voiceover = "cis_missionbriefing_nab2",
outtromovie = "nab2h01",
briefingmusic = "shell_droidinvasion",
unlockable = 1,
iconmodel = "com_icon_CIS"
}, --Player is CIS
{
mapluafile = "kas1c_h",
side = 1,
showstr = "ifs.sp.cw.map3name",
description = "ifs.sp.cw.map3descr",
movie = "kas1fly",
voiceover = "cis_missionbriefing_kas1",
briefingmusic = "shell_droidinvasion",
unlockable = 2,
iconmodel = "com_icon_CIS"
},

--Player is Republic
{
mapluafile = "geo1r_h",
side = 1,
showstr = "ifs.sp.cw.map4name",
description = "ifs.sp.cw.map4descr",
movie = "geo1fly",
outtromovie = "geo1h01",
voiceover = "rep_missionbriefing_geo1",
briefingmusic = "shell_clonewars",
unlockable = 3,
iconmodel = "com_icon_republic"
},

--Player is Republic
{
mapluafile = "kam1c_h",
side = 2,
showstr = "ifs.sp.cw.map5name",
description = "ifs.sp.cw.map5descr",
movie = "kam1fly",
intromovie = "kam1h01",
outtromovie = "kam1h02",
voiceover = "rep_missionbriefing_kam1",
briefingmusic = "shell_clonewars",
unlockable = 4,
iconmodel = "com_icon_republic"
},--Player is Republic
{
mapluafile = "rhn1r_h",
side = 1,
showstr = "ifs.sp.cw.map6name",
description = "ifs.sp.cw.map6descr",
movie = "rhn1fly",
voiceover = "rep_missionbriefing_rhn1",
briefingmusic = "shell_clonewars",
unlockable = 5,
iconmodel = "com_icon_republic"
},--Player is Republic
{
mapluafile = "kas2c_h",
side = 2,
showstr = "ifs.sp.cw.map7name",
description = "ifs.sp.cw.map7descr", side = 2,
movie = "kas2fly",
voiceover = "rep_missionbriefing_kas1",
briefingmusic = "shell_clonewars",
exitmovie = "kas2h01",
iconmodel = "com_icon_republic"
},--Player is Republic
}

SPCampaign_GCW = {
--Player is the Empire
{
mapluafile = "tat1i_h",
side = 1,
showstr = "ifs.sp.gcw.map1name",
description = "ifs.sp.gcw.map1descr",
movie = "tat1fly",
intromovie = "tat1h01",
outtromovie = "tutorial01gcw",
outtromovie_left = 90,
outtromovie_top = 60,
outtromovie_width = 460,
outtromovie_height = 350,
outtromovielocalized = 1,
voiceover = "imp_missionbriefing_tat1",
briefingmusic = "shell_imperialmarch",
iconmodel = "com_icon_imperial"
},--Player is the Empire
{
mapluafile = "tat2i_h",
side = 1,
showstr = "ifs.sp.gcw.map2name",
description = "ifs.sp.gcw.map2descr",
movie = "tat2fly",
intromovie = "tat2h01",
voiceover = "imp_missionbriefing_tat2",
briefingmusic = "shell_imperialmarch",
unlockable = 6,
iconmodel = "com_icon_imperial"
},--Player is the Empire
{
mapluafile = "rhn2a_h",
side = 2,
showstr = "ifs.sp.gcw.map3name",
description = "ifs.sp.gcw.map3descr",
movie = "rhn2fly",
voiceover = "imp_missionbriefing_rhn1",
briefingmusic = "shell_imperialmarch",
iconmodel = "com_icon_imperial"
},--Player is the Empire
{
mapluafile = "yav2i_h",
side = 1,
showstr = "ifs.sp.gcw.map4name",
description = "ifs.sp.gcw.map4descr",
movie = "yav2fly",
intromovie = "yav2h01",
voiceover = "imp_missionbriefing_yav1",
briefingmusic = "shell_imperialmarch",
iconmodel = "com_icon_imperial"
},--Player is the Alliance
{
mapluafile = "yav1i_h",
side = 2,
showstr = "ifs.sp.gcw.map5name",
description = "ifs.sp.gcw.map5descr",
movie = "yav1fly",
intromovie = "yav1h01",
voiceover = "all_missionbriefing_yav1",
briefingmusic = "shell_clash",
unlockable = 7,
iconmodel = "com_icon_alliance"
},--Player is the Alliance

--Player is the Alliance
{
mapluafile = "hot1i_h",
side = 2,
showstr = "ifs.sp.gcw.map6name",
description = "ifs.sp.gcw.map6descr", side = 2,
movie = "hot1fly",
outtromovie = "hot1h02",
voiceover = "all_missionbriefing_hot1",
briefingmusic = "shell_clash",
unlockable = 8,
iconmodel = "com_icon_alliance"
},--Player is the Alliance
{
mapluafile = "bes2a_h",
side = 1,
showstr = "ifs.sp.gcw.map7name",
description = "ifs.sp.gcw.map7descr",
movie = "bes2fly",
intromovie = "bes2h01",
voiceover = "all_missionbriefing_bes1",
briefingmusic = "shell_clash",
unlockable = 9,
iconmodel = "com_icon_alliance"
},--Player is the Alliance
{
mapluafile = "bes1a_h",
side = 1,
showstr = "ifs.sp.gcw.map8name",
description = "ifs.sp.gcw.map8descr",
movie = "bes1fly",
outtromovie = "bes1h01",
voiceover = "all_missionbriefing_bes2",
briefingmusic = "shell_clash",
unlockable = 10,
iconmodel = "com_icon_alliance"
},--Player is the Alliance
{
mapluafile = "end1a_h",
side = 1,
showstr = "ifs.sp.gcw.map9name",
description = "ifs.sp.gcw.map9descr",
movie = "end1fly",
outtromovie = "end1h02",
exitmovie = "end1h03",
voiceover = "all_missionbriefing_end1",
briefingmusic = "shell_clash",
iconmodel = "com_icon_alliance"
},--Player is the Alliance
}
I've already added in the neccesary stuff to this script add CW Endor/Hoth and GCW Geonosis/Kamino. I'll leave mission.lua and map to you.
Ty294
Sergeant Major
Sergeant Major
Posts: 247
Joined: Thu Mar 12, 2009 10:28 pm
Projects :: Various
Location: Minnesota

Re: Adding Eras to shipped maps

Post by Ty294 »

The bigger question is, where the heck is the Addme.lua and how would I get the edited one in-game?

And just to clarify, that text you posted overwrites the existing content of the Addme.lua?
User avatar
jdee/barc
1st Lieutenant
1st Lieutenant
Posts: 444
Joined: Wed Aug 25, 2010 2:47 pm
Projects :: Battlefront One and a Half
xbox live or psn: No gamertag set
Location: Boston

Re: Adding Eras to shipped maps

Post by jdee/barc »

to get an addme lua go to bf builder (perferably pro update or bamdur's 2.0 pro edit) and create an addonmap. then go to Data(modname) and open the folder addme. the script should be there. now do what ggctuk said.
Ty294
Sergeant Major
Sergeant Major
Posts: 247
Joined: Thu Mar 12, 2009 10:28 pm
Projects :: Various
Location: Minnesota

Re: Adding Eras to shipped maps

Post by Ty294 »

Okay, found it, copied over the existing content (right? or was it supposed to go alongside the existing content?). Now what? Do I munge the map and find a .lvl file or something?

I should note my current mod is in the final stages, but I wanted to add the GCW to Kamino, so that's why I brought it up.
User avatar
giftheck
Droid Pilot Assassin
Droid Pilot Assassin
Posts: 2218
Joined: Mon Jan 19, 2009 5:58 pm
Projects :: Star Wars Battlefront Anniversary

Re: Adding Eras to shipped maps

Post by giftheck »

Ty294 wrote:Okay, found it, copied over the existing content (right? or was it supposed to go alongside the existing content?). Now what? Do I munge the map and find a .lvl file or something?

I should note my current mod is in the final stages, but I wanted to add the GCW to Kamino, so that's why I brought it up.
Yes, it needs to be compiled and then added to Addon. It overrides the game's native mission list, hence why you need the whole thing.
Ty294
Sergeant Major
Sergeant Major
Posts: 247
Joined: Thu Mar 12, 2009 10:28 pm
Projects :: Various
Location: Minnesota

Re: Adding Eras to shipped maps

Post by Ty294 »

Okay, well I guess that means I gotta back a map. :runaway:

Thanks fellas!
User avatar
jdee/barc
1st Lieutenant
1st Lieutenant
Posts: 444
Joined: Wed Aug 25, 2010 2:47 pm
Projects :: Battlefront One and a Half
xbox live or psn: No gamertag set
Location: Boston

Re: Adding Eras to shipped maps

Post by jdee/barc »

ggctuk wrote: It overrides the game's native mission list, hence why you need the whole thing.
correction: you don't need the whole thing, unless you want to edit campaign. you only need the beginning, to the end before the camapgin info starts. thats how i've always done it.
Post Reply