Adding locals

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

mnl1121

Adding locals

Post by mnl1121 »

welcome ladies and gentlemen to another one of my questions. lol. as some people probably have noticed is that i have many questions. well i would just like to say THANK YOU everyone that have been answering my questions b/c now my map is about 50% complete and im begeining to learn how to do many things.

well now to my question. i want to add wumpas as locals to my map. does anyone know how to do that?

again thx in advance
User avatar
Rends
Sith
Sith
Posts: 1278
Joined: Fri Oct 15, 2004 6:34 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Germany
Contact:

Post by Rends »

Yes i know it ;-)

For everything else read the fxxxxn docs!

Someone spend lot of time to write them

EDIT: to be more specific: Read the BF2 Jedi Creation doc.
It´s all there you only need to R E A D IT!
mnl1121

Post by mnl1121 »

hay someone getting a little mad
but the jedi creation to add locals? ok whatever u say RENDS

EDIT: i didn't read the BF2 jedi creation doc b/c i do'nt want to create a jedi

how am i supposed to know that adding wumpas as locals will be in there
-_-
Gametoast Staff
Gametoast Staff
Posts: 2678
Joined: Sat May 07, 2005 1:22 pm

Post by -_- »

look at the other luas for reference.
User avatar
Rends
Sith
Sith
Posts: 1278
Joined: Fri Oct 15, 2004 6:34 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Germany
Contact:

Post by Rends »

EDIT: My fault. Just noticed that you want them locals only.

Nothing faster than this:

ReadDataFile("SIDE\\snw.lvl",
"snw_inf_wampa")



SetTeamName (3, "locals")
AddUnitClass (3, "snw_inf_wampa", 7)
SetUnitCount (3, 7)

this will put 7 wampas on your map!
mnl1121

Post by mnl1121 »

lol thx cool
no harm done
mnl1121

Post by mnl1121 »

RENDS i have problem!!!!!!!!!! the wampas do'nt show up. this is what i have in the script right now:

"imp_inf_dark_trooper",
"imp_hero_darthvader",
"imp_fly_destroyer_dome",
"imp_walk_atst")

ReadDataFile("SIDE\\tur.lvl",
"tur_bldg_hoth_dishturret",
"tur_bldg_hoth_lasermortar")

ReadDataFile("SIDE\\snw.lvl",
"snw_inf_wampa")




SetTeamName (3,"locals")
AddUnitClass (3,"snw_inf_wampa",7)
SetUnitCount (3,7)

SetupTeams{
all = {
team = ALL,
units = 20,
reinforcements = 150,
soldier = { "all_inf_rifleman_snow",9, 25},
assault = { "all_inf_rocketeer_snow",1,4},
engineer = { "all_inf_engineer_snow",1,4},


what am i doing wrong? do i have to add command posts for them to spawn from? and if so what do i name the command post so the wampas are a seperate team?
froshthewookie

Post by froshthewookie »

I couldn't get my locals to work without assigning them a CP...
mnl1121

Post by mnl1121 »

i gotta ask rends. im sure he knows. i think i just have it in the wrong place in the script.
User avatar
Rends
Sith
Sith
Posts: 1278
Joined: Fri Oct 15, 2004 6:34 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Germany
Contact:

Post by Rends »

try adding

SetTeamName (3,"locals")
AddUnitClass (3,"snw_inf_wampa",7)
SetUnitCount (3,7)

right below "Setup teams" instead of before (dunno if it is the cause but worth a try.)

Next make sure that you add a CP and a spawnpath for your locals.

Done!

------------------------------------------------------------------------------------------

If you want to make them allied to a side you don´t need an extra CP for them but a spawnpath only.
So create a spawnpath first. Name it "Wampaspawn" (without quotes)
Simple add the wampa spawnpath to the allied CP where you want to have them span and put the name of the wampa spawnpath "Wampaspawn" (without quotes) into the alliedpath box in Object instance of the right side once you select the CP in Zeroeditor.

Next you need to make them friend or foe for the other 2 playable sides in the mission lua:

SetTeamAsEnemy(SNW, ATT)
SetTeamAsEnemy(ATT, SNW)


SetTeamAsFriend(SNW, DEF)
SetTeamAsFriend(DEF, SNW)

Done!
This example means that the Wampa would be friends of the DEFende and enemies of the ATTacker
mnl1121

Post by mnl1121 »

thx RENDS i gotta go do that right now
User avatar
Rends
Sith
Sith
Posts: 1278
Joined: Fri Oct 15, 2004 6:34 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Germany
Contact:

Post by Rends »

guess i need to be more specific. When i say to place the locals just after setup teams i didn´t mean the very next line but after the teams has been created.
Here is an example from mos eisley:

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 = { "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},
}
}

-- Jawas --------------------------
SetTeamName (3, "locals")
AddUnitClass (3, "tat_inf_jawa", 7)
SetUnitCount (3, 7)
SetTeamAsFriend(3,ATT)
SetTeamAsFriend(3,DEF)
SetTeamAsFriend(ATT,3)
SetTeamAsFriend(DEF,3)
-----------------------------------

got it?
mnl1121

Post by mnl1121 »

i knew what u meant. but i dind't put the SetTeamAsFreind b/c i didn't want them as freind for one team and enemry for the other and it didn't work, so i had an idea to put them both SetTeamAsEnemy, but the wampas still don't work.

any ideas?
Penguin
Jedi Admin
Jedi Admin
Posts: 2541
Joined: Sun Mar 05, 2006 12:00 am
Location: Australia

Post by Penguin »

i have this problem to, i can't get any of my tuskans to spawn ((i have a command post set to team 3)) >.<
Jawa_Killer
Brigadier General
Brigadier General
Posts: 629
Joined: Thu Jun 23, 2005 6:06 am
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set

Post by Jawa_Killer »

the addaigoal line is the most important one.....without this line no troops will show up BUT USE THE FXXXXN SEARCH FUNCTION I ALREADY EXPLAINED HOW TO ADD A 3RD SIDE!
mnl1121

Post by mnl1121 »

oh sorry. jeez whats with some people. u don't have to go all testy

oh and one more thing i already have the SetAIGoal (blah balh blah)

but instead of the 3 after set ai goal i had locals so i think that was my prob.

im munging right now so ill have to see if it works
mnl1121

Post by mnl1121 »

YUP it worked!

but now i have the [NULL] problem.

well i searched the [NULL] problem and followed the instructions. the only thing is i must have done it wrong and screwed everything up. now errors come up everytime i munge it and when im in game my map shows up as HOV%&_ or something like that. i heard thats a localize problem.

anyone have any ideas?

EDIT: well since teancum locked the other thread where i wanted to post pics ill do it here. but since the pics are too small and photobucket doesn't let you have bigger pics i mays well just post the errors here. the pic doesn't really matter.
all the spacing will probably be messed up though which is what i wanted to avoid.

ERROR[localizemunge English.cfg]:Text file syntax error. (File end)ERROR[localizemunge English.cfg]:Text file syntax error. (File end) [continuing]
ERROR[localizemunge French.cfg]:Text file syntax error. (File end)ERROR[localizemunge French.cfg]:Text file syntax error. (File end) [continuing]
ERROR[localizemunge german.cfg]:Text file syntax error. (File end)ERROR[localizemunge german.cfg]:Text file syntax error. (File end) [continuing]
ERROR[localizemunge Italian.cfg]:Text file syntax error. (File end)ERROR[localizemunge Italian.cfg]:Text file syntax error. (File end) [continuing]
ERROR[localizemunge japanese.cfg]:Text file syntax error. (File end)ERROR[localizemunge japanese.cfg]:Text file syntax error. (File end) [continuing]
ERROR[localizemunge spanish.cfg]:Text file syntax error. (No matching bracket)ERROR[localizemunge spanish.cfg]:Text file syntax error. (No matching bracket) [continuing]
12 Errors 0 Warnings
Last edited by mnl1121 on Thu Mar 16, 2006 4:04 pm, edited 1 time in total.
mnl1121

Post by mnl1121 »

does anyone know? this is a serious problem and i NEED to fix it.


EDIT: here are some pics of what i am talking about. sorry if they r big.

Image

Image

Image

Image

Image
User avatar
Rends
Sith
Sith
Posts: 1278
Joined: Fri Oct 15, 2004 6:34 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Germany
Contact:

Post by Rends »

post a screenshot of your localize tree. Guess that´s something setup wrong there
User avatar
Teancum
Jedi Admin
Jedi Admin
Posts: 11080
Joined: Wed Sep 07, 2005 11:42 pm
Projects :: No Mod project currently.
Games I'm Playing :: Destiny
xbox live or psn: No gamertag set
Location: Indiana

Post by Teancum »

Hmm... A syntax error. That's NOT good.
Post Reply