Converting your own cars to NFS: Most Wanted

I. Preparation for work:
List of programs:
1. NFSMW-Modtools
2. Zmodeler 1.0.7
3. 3Ds Max, or another program for working with 3D models, from which export to a format supported by Zmodeler is possible.
4. Adobe Photoshop
5. DDS-plugin for Adobe Photoshop
Note:

– you can easily do without item 3, since Zmodeler itself is a pretty good 3d editor.
– our site hosts version 6.28 of the dds-plugin, but version 8.33 or even higher can be found online. The tutorials and all programs were created taking into account the specifics of plugin version 6.28, and files processed by version 8.33 may not work correctly.
– there are also newer versions of the Zmodeler program, that is, 2.0 and higher. To prepare models you must use version 1.0.7, since the new zmodeler versions do not understand the format for Most Wanted (*mwr).

Setting up the programs:
Install photoshop and the dds-plugin for it, install Zmodeler 1.0.7. Unpack NFSMW-Modtools. There you will see several folders; let's figure out what is stored in them.
- The zmodeler folder contains a filter for Zmodeler. It must be copied to the Filters folder of the installed program (only for version 1.0.7).
- The ferrari360 folder contains the example files of the Ferrari Spider 360 car imported by Arushan.
- The bin folder contains all the main programs used for importing new cars into NFS MW:
1. binTex - a program for viewing textures from the game's TEXTURES.bin and VINYLS.bin files.
It is mainly used to check the created files for functionality and to replace textures; I advise using the MWtex program for MW.
2. vltedit - a program for finding out the addresses that will then have to be patched (i.e. for setting up wheels, engine sound, recognition by cops, the car's performance characteristics, drive type, etc.)
3. The files mwgc.exe, mwtc.exe, texpatch.exe serve to compile textures and the model. Do not try to run them; they only work with command-line parameters, i.e. with the build.bat file in the ferrari360 folder.
Note:

- Some antiviruses flag Zmodeler. In fact, they flag not the program itself, but its uninstaller. It is enough to let the antivirus delete this file and the problem will go away. The program will work as before. If you don't trust it, you can skip downloading it. But then you can forget about importing your car into the games, at least into NFS-9.

II. Preparing the car model.
Working on the geometry:
Before working on the car, I advise you to look around carefully. The thing is that the game has several types of car parts: permanent, specific and variable. Variable ones are those that change together with bodykits, permanent ones are those that remain unchanged with any bodykits. We'll talk about specific ones later. So I advise you to decide which parts should change with different bodykits and which will be displayed permanently.

1) Names for permanent parts: (the original purpose of the part is written in parentheses, but you can combine them as you like – for example, merge everything that doesn't change into one object and call it basea)
base
Q – an object with this name must be present in the model: if it is missing, your car's headlights, exhaust, etc. will not work.
kit00leftbrakelightQ (rear left light)
kit00
rightbrakelightQ (rear right light)
kit00leftheadlightQ (front left light)
kit00
rightheadlightQ (front right light)
kit00leftheadlightglassQ (front left light glass)
kit00rightheadlightglassQ (front right light glass)
kit00leftbrakelightglassQ (rear left light glass)
kit00rightbrakelightglassQ (rear right light glass)
kit00leftsidemirrorQ (left side mirror)
kit00rightsidemirrorQ (right side mirror)
kit00frontwindowQ (front window)
kit00
rearwindowQ (rear window)
kit00frontleftwindowQ (front left side window)
kit00frontrightwindowQ (front right side window)
kit00rearleftwindowQ (rear left side window)
kit00rearrightwindowQ (rear right side window)
kit00interiorQ (car interior)
Notes:
- Q is the model quality parameter (from the English word quality).
- Be careful with the objects for the car's windows and lights. The thing is that the game has a certain damage model. A frontal impact causes cracks on the windshield, a rear impact – on the rear window respectively, etc. And if you merge all the windows into one object (for example, kit00frontwindow_Q), then all the windows will break on a frontal impact, and none on a side or rear impact. The same goes for the light glass, so I advise using the object names for the light glass and the body according to their purpose.

2) Names for variable parts: actually, in the game there is only one part of this type for each body: kitNNbodyQ, where NN is the body number, Q is the part quality (can be a, b, c, d, e). If you want, for example, the lights or the interior to change together with the body, they must be attached to the body.

3) Names for specific parts:
kit00driverQ - the car's driver (appears only during a race or free roam, not displayed in the garage and shop)
kit00frontbrakeQ - front brake
kit00
rearbrakeQ - rear brake
kit00fronttireQ - car wheel
kit00
hoodQ – stock hood
styleCC
hoodQ – tuning hood. CC can take the value: 02, 03, 04, 05, 06, 07, 09, 10, 13, 16, 17, 20, 21, 23, 26, 31, 32.
kit00
spoilerQ – the car's spoiler in the base configuration, disappears when tuned.
kit00
universalspoilerbase_Q – spoiler mount on some cars, such as Porcshe.

Now we determine which parts will remain unchanged for all bodies, which will change, and which should appear in the game only during a race. Then we merge the necessary parts with each other and name them accordingly.

4) Special car objects:
Objects for bringing the model to life (dummies). These objects are used to place the attachment points for the spoiler, air intakes, as well as for headlights and activating exhaust pipes. These objects do not take geometry, material or textures into account; only the location of their coordinates matters to the game. In the modeling environment it is customary to use cubes. They must be moved to where they will perform their function.
Dummies are set once for all bodies, i.e. you need to be careful with bodies in which the headlights or exhaust pipes move.
Attention: dummies do not replace, for example, the rear or front headlights, they simply create an imitation of the headlights (lights) working!

LEFTREVERSE, #RIGHTREVERSE – dummies for the white light on the rear headlights (when driving in reverse)

LEFTBRAKELIGHT, #RIGHTBRAKELIGHT – dummies for the rear headlights. When driving they glow as side lights, when parked – as brake lights.

LEFTHEADLIGHT, #RIGHTHEADLIGHT – the light of the front headlights. They glow constantly and regardless of driving pace.

LEFTEXHAUST, #RIGHTEXHAUST – exhaust dummies. An epic glow flies out of them when nitrous oxide is injected.

SPOILER – the attachment point for the in-game spoiler; the coordinates of the dummy are the place where the spoiler's "leg" will stand.

ROOF_SCOOP – the attachment point for the air intakes on the roof (and not only) of the car. The coordinates of the dummy are the center of the air intakes along the longitudinal and transverse axes and the bottom along the vertical axis.

When installing several dummies with the same effect, you should create copies and append numbers to them in square brackets, for example #LEFTBRAKELIGHT, #LEFTBRAKELIGHT[0], #LEFTBRAKELIGHT[1], …, #LEFTBRAKELIGHTw34;. The program Zmodeler 1.0.7b does this by itself.

5) Objects for applying decals. The game has decals, as you know. In order for your car to support them, you need to do the following. To begin with, we create objects for the doors, front/rear windows, fenders. The objects for the fenders, front/rear windows are simply a strip in the right place on the car. The objects for the doors include slots from the 1st to the 6th slots in the game, as well as slots for numbers (separately for tens and for units).
We name them:
decalfrontwindowwidemediumQ – object for the front window.
decal
rearwindowwidemediumQ – object for the rear window.
KitNNdecalrightdoorrectmediumQ – object for the right door.
KitNNdecalleftdoorrectmediumQ – object for the left door.
KitNNdecalrightquarterrectmediumQ – object for the right quarter panel.
KitNNdecalleftquarterrectmediumQ – object for the left quarter panel.
Now we assign the necessary materials to them:
DECAL1 = DECAL/DUMMYDECAL1 - material for the front, rear window, decals on the fenders and the first slot on the doors;
DECAL2 = DECAL/DUMMY
DECAL2 - for the second slot on the doors;
DECAL3 = DECAL/DUMMYDECAL3 - for the third slot on the doors;
DECAL4 = DECAL/DUMMY
DECAL4 - for the fourth slot on the doors;
DECAL5 = DECAL/DUMMYDECAL5 - for the fifth slot on the doors;
DECAL6 = DECAL/DUMMY
DECAL6 - for the sixth slot on the doors;
DECAL7 = DECAL/DUMMYNUMBERLEFT - material for the left part of the number sticker (i.e. for tens);
DECAL8 = DECAL/DUMMYNUMBERRIGHT - material for the right part of the number sticker (for units);

6) Damage objects. Among other things, the game has a simple damage model. For a user car (i.e. for the racer) it consists in damage to the rear, the front, the right/left front/rear side section. They appear in a race (free roam mode) when the corresponding sections of the car are hit. Special parts are responsible for them (each for one of the six sectors of the car). These parts are overlaid directly on top of the undamaged body. Here are the names for them:
KitNNdamage0frontQ – the front of the car.
KitNN
damage0rearQ – the rear of the car.
kitNNdamage0frontrightQ – the right front part of the side.
kitNN
damage0frontleftQ – the left front part of the side.
kitNNdamage0rearrightQ – the right rear part of the side.
kitNN
damage0rearleftQ – the left rear part of the side.

7) General notes:
- As you have already noticed, many parts have such a parameter Q. I have already mentioned that it can take the value a, b, c, d, e. This is a parameter for the quality of the part. It allows ensuring the best appearance of the part in particular and of the car in general, and at the same time allows saving system resources (for owners of low-power "budget" computers this is quite important). Parts with the parameter "a" are enabled in the garage/shop and when the camera approaches the car closer than 20 meters, parts "b" at a distance from 20 to approximately 55-60 meters (for brevity they can be made the same as "c"), parts "c" from 55-60 to 90 meters, parts "d" are activated from 90 to 120-130 meters, parts "e" (the lowest-poly) from 120-130 and further. Of course, these parameters depend on the graphics settings. When creating a model it is necessary to create all the qualities of the model, otherwise the bots participating in a competition in your car will disappear as soon as they drive those very 20 meters away. Your car will disappear in exactly the same way if you set the camera too far. If you do not have the ability to create objects of different quality, simply copy these parts or register them in the xlink.txt file, in the folder with the build.bat file. Here is an example of text for a stock body:
KIT00BODYB=KIT00BODYA
KIT00BODYC=KIT00BODYA
KIT00BODYD=KIT00BODYA
KIT00BODYE=KIT00BODYA
- Parts having the prefix "kit" with the parameter NN should be set individually for each body.
- Parts having the prefix "kit" with the parameter 00 are common to all bodies, they do not need to be duplicated for each. I.e. there is no need to copy the wheel five times and name the copies kit00fronttirea, kit01fronttirea, kit02fronttirea, kit03fronttirea, kit03fronttirea, kit04fronttirea, kit05fronttirea. It is enough to limit yourself to one wheel named kit00fronttirea, the other five will not work.

III. Applying materials to objects:
But geometry alone is not enough for a complete car. Now all objects need to be assigned materials. You can give the material any name you like, the most important thing is that it is written in Latin characters and contains only underscores ("_"), spaces and digits. The most important rule to keep in mind: "only one texture can be applied to one material". For example, one texture file may contain images of the interior, headlights and moldings. So assign one material to the interior, headlights and moldings so that the texture then lands where it should.

IV. Preparing the car textures.
So, the 3-d model is finished, now we move on to preparing the textures. I won't go into the details of working in various photo editors, I'll only touch on what is directly related to converting the car. Textures without an alpha mask must be saved in dxt1 format (no alpha). Textures with an alpha mask are saved in dxt3. Be careful – objects to which a texture with an alpha mask is applied in the game sometimes become semi-transparent!

V. Working with the folder that contains the build.bat file.
So, now we have reached the cherished folder that will give our car its ticket into the game.

1) What is in there:
the output folder – this is where our creation is born, in a form the game understands. It must contain any GEOMETRY.BIN and TEXTURES.BIN (from any add-on, or the original files from the game), and they must be in a folder named after the car you are replacing. For example: output/CARSREPLACE/IMPREZAWRX/.
build.bat – the main working file, it is what coordinates the work of several programs for the successful compilation (i.e. creation) of our car.
matlist360.txt – the file that lists the material names in the 3-d model, their properties and the texture applied to them.
texdefn.txt – the file that lists the texture names on the hard drive and the names of those same textures in the game file TEXTURES.BIN.
xlink360.txt – the file that lists the names of objects not created by you but which must be present in the model, for example parts of different quality levels.
mw360.mwr – the car model in a format already ready for compilation.
mw360.z3d – the car model (Ferrari 360) in z3d format for working with it in Zmodeler 1.0.7b. This model is in the folder for reference; you don't need to put your car's model there.
360misc.dds, 360tire.dds – textures of the Ferrari 360 car.
The textures, like the 3-d model in .z3d format, are in the Ferrari 360 folder so that you can see the conversion of your car using a clear example.
To get your car's model in .mwr format, export it from Zmodeler 1.0.7b into this format (the file-> export command).
Rename the saved textures of your car however you like, but the names must consist only of Latin letters, digits and underscores ("
"). Then move them into our cherished folder.

2) Now let's look in more detail at working with the txt files.

Texdefn.txt
It lists the texture names on the hard drive and the names of those same textures after they get into the game container file TEXTURES.BIN. We open it and see:
[tpk]
Identifier=CARTEXTURES
PipelinePath=GlobalPipelineCarTemplateTexturesCARNAME.tpk
XName= CARNAME
Output=outputCARS
REPLACE CARNAME TEXTURES.BIN
We edit the header. Instead of CAR
NAME, everywhere we write the name of the car you intend to replace.
Let's move on to creating the texture entries. Each [texture] block denotes one dds file in the BIN container. It consists of three lines and contains information about the texture name on the hard drive (they must all be in the same folder as build.bat) and the texture name in the BIN container.
[texture]
Name=MISC
File=MISC.dds
The Name line means the texture name in the BIN container. Be careful, the game works with these names! Unfortunately, we can only use the predefined texture names. Otherwise they won't work. Here are the allowed texture names:
ENGINE
MISC
MISCN
TIRE
TIRE
N
INTERIOR
INTERIORN
BADGING
BADGING
N
SKIN2
SKIN3
SKIN4
SKIN1
LOGO
DRIVER
TREAD
TREADN
RIM
BLUR
RIM
NEON
DOORHANDLE
SIDELIGHT
BADGING
EU
SKIN1B
The File line – the name of the dds file in the folder that contains the build.bat file. It will be imported into the game under a new name – the one written in the Name line.
Note:
- The name in the Name line must not exceed 23 characters. On top of these 23, the car name and an underscore ("_") are added.

Matlist360.txt
It lists the material names in the 3-d model, their properties and the texture applied to them. It contains lines with material entries (one line – one material) in the form

Material name=shader/texture.

Material name - the material name in the 3-d model.
Shader – An entry about the material's properties. You choose from the ready-made list of shaders the one that gives the part the properties you need - reflection, refraction, sometimes color tinting. Here is the list:
0xD6D6080A Open and load the frontend.vlt file from the vlt directory located in the program's folder. Follow the path ecar/default/racers/nameofthecaryouarereplacing (that is the word you write instead of CARNAMEVLT. Here we need the wheel_position* parameter, open the list, we see four values for the four wheels respectively.
Click on the first one, get the value, writing it out from the OFFSET field. It is located between the status line and the work area. For the remaining wheels we do the same operation. Next, open the ATTRIBUTES.MWPS file in the folder with the finished car using Notepad.
To configure just the wheels, the file should look something like this:
memfile GLOBAL/GlobalMemoryFile.bin
vpak GLOBAL/ATTRIBUTES.BIN db

wheel position

in x,y,z,w format (x=wheel coordinate on the longitudinal axis, y=wheel coordinate on the transverse axis, z=wheel position by height, w=wheel size)

patch float bin:0x3f7f0 1.28
patch float bin:0x3f7f4 0.8
patch float bin:0x3f7f8 0.0
patch float bin:0x3f7fc 0.30

patch float bin:0x3f800 1.28
patch float bin:0x3f804 -0.8
patch float bin:0x3f808 0.0
patch float bin:0x3f80c 0.30

patch float bin:0x3f810 -1.311
patch float bin:0x3f814 -0.8
patch float bin:0x3f818 0.0
patch float bin:0x3f81c 0.30

patch float bin:0x3f820 -1.311
patch float bin:0x3f824 0.8
patch float bin:0x3f828 0.0
patch float bin:0x3f82c 0.30

As we can see, each wheel has four parameters, but we only have one. To get the rest, we do the following.
Example:
We got, for example, the address bin:0x3da60 (one of the wheels of the Lamborgini Gallardo).
We write the rest in this format 0x3da6x (where x is 4, 8 or c respectively for the y, z, w coordinate).
In full it will look like this:

patch float bin:0x3da60 1.28
patch float bin:0x3da64 0.8
patch float bin:0x3da68 0.0
patch float bin:0x3da6c 0.30

The same goes for the other wheels. When everything is ready, save the file to the folder with the model and textures. Then drop everything where it belongs and admire the result. :)
If something is wrong, fix it.

VIII. Activating the car logo.
Go along the path Database -> frontend -> vehicles. There are three departments there: europe, north_america, japan. Each of them means the place of manufacture of the car – the one you are replacing.
Example: the logo of the Mersedes-Benz SL65 car.
The path to it is Database/frontend/vehicles/europe/mercedes/sl65.
Click on sl65, and a bunch of various parameters appear in the window on the right, but we are interested in only one - that is manufacturer, or more precisely its value.
When we click on manufacturer we get the value bin:0x8954.

Let's go into the directory output/CARS_REPLACE/SL65, open the file FE.MWPS with Notepad

manufacturer

patch dword значение_ manufacturer N, where N is the prefix in the name of the file with the manufacturer's logo (remember, I asked you to remember the number?). In the SL65 example the number 32 was used.
Example for SL65:

manufacturer

patch dword bin:0x8954 32

The next file that needs to be processed is CAR.INI in the same folder.

[car]
name=the name that will be shown in the game.
manufacturer= MANUFACTURERNAME
internal=CARNAME
modloader=0.2

MANUFACTURERNAME – the name of the manufacturer.
CARNAME – the name of the car you are replacing. This is the name of the folder with the car, only written in lowercase letters.

To avoid seeing the logos from the Ferrari 360, change the textures in the files SECONDARYLOGO.BIN and N-MANUFACTURERNAME.BIN.

IX. Well, that's probably all. This tutorial is not the most complete on the planet, it was created to clearly present the minimum necessary for creating a decent car. If you want to create truly masterpiece mods, then this information will not be enough for you – you will need to work on self-improvement. Communicate with more experienced modellers, read the relevant threads on forums. It is impossible to describe absolutely everything in one tutorial.

X. Special thanks to the following people:
1) Chapai (Femicide) – checking, detailed criticism, information.
2) McLaren_3Dcm – checking, criticism.
3) K1llM@n – permission to use his tutorial as a reference source of information.
4) REXAR (vinokurov GT-R) – checking, criticism, writing part of the tutorial.
5) Eclipse 72rus - additions, corrections.

XI. This tutorial was created for the nfs.place website, and its use on other websites is permitted with my consent and provided there is a link to the author in this format: ODiLISk; nfs.place; Russia. I reserve the right to publish the tutorial on any websites.

Author ODiLISk for nfs.place

Comments

Do you agree with the author? Share your experience or correct us.

Reviews: 0
Sign in  or  sign up  Sign in or sign up to leave a comment.