Difference between revisions of "PATH"

From GTAMods Wiki
Jump to navigation Jump to search
(Flags)
Line 24: Line 24:
 
|}
 
|}
 
'''''Note:''' I (Swoorup) believe that the maximum value for this speed limit is 3 since its storage is limited to 2 bits''
 
'''''Note:''' I (Swoorup) believe that the maximum value for this speed limit is 3 since its storage is limited to 2 bits''
 +
 +
 
'''Flag 2, Vehicle Travel/Roadblock'''
 
'''Flag 2, Vehicle Travel/Roadblock'''
  

Revision as of 15:03, 28 May 2012

PATH (IPL section)
IPL Sections:
2DFX AUZO BLOK CARS CULL ENEX GRGE
INST JUMP LINK LODM MLO+ MULT OCCL
PATH PICK RTFX SLOW TCYC VNOD ZONE

Paths in Vice City are grouped into nodes, each with at most 12 sub-nodes. The group nodes define the type of vehicle going to be used by the sub nodes. Sub nodes contain path coordinates which are linked to each other. There are two kinds of links:

  • internal links – connecting nodes within the same group.
  • external links – connecting nodes over two different groups.

Description of the Vice City paths system

First of all, consider a small segment of the line in a group node. The group node has to be defined and then there are the 12 sub-nodes inside it. The number of coordinates vary from 2 to 12. If the number of coordinates does not reach 12, then they are filled with null nodes which does not do anything just to make the group node hold always 12 nodes. The internal and external sub nodes are defined each with a special attribute in it. The internal sub nodes are the middle parts of a segment of the line, while the external sub nodes are the end points of the segment of the line. They are used to connect to other external sub-node or end point of another segment (another group) of the line. To connect the external sub-nodes or end points, they must and always must have the same coordinates. All the other group nodes link up together using this concept, thus you get a path which a vehicle or a ped follows from the beginning and to the end of the line. Spawns are made in the external nodes (always remember that fact) and then they follow the route of the line.

One can add a maximum of 24 group nodes in Vice City though this limit can be increased by Maxorator's Path hacks. [1]

Flags

The last three numbers at the end of a paths line are the Flags, each ones can define a special function.

Flag 1, Node Speed Limit

Flag 1 has been identified as a Speed function. It specifies the speed of NPC Vehicles travelling in the node

0 Slow Vehicle Speed
1 Average Vehicle Speed
2 Fast Vehicle Speed

Note: I (Swoorup) believe that the maximum value for this speed limit is 3 since its storage is limited to 2 bits


Flag 2, Vehicle Travel/Roadblock

Flag 2 has been identified as a controller for where some vehicle can travel and where Police Roadblock will spawn.

Note: Police Roadblock will only work if it is a Vehicle node with that Flag.

Note: Specified Vehicles Only, means that only Vehicles with a Specified flag will use the Paths.

0 No flags
1 Node Ignored By Traffic
2 Police Roadblock Spawns
4 Restricted Node

Note: Although 8 seems to be used in most of the boat paths, it does not do anything and its function is same as that of setting the flag to 0

Flag 3, Spawn Rate

Flag 3 is supposably used to control the Spawn rate of Vehicles on that path but people have not noticed a difference. The spawn frequency can range from 0.0 to 1.0

Setup of a VC Paths Line

 iNodeType, iNextNode, bIsCrossRoad, fX, fY, fZ, fMedian, dwLeftLanes, dwRightLanes, dwSpeedLimit, dwFlags, fSpawnRate

Note: bIsCrossRoad is a boolean value which denotes if there is a cross road in the imaginary line joined by two nodes.

Tools and scripts

External links