Difference between revisions of ".patch"

From GTAMods Wiki
Jump to navigation Jump to search
(Created page with "'''.patch''' files are used in GTA V to update .meta files during game load. The file name of the .patch file (without extension) will match the file name of the .met...")
 
m
 
Line 1: Line 1:
'''.patch''' files are used in GTA V to update [[META|.meta]] files during game load. The file name of the .patch file (without extension) will match the file name of the .meta file (without extension) it patches. Patches are XML formatted text files and can be edited with any text editor.
+
'''.patch''' files are used in the PS3/360 versions of GTA V to update [[META|.meta]] files during game load. The file name of the .patch file (without extension) will match the file name of the .meta file (without extension) it patches. Patches are XML formatted text files and can be edited with any text editor.
  
 
==Item==
 
==Item==

Latest revision as of 22:54, 9 May 2015

.patch files are used in the PS3/360 versions of GTA V to update .meta files during game load. The file name of the .patch file (without extension) will match the file name of the .meta file (without extension) it patches. Patches are XML formatted text files and can be edited with any text editor.

Item

The <Item > </Item> brackets define what is being patched and inside the brackets is the parameter that will be patched.

Verb

Verb is how the patch will place what it's changing

Value:
PUT = Overwrite existing parameter.
POST = Create new parameter.

URI

The URI is used to define exactly what parameter in the .meta file is going to be patched. Example URI:

uri="weaponShopItems/1/weaponComponents/1/cost"
	    (A)	    (B)	     (C)       (D) (E)

(A) here refers the weaponShopItems sections of a .meta file

(B) is the number of (A) sections, starting at 0. So this is referring to the 2nd weaponShopItems section.

(C) refers to the weaponComponents sections within the 2nd weaponShopItems section.

(D) is the number of (C) sections. So this is referring to the 2nd weaponComponents inside the 2nd weaponShopItems section.

(E) is the parameter name.

Using .patches

Below is an example of changing a parameter of the Obey 9F.

Example from vehicles.meta:

<?xml version="1.0" encoding="UTF-8"?>
<CVehicleModelInfo__InitDataList>
  <residentTxd>vehshare</residentTxd>
  <residentAnims />
  <InitDatas>
    <Item>
      <modelName>ninef</modelName>
      <txdName>ninef</txdName>
      <handlingId>NINEF</handlingId>
      <gameName>NINEF</gameName>
      ...

Example of a patch for vehicles.meta:

	<Item verb="PUT" uri="InitDatas/0/handlingId">Cheetah</Item>

This patch will change the very first InitDatas handlingID parameter (the hardtop 9F) so that it will use the Cheetah handling name in handling.meta.