Log in to reply
 

[ Tutorial ] How to disable/remove specific EXTRAS from vehicles/vehicle spawns



  • Backup:
    As with anything modding related, make backups of everything you intend to edit first.
    For GTA V, I wholeheartedly recommend backing up the entire '.rpf' archive, not just the files you are editing.
    That has got me out of a few tight spots over the years & can mitigate the task of having to reinstall every edited file to a '.rpf' if things go wrong. :thumbsup:

    HOW TO REMOVE EXTRAS FROM VEHICLES:

    Basic Procedure:

    • Export vehicle's '.yft' & '_hi.yft' to '.yft.xml' using Codewalker's RPF Explorer.
    • Edit '.yft.xml' files using text editor & reduce scale of selected extras to zero to stop them from appearing in-game.
    • Import vehicle's '.yft.xml's back into the game using Codewalker's RPF Explorer.

    Detailed Procedure:

    Make a note of what extras you want to remove:

    • Boot up the game, spawn the vehicle & using a trainer make a note of what extras you do not want to appear.
    • They are numbered the same in the files as they are in ENT anyway, so figure most trainers will be the same.

    Export vehicle '.yft' to '.yft.xml' using Codewalker:

    • Grab yourself a copy of CodeWalker from the CodeWalker discord (Note: Codewalker v.29 on gta-mods is out of date & lacks necessary features, always get the latest version of CodeWalker from it's Discord :thumbsup:)
    • Once you have a copy of CodeWalker load up it's 'RPF Explorer' (either, CodeWalker > '[<<]' button (top right) > '[Tools]' > 'RPF Explorer...' or in new versions you can find the 'CodeWalker RPF Explorer.exe' in Codewalker's install folder & load it on it's own from there).
    • In 'CodeWalker RPF Explorer' track to the location of the vehicle you want to remove extra's from.
    • Once there, highlight the vehicle's '.yft' by left clicking on it & then use 'Ctrl+left-click' to also highlight it's '_hi.yft'.
    • With both files selected/highlighted, right-click & select 'Export XML...'.
    • Select a location for the exported '.yft.xml's & hit '[OK]'

    Edit '.yft.xml' using a Text Editor (like Notepad++ etc):

    • Track to the '.yft.xml' export location & open them with your text editor of choice
    • Search for 'extra' in the '.yft.xml's & near the top you will find sections like this for each of the extras:

    Example:

        <Item>
         <Name>extra_8</Name>
         <Tag value="8881" />
         <Index value="11" />
         <ParentIndex value="0" />
         <SiblingIndex value="12" />
         <Flags>RotX, RotY, RotZ, TransX, TransY, TransZ</Flags>
         <Translation x="2.273737E-13" y="-1.966892" z="-0.1955207" />
         <Rotation x="0" y="2.710494E-20" z="-2.842159E-14" w="1" />
         <Scale x="1" y="1" z="1" /> 
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
    
    • Using their numbering as a guide, find the extra/s you want to remove, & then simply set the x, y & z values in their '<Scale' line to zero.

    Example:

        <Item>
         <Name>extra_8</Name>
         <Tag value="8881" />
         <Index value="11" />
         <ParentIndex value="0" />
         <SiblingIndex value="12" />
         <Flags>RotX, RotY, RotZ, TransX, TransY, TransZ</Flags>
         <Translation x="2.273737E-13" y="-1.966892" z="-0.1955207" />
         <Rotation x="0" y="2.710494E-20" z="-2.842159E-14" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- set x, y & z to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
    
    • Save the file/s & head back to Codewalker's RPF Explorer

    Importing edited '.yft.xml''s back into the game:

    • In CW's RPF Explorer, hit the '[:shield:Edit mode]' button (top right-ish) & accept any warnings by hitting '[Yes]'
    • Right-click anywhere in the folder (the folder where you got the original '.yft' from obvs) & select 'Import XML...'
    • Track to the location of your edited '.yft.xml' files, select them both & hit '[Open]'
    • Codewalker will take a few seconds to import the files, wait for it to complete & then close the 'RPF Explorer' window.

    That's it, those extra's, although still technically there in the '.yft', should not appear in game.

    Combine this with the info in my previous post on How to make specific vehicle EXTRAS appear on a vehicle EVERY spawn & you will have pretty much complete control over what combination of extras appear or do not appear in any given vehicle spawn.

    Any questions/issues, give me a shout :thumbsup:



  • @MissSnowie
    Depending on how the vehicle/certain extras are made, funky things like that can happen. I think it would need to be fixed/edited in ZModeler3 to stop it happening.



  • you can't click on the extract XML button it is locked



  • @I-AM-DEFALT
    Make sure you are using the newest version of CodeWalker from the CodeWalker Discord. :thumbsup:

    ie Don't use the v.29 on this site (gta5-mods), it's old & lacks features.



  • My game crash after do edit the car mod using this method



  • @Teodoric0420
    You must have made a mistake, it's always worked for me. Try your edits again :thumbsup:

    Tutorial Extra:

    Figured out how to remove lightbars & other more complex extras. Just check the extra you are interested in making invisible in OpenIV's Model Viewer & make a note of it's children & then also reduce the scale values for all of those children in the '.yft.xml' as well:

    extra_2

    Note:
    The scaled to zero extras will still appear in OpenIV's Model Viewer, but they will be invisible in-game.

    '.yft.xml' Parent & Children Example:

        <Item>
         <Name>extra_2</Name>  <!-- extra_2 (parent) -->
         <Tag value="8875" />
         <Index value="80" />
         <ParentIndex value="0" />
         <SiblingIndex value="90" />
         <Flags>RotX, RotY, RotZ, Unk0</Flags>
         <Translation x="-0.001079" y="0.0021" z="0.824132" />
         <Rotation x="0" y="0" z="0" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
        <Item>
         <Name>siren15</Name>  <!-- siren15 (child) -->
         <Tag value="5719" />
         <Index value="81" />
         <ParentIndex value="80" />
         <SiblingIndex value="82" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="-0.439644" y="-0.130335" z="0.100557" />
         <Rotation x="0" y="0" z="0" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
        <Item>
         <Name>siren16</Name> <!-- siren16 (child) -->
         <Tag value="5720" />
         <Index value="82" />
         <ParentIndex value="80" />
         <SiblingIndex value="83" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="-0.30979" y="-0.128083" z="0.100557" />
         <Rotation x="0" y="0" z="0" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
        <Item>
         <Name>siren17</Name> <!-- siren17 (child) -->
         <Tag value="5721" />
         <Index value="83" />
         <ParentIndex value="80" />
         <SiblingIndex value="84" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="-0.171561" y="-0.128838" z="0.100557" />
         <Rotation x="0" y="0" z="0" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
        <Item>
         <Name>siren18</Name> <!-- siren18 (child) -->
         <Tag value="5722" />
         <Index value="84" />
         <ParentIndex value="80" />
         <SiblingIndex value="85" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="0.174585" y="-0.131697" z="0.100557" />
         <Rotation x="0" y="0" z="0" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
        <Item>
         <Name>siren19</Name> <!-- siren19 (child) -->
         <Tag value="5723" />
         <Index value="85" />
         <ParentIndex value="80" />
         <SiblingIndex value="86" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="0.314211" y="-0.131405" z="0.100557" />
         <Rotation x="0" y="0" z="0" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
        <Item>
         <Name>siren20</Name> <!-- siren20 (child) -->
         <Tag value="5698" />
         <Index value="86" />
         <ParentIndex value="80" />
         <SiblingIndex value="87" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="0.445633" y="-0.130335" z="0.100557" />
         <Rotation x="0" y="0" z="0" w="1" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="4" z="-3" w="0" />
        </Item>
        <Item>
         <Name>siren_glass16</Name> <!-- siren_glass16 (child) -->
         <Tag value="16458" />
         <Index value="87" />
         <ParentIndex value="80" />
         <SiblingIndex value="88" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="-0.325677" y="-0.127071" z="0.120342" />
         <Rotation x="0.7071066" y="0" z="0" w="0.7071069" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="2.000001" z="-1.000001" w="0" />
        </Item>
        <Item>
         <Name>siren_glass4</Name> <!-- siren_glass4 (child) -->
         <Tag value="63115" />
         <Index value="88" />
         <ParentIndex value="80" />
         <SiblingIndex value="89" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="0.001079" y="-0.127071" z="0.120818" />
         <Rotation x="0.7071066" y="0" z="0" w="0.7071069" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="2.000001" z="-1.000001" w="0" />
        </Item>
        <Item>
         <Name>siren_glass19</Name> <!-- siren_glass19 (child) -->
         <Tag value="16461" />
         <Index value="89" />
         <ParentIndex value="80" />
         <SiblingIndex value="-1" />
         <Flags>RotX, RotY, RotZ</Flags>
         <Translation x="0.327835" y="-0.127071" z="0.120342" />
         <Rotation x="0.7071066" y="0" z="0" w="0.7071069" />
         <Scale x="0" y="0" z="0" /> <!-- xyz scale to zero -->
         <TransformUnk x="0" y="2.000001" z="-1.000001" w="0" />
        </Item>
    


  • Does the exported .yft_hi.xml also need to be modified?



  • @Ripple343
    Yeah, if the '_hi.yft' contains the things you want to remove, you edit that as well :thumbsup:



  • @a63nt-5m1th said in [ Tutorial ] How to disable/remove specific EXTRAS from vehicles/vehicle spawns:

    Backup:
    As with anything modding related, make backups of everything you intend to edit first.
    For GTA V, I wholeheartedly recommend backing up the entire '.rpf' archive, not just the files you are editing.

    The practice of backing up the entire rpf is particularly valid for FiveM which has zero tolerance for modified vanilla files. Although it's a best practice to use a mods folder in SP, FiveM uses a resources folder, making modding different and not allowing you to restore one file in an rpf, instead you need to restore the entire vanilla file. Ofc, you shouldn't make that same mistake twice.


Log in to reply
 

Looks like your connection to GTA5-Mods.com Forums was lost, please wait while we try to reconnect.