Element/Vehicle: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 6: Line 6:
==XML syntax==
==XML syntax==
<syntaxhighlight lang="xml">
<syntaxhighlight lang="xml">
<vehicle id="" model="" posX="" posY="" posZ="" rotX="" rotY="" rotZ="" colors="" upgrades="" paintjob=""/>
<vehicle id="" model="" posX="" posY="" posZ="" rotX="" rotY="" rotZ="" colors="" upgrades="" paintjob="" plate=""/>
</syntaxhighlight>
</syntaxhighlight>


Line 22: Line 22:
* '''upgrades''': An integer representing the vehicle's mod upgrade(s) (seperated by commas), defined in San Andreas\data\maps\veh_mods\veh_mods.ide
* '''upgrades''': An integer representing the vehicle's mod upgrade(s) (seperated by commas), defined in San Andreas\data\maps\veh_mods\veh_mods.ide
* '''paintjob''': An integer indicating the vehicle's paint job (only works on certain vehicles).
* '''paintjob''': An integer indicating the vehicle's paint job (only works on certain vehicles).
* '''plate''': A set of up to 8 characters that will be shown on the vehicle's license plate.


==Related scripting functions==
==Related scripting functions==
{{Vehicle functions}}
{{Vehicle functions}}

Revision as of 09:39, 10 December 2006

The vehicle class represents vehicles in the GTA world. Vehicles can be occupied and controlled by players.

The element type of this class is "vehicle".

XML syntax

<vehicle id="" model="" posX="" posY="" posZ="" rotX="" rotY="" rotZ="" colors="" upgrades="" paintjob="" plate=""/>

Required Attributes

  • model: The vehicle ID of the vehicle being created.
  • posX: A float representing the X position of the vehicle.
  • posY: A float representing the Y position of the vehicle.
  • posZ: A float representing the Z position of the vehicle.

Optional Attributes

  • rotX: A float representing the X rotation of the vehicle.
  • rotY: A float representing the Y rotation of the vehicle.
  • rotZ: A float representing the Z rotation of the vehicle.
  • colors: An integer indicating the vehicle's color(s) (seperated by commas).
  • upgrades: An integer representing the vehicle's mod upgrade(s) (seperated by commas), defined in San Andreas\data\maps\veh_mods\veh_mods.ide
  • paintjob: An integer indicating the vehicle's paint job (only works on certain vehicles).
  • plate: A set of up to 8 characters that will be shown on the vehicle's license plate.

Related scripting functions