Difference between revisions of "CARS (IPL Section)"
m (→Binary format) |
|||
Line 9: | Line 9: | ||
== Format == | == Format == | ||
− | ''CARS'' | + | ''CARS'' is used to place car generators (parked cars) permanently, randomly or limited, around the game world. For this they need a position, a rotation, information about which car should be placed, the car's colors and some additional information. |
=== San Andreas === | === San Andreas === | ||
Line 25: | Line 25: | ||
|<center>CarID</center>||The ID number of the car as defined in the [[IDE]] or -1 for random car parks (influenced by the <code>[[popcycle.dat]]</code> file) | |<center>CarID</center>||The ID number of the car as defined in the [[IDE]] or -1 for random car parks (influenced by the <code>[[popcycle.dat]]</code> file) | ||
|- | |- | ||
− | |<center>PrimCol, SecCol</center>||A car color defined in the <code>[[carcols.dat]]</code> file. If it is set to -1 the color will be randomly | + | |<center>PrimCol, SecCol</center>||A car color defined in the <code>[[carcols.dat]]</code> file. If it is set to -1 the color will be randomly chosen. |
|- | |- | ||
|<center>ForceSpawn</center>||Vehicles spawn more reliably if this is set to 1. | |<center>ForceSpawn</center>||Vehicles spawn more reliably if this is set to 1. | ||
Line 46: | Line 46: | ||
4b - INT32 - Object ID (an index to an [[CARS_(IDE_Section)|vehicle definition]]) | 4b - INT32 - Object ID (an index to an [[CARS_(IDE_Section)|vehicle definition]]) | ||
4b - INT32 - Primary color | 4b - INT32 - Primary color | ||
− | 4b - INT32 - | + | 4b - INT32 - Secondary color |
4b - INT32 - Force spawn (Windows BOOL - see ''<code>WinDef.h</code>'') | 4b - INT32 - Force spawn (Windows BOOL - see ''<code>WinDef.h</code>'') | ||
− | 4b - INT32 - Alarm | + | 4b - INT32 - Alarm probability |
− | 4b - INT32 - Locked | + | 4b - INT32 - Locked probability |
− | 4b - INT32 - Unknown1 (Could be | + | 4b - INT32 - Unknown1 (Could be tertiary color) |
− | 4b - INT32 - Unknown2 (Could be | + | 4b - INT32 - Unknown2 (Could be quarterdeck color) |
=== GTA IV === | === GTA IV === | ||
{{Research}} | {{Research}} | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
== References == | == References == | ||
{{note|1}} {{Icon|SA}} [[Saves_(GTA_SA)#Block_12:_Car_Generators|Car generators in save files]]<br> | {{note|1}} {{Icon|SA}} [[Saves_(GTA_SA)#Block_12:_Car_Generators|Car generators in save files]]<br> | ||
− | {{note|2}} {{Icon|SA}} [[ | + | {{note|2}} {{Icon|SA}} [[Spawn a vehicle#... car generator opcode|Creating a parked car generator]] via scripts. |
== External link == | == External link == |
Revision as of 04:31, 12 September 2010
Short description: | Creates a parked car generator | |||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Supported games: | GTA SA, GTA IV | |||||||||||||||||||||
IPL Sections:
|
CARS is a section in the item placement file introduced in San Andreas. This section is a simplified method to create parked cars. Usually parked cars are created by the scripts, but just as unique stunt jumps they can be written inside plain text or binary IPLs. Since parked car generators are related to savegames[1] a new game must be started before they are applied to the game. It is possible to create parked car generators without starting a new game using CLEO[2].
Format
CARS is used to place car generators (parked cars) permanently, randomly or limited, around the game world. For this they need a position, a rotation, information about which car should be placed, the car's colors and some additional information.
San Andreas
PosX, PosY, PosZ, Angle, CarID, PrimCol, SecCol, ForceSpawn, Alarm, DoorLock, Unknown1, Unknown2
Identifier | Description |
---|---|
The real world coordinates of the car as floating point values. | |
The angle of the car in radians (degrees/~57.2958). | |
The ID number of the car as defined in the IDE or -1 for random car parks (influenced by the popcycle.dat file)
| |
A car color defined in the carcols.dat file. If it is set to -1 the color will be randomly chosen.
| |
Vehicles spawn more reliably if this is set to 1. | |
The probability of triggering the alarm system (0 - 100). | |
The probability that the doors of the vehicle is locked (0 - 100). | |
Unknown (Zero). |
Binary format
CARS is one of the known sections which can be used in binary format inside streaming files. It's format is similar to the plain text format:
4b - FLOAT - Position X
4b - FLOAT - Position Y
4b - FLOAT - Position Z
4b - FLOAT - Angle (Around Z-Axis)
4b - INT32 - Object ID (an index to an vehicle definition)
4b - INT32 - Primary color
4b - INT32 - Secondary color
4b - INT32 - Force spawn (Windows BOOL - see WinDef.h
)
4b - INT32 - Alarm probability
4b - INT32 - Locked probability
4b - INT32 - Unknown1 (Could be tertiary color)
4b - INT32 - Unknown2 (Could be quarterdeck color)
GTA IV
References
^ Car generators in save files
^ Creating a parked car generator via scripts.
External link
- GTAForums: Documentation of San Andreas IPL file format
Grand Theft Auto IV | |
---|---|
File Formats | .dat • .gxt • .ide • .img • .ipl • .nod • .sco • .rpf • .rrr • .wad • .wbd/.wbn • .wdd • .wdr • .wft • .whm • .wpl • .wtd |
Documentation | Audio • Bink Video • Cryptography • Cutscenes • GXT Text • Image listing • Keycodes • Map Listing • Native functions • Paths • Radar Blips • Radio Stations • Saves • Scenarios • VTable • Weapons |
Tools | ASI Loader • ENBSeries • G-Texture • GIMS IV • Ingame WPL Editor • IV Needle • OpenIV • SparkIV • XLiveLess • WPL Manager • X Mod Installer Alice • C++ Script Hook • .NET Script Hook • Scocl |
Tutorials | Importing Textures with OpenIV • Importing Textures with SparkIV |
Modifications | GTA Connected • Gostown IV • Four Multiplayer • IV Multiplayer • CitizenMP:IV Reloaded |
Useful links | Community portal • Discussion forums • Modding forums • Mods on GTAGarage.com |