No vehicles!?

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
linksith
Command Sergeant Major
Command Sergeant Major
Posts: 284
Joined: Mon Jul 12, 2010 12:19 pm
Projects :: Waaay too many projects
Games I'm Playing :: too many
xbox live or psn: me has no xbox
Location: looking for a wifi connection

No vehicles!?

Post by linksith »

Help! I have problems with putting vehicles into all of the maps I try to create. I follow and re-follow all of the directions in the documentation but no vehicles ever show up. Any advice may help. Thanx
AQT
Gametoast Staff
Gametoast Staff
Posts: 4910
Joined: Sat Nov 03, 2007 4:55 pm
Location: SoCal, USA

Re: NO VEHICLES!?!?!?

Post by AQT »

Welcome to Gametoast. Please don't type topic titles in all uppercase as it is against the Site Rules
linksith wrote:I follow and re-follow all of the directions in the documentation but no vehicles ever show up.
Please explain how you did all this in detail if you really want help.
Press_Tilty
Chief Warrant Officer
Chief Warrant Officer
Posts: 331
Joined: Fri Jun 04, 2010 10:57 pm
Projects :: Korsava IV - Pre WIP
Games I'm Playing :: MW2-Reach-BF2
Location: Seattle Area

Re: NO VEHICLES!?!?!?

Post by Press_Tilty »

Make sure you put the appropriate vehicle in both the Att AND Def lines (they're mostly on the second page).

The first time I did it, I didn't read that right in fierfek's tutorial either.

Oh, and make sure you put them in the .lua's - i nearly forgot that as well :)

And welcome to GT
User avatar
SAMofBIA
Major General
Major General
Posts: 649
Joined: Tue Jun 15, 2010 3:38 pm
Projects :: Nothing....nothing at all.
Games I'm Playing :: League of Legends
xbox live or psn: No gamertag set
Location: MIA and not stopping in often anymore.

Re: NO VEHICLES!?!?!?

Post by SAMofBIA »

if you arent using Fierfek's tutorial, heres the excerpt from it about vehicles (very long)
Hidden/Spoiler:
Part 8. Vehicles

Okay, so you made your map, and are having fun playing it in BF2. But you want to have some way to get around your map besides walking. I don’t blame you, I would too. So, in this section, I will teach you to add in vehicles, and we will add in some speeders.
First, we need to figure out the coded names of the speeders. Go to each side folder, but instead of going into odf, open the req file (the one without shell on the end). There is a list of vehicle codenames. The ones we want here are:

Rep_hover_barcspeeder
Cis_hover_stap
Imp_hover_speederbike
(the rebels don’t have their own speeder, so they use the imperial one)

Okay, open up zeroeditor. Make sure you are in the conquest layer. Now, in objects, click browse. Go to ModID\common\odfs. Find com_item_vehicle_spawn. You will also need to create control regions for your command posts. Control Regions are made exactly the same way as capture zones, except for a few differences:

- Control Regions are not written as cp#_capture, but cp#_control
- Control Regions are squares, not cylinders
- Control Regions should be 10 height instead of 5
- Control Regions should be placed next to the command posts instead of over them

Edit the command posts so that the palettes look something like this:



Then, make the control regions. Place them next to the command posts. Now we will make vehicles.
Go back to objects, and find com_item_vehicle_spawn again. Place 2 or 3 next to each command post, outside the capture zone/spawn path, inside the control region. You don’t want them inside the spawn path because if you do, people would spawn inside vehicles (which would be a little disturbing). The right palette will look like this:



Now here it gets a bit repetitive. In ControlZone, write the command post number. So, if it is cp1, write cp1, if cp2 write cp2, etc. In Spawn Count, put 1. In Spawn time, put 30.0. In ExpireTimeEnemy, put 30.0. In ExpireTimeField, put 60.0. In DecayTime, put 30.0. Now, you need to specify what class of vehicle you are putting in. Each field (find more by pressing page dn) specifies a kind of vehicle. The ones you need to fill in are:

ClassAllATK
ClassCISATK
ClassImpATK
ClassRepATK
ClassAllDef
ClassCISDef
ClassImpDef
ClassRepDef

Now, each of these is for a side. So, for the All and Imp ones, type:

Imp_hover_speederbike

For Each of the Rep ones, type:

Rep_hover_barcspeeder

And For Each of the CIS ones, type:

Cis_hover_stap

Easy? Yeah, but you have to do that for every single vehicle spawner. It gets really tiring. You can do different vehicles kinds as well. Look through all the vehicle types in the side folder and req files. There are many different varieties.
Before the vehicles will work, we need to edit the LUA files again. Go to common\scripts\MAP. You need the same 4 we worked with before. Open MAPc_con. Find the text:

ReadDataFile("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_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")

Now, remember, these tell the game what files to read. So, now we need to input our vehicles. Edit it so it looks like this:

ReadDataFile("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_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",
“cis_hover_stap” )

See? We added cis_hover_stap. Now the game knows to read that file. Do the same to MAPc_con.lua. Now, onto the GCW files. Open MAPg_con. Find the text:

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" )

Remember, no Rebel files need to be read, because they are borrowing the Imperial’s speeder. Edit it so it says:

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",
“imp_hover_speederbike” )

See? We added imp_hover_speederbike. Get used to fiddling with these LUA files. Do the same to MAPg_con.lua. Now, vehicles should spawn in your map. The next section will teach you to make the AI smarter, so they know where to walk
hope it helps!
User avatar
linksith
Command Sergeant Major
Command Sergeant Major
Posts: 284
Joined: Mon Jul 12, 2010 12:19 pm
Projects :: Waaay too many projects
Games I'm Playing :: too many
xbox live or psn: me has no xbox
Location: looking for a wifi connection

Re: No vehicles!?

Post by linksith »

Thank you so much! I was using the documentation that came with the mod tools but I didn't see where I was supposed to modify the LUA. I didn't even know that Fierfek's guide existed. Now i just remembered one more thing I'm having trouble with. I place turrets into my map but they don't appear into the map. The turret file is in "data_WOB\Sides\tur\odf"and is labeled as "tur_bldg_beam". Thanks again.
User avatar
Marvel4
Rebel Colonel
Rebel Colonel
Posts: 556
Joined: Mon Jun 21, 2010 12:57 pm
Projects :: Marvel4s BF1 Conversion Pack + Era Mod

Re: No vehicles!?

Post by Marvel4 »

Add to your lua:
ReadDataFile("SIDE\\tur.lvl",
"tur_bldg_beam")
User avatar
linksith
Command Sergeant Major
Command Sergeant Major
Posts: 284
Joined: Mon Jul 12, 2010 12:19 pm
Projects :: Waaay too many projects
Games I'm Playing :: too many
xbox live or psn: me has no xbox
Location: looking for a wifi connection

Re: No vehicles!?

Post by linksith »

Thanks a lot. I feel stupid for not looking for it in the lua, but I guess that's a habit of mine. Thanks again!
Post Reply