Fandom

Need For Madness Wiki

Hacking Tracks

291pages on
this wiki
Add New Page
Comments20 Share

Hacking Tracks is one of the easiest type of Hacking/Editing, as it requires no extracting, image editing, or file renaming. However, it is still very easy to crash the game if the edit goes wrong, and thus those who try should be aware of should be careful and in some cases, make backups.

BackgroundEdit

Track Editing can be used to make minor, major, or fundamental changes to certain stages. Variables like names, laps and lighting can be altered, pieces can be added or moved, and the track can be redesigned from scratch, it's all made from numbers.

How do we hack tracks?Edit

See also: Tutarial how to hack need for madness tracks

The steps for hacking is relatively easy, as shown.

  1. Open the Need For Madness folder.
  2. Go to the stages (tracks for NFM2) folder.
  3. There should be a number of .txt files. If it's the first Need For Madness game, there should be 11 .txt files for each stage. Need For Madness 2 has 17 .txt files.


New Picture (1)

ExampleEdit

A typical code file looks something like below. Lines in red will be explained below.
snap(20,-30,-60)[1]

sky(200,227,255)
fog(215,245,220)

ground(195,210,217)[2]
polys(190,208,224)[*]

fadefrom(7000)[3]

name(The Mad Party)[4]

nlaps(1000)[5]
lightson()[11][*]

set(15,0,0,0)p


set(15,0,5600,0)[6]
set(15,0,11200,0)p
set(15,0,16800,0)p
set(20,0,22400,0)p
set(14,0,26950,-90)p


chk(40,-1750,26950,90)[7]
set(14,-3500,26950,0)p
set(10,-3500,22400,0)p
set(10,-3500,16800,0)p
set(10,-3500,11200,0)p
set(10,-3500,5600,0)p
set(20,-3500,0,0)p
set(17,0,-4550,180)p
chk(42,-1750,-4550,90)
set(33,0,11200,180)
set(32,-3500,11200,180)
set(17,-3500,-4550,90)p


fix(41,0,19000,-1500,0)s[8,9]
fix(41,0,19000,-1000,0)s
fix(41,0,19000,-2000,0)s


set(37,-1750,-3000,90)
set(37,-1750,0,90)
set(37,-1750,3000,90)
set(37,-1750,6000,90)
set(37,-1750,9000,90)
set(37,-1750,12000,90)
set(37,-1750,15000,90)
set(37,-1750,18000,90)
set(37,-1750,21000,90)
set(37,-1750,24000,90)


maxr(8,3000,-6000)[10]
maxb(2,-8400,-4200)
maxl(8,-6600,-6000)
maxt(2,30000,-4200)



ExplanationEdit

Each line has a function.

  • 1: Denotes the lighting conditions in RGB. For example, a 0,0,0 value leaves all values at default, whereas a -80,-40,30 value would strongly bias towards blue and away from red and green.
  • 2: "sky", "fog", "ground" and "polys" (NFM2 only) are the RGB colors of the sky, horizon, open ground and ground texture respectively. Caution: applying values that are too different from each other on the sky and fog makes the blending rather poor.
  • 3: The draw distance in units. Objects beyond this do not appear. Do not make large or small unless necessary.
  • 4: The Stage name. If left blank, it will be named 'hogan rewish'.
  • 5: The number of laps required to complete the stage by racing.
  • 6: A track piece. More on that below.
  • 7: A checkpoint. More on that below.
  • 8: Enables a track piece to be like the Fixing Hoop (#41 as default). More on that below.
  • 9: An AI directive, telling the AI cars what to do. "p" for straight, "pr" for jump. "pt" for a turn, "po" for the ramp to get to the fixing hoop (A new function in NFM2), "ph" for quarterpipes, "s" for the hoop.
  • 10: These four lines set the bounding walls, in this case right, back, left, and front ("to"), respectively. The first number is the length, the second is the actual distance from the starting point (in terms of x or y coordinates, see below), and the last is the starting point of the wall. While it is possible and permitted to have more than one of each wall, it is not recommended. It is also possible to use one kind of wall in another's place, but it is also not recommended, as each are "opaque" to movement from one side only.
  • 11. Lights on the cars (if coded with lightF/lightB) will turn on if this feature is enabled [NFM2 only]

Note: [*] NFM2 only.

More Detail on Track ItemsEdit

Track piecesEdit

Track pieces are identified and placed with a special set of numbers. A standard piece is place with "set(ID,x,y,r)", The x and y are their coordinates relative to the player's starting position. x is the left-right direction, y is the front-back direction. Positive x and y are right and forwards respectively. The distances are measured in arbitrary units. For a sense of scale, one track piece is about 2400x by 5600y, and the average car (not EL KING or MASHEEN) is about 600 long.

CheckpointsEdit

A checkpoint follows the same code as other Track pieces, with the word "chk" used instead of "set".

The HoopEdit

The Hoop follows the "fix(ID,x,y,-z,r)" code. The r value is the rotation in degrees. Negative values are allowed, as are angles >360. However, there is no functional difference from their "[0,360]" counterparts. Positive rotations rotate an object counterclockwise when viewed from above.

The z value is height, and only applies for the hoop. Oddly, it must be preceded by a negative sign, indicating that positive z would be down into the ground. Needless to say, 0 is ground level, where -500 is low, and -10000 very high.

OthersEdit

When placing boundary walls, there is only one coordinate; it is used for x or y depending on the wall type (maxt and maxb use y, maxl and maxr use x). Sign conventions and distances are the same.

The ID number identifies the type of piece used. Each piece - including checkpoints - has its own unique ID. The ID numbers are as follows at default:

  • 0 [-6][*] = Tornado Shark model (does not move or interact)
    • 0 = Lead Oxide model (does not move or interact) [For NFM2 only]
  • 1 [-5][*] = Formula 7 model (does not move or interact)
    • 1 = Kool Kat model (does not move or interact) [For NFM2 only]
  • 2 [-4][*] = Wow Caninaro model (does not move or interact)
    • 2 = Drifter X model (does not move or interact) [For NFM2 only]
  • 3 [-3][*] = La Vite Crab model (does not move or interact)
    • 3 = Sword of Justice model (does not move or interact) [For NFM2 only]
  • 4 [-2][*] = Nimi (does not move or interact)
    • 4 = High Rider model (does not move or interact) [For NFM2 only]
  • 5 [-1][*] = MAX Revenge model (does not move or interact)
    • 5 = EL KING model (does not move or interact) [For NFM2 only]
  • 6 = Lead Oxide model (does not move or interact)
    • 6 = Mighty Eight Model (does not move or interact) [For NFM2 only]
  • 7 = EL KING model (does not move or interact)
    • 7 = MASHEEN model (does not move or interact) [For NFM2 only]
  • 8 = Radical One model (does not move or interact)
  • 9 = DR Monstaa model (does not move or interact)
  • 10 = Long, paved track (regular)
  • 11 = Railings
  • 12 = Long, paved track at an angle to the right
  • 13 = Long, paved track at an angle to the left
  • 14 = Paved turn (right turn at 0 degrees)
  • 15 = Long, offroad track
  • 16 = Long, bumpy grass track
  • 17 = Offroad turn (right turn at 0 degrees)
  • 18 = 'Halfpipe' paved track
  • 19 = 'Halfpipe' paved track with a right curve
  • 20 = Long, track going from offroad to paved
  • 21 = Long track going from offroad to 'Halfpipe' paved
  • 22 = Short, track going from paved to 'Halfpipe' paved
  • 23 = Paved track end
  • 24 = Offroad track end
  • 25 = Paved track segment
  • 26 = Standard Concrete Ramp [Basic Ramp]
  • 27 = Wall-sided Ramp  [Crash Ramp]
  • 28 = Two Way Ramp - dual-sided
  • 29 = Split Ramp [Two Way High-Low Ramp]
  • 30 = Landing Ramp
  • 31 = Giant Ramp [Big-Takeoff Ramp]
  • 32 = Small Paved Ramp
  • 33 = Speedbump
  • 34 = Large Offroad Ramp
  • 35 = Small Offroad Ramp
  • 36 = Quarterpipe
  • 37 = Spikes
  • 38 = Frame/Hurdle (single)
  • 39 = Fake track border segment (aka fake wall)
  • 40 = Blue Checkpoint
  • 41 = Fixing Hoop
  • 42 = Purple Checkpoint
  • 43 = Offroad Bumpy Sides[*]
  • 44 = Offroad Bumpy Sides Start[*]
  • 45 = Paved Raised Ramp[*]
  • 46 = Paved Raised[*]
  • 47 = Paved Start Road[*]
  • 48 = Offroad Start Road[*]

Note: [*] NFM2 only.

NotesEdit

  • Stages can vary widely in size and complexity, but large stages may run or load slowly.
  • There is a maximum to the total number of pieces allowed, plus a maximum per category. Placing extra pieces will cause a failure to load the stage, unless the stage limit has been increased via Java Editing.
  • Track pieces may intersect without errors, but it is not recommended since the AI may act strangely around that "double collision".
  • ITrack pieces may be placed outside the boundary walls as far as desired.
  • Comments are allowed in the track files. They can accept either the "# comment" or the "// comment" forms, as per the Java coding language.
  • IF YOU ARE STARTING, USE ONLY SET IDs 10(paved road), 14(paved turn), 40 or 42 (blue & purple checkpoints), and some ramps (26,31,30,etc.)sm.

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.