Showing posts with label [NFS III]. Show all posts
Showing posts with label [NFS III]. Show all posts

Tuesday, August 19, 2025

How to make NFS3-styled loading track slides

In this tutorial you will learn how to make a track loading slide in a style that's quite close to the one used in the vanilla game's ones.

    Stuff you'll need

    • GIMP [portable version] - image editor (version 2.10 shown; while you will still be good if you're using the latest version -3.0.4 at the time- you can use the GIMP 3 version of the template instead, which has several filters pre-applied as non-destructive effects)
    • My track slide templates
    • FSHTool [download] - QFS/FSH file unpacker/packer, for slides and vidwalls
    • Earth Normal font [download] - font used for the car names in the slides
      • Future Earth [download] is also a good alternative (there's a layer in the template that uses that font since it has different metrics)
    I will use Opus IV's conversion of Andreas Neuer's Country Summer as an example.     

    GIMP's user interface

    If you're not famliarized with GIMP, I will give you a quick rundown of the UI so you can get yourself acquainted with it. Here's the default UI for version 2.10


    1. Toolbox: here's where you will find most of the tools used for editing, like selection, paintbrush, bucket fill, text, etc. By default tools are grouped into several groups (which are indicated by the small arrows on the bottom right of the buttons); to select another tool in the group, right-click on the button to display the available tools in that tool to select them. Also, you can select the foreground and background colors (the black and white squares, respectively)
    2. Tool options/Information/Undo history/Recent files tabs: for this tutorial we're just going to focus on the Tool options; here's where the selected tool's parameters can be configured.
    3. Brushes/Patterns/Fonts/Messages tabs: not important for this tutorial.
    4. Layers/Channels/Paths tabs: here's when you can manage the image layers, channels and paths. We'll just focus on layers and paths.

    Step 1: Uncompressing the .qfs files

    1. Unzip FSHTool into a folder
    2. Copy the fedata\art\slides\t#_00.qfs file from the game's folder into the FSHTool folder
      • The # stands for the track number, here's the list of numbers with their corresponding track:
        Track #
        Track name
        Track folder
        0 Hometown
        HOMETOWN
        1 Redrock Ridge
        REDROCK
        2 Atlantica
        ATLANTICA
        3 Rocky Pass
        ROCKYPAS
        4 Country Woods
        COUNTRY
        5 Lost Canyons
        LOSTCANY
        6 Aquatica
        AQUATICA
        7 Summit
        SUMMIT
        8 Empire City
        EMPIRE

    3. Now either drag the .qfs files into the FSHTool.exe file to uncompress them; a new folder with the file name will be generated for each file.

    Step 2: Making the slide background image

    1. Take a screenshot of the track in-game; remember to disable the HUD with F5 first.
      • Also I recommend to take it under the highest resolution possible
      • You can also use a photo that's more of less representative of your track if you want something closer to the style of the game.
    2. Make sure you have installed the Earth or Future Earth font.
    3. Unzip the files of the templates to a folder and open the track_vidwall.xcf file in GIMP. Select the base layer in the trackimg group by clicking on its name in the Layers pane.


    4. Open the screenshot you took and resize (go to Image > Scale Image) it to 640px width if neccesary. Then copy it (Ctrl+C) and paste it (Ctrl+V) into the base layer of the template. You'll see there's a white dotted border which is the selection and in the Layers pane there is a Floating Selection layer; that's what we've pasted. Pick the Move (keyboard: M) tool in the toolbox, then click and drag the layer while holding Ctrl (to keep it sticked to the image edges) to adjust it.


    5. When you're done, anchor the selection to the layer below (base) by going to Layer > Anchor Layer (Ctrl+H). You will see the yellow dotted border, which is the layer boundary will change size; we don't want that since we'll need all the layers in that group to have the same size.


    6. Select the trackimg group by in the Layers pane, then go to Layer > Mask > Mask to selection. Go back to the base layer. You will see the selection now fits the image; now we'll crop it to that selection by going to Layer > Crop to selection. The layer size is now adjusted to the selection.


    7. If you want to adjust the image contrast, go to Colors > Curves. For example, you can adjust the curve a little like this (moving the bottom left point towards the right will make the darkest colors in the image darker and moving the upper right point towards the left will make the brightest colors brighter. When you're done, click OK .


    8. Copy the layer (Ctrl+C), switch to the blur layer and paste it (Ctrl+V) in there. Now go to Filters > Blur > Gaussian Blur and set the following values. Click OK to apply it and anchor the layer.

    Step 3: The track name text

    1. Pick the Text (T) tool in the Toolbox, then go to the track name layer any of the trackname folders and triple-click on it to select all the text; type the track name afterwards, the layer name will change as well.
      • Leave a space after the text so the last letter won't get cut off. 
      • If you're using the Earth font, type your text in uppercase; if you're using Future Earth, type it in lowercase or lowercase with some letters such as T, Y or H in uppercase if you're using the Future Earth Variants font.

    2. Press Esc to exit text edit mode, then pick the Unite Transform (Shift+T) tool. Move the pivot point right to the text's upper right corner, then Ctrl-click and drag to the right the diamond shaped point on the top side of the layer; use the placeholder text below as a guide for the shear (which is around 16 in the upper-right value of the Transform box). When you're done, click on Transform or press Enter.

    3. Select the shadow layer below the text, right-click on the text layer and select Alpha to Selection, then go to Selection > Grow and grow the selection by 3px. Then pick the Bucket Fill tool and paint the selection black.

    4. Deselect your selection, then go to Filters > Blur > Gaussian Blur and apply a blur using these values. Then go to Layer > Crop to Selection to crop out the empty space in the layer.

    Step 4: The track map

    1. Take a screenshot of the track map in-game. To do so:
      • Set the map to full screen by tapping the Tab key.
      • Start a race, switch to bumper cam and turn 90 degrees facing a dark wall; drive up close to it.
      • For better results, set track time to night and turn off your car lights with the L key.

    2. Open the screenshot and pick the Select by Color (Shift+O) tool. Set the threshold to 75 and click on the track map to select it (you might have to zoom in). If there's anything else than the map selected, you can pick the Rectangle Select (R) tool and Ctrl-click and drag to deselect the parts you don't want.

    3. Go to Select > Grow, set how many pixels you want to grow the selection (that will depend on how big and complex your map is, alongside resolution; I will pick 3px for mine) and click OK. You will see the selection is now thicker

    4. Pick the Free Select (F) tool, then deselect the parts of the map you don't need by Ctrl-clicking and making a shape around those; press Enter to confirm the deselection. Then bridge the gap that's missing by Shift+clicking, selecting in a way that bridges the gap and press Enter when done.

    5. Go to the Select > To Path, you will see now a red outline lies in place of our selection; that's a path.

    6. Now go to Layer > New Layer... (Ctrl+Shift+N). Name the layer course and click on OK. Make sure you have black as foreground color (you can reset the default colors by pressing the D key); then switch to the Paths tab and right-click on the path of the track course, click on Fill Path, choose Solid Color and click on Fill. You will see now there's the path is now filled.

    7. Deselect everything and copy (Ctrl+C) the course layer, then go back to the template file and paste it (Ctrl+V) into the mapbase layer; go to Layer > Crop to Content and use the United Transform (Shift+T) tool and resize (by clicking and dragging the edge handles) and move it into place on the rightmost part of the image. Press Enter when done and anchor the layer when you're done.

    8. Go to Layer > Crop to Content to crop out the empty space off the map, pick the Alignment (Q) tool, set Relative to to Active layer in the Tool Options and click+drag just over the image and map area to set an alignment selection. In the layer list pane, select the base layer in the trackimg folder and press the Align middle of target button to vertically center the track map to the track image.

    9. Go to the start layer of the trackmap folder, pick the Move (M) tool, then click and drag the start icon to where the track start/finish line would be.

    10. Select the trackmap folder in the layer list, then go to Layer > Transparency > Alpha to Selection, and go to Selection > Grow and grow the selection by 2 px. Go to the shadow layer, pick white as the foreground color and paint the selection with the Bucket Fill (Shift+B) tool, deselect everything by pressing Ctrl+Shift+A, then go to Filters > Blur > Gaussian Blur, set a blur of 3 and click OK.

    11. To save the track slide, go to File > Export (Ctrl+E) or File > Export As (Ctrl+Shift+E). Save it as 0000.bmp in the T#_00 folder of the qfs file you uncompressed with FSHTool. When the export options dialog shows up, use the settings shown below and click on Export

    Step 5: Compiling the .qfs files and setting them in-game

    1. Go to the T#_00 folder and drag the index.fsh file into the FSHTool executable (you might need to open a second window to do this)
    2. Copy the t#_00.qfs file and paste it into the fedata\art\slides folder of NFS3 (make backups first!)
    And that's it! This is how you can make NFS3-styled track slides. Hope this tutorial has been helpful.

    See you around!

    Friday, December 29, 2023

    NFS3/NFSHS Car Sound Tutorial

    Note: this tutorial is made with the assumption you are familiarized with Audacity's interface and tools. If you don't I strongly recommend to read the program's manual here

      Intro

      There's a couple of car sound editing for NFSHS out there but I always had some trouble making sounds because they either had clicking in spite of following the steps (albeit adapted for Audacity), uneven looping or sounds sounding "muffled" compared to source. After messing around with samples and some hex editing (alongside the advent of new software for better BNK editing) I finally came up with a method to get consistently decent loops in-game and in addition, gathered some insight on NFS3 sound editing as well.

      Tools you'll need


      The BNK files structure

      NFS3 and NFSHS use sound bank files (.BNK) for car sounds; NFSHS has also the CARENG.CTB and CARENG.LTB files, which are presumed to tell the game which sample (or stream) of (S)CARENG.BNK use at what rpm since each car has a different set. NFS3 on the other hand has a simpler, standardized structure recycled from NFS2 (the only difference is that NFS3 CAR.BNKs might come with alternate streams which NFSWizard cannot read, but NFS2 .BNKs can be used as-is). 

       

      NFS3 car sound structure

      File Description Samples [streams] Notes
      car.bnk
      Player car sound bank
      1. Engine accelerating [0]
      2. Engine decelerating [1]
      3. Gear shift [2]
      4. Horn [3]
      • Samples 1, 2 and 4 are looped
      • Samples 1 and 2 are normally stereo but mono samples can be used without issues
      • Samples 1 and 2 might also come with alternate streams for interior sounds, though they aren't mandatory
      ocar.bnk
      Opponent car sound bank
      1. Engine accelerating [0]
      2. Horn [3]
      • Samples are looped
      ocard.bnk
      Opponent car sound bank (for Dolby sound, perhaps?) same as ocar.bnk
      same as ocar.bnk
      scar.bnk
      Player 2 in split-screen bank
      same as car.bnk
      same as car.bnk but all samples are mono


      NFSHS car sound structure (CLK-GTR sounds files)

      File Description Samples [streams] Notes
      careng.bnk
      Player car sound bank
      1. Gear shift [2]
      2. Horn [3]
      3. Idle (decelerating) [32]
      4. Low-RPM (decelerating) [33]
      5. Mid-RPM (decelerating) [34]
      6. High-RPM (decelerating) [35]
      7. Idle (accelerating) [48]
      8. Low-RPM (accelerating) [49]
      9. Mid-RPM (accelerating) [50]
      10. High-RPM (accelerating) [51]
      11. Idle (decelerating, interior) [64]
      12. Low-RPM (decelerating, interior) [65]
      13. Mid-RPM (decelerating, interior) [66]
      14. High-RPM (decelerating, interior) [67]
      15. Idle (accelerating, interior) [80]
      16. Low-RPM (accelerating, interior) [81]
      17. Mid-RPM (accelerating, interior) [82]
      18. High-RPM (accelerating, interior) [83]
      • All samples except 1 are looped
      • Samples 11 to 18 are normally stereo but mono samples can be used without issues
      ocareng.bnk
      Opponent car sound bank
      1. Engine accelerating [0]
      2. Horn [3]
      • Samples are looped
      scareng.bnk
      Player 2 in split-screen bank
      same as careng.bnk
      same as careng.bnk but all samples are mono
      careng.ltb
      careng.ctb
      presumably lookup tables for the (s)careng.bnk files



      Sample requirements

      NFS3/NFSHS audio samples do have some requirements in order to work correctly, mostly due to sound memory constraints. Such requirements are:
      • 22050 Hz sample rate
      • Can be mono or stereo
        • Stereo samples should be pitched down 50% compared to mono
      • Max length of samples vary per game but rule of thumb is to not exceed 1.2 seconds (NFSHS maximum) for mono samples, stereo samples are around half of that.

      In general terms, working with mono samples is easier than with stereo samples because of the latter two points.


      Why it was a massive PITA to get decent sound loops... until now

      (this is a rather lengthy theoretical part, so buckle up)
       
      In the simplest terms, it's because the sole program (until very recently) that could work with BNK files (NFSWizard) is ancient jank. NFS Wizard for some forsaken reason corrupts each audio sample at the beginning upon closing a BNK file; it appears it inserts some additional sample info data but it "pushes" audio data forward by fractions of a second, leading to the end of each sample "stomp" on the beginning of the next, creating a noticeable "click" on playback. That's why it was often advised to import all samples again every time you open a BNK file.

      Making matters more complicated, the sample looping interface in NFSWizard is just a couple of sliders; you can't punch the value you need there, hence it's very imprecise. The combination of both factors made getting loops right a near endless game of trial and error.

      However, not all is lost. As mentioned before, the end of each sample stomps on the beginning of the next one; that means one could put a bit of silence at the end of each sample so the "click" is (mostly) avoided. But that's not all: the loop points still have yet to be set and they can't be set precisely... unless you are willing to do some hex editing magic, like I did. 

      First I looked over into the Sample Info tab of NFSWizard to see if the loop info is there. After moving the loop points and looking at the tab, I found the two addresses that correspond to the loop points:  

      Then I exported the BNK file and opened it with a hex editor. I searched the addresses with the values, and lo and behold there are:

      Each looped sample has 2 addresses of 4 bytes each, one starts with 86 and the other with 87: these correspond to the loop points. The part we're interested is this one:

      "What the hell is a wave sample?", you might ask. Well, a wave sample is the basic unit of sound which varies with the sound frequency: in a 1 second-long 22050 Hz sound there are 22050 samples, for example. Which means 22 wave samples is equivalent to 0.001 seconds... which is about the amount the NFS3 samples get "shifted" around. (NFSHS sounds get shifted by 28 wave samples).

      Now you see the number I pointed out in red doesn't read 22 or anything of the sort, that's because it's a hexadecimal number; you have to convert your decimal numbers to those. Windows Calculator has a programmer mode that allows for such thing, so punching 22 in decimal mode should yield "16" in hexadecimal (or "1C" for 28). Changing the bytes in the space I pointed out to 00 16 and saving in the hex editor will set the starting loop to 22 wave samples (the end loop can be just be dragged all the way to the end in NFSWizard) and now I can import it back to NFSWizard.

      Do you have to do this for this tutorial? No, luckily for you I have uploaded sets of edited BNK files with the starting loop points fixed, linked above (or just use Vivianne, lmao). Though you might want as well to use the BNK horn loop tweaker for setting the horn samples precisely if you're using NFSWizard.

      Enough theoretical babble, let's get onto sourcing a sound sample.


      Step 1: Sourcing your samples

      You'll need to get your sounds from *somewhere* (duh), however there are a couple of considerations to take to get a decent sound:
      • You'll need to get a sound sample that's clean as possible. That means no echoing, no distortions, no foreign sounds like wind/road noise, etc.
      • It needs to be as steady as possible for at least 0.5-0.6 seconds; relatively minor pitch changes (such as accelerating/decelerating down a road) can be corrected with the Sliding Stretch tool.
      • If you can, get both acceleration and deceleration sounds. Otherwise just the acceleration sounds might suffice.

      Regardless, you can get your sounds by either recording them from another videogame (using OBS, Xbox Game Bar or Audacity's built-in loopback recorder) or by ripping it from some online video. In case you want to record it from another videogame, here's an excerpt adapted from Zpectre's first tutorial linked above:

      If you are using an analog device (like a gamepad or steering wheel), you first need to assign the throttle command to the Y axis. When the game asks you which key/button/command you want to use for the throttle, move the stick forward (I guess you all know how to do it) or press the right trigger. If you have a wheel, just use the pedals. After you customize your controls, start a race using manual transmission. When you are in control of the car, leave it at neutral gear. Now start pushing the throttle slowly until you reach an RPM value that is 1000-2000 RPM lower than the max RPM for the car (this gives better sounds). When you reach the value you want, keep the tachometer at it, then begin to record your sound. Make a 5-10 seconds long video, then stop recording.

      The second method is suitable for keyboard users and for some games which make distinction between engine and exhaust samples (like NFSU2 and NFSMW). You need to find a track with a section where the car will keep accelerating for some seconds, but won't increase RPM any further (for example, the small ramp before the first tollbooths in NFSMW's City Perimeter track). Start a race with the car you want on the track you think will be best to record sounds on, preferably with manual transmission (so you have more control over the RPM ranges). Before you reach the part of the track where the RPM will remain constant, start to record, then end it after you get the sound you wanted.
      Also it's worth adding:
      • As long as it's possible try to turn down all sounds that aren't the engine sound. In some cases you might have to mod the source game to achieve that.
      • Try to avoid recording supercharger/turbocharger sounds because they won't sound good on idle/lower revs. Again, try to turn them down/remove them. However, for NFSHS, you can also record one sound with supercharger/turbo and one without them for use with high/low rpms, respectively.
      • Avoid driving through tunnels and overpasses, the resulting echo effect can affect quality.
      • To use Audacity's loopback recorder, set the Host to Windows WASAPI, Recording Channels to "1  (Mono)", Project Sample Rate to 22050 Hz and Playback/Recording Device to your speakers or headphones (whichever is plugged) in Audio Settings. Then you can hit the Record button in the toolbar to start recording.
      • The resulting sounds might not be 100% accurate to the source sound, that's due NFS3/HS relatively primitive sound engine.

      If you're going to source sounds from internet videos, then you might have to do some legwork to get a decent one because many are not quite optimal. Flyby and dyno videos might give you a better chance but they might require additional editing that won't be covered in this tutorial. 


      Step 2: Preparing your base sounds

      Once you have your sound recorded/imported, it's time to make your base sounds. Just in case, save them as an Audacity project. Select 0.5-0.75 seconds of your recorded sounds and copy them into a new project. Then select the entirety of newly pasted sound and apply the following effects:
      • Volume and Compression > Amplify
        • Default values are usually fine but you can check the Allow clipping checkbox and set the Amplification value 1-2 dBs higher than the default
      • Volume and Compression > Limiter (or Legacy Limiter if you're on 3.6.2 and above)
        • Set Type to Soft Clip and Apply Make-up Gain to Yes
      • If you're working with a unsteady sound (like one from an accelerating/decelerating car) you can use Pitch and Tempo > Sliding stretch before using the Amplify and Limiter effects
        • Usually a value of (-)1 to (-)5 percent on one end does even out the sound.
      • Also if you want to make an interior engine sound out of your sound you can use EQ and Filters > Bass and Treble for that before using the Amplify and Limiter effects.
        • Usually a 15%-20% treble value does the job
      • In recent versions of Audacity, sections that peak too much ("clipping") will be shown as a red line; you can use Legacy Limiter in Hard Limiter mode to get rid of them
      After that you have to set the pitch of the base sample with Effects > Pitch and Tempo > Change speed and pitch; your target is what would sound best when played at 140% speed (NFS3) or 135% speed (NFSHS); the Playback-at-Speed toolbar pretty much helps with that. As a rule of thumb, here are the percent changes you'll usually have to use per game:
      • NFS3: -30 to -35 percent change
      • NFSHS: -15 to -25 percent change
      Sometimes after applying speed/pitch changes might result in distotions such as crackling or clipping; if that's the case, undo the speed/pitch change, use Volume and Compression > Amplify with a value of -0.5 to -1, apply speed/pitch changes again then use Legacy Limiter in Hard Limiter or Soft Clip mode to bring volume back up.

      When you're done, select your whole track, press Z to set the selection to zero points (the black line that's in the middle of the wave, this is important since that would avoid -most- instances of clicking), press Ctrl+T to trim the track and go to Tracks > Align Tracks > Start to zero to get rid of the empty space it might make. You might also want to delete any remaining sound after the 0.75 second mark by selecting it and pressing Ctrl+K.

      Save your base sound as an Audacity project because you will need to get back to it, especially if you're making a NFSHS sound


      Step 3: Making the engine sounds

      With the base sound done, copy it and paste it into a new project. Copy and paste it again, but in a new track this time and reverse it with the Special > Reverse effect. Move the new track towards the right and make sure there's at least a 0.2-0.25 second overlap between the tracks, like this:

      Also make sure the waves "match" as possible in order to not get your sound muted at the middle after the next step, you might want to zoom in with Ctrl+mouse wheel to check.

      Next select the overlapping parts of the tracks like this...
      ...then go to Effects > Fading > Crossfade tracks, set Fade TYPE to Constant Power 1 and click OK.

      Try out the track loop by selecting all tracks, enable looping by pressing L and set the loop to selection by pressing Shift+Alt+L and play it back. If you hear any noticeable click/gap, you can do any of the following:
      • Go back to the beginning of this step, select one bit of the beginning (mind the zero points), delete it with Ctrl+K and do the whole process again.

        -OR-

      • Use the Special > Invert effect on the reversed track.

      If you're using NFSWizard for importing the sounds: select your track, press the End key to bring the cursor to the end of the track, go to Generate > Silence, click on the arrow next to the Duration field to open the dropdown menu and select hh:mm:ss+samples. Set Duration to 00h 00m 00s + 00022 samples (for NFS3) or 00h 00m 00s + 00028 samples (for NFSHS) and click Generate . Select all tracks and press Ctrl+J to join them.


      Export your track by going to File > Export Audio , give it a filename and select a location to save it in, set format to WAV (Microsoft), set Channels to Mono, Sample Rate to 22050 Hz, Encoding to Signed 16-bit PCM and Export Range to Current Selection. Click on Export to export the file. 

      For opponent car sounds you can select the track, go to Effects > Volume and Compression > Amplify and use a -2 to -3 dB amplification so your opponent sounds don't drown the player's.

      For NFS3 you can proceed to the next step, but for NFSHS you have to make the rest of the sounds (mid, low, idle). Go back to the beginning of this step and proceed to do the following:
      • Select your track and go to Effects > Pitch and Tempo > Change speed and pitch. Apply the following percent changes for the following:
        • -20 for the mid-rpm sound
        • -40 for the low-rpm sound
        • -60 for the idle sound
      • (If needed) Press Z to set selection to zero points, trim it with Ctrl+T and align tracks to zero
      • Select any remaining sound past the 0.75 second mark and delete it with Ctrl+K

      Then proceed as usual.

       

      Step 4: Importing samples to the BNK file

      If you're using Vivianne:

      1. Open your car.viv file.
        • For best results, use the edited BNK files; open the file containing the edited BNKs in Vivianne, export all the files. Then open your car.viv file and import the files you exported by clicking on the + button on the file list of the left.
      2. Open the CAR.BNK/CARENG.BNK file. Select the first engine sound stream, click on Import and import your sample.
      3. Click on Add audio padding and add a padding of 1. This is because currently Vivianne does not write the loop start data if it's set to 0 and it might break the file.
      4. Repeat this process for the rest of the engine sound streams in the BNK file. For streams 64 to 83 (interior accel/decel sounds) you might want to use the Inject padding bytes button with their default values to avoid breaking the file. Save the BNK file.
      5. Repeat steps 2 and 3 with the opponent (OCAR/OCARGENG) BNK file.
      6. Once done, you can duplicate the CAR/CARENG.BNK file into a SCAR/SCARENG.BNK file for splitscreen player 2 sounds and for NFS3, the OCAR.BNK into OCARD.BNK. Save your car.viv file, you're done.

      If you're using NFS Wizard:

      1. Open the .VIV file containing the edited BNKs and your car.viv file in NFS Wizard. Go to Window > Tile Vertically to set both windows side to side and drag the files from the edited file's VIV to your CAR.VIV.
      2. Close the edited BNKs .VIV file and open the CAR.BNK/CARENG.BNK file. Select the first engine sound, right click on it and make sure Show Loop is enabled. Press Ctrl+I to import a sound file and select your engine sound.
      3. Once imported, click and drag the ending loop marker all the way to the right edge of the window.
      4. Repeat this process for the rest of the engine sound samples in the BNK file and close it. Then repeat this step with the opponent (OCAR/OCARGENG) BNK file.
      5. Once done, you can duplicate the CAR/CARENG.BNK file into a SCAR/SCARENG.BNK file for splitscreen player 2 sounds and for NFS3, the OCAR.BNK into OCARD.BNK. Save your car.viv file, you're done.
      Remember that if for some reason you have to reimport samples, you have to reimport all of them, so it's advised to have the gear shift and horn samples exported at hand.

      That's it for this tutorial, hope you get neat sounds out of it. See you around!

      Tuesday, January 3, 2023

      How to make NFS3 photo album slides

      In this tutorial you will learn how to make photo album slides for your car in a style that's quite close to the one used in the vanilla game's ones.

        Stuff you'll need

        • GIMP [portable] - image editor (version 2.10 shown; while you will still be good if you're using the latest version -3.0.4 at the time- you can use the GIMP 3 version of the template instead, which has several filters pre-applied as non-destructive effects)
        • My NFS3 photo album templates
        • FSHTool -JimD's version- [download] - QFS/FSH file unpacker/packer, for slides and vidwalls; JimD's version allows for packing resized bitmaps without having to edit the index.fsh file for that

        GIMP's user interface

        If you're not famliarized with GIMP, I will give you a quick rundown of the UI so you can get yourself acquainted with it. Here's the default UI for version 2.10


        1. Toolbox: here's where you will find most of the tools used for editing, like selection, paintbrush, bucket fill, text, etc. By default tools are grouped into several groups (which are indicated by the small arrows on the bottom right of the buttons); to select another tool in the group, right-click on the button to display the available tools in that tool to select them. Also, you can select the foreground and background colors (the black and white squares, respectively)
        2. Tool options/Information/Undo history/Recent files tabs: for this tutorial we're just going to focus on the Tool options; here's where the selected tool's parameters can be configured.
        3. Brushes/Patterns/Fonts/Messages tabs: not important for this tutorial.
        4. Layers/Channels/Paths tabs: here's when you can manage the image layers, channels and paths. We'll just focus on layers. 

        Step 1: Uncompressing the .qfs files

        1. Unzip FSHTool into a folder 
        2. Copy the FEDATA.FSH you extracted and at least 2 fedata\art\showcase\sl<car id>##.qfs file from the game's folder into the FSHTool folder.
          • <car id> stands for your car's FEDATA ID (i.e. F355)
          • The ## stands for the slide number, 01 is the first slide which is styled differently from the rest and it's what enables the photo album feature for your car.
          • Copy more sl<car id>##.qfs if you want to add more slides
        3. Now drag the files you copied into the FSHTool.exe file to uncompress them; a new folder with the file name will be generated for each file. 

         

        Step 2: Making the first slide

        1. Unzip the contents of the templates zip file to a folder and open the nfs3_photo_1st_slide_template.xcf file in GIMP. Select the wheel layer in the back group by clicking on its name in the Layers pane.


        2. Get an image of your car's side (focusing on it's wheels, preferably), open it in GIMP, copy it and paste it on the template's wheel layer


        3. Pick the Unite Transform (Shift+T) tool and resize the layer you pasted until the wheel covers both top and bottom of the area between the base (and then some) by clicking and dragging on the squares alongside the logo's border (you can lower the Image Opacity parameter to 50 in the Tool Options pane to help yourself); Ctrl-click and dragging them will resize the layer while keeping it centered. You can also move the layer by just clicking and dragging it. Once you're done, press the Transform button or press the Enter key, then press the anchor button in the layers pane (or press Ctrl+H) to anchor the pasted selection to the layer below. You can zoom in or out as needed with Ctrl+mouse wheel or the +/- keys.


        4. Adjust the contrast by going to Colors > Curves. Make sure it's set to Value and move the points to adjust brightness and contrast; lower-left point controls the darker colors -if you move it upwards it will make the dark colors brighter; if you move it towards the right it will make them darker- and the upper-right one controls the brightest colors -if you move it downwards it will make them darker; if you move it towards the left it will make them brighter-. Click OK to apply the adjustments. Right click on the wheel layer and click on Layer to Image Size when you're done.
          • You can also add points by clicking in any point of the curve and dragging for more precise control.


        5. Select the color layer and pick the Bucket Fill (Shift+B) tool; then pick the foreground color of your preference (I will be picking the #ffc44c [HSV 40,70,100] color for this one) and click anywhere on the layer to color it.


        6. Select the make_bg layer, then get a logo with transparency (preferably a black monochrome one) of your car's manufacturer, open it in GIMP, copy it and paste it on the template's make_bg layer. Then pick the Unite Transform (Shift+T) tool, then resize and move the logo to the left and middle of the background. Once you're done, press the Transform button or press the Enter key, then anchor the pasted selection to the layer below.
          • If you only have access to a black and white logo with no transparency, you can use the Colors > Color to Alpha command to make the background color transparent
          • If your logo comes in other color than black, you can lock the transparency by clicking on the checkerboard button above the layer list and fill it up with black by picking the Bucket Fill (Shift+B) tool and shift clicking on the logo to color it.
          • If the logo is just a part of your source image, you can select it with the Rectangle Select (R) tool, copy it, paste it, unlock the transparency then crop off the empty borders with Layer > Crop to Content, cut it and paste it on the template.


        7. Select the car layer and paste a pic of your car in there, preferably a front 3/4 angle pic of it. Then use the Unite Transform (T) tool to resize, rotate (by clicking and dragging outside of the selection) and move the car layer to the lower right zone (right up to rear wheel going past the image edge) , then anchor the layer with Ctrl+H. Then adjust the contrast with Colors > Curves.
          • You'll need a pic with transparency (that means, without background) of the car you're making for this one. You can use GIMP's own Foreground Select and Quick Mask features to select the image's foreground, then invert the selection and delete the background. There are also background removal apps such as the one provided by DepositPhotos that you can use.
          • You can also apply curves in different channels (such as red, green, blue, alpha, etc) for different effects, like I did here: I changed the image tone using the rim color as a base (if you click on a part of the image while in the Curves dialog it will pick the color you clicked on as a sample which will displayed as a vertical line) and reduced the blue channel value while raising the values on the red channel to make the image tone match the background.


        8. Select the mk layer in the make group, paste the manufacturer's wordmark (word logo) into it, use the Unite Transform tool to resize it and move to near the upper left corner and anchor it with Ctrl+H. Then lock the transparency by clicking the third upper button in the Layers pane, pick the Bucket Fill tool, choose a HSV 0 0 50 gray, hold Shift and click on the layer to paint it entirely with gray.


        9. Duplicate the mk layer with the Duplicate button (the one pointed at with a red arrow) on the Layers pane, press F2 and rename the layer to mk_shine, then move it under the mk layer on the Layers pane by either dragging or clicking on the Move Layer Down button (the one pointed at with a green arrow). Pick the Bucket Fill tool, pick a white color for the foreground and Shift+click to paint it all white. Pick the Move (M) tool, then Shift+click and drag the layer 1 px to the top and left.


        10. Repeat the above process for the shadow, but painting it with off-black (HSV 0,0,5) and moving it 1px to the bottom and right


        11. Hide the make group by clicking on the eye icon next to it. Repeat steps 9 and 10 for the model group layers, but with the model's logo


        12. Select the color layer of the logos group, pick the Bucket Fill tool, select a foreground color (I will be picking #ffc44d [HSV 40, 70, 90]) and click on the layer to paint it


        13. Hide the logos group. You're done with the first slide, but now you'll have to export it's parts (background, model logo and make logo)


        14. To save the background, go to File > Export (Ctrl+E) or File > Export As (Ctrl+Shift+E). Save it as 0000.bmp in the sl<car id>01 folder of the qfs file you uncompressed with FSHTool. When the export options dialog shows up, use the settings shown below and click on Export

        15. Unhide the logos group, hide the model group within it and unhide the make group. Pick the Rectangle Select (R) tool and select the upper left area where the logo is.


        16. Copy the visible selection with Ctrl+Shift+C and paste it as a new image with Ctrl+Shift+V. Export the newly pasted image as 0002.bmp in the sl<car id>01 folder with the same settings as the previous step.


        17. Go back to the template file and repeat steps 15 and 16 for the model logo


        Step 3: Making the rest of the slides

        1. Open the nfs3_photo_slides_template.xcf file in GIMP. Select the image layer.


        2. Open the pic you want to use as a slide, go to Image > Scale Image and resize it to 640 pixels wide.


        3. Copy the image, go back to the slide template and paste it over the image layer, then pick the Move tool and Ctrl+drag (to move it alongside the image's edges) the image up or down until your desired position.


        4. Press Ctrl+Shift+N to make your pasted image into a new layer.


        5. To save the slide, go to File > Export (Ctrl+E) or File > Export As (Ctrl+Shift+E). Save it as 0000.bmp in a sl<car id>## folder of the qfs files you uncompressed with FSHTool. When the export options dialog shows up, use the settings shown below and click on Export


        6. Repeat this process for each additional slide you want to make.
           

        Step 4: Compiling the logo and slide files and setting them in-game

        1. Go to each sl<car id>## folder and drag the index.fsh file into the FSHTool executable (you might need to open a second window to do this)
        2. Copy the sl<car id>##.qfs files and paste them into the fedata\art\showcase folder of NFS3

        And that's it! This is how you can make NFS3-styled photo albums. Hope this tutorial has been helpful. 


        See you around!