[SOLVED]Side Not working

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
User avatar
Xterminator
Private Second Class
Posts: 69
Joined: Thu Feb 19, 2009 5:07 pm

[SOLVED]Side Not working

Post by Xterminator »

Ok ive done everything in calebs tut but theres a problem with my .lua (I think)

I tried to add a trooper to my rep side but when in game he doesnt appear.
After i munge i get 2 errors

Code: Select all

C:\BF2_ModTools\ToolsFL\Bin\luac.exe: ..\..\common\scripts\IHS\IHSc_con.lua:82: `)' expected (to close `(' at line 74) near `"rep_hover_fightertank"'
ERROR[scriptmunge scripts\IHS\IHSc_con.lua]:Could not read input file.ERROR[scriptmunge scripts\IHS\IHSc_con.lua]:Could not read input file. [continuing]
   2 Errors    0 Warnings

ERROR[levelpack mission\IHSc_con.req]:Expecting bracket, but none was found.
File : munged\pc\ihsc_con.script.req(1)...

ucft <--
ERROR[levelpack mission\IHSc_con.req]:Expecting bracket, but none was found.
File : munged\pc\ihsc_con.script.req(1)...

ucft <--

   2 Errors    0 Warnings

My .Lua

Code: Select all

 
    ReadDataFile("sound\\yav.lvl;yav1cw")
    ReadDataFile("dc:SIDE\\rep.lvl",
                             "rep_inf_ep3_rifleman",
                             "rep_inf_ep3_rocketeer",
                             "rep_inf_ep3_engineer",
                             "rep_inf_ep3_sniper",
                             "rep_inf_ep3_officer",
                             "rep_inf_ep3_jettrooper",
                             "rep_inf_arc_heavy_gunner"
                             "rep_hover_fightertank",
                             "rep_hero_anakin",
                             "rep_hover_barcspeeder"
    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")
                             
                             
    ReadDataFile("SIDE\\tur.lvl", 
    			"tur_bldg_laser",
    			"tur_bldg_tower")          
                             
	SetupTeams{
		rep = {
			team = REP,
			units = 20,
			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 = 20,
			reinforcements = 150,
			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},
		}
	}
     
    SetHeroClass(CIS, "cis_hero_darthmaul")
    SetHeroClass(REP, "rep_hero_anakin")

    AddUnitClass(REP, "rep_inf_arc_heavy_gunner",1,4)
   

Help would be great :)

Thanks
Last edited by Xterminator on Thu Apr 09, 2009 6:05 am, edited 1 time in total.
User avatar
sampip
General
General
Posts: 792
Joined: Mon Mar 16, 2009 12:08 pm
Projects :: Something big. And exciting.
Games I'm Playing :: Battlefield 3
xbox live or psn: masowner66
Location: Zebra

Re: Side Not working

Post by sampip »

Read the error, you can see it was expecting a bracket, but none was found. You are missing a bracket after:

Code: Select all

"rep_hover_barcspeeder" 
.It should look like this:

Code: Select all

"rep_hover_barcspeeder") 
The other error is on your Arc gunner. You are missing a comma after

Code: Select all

"rep_inf_arc_heavy_gunner" 
. It should look like this:

Code: Select all

"rep_inf_arc_heavy_gunner", 
Try munging again after that.
User avatar
Xterminator
Private Second Class
Posts: 69
Joined: Thu Feb 19, 2009 5:07 pm

Re: Side Not working

Post by Xterminator »

Ok i did what you said and it got rid of the errors but still no arc gunner .

But I did get anakin straight away is this somthing to do with it?
User avatar
sampip
General
General
Posts: 792
Joined: Mon Mar 16, 2009 12:08 pm
Projects :: Something big. And exciting.
Games I'm Playing :: Battlefield 3
xbox live or psn: masowner66
Location: Zebra

Re: Side Not working

Post by sampip »

I have a small idea, but could you post your .lua again please. Now that you've corrected it.
First of all, this:

Code: Select all

SetHeroClass(CIS, "cis_hero_darthmaul")
    SetHeroClass(REP, "rep_hero_anakin")

    AddUnitClass(REP, "rep_inf_arc_heavy_gunner",1,4)
Try putting it like this:

Code: Select all

AddUnitClass(REP, "rep_inf_arc_heavy_gunner",1,4)

SetHeroClass(CIS, "cis_hero_darthmaul")
SetHeroClass(REP, "rep_hero_anakin")
so that the Unit loads first. If this does not work, make sure your unit has a req, and make sure that he is called in your sides req folder.
User avatar
Xterminator
Private Second Class
Posts: 69
Joined: Thu Feb 19, 2009 5:07 pm

Re: Side Not working

Post by Xterminator »

Code: Select all

    ReadDataFile("sound\\yav.lvl;yav1cw")
    ReadDataFile("dc:SIDE\\rep.lvl",
                             "rep_inf_ep3_rifleman",
                             "rep_inf_ep3_rocketeer",
                             "rep_inf_ep3_engineer",
                             "rep_inf_ep3_sniper",
                             "rep_inf_ep3_officer",
                             "rep_inf_ep3_jettrooper",
                             "rep_inf_arc_heavy_gunner",
                             "rep_hover_fightertank",
                             "rep_hero_anakin",
                             "rep_hover_barcspeeder")
    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")
                             
                             
    ReadDataFile("SIDE\\tur.lvl", 
    			"tur_bldg_laser",
    			"tur_bldg_tower")          
                             
	SetupTeams{
		rep = {
			team = REP,
			units = 20,
			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 = 20,
			reinforcements = 150,
			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},
		}
	}
     
    SetHeroClass(CIS, "cis_hero_darthmaul")
    SetHeroClass(REP, "rep_hero_anakin")

    AddUnitClass(REP, "rep_inf_arc_heavy_gunner",1,4)
   

i'll try that now :)
Last edited by Xterminator on Thu Apr 09, 2009 6:04 am, edited 2 times in total.
User avatar
sampip
General
General
Posts: 792
Joined: Mon Mar 16, 2009 12:08 pm
Projects :: Something big. And exciting.
Games I'm Playing :: Battlefield 3
xbox live or psn: masowner66
Location: Zebra

Re: Side Not working

Post by sampip »

I seem to remember the same thing happened to me, but I forget how I fixed it now *bangs head on table*, I think that should work though. If it doesn't, try doing a manual clean, and then munging again. Something could have got stuck...
Off topic: 100 posts!! :D
User avatar
Xterminator
Private Second Class
Posts: 69
Joined: Thu Feb 19, 2009 5:07 pm

Re: Side Not working

Post by Xterminator »

Thankyou swapping the heroes with the arc worked , thankyou you so much you are awesome :D
User avatar
sampip
General
General
Posts: 792
Joined: Mon Mar 16, 2009 12:08 pm
Projects :: Something big. And exciting.
Games I'm Playing :: Battlefield 3
xbox live or psn: masowner66
Location: Zebra

Re: [SOLVED]Side Not working

Post by sampip »

No problem. :D I've had to live through all these errors myself!! :wink:
Post Reply