Page 1 of 2

How to replace sides?

Posted: Tue Oct 23, 2012 7:51 pm
by BobTheHunted
Ok, first off, I hope it's ok that I have been posting so many questions and stuff in this section. My question now is how do you replace stock sides? I have just been creating a sides mod and I decided to replace the CIS with Empire(imp). How does one go about doing this?

Re: How to replace sides?

Posted: Tue Oct 23, 2012 7:57 pm
by CreatorOfThings

Re: How to replace sides?

Posted: Tue Oct 23, 2012 11:36 pm
by BobTheHunted
CreatorOfThings wrote:Here's a good guide http://www.gametoast.com/forums/viewtop ... 27&t=12729 :)
that didn't work unfortunately

Re: How to replace sides?

Posted: Wed Oct 24, 2012 6:33 am
by CressAlbane
This would be a LUA change. Where the game loads the units for the CIS, just replace that with the section that loads the IMP units from a different LUA file.

Re: How to replace sides?

Posted: Wed Oct 24, 2012 7:50 pm
by BobTheHunted
CressAlbane wrote:This would be a LUA change. Where the game loads the units for the CIS, just replace that with the section that loads the IMP units from a different LUA file.
That didn't work but thanks anyways

Re: How to replace sides?

Posted: Wed Oct 24, 2012 8:18 pm
by CressAlbane
Really? I've done this before myself, and I can say with confidence that this method will work.

Make sure that you also change the part where units are assigned to teams (I had assumed you would do that.)

Re: How to replace sides?

Posted: Wed Oct 24, 2012 8:28 pm
by BobTheHunted
CressAlbane wrote:Really? I've done this before myself, and I can say with confidence that this method will work.

Make sure that you also change the part where units are assigned to teams (I had assumed you would do that.)
hmmm that's interesting... what lua files did you change? I replaced all of the units in the c_con file...

Re: How to replace sides?

Posted: Wed Oct 24, 2012 8:42 pm
by CressAlbane
Replace this:

Code: Select all

    ReadDataFile("SIDE\\cis.lvl",
                             "cis_inf_rifleman",
                             "cis_inf_rocketeer",
                             "cis_inf_engineer",
                             "cis_inf_sniper",
                             "cis_inf_officer",
                             "cis_inf_droideka",
                             "cis_hero_darthmaul",
                             "cis_hover_aat")
With this:

Code: Select all

    ReadDataFile("SIDE\\imp.lvl",
                    "imp_inf_rifleman",
                    "imp_inf_rocketeer",
                    "imp_inf_engineer",
                    "imp_inf_sniper",
                    "imp_inf_officer",
                    "imp_inf_dark_trooper",
                    "imp_hero_bobafett",
                    "imp_fly_destroyer_dome" )
Then replace this:

Code: Select all

soldier  = { "cis_inf_rifleman",9, 25},
			assault  = { "cis_inf_rocketeer",1, 4},
			engineer = { "cis_inf_engineer",1, 4},
			sniper   = { "cis_inf_sniper",1, 4},
			officer = {"cis_inf_officer",1, 4},
			special = { "cis_inf_droideka",1, 4},
With this:

Code: Select all

               soldier = { "imp_inf_rifleman",9, 25},
                        assault = { "imp_inf_rocketeer",4, 8},
                        engineer = { "imp_inf_engineer",4, 8},
                        sniper = { "imp_inf_sniper",4, 8},
                        officer = { "imp_inf_officer",4, 8},

Re: How to replace sides?

Posted: Wed Oct 24, 2012 9:08 pm
by BobTheHunted
CressAlbane wrote:Replace this:

Code: Select all

    ReadDataFile("SIDE\\cis.lvl",
                             "cis_inf_rifleman",
                             "cis_inf_rocketeer",
                             "cis_inf_engineer",
                             "cis_inf_sniper",
                             "cis_inf_officer",
                             "cis_inf_droideka",
                             "cis_hero_darthmaul",
                             "cis_hover_aat")
With this:

Code: Select all

    ReadDataFile("SIDE\\imp.lvl",
                    "imp_inf_rifleman",
                    "imp_inf_rocketeer",
                    "imp_inf_engineer",
                    "imp_inf_sniper",
                    "imp_inf_officer",
                    "imp_inf_dark_trooper",
                    "imp_hero_bobafett",
                    "imp_fly_destroyer_dome" )
Then replace this:

Code: Select all

soldier  = { "cis_inf_rifleman",9, 25},
			assault  = { "cis_inf_rocketeer",1, 4},
			engineer = { "cis_inf_engineer",1, 4},
			sniper   = { "cis_inf_sniper",1, 4},
			officer = {"cis_inf_officer",1, 4},
			special = { "cis_inf_droideka",1, 4},
With this:

Code: Select all

               soldier = { "imp_inf_rifleman",9, 25},
                        assault = { "imp_inf_rocketeer",4, 8},
                        engineer = { "imp_inf_engineer",4, 8},
                        sniper = { "imp_inf_sniper",4, 8},
                        officer = { "imp_inf_officer",4, 8},
it must not be munging correctly... I had some custom textures applied to cis and i got a clean version from the assets folder, and they still had the retextures in the game...

Re: How to replace sides?

Posted: Wed Oct 24, 2012 9:35 pm
by Cleb
Did you try a clean? Or a manual clean? That would help...

Re: How to replace sides?

Posted: Wed Oct 24, 2012 10:02 pm
by BobTheHunted
does the side replacement have to be on a custom map? or can I just copy the .lvl files so it applies to all maps?

Re: How to replace sides?

Posted: Wed Oct 24, 2012 10:12 pm
by Cleb
Not entirely sure, never tried something like that, my maybe guess would be that if your side had the same odf names as say, the republic side, (like one of your units odf names was rep_inf_ep3_trooper but had your odf) and you renamed your sides .lvl to rep.lvl, then replaced the rep side, it might work. Make sure you back up your side you're replacing and if it worked then that side would be replaced on all levels. Not sure you're even allowed to do that. :?

Error when replacing sides?

Posted: Sat Oct 27, 2012 6:37 pm
by BobTheHunted
Cleb wrote:Not entirely sure, never tried something like that, my maybe guess would be that if your side had the same odf names as say, the republic side, (like one of your units odf names was rep_inf_ep3_trooper but had your odf) and you renamed your sides .lvl to rep.lvl, then replaced the rep side, it might work. Make sure you back up your side you're replacing and if it worked then that side would be replaced on all levels. Not sure you're even allowed to do that. :?
um... what? that didn't make much sense but ill try and see what i get out of it...

EDIT
I replaced the CIS with the Empire on my map, but the empire has no sounds. How can I fix this? I have searched but found no solutions...

Re: How to replace sides?

Posted: Sat Oct 27, 2012 10:49 pm
by AQT
The CW era subsections of the stock sound .lvl files do not contain the sounds necessary for the Empire. To have sound for both the Republic and Empire at the same time, one option is to use the stock kam.lvl file with subsection kam1cross. From the stock Kamino campaign script:
kam1c_c wrote:

Code: Select all

    ReadDataFile("sound\\kam.lvl;kam1cross")

Re: How to replace sides?

Posted: Sun Oct 28, 2012 3:20 pm
by BobTheHunted
I have just started trying to make a clone vs clone map. I used the same process but renamed the folder and made a .lvl with the same name. It didn't work. How could I make a clone vs clone map where I can customize the units specific to each side?

I just got it to do clone vs clone but they have the same textures... any help?

EDIT
Cleb wrote:Not entirely sure, never tried something like that, my maybe guess would be that if your side had the same odf names as say, the republic side, (like one of your units odf names was rep_inf_ep3_trooper but had your odf) and you renamed your sides .lvl to rep.lvl, then replaced the rep side, it might work. Make sure you back up your side you're replacing and if it worked then that side would be replaced on all levels. Not sure you're even allowed to do that. :?
No one seems to want to reply to this topic anymore, but, is there a way to make it so there is custom units in the team setup thing? Like this
Hidden/Spoiler:
SetupTeams{
rep = {
team = REP,
units = 28,
reinforcements = 150,
soldier = { "dc:rep_inf_ep3_rifleman",9, 25},
assault = { "dc:rep_inf_ep3_rocketeer",1,4},
engineer = { "dc:rep_inf_ep3_engineer",1,4},
sniper = { "dc:rep_inf_ep3_sniper",1,4},
officer = {"dc:rep_inf_ep3_officer",1,4},
special = { "dc:rep_inf_ep3_jettrooper",1,4},
So it reads the individual textures and such? I'm trying to make a clone vs clone map, but no matter what I do, each side has the same clones, not ones with different textures that I made. I want to have textures specific to each side

Double posting is against the RULES; please EDIT your post instead -Staff

Re: How to replace sides?

Posted: Sun Oct 28, 2012 3:35 pm
by Cleb
If you want your custom side for one map, not all of the maps, see this topic:
http://www.gametoast.com/forums/viewtop ... 27&t=28535

Re: How to replace sides?

Posted: Sun Oct 28, 2012 3:50 pm
by BobTheHunted
Cleb wrote:If you want your custom side for one map, not all of the maps, see this topic:
http://www.gametoast.com/forums/viewtop ... 27&t=28535
Ok, maybe you didn't understand what I said. What I mean is, how do I have it take the units out of custom sides if the units have the exact same name, but are in different side folders? Heres my lua:
Hidden/Spoiler:
SetTeamAggressiveness(REP, 0.95)
SetTeamAggressiveness(CIS, 0.95)

SetMaxFlyHeight(40)
SetMaxPlayerFlyHeight(40)

ReadDataFile("sound\\tat.lvl;tat2cw")
ReadDataFile("dc:SIDE\\ret.lvl",
"rep_inf_ep3_rocketeer",
"rep_inf_ep3_rifleman",
"rep_inf_ep3_sniper",
"rep_inf_ep3_engineer",
"rep_inf_ep3_jettrooper",
"rep_inf_ep3_officer",
"rep_hero_obiwan")

ReadDataFile("dc:SIDE\\red.lvl",
"rep_inf_ep3_rocketeer",
"rep_inf_ep3_rifleman",
"rep_inf_ep3_sniper",
"rep_inf_ep3_engineer",
"rep_inf_ep3_jettrooper",
"rep_inf_ep3_officer",
"rep_hero_obiwan")

ReadDataFile("SIDE\\des.lvl",
"tat_inf_jawa")

ReadDataFile("SIDE\\tur.lvl",
"tur_bldg_tat_barge",
"tur_bldg_laser")

SetAttackingTeam(ATT)

SetupTeams{
rep = {
team = REP,
units = 28,
reinforcements = 150,
soldier = { "rep_inf_ep3_rifleman",9, 25},
assault = { "rep_inf_ep3_rocketeer",1,4},
engineer = { "rep_inf_ep3_engineer",1,4},
sniper = { "rep_inf_ep3_sniper",1,4},
officer = {"rep_inf_ep3_officer",1,4},
special = { "rep_inf_ep3_jettrooper",1,4},

},
cis = {
team = CIS,
units = 28,
reinforcements = 150,
soldier = { "rep_inf_ep3_rifleman",9, 25},
assault = { "rep_inf_ep3_rocketeer",1,4},
engineer = { "rep_inf_ep3_engineer",1,4},
sniper = { "rep_inf_ep3_sniper",1,4},
officer = {"rep_inf_ep3_officer",1,4},
special = { "rep_inf_ep3_jettrooper",1,4},
}
}
ret and red are both the same as republic except for the custom textures... each side has different textures, but ingame, they have the same textures...

Re: How to replace sides?

Posted: Sun Oct 28, 2012 4:08 pm
by Cleb
Ok now I get what you mean... One side has to have each unit have a different odf name because now the game doesn't know which side to load from. So you could do this:
Hidden/Spoiler:
SetTeamAggressiveness(REP, 0.95)
SetTeamAggressiveness(CIS, 0.95)

SetMaxFlyHeight(40)
SetMaxPlayerFlyHeight(40)

ReadDataFile("sound\\tat.lvl;tat2cw")
ReadDataFile("dc:SIDE\\ret.lvl",
"rep_inf_ep3_rocketeerr",
"rep_inf_ep3_riflemanr",
"rep_inf_ep3_sniperr",
"rep_inf_ep3_engineerr",
"rep_inf_ep3_jettrooperr",
"rep_inf_ep3_officerr",
"rep_hero_obiwanr")


ReadDataFile("dc:SIDE\\red.lvl",
"rep_inf_ep3_rocketeer",
"rep_inf_ep3_rifleman",
"rep_inf_ep3_sniper",
"rep_inf_ep3_engineer",
"rep_inf_ep3_jettrooper",
"rep_inf_ep3_officer",
"rep_hero_obiwan")

ReadDataFile("SIDE\\des.lvl",
"tat_inf_jawa")

ReadDataFile("SIDE\\tur.lvl",
"tur_bldg_tat_barge",
"tur_bldg_laser")

SetAttackingTeam(ATT)

SetupTeams{
rep = {
team = REP,
units = 28,
reinforcements = 150,
soldier = { "rep_inf_ep3_rifleman",9, 25},
assault = { "rep_inf_ep3_rocketeer",1,4},
engineer = { "rep_inf_ep3_engineer",1,4},
sniper = { "rep_inf_ep3_sniper",1,4},
officer = {"rep_inf_ep3_officer",1,4},
special = { "rep_inf_ep3_jettrooper",1,4},

},
cis = {
team = CIS,
units = 28,
reinforcements = 150,
soldier = { "rep_inf_ep3_riflemanr",9, 25},
assault = { "rep_inf_ep3_rocketeerr",1,4},
engineer = { "rep_inf_ep3_engineerr",1,4},
sniper = { "rep_inf_ep3_sniperr",1,4},
officer = {"rep_inf_ep3_officerr",1,4},
special = { "rep_inf_ep3_jettrooperr",1,4},

}
}
Just make sure you change the names of the files and their contents (so for req you would change the name and the contents to correspond with the new odf name) in the sides file that is changed (ret in this example)

Re: How to replace sides?

Posted: Sun Oct 28, 2012 4:47 pm
by BobTheHunted
Cleb wrote:Just make sure you change the names of the files and their contents (so for req you would change the name and the contents to correspond with the new odf name) in the sides file that is changed (ret in this example)
This is what happened when I did that
Hidden/Spoiler:
Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(829)
Unable to find level chunk rep_inf_ep3_rocketeerr in C:\Program Files (x86)\Star wars Battlefront II\GameData\AddOn\TA4\Data\_lvl_pc\SIDE\ret.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(829)
Unable to find level chunk rep_inf_ep3_riflemanr in C:\Program Files (x86)\Star wars Battlefront II\GameData\AddOn\TA4\Data\_lvl_pc\SIDE\ret.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(829)
Unable to find level chunk rep_inf_ep3_sniperr in C:\Program Files (x86)\Star wars Battlefront II\GameData\AddOn\TA4\Data\_lvl_pc\SIDE\ret.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(829)
Unable to find level chunk rep_inf_ep3_engineerr in C:\Program Files (x86)\Star wars Battlefront II\GameData\AddOn\TA4\Data\_lvl_pc\SIDE\ret.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(829)
Unable to find level chunk rep_inf_ep3_jettrooperr in C:\Program Files (x86)\Star wars Battlefront II\GameData\AddOn\TA4\Data\_lvl_pc\SIDE\ret.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(829)
Unable to find level chunk rep_inf_ep3_officerr in C:\Program Files (x86)\Star wars Battlefront II\GameData\AddOn\TA4\Data\_lvl_pc\SIDE\ret.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(829)
Unable to find level chunk rep_hero_obiwanr in C:\Program Files (x86)\Star wars Battlefront II\GameData\AddOn\TA4\Data\_lvl_pc\SIDE\ret.lvl


Message Severity: 3
C:\Battlefront2\main\Battlefront2\Source\LoadUtil.cpp(1019)
Unable to find level chunk in dc:SIDE\ret.lvl
i'm not sure if i forgot to rename something or what, but that happened

Re: How to replace sides?

Posted: Sun Oct 28, 2012 4:52 pm
by AQT
BobTheHunted wrote:No one seems to want to reply to this topic anymore
Off-topic: :? It hasn't even been 24 hours yet since the last post, and no one is obligated to reply, so you have no excuse to be that impatient.