Texture Replacement

From FreeSpace Wiki
Jump to: navigation, search

Texture Replacement is an SCP feature implemented by Goober5000 which allows the user to alter the specific texture maps applied to pre-UVed chunks of the ship. As the name suggests, it does not alter the way these maps are applied in any way, but simply replaces the in-game data used for the ship. Its primary use is to allow premade nameplates for ships like the Orion and the HTL Fenris to be swapped on a per ship basis without the need for multiple table entries.

Use

Texture replacement can be accessed through the Ship editor (Accessible by Shift-S, right clicking a ship, or through the Editors menu).

Two types of texture replacement are available: Regular and Duplicate Model. Regular runs just as fast as (in some cases faster than) a model with no replacement textures and consumes no additional memory. In contrast, Duplicate Model must load and reskin an entire additional model into the game for every ship that uses it, and on top of that it tends to run slightly slower.

In summary, always use Regular replacement - do not use Duplicate Model unless troubleshooting for bugs.

How To

There are 3 types of nameplates: 1. nameplate with a background texture - like the stock Orion nameplate 2. transparent pcx nameplate 3. transparent .dds nameplate

Here's how to make each one:


1. Take the background texture and just paint the name in stop font over it, with a small transparency setting. Save as 8 bit pcx.

2. Make an image with a pure green background (0, 255, 0) and just paint the name in stop font over it. Save as 8-bit pcx.

3. Make a new image (512x128 pixels). pure white background. Make sure the image mode is set to RGB. Now, add a alpha channel (pure black) Type in almost white stop font the ship name on it. The grayer the font color the more transparent will the name appear. Save as a DTX5 type .dds


Note that for an Orion nameplate, there is a template available that will achieve an effect very close to that used in FreeSpace. The template (and associated tutorial) can be found here: [1].

See also