Objects

Modders can post their questions on scripting and more.

Moderators: Slitherine Core, BA Moderators

Post Reply
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Objects

Post by junk2drive »

Looking in the objects folder, some things have s4f, some have dds, none have both. I compare that to a unit which has s4f, dds and destroyed dds.

I can place the destroyed_car on the map in the editor. It is an s4f. Can I place a destroyed tank, say a Sherman, on a map? Can I simply copy the s4f from units to objects?
adherbal
The Artistocrats
The Artistocrats
Posts: 3900
Joined: Fri Jun 24, 2005 6:42 pm
Location: Belgium

Post by adherbal »

many objects share same texture. For example most vegetation textures are placed in a single DDS. Not sure if using vehicle models works. It's worth a try.
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Post by junk2drive »

No

I used the Sherman_0.s4f, nope. Added the D dds, nope. Renamed to Sherman.s4f, nope. The car is not in the Objects.txt so I don't think it needs to be added there.
pipfromslitherine
Site Admin
Site Admin
Posts: 9863
Joined: Wed Mar 23, 2005 10:35 pm

Post by pipfromslitherine »

There is usually a correspondence between a unit s4f and it's textures - each unit has a single main texture and (if needed) a destroyed one. Note that the names of the s4f and the texture do not need to be the same as the texture name is defined in the s4f

Object s4fs all tend to reference a small number of textures for their detail. This is for performance mainly, as having tons of different textures is signficantly less efficient.

Hope that helps

Cheers

Pip
junk2drive
BA Moderator
BA Moderator
Posts: 1478
Joined: Sun May 23, 2010 4:47 pm
Location: Arizona USA -7GMT

Post by junk2drive »

Sounds like someone would have to open the unit s4f and export it as an object s4f.

Is there a way to put destroyed units on the map in the editor? My thought with objects is that they cannot be removed/bulldozed.
IainMcNeil
Site Admin
Site Admin
Posts: 13558
Joined: Fri Apr 01, 2005 10:19 am

Post by IainMcNeil »

You can use the script to create a unit and then destroy it :)

I dont know if it would end up smoking, it might even explode which you may not want.
tim1966
Administrative Corporal - SdKfz 232 8Rad
Administrative Corporal - SdKfz 232 8Rad
Posts: 161
Joined: Sat Jul 31, 2010 7:15 pm
Location: Brighton, UK
Contact:

Post by tim1966 »

In a similar vein - is it possible to use the aircraft models as objects on the ground to be destroyed?
Models from Tim's Surplus Store ... Established 1966 ... Open 24/7 ... closed for TEA TIME
Merr
Captain - Heavy Cruiser
Captain - Heavy Cruiser
Posts: 903
Joined: Mon Aug 16, 2010 2:00 pm

Post by Merr »

j2j,

Here's how to add a destroyed Sherman Object to the map (in the Editor) ....

1. Create a folder in your Objects folder in your campaign folder ..... ie My Games\BBCBA\CAMPAIGNS\My_Campaign\Objects\destroyed
2. Copy these files to the new folder .... sherman_0.s4f, sherman_d.dds
3. Rename the sherman_d.dds to sherman.dds (changes the default sherman texture).
4. Create an OBJECTS txt file in your destroyed folder and add this line ...

[SHERMAN_0]
BLOCKING
FADE

5. Save the OBJECTS.txt file
6. Open the editor and load your campaign, then click on the object icon ... you should see a new folder called destroyed containing the sherman_0 object.

NOTE : No need to add BLOCKING or FADE ... I did this to block LOS and fade the object when entered. The basic line you need can just read ;

[SHERMAN_0]

Should work with any unit you want as a static unit, ie planes.

Hope this helps.
Post Reply

Return to “Battle Academy : Modders Corner ”