Quantcast

Jump to content

» «
Photo

Map Coll Making & SA LOD Colls

2 replies to this topic
DeathSquad
  • DeathSquad

    CEO DeathSquad Industries

  • Members
  • Joined: 02 Aug 2003

#1

Posted 06 March 2006 - 10:21 AM

Map Coll Making & SA LOD Colls
By. Deathsquad Industries



[ INTRO ]

Couldn't find anything in the tutorial thread or archieve on using Steve-M's Collision File Maker, and I know there has been some problems I believe with the sketchup program and mysterious invisable walls, so I figured I'd fully explain how to make collision files with Steve-M's Coll Maker. So here is an indepth tutorial on using those programs. All of Steve-M's programs are found at his homepage (http://www.steve-m.com) along with his own tutorials from which I leanred from. This also covers Zmod2 users whom just need ti simply export their models as something Zmod1 can read such as a VC Dff, then export as an X file. I also cover the different between VC LOD Collision Files and SA LOD Collision Files, but credit goes to Steve-M and everyone else who has explained it, I'm just recapping on it.




[ STEP 1 ]

First of course you need a model to make a collision file, otherwise making a collision file without a model would be seen as some freakish sex fetish. For this project I have made a vehicle tube style tunnel.

Zmod2 Users: Export your model as a Vice City / GTA III DFF Model, and import into Zmod1. The model will appear with no textures, but collision doesn't need textures.

In Zmod1 export your file as a DirectX Mesh File (*.X).

user posted image



[ STEP 2 ]

Start up the Collision File Maker, if this if your first time using it and are english speaking / reading, click Optionen->Language->English to set the program to english. Otherwises, lets get started.

user posted image

OBJECT NAME: This should be the name of the collision that will appear in your main collision file, and should be the same name as the DFF and IDE Entry.

INPUT PANEL FOR VERTEX & FACE DATA: This is X File Text Data that will create your collision, starting with the first line, delete everything to FRAME MAIN. 3 Lines below, you will see a single number followed by a group of 3 coordinate numbers. Delete everyting to the first single number 3 lines below FRAME MAIN. You should have something like so...

user posted image

NOTE: The Single Digit Number is your VERTEX Count.

From the top now scroll down the text, after the first section of 3 coordinate numbers, you will come to another section starting with a single digit line, followed by a smaller group of 4 numbers. At the end of this section you will find MESHNORMALS. Delete MeshNormals and everything else below this line. You can now click MAKE COLLISION FILE, the program will compile the data and ask you to save the file somewhere. Do so.

NOTE: The 2nd Single Digit Number is your POLYGON Count.



[ STEP 3 ]

Start up the Collision File Editor II, and open up your Main Collision Library. These file libraries contains groups of collision files for certain aspect of the game, typically grouped per IDE/AREA/ZONES. Vehicle Collision Libraries are used in GTA III and GTA VC, while in GTA SA vehicle collision is stored with the vehicle DFF. For Maps these files are located in your GTA3.IMG directory. In such games such as Vice City, you can use the map collision file externally by loading it in the gtavc.dat file.

Create or open a collision file library, click EDIT and then ADD, select and add your newly made collision file. Go to the bottom of the screen, click on EDIT MODE, then the FACE tab. Click the ALL button, and then under the surface settings click on the small VC/SA Mode button if this applies. Click on the button that says DEFAULT [ DEFAULT ] and pick the material of your collision.

user posted image

Different materials give different effects, such as dirt will cause a car to kick up dirt and leave muddy tracks behind, versus pavement in which the car burns rubber and leaves tire tracks.

user posted image

The Brightness Meter is for use with COL3 Type Collisions which are used for San Andreas. This does not determine how bright your model will appear in game, that is vertex prelighting. This will determine how bright or dark certain models will appear while on this collision, such as vehicles, peds and your character. Between 1/4 and 1/2 is a good range, look at original SA models for an idea.

In the EDIT SELECTION menu, click on "FLIP" which will flip over all your faces, as they will be flipped backwards when first imported. Last right click on the name of the collision model in the menu above, select MIRROR->X AXIS. This will flip your model 180 degrees, as it was also backwards.

If this collision is for San Andreas, then in the same menu click TARGET VERSION and select COL3.

user posted image

Save File.



[ STEP 4 ]

FOR GTA VC: In CollEditor 2 right click on your collision file and select COPY AS LOD, this will create the blank scale collision file used for LOD models. Save once again, and closed the program. You are done.

FOR GTA SAN ANDREAS: San An does not use the same method as Vice City. The game will function if the VC Method is used, but your LOD will not disappear in game (c:Gforce). The LOD Models take their collision data from the original model/collision that they are replacing, which is determined by the last code digit in the IPL code lines.

For Example, a working set of IPL lines:

CODE
+----+-------------------------------------------------------------------------------+
|LINE| ORIGINAL IPL DATA                                                             |
+----+-------------------------------------------------------------------------------+
|    |inst                                                                           |
| 0  |18643, sa420_i_land, 0, 1236.33, -2674.15, 15, 0, 0, 0.707106, 0.707107, 1     |
| 1  |18644, LOD20_i_land, 0, 1236.33, -2674.15, 15, 0, 0, 0.707106, 0.707107, -1    |
| 2  |18641, sa420_dam_v1, 0, 1067.83, -2487.8, 15.1, 0, 0, 0.707106, 0.707107, 3    |
| 3  |18642, LOD20_dam_v1, 0, 1067.83, -2487.8, 15.1, 0, 0, 0.707106, 0.707107, -1   |
| 4  |18631, sa420_e_legion, 0, 783.289, -2702.67, 26.1, 0, 0, 0, 1, 5               |
| 5  |18632, LOD20_e_legion, 0, 783.289, -2702.67, 26.1, 0, 0, 0, 1, -1              |
| 6  |18637, sa420_m_legion, 0, 554.269, -2702.68, 29.05, 0, 0, 0, 1, 7              |
| 7  |18638, LOD20_m_legion, 0, 554.269, -2702.68, 29.05, 0, 0, 0, 1, -1             |
| 8  |18633, sa420_w_legion, 0, 318.495, -2702.66, 28.17, 0, 0, 0, 1, 9              |
| 9  |18634, LOD20_w_legion, 0, 318.495, -2702.66, 28.17, 0, 0, 0, 1, -1             |
| 10 |18635, sa420_o_ramp, 0, 1239.39, -2691.23, 15.55, 0, 0, 0.708955, 0.705254, 11 |
| 11 |18636, LOD20_o_ramp, 0, 1239.39, -2691.23, 15.55, 0, 0, 0.708955, 0.705254, -1 |
| 12 |18639, sa420_approach, 0, 996.56, -2703.27, 9.86, 0, 0, 0, 1, 13               |
| 13 |18640, LOD20_approach, 0, 996.56, -2703.27, 9.86, 0, 0, 0, 1, -1               |
|    |end                                                                            |
+----+-------------------------------------------------------------------------------+


A last digit code of -1 means there is -no- lod file for the model, meaning all LOD Ipl lines will be -1. Otherwise this digit is the number of the IPL LINE of its LOD, with the first IPL Line in the INST section as Line 0 (as shown above).

So "sa420_i_land" points to its LOD counterpart on LINE 1 of the Ipl->INST section. "Sa420_approach" points to its LOD counterpart on LINE 13. I doubt that the model's IPL definitions need to be side-by-side as the list above, just make sure the main model points to the correct LOD line.

steve-m
  • steve-m

  • Members
  • Joined: 26 Jul 2002

#2

Posted 31 March 2006 - 02:48 PM

Nice tutorial, but why not save step 2 and export to a .3ds file instead of .x? CE2 imports .3ds directly, so no need to fiddle with deleting lines, flipping faces and so on. Also, to get rid of Sketchup's invisible walls you'd have to use CE2's optimize function, which isn't done automatically when you're importing/opening an existing .col file (as in your tut).

DeathSquad
  • DeathSquad

    CEO DeathSquad Industries

  • Members
  • Joined: 02 Aug 2003

#3

Posted 13 April 2006 - 05:48 PM

Thanks Steve, at the time I wrote the tutorial I hadn't noticed you could just directly import the 3ds files into CE2. Haven't had time to play with that function, but will update the tutorial when I do. I tried it once but I screwed up somewhere.




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users