Quantcast

Jump to content

» «
Photo

[PoC|V] Creating a DLC pack and adding a "new" weapon

38 replies to this topic
SonofUgly
  • SonofUgly

  • Feroci
  • Joined: 27 Jul 2011
  • None

#1

Posted 16 May 2015 - 06:35 AM Edited by SonofUgly, 28 August 2015 - 06:10 PM.

There's no way to edit/add new models yet, so this may not be that useful right now, but it could be a very nice way for modders to setup and distribute mods in the future.

Creating a DLC pack.
Your DLC is going to need a name, and that name is going to be unique as it could be a conflict if someone else uses the same name.
For this example I'm using the name 'Tranq', anytime you see this used in anything in this thread, replace it with your DLC's name.

With OpenIV, create an RPF7 archive named "dlc.rpf" in Grand Theft Auto V\update\x64\dlcpacks\tranq (again, tranq = your DLC's name)

In the root of this RPF you're going to need setup2.xml and content.xml. Make a copy of another DLC's files (like christmas2).
setup2.xml tells the game what your DLC is and how it's going to be loaded. An example (probably all you'll need for weapons/cars):
Spoiler


The content.xml file points at what files/archives are going to be loaded, so every file you add to your dlc.rpf, is going to need to be in here. Also make sure every filename in content.xml begins with "dlc_Tranq:"
Example file.

To load the DLC pack, all you have to do is add the path to Grand Theft Auto V\update\update.rpf\common\data\dlclist.xml, like so:
Spoiler


Adding a weapon.
Again, still using the name tranq, so replace all of them with your weapon's/DLC's name. This goes for filenames too.
First off, these are all the files you're going to need by the end of this:
common/data/ai/loadouts.meta	//optional
common/data/ai/weaponanimations.meta
common/data/ai/weapontranq.meta
common/data/dlctext.meta
common/data/pedpersonality.meta
common/data/pickups.meta		//optional
common/data/shop_weapons.meta		//optional
common/data/tranqcontentunlocks.meta
common/data/weaponarchetypes.meta
common/data/spstatssetup.xml
common/data/spstatsuisetup.xml
x64/data/lang/ *all your language files (see the next part)*
x64/models/cdimages/weapons.rpf		//and your weapon models/textures in that
loadouts, pickups, and shop_weapons are all for ways you can get your weapon in-game without a trainer. Some of the info needed is in the modding wiki.

There's no way yet to edit animation files, so for now you have to use pre-existing animations. Take info from a different weapons weaponanimation.meta that will fit your weapon (for this example I used the SNS's file) and change all the <Item key="WEAPON_SNS"> to <Item key="WEAPON_TRANQ">

weapontranq.meta is just like the normal weapons.meta, but only includes things pertinent to your weapon. Make sure to use an empty SLOT - R* left plenty of room there so it shouldn't be an issue.

Just copy/paste dlctext.meta from a different DLC, no need to modify that.

pedpersonality.meta can be kinda a tricky one as the original one is a .ymt file, so you have to edit other DLC files and don't have access to the names of the animations without looking up the individual anim files. As it's more animation stuff, pick a DLC weapon that fits closest to yours.

tranqcontentunlocks.meta, weaponarchetypes.meta and the .xml files are pretty straightforward, just copy/paste your weapon's name where applicable.

Adding to global.gxt2
See this thread for modifying GXT2 files. These are the hash names you'll need for a weapon:
//wt_pist_tranq (HumanNameHash weapontranq.meta)
0x8B8449F4 = Tranquilizer

//tranq_kills (spstatsetup)
0xA5D2FD5F = Tranquilizer kills

//wtd_tranq (weaponDesc shop_weapon.meta)
0xC982B584 = A modified special ops version of the Mk22, a suppressor-equipped tranquilizer gun being developed by the Navy.

//wtu_tranq (weaponUppercase shop_weapon.meta)
0x92E66C86 = TRANQUILIZER

//wt_tranq (textLabel shop_weapon.meta)
0x3A56493D = Tranquilizer

//wtt_tranq (weaponTT shop_weapon.meta)
0x3426E2E2 = Tranquilizer
End Result/Tranquilizer
I didn't really focus of what the tranq was, this was more just trying to see if this would work, so it's basically just a sh*tty gun using the stunguns model that doesn't work as a tranquilizer at all.
Anyway, here's a video of it everything working in-game, and a download link for it:


Still missing the HUD icon, I believe you need to edit both a .ytd file (non-editable yet) and a .gfx file (kind of a pain to do).

Adding a vehicle.
Using 'newveh' here as the test name. Took the massacro2 and made it into a 'new' vehicle.
Files you're going to need to modify:



common/data/ai/vehiclelayouts.meta		//optional (if your vehicle needs a custom layout
common/data/levels/gta5/vehicles.meta
common/data/carcols.meta		//optional (for vehicle_mods)
common/data/carvariations.meta
common/data/dlctext.meta		//used for telling the game there's a global.gxt2 file in the dlc pack
common/data/handling.meta
common/data/newvehcontentunlocks.meta	//optional (used for buying online
x64/data/lang/ *all your language files (see the part before)*
x64/levels/gta5/vehicles.rpf		//and your vehicle models/textures in that
x64/levels/newveh/vehiclemods/newveh_mods.rpf		//optional
update.rpf/common/data/ai/vehiclemodelsets.meta		//optional
Here's the download: newveh.zip

Video Tutorial:

  • Gforce, GaffaÖ, lpgunit and 6 others like this

Ss4gogeta0
  • Ss4gogeta0

    Spilled coffee on Laptop. no more mods

  • BUSTED!
  • Joined: 24 May 2011
  • United-States

#2

Posted 16 May 2015 - 06:44 AM

curious if a similar premise would work with GTAIV...?

  • lpgunit and Sweet Bellic like this

lpgunit
  • lpgunit

    It's L, as in Lpgunit, not I.

  • Feroci
  • Joined: 24 May 2008
  • Philippines

#3

Posted 16 May 2015 - 06:45 AM

It definitely would be a 'swell way to load up mods, other than having to poke through update.rpf just to add references to your mod package.

 

Now if only that either R* would release a similar RPF loader update, or if a modder or two would code a non-invasive utility allowing for being able to inject RPFs for SP while still retaining GTAO functionality, I'd be more than overjoyed. :D


curious if a similar premise would work with GTAIV...?

Likely so, if we base it on how NTAuthority loaded up the Los Santos map in IV.

  • Ss4gogeta0 likes this

Ss4gogeta0
  • Ss4gogeta0

    Spilled coffee on Laptop. no more mods

  • BUSTED!
  • Joined: 24 May 2011
  • United-States

#4

Posted 16 May 2015 - 06:48 AM

It definitely would be a 'swell way to load up mods, other than having to poke through update.rpf just to add references to your mod package.

 

Now if only that either R* would release a similar RPF loader update, or if a modder or two would code a non-invasive utility allowing for being able to inject RPFs for SP while still retaining GTAO functionality, I'd be more than overjoyed. :D


curious if a similar premise would work with GTAIV...?

Likely so, if we base it on how NTAuthority loaded up the Los Santos map in IV.

this must be researched abit more... because if this is possible then people wouldnt have to rely on using the native trainer to spawn weapons/vehicles/etc and everything would load ingame as if it were there from day 1... 


lpgunit
  • lpgunit

    It's L, as in Lpgunit, not I.

  • Feroci
  • Joined: 24 May 2008
  • Philippines

#5

Posted 16 May 2015 - 06:53 AM Edited by lpgunit, 16 May 2015 - 06:54 AM.

 

It definitely would be a 'swell way to load up mods, other than having to poke through update.rpf just to add references to your mod package.

 

Now if only that either R* would release a similar RPF loader update, or if a modder or two would code a non-invasive utility allowing for being able to inject RPFs for SP while still retaining GTAO functionality, I'd be more than overjoyed. :D


curious if a similar premise would work with GTAIV...?

Likely so, if we base it on how NTAuthority loaded up the Los Santos map in IV.

this must be researched abit more... because if this is possible then people wouldnt have to rely on using the native trainer to spawn weapons/vehicles/etc and everything would load ingame as if it were there from day 1... 

 

Yeah, but some would find the native trainer to be a tad more convenient, especially mod developers who aren't arsed to spend ingame money or roam throughout the map just to obtain an item they made.

 

What's important though is that the goal here is we wouldn't have to tamper with the original assets - every stock RPF is left untouched, and all we have to do is to load external packages from it along with a helper tool/ASI. It should only work in singleplayer; only the vanilla game would be loaded once GTAO is launched.


Ss4gogeta0
  • Ss4gogeta0

    Spilled coffee on Laptop. no more mods

  • BUSTED!
  • Joined: 24 May 2011
  • United-States

#6

Posted 16 May 2015 - 06:59 AM

 

 

It definitely would be a 'swell way to load up mods, other than having to poke through update.rpf just to add references to your mod package.

 

Now if only that either R* would release a similar RPF loader update, or if a modder or two would code a non-invasive utility allowing for being able to inject RPFs for SP while still retaining GTAO functionality, I'd be more than overjoyed. :D


curious if a similar premise would work with GTAIV...?

Likely so, if we base it on how NTAuthority loaded up the Los Santos map in IV.

this must be researched abit more... because if this is possible then people wouldnt have to rely on using the native trainer to spawn weapons/vehicles/etc and everything would load ingame as if it were there from day 1... 

 

Yeah, but some would find the native trainer to be a tad more convenient, especially mod developers who aren't arsed to spend ingame money or roam throughout the map just to obtain an item they made.

 

What's important though is that the goal here is we wouldn't have to tamper with the original assets - every stock RPF is left untouched, and all we have to do is to load external packages from it along with a helper tool/ASI. It should only work in singleplayer; only the vanilla game would be loaded once GTAO is launched.

 

well it would help out with Total Conversions, so that instead of having to include the SNT and break immersion, they could have everything they want included and spawning normally in the game...

 

besides, it would be nice to play IV with V's weapons/vehicles/etc without having to use SNT aswell... giving it a feel as if they were always there. 

 

also I dont think SNT allows cars added into the game to spawn in traffic.

  • lpgunit likes this

lpgunit
  • lpgunit

    It's L, as in Lpgunit, not I.

  • Feroci
  • Joined: 24 May 2008
  • Philippines

#7

Posted 16 May 2015 - 08:16 AM

SNT's there to aid with development, but yeah, I do agree that added mods should spawn or be obtained as you would expect with a vanilla object to make it as seamless as possible.

  • Ss4gogeta0 likes this

Ss4gogeta0
  • Ss4gogeta0

    Spilled coffee on Laptop. no more mods

  • BUSTED!
  • Joined: 24 May 2011
  • United-States

#8

Posted 16 May 2015 - 01:28 PM

SNT's there to aid with development, but yeah, I do agree that added mods should spawn or be obtained as you would expect with a vanilla object to make it as seamless as possible.

it would be like a bootleg mod loader lol

  • lpgunit likes this

Drkz
  • Drkz

    Punk-ass Bitch

  • Members
  • Joined: 17 Apr 2015
  • None

#9

Posted 24 May 2015 - 12:21 PM

Interesting. Thanks for the tutorial.

 

That being said i'm waiting for the proper tools to start adding weapons instead of replacing them. Right now it's just too much hassle for a non-perfect result.

 

But still, once we get the proper tools (mostly a good .gxt2 editor and proper .ytd support) it will become an interesting solution, yes. 


_CP_
  • _CP_

    Boss

  • Feroci
  • Joined: 27 Dec 2007
  • Poland
  • Most Helpful Modding 2016 [Runner-up]
    Best Vehicle 2016 [IVPack]
    Best Map 2013 "ViceCityStories PC Edition"

#10

Posted 24 May 2015 - 06:36 PM

Tried to add .xml files via DLC pack - without success.


ayaanniazi2015
  • ayaanniazi2015

    Player Hater

  • New Members
  • Joined: 29 May 2015
  • Pakistan

#11

Posted 29 May 2015 - 06:48 PM

its really confusing and complicated


DrGta
  • DrGta

    Mark Chump

  • Members
  • Joined: 06 Apr 2014
  • United-States

#12

Posted 05 June 2015 - 10:21 PM Edited by DrGta, 06 June 2015 - 02:43 AM.

make a video? im not sure how to use the hex editor and what software you recommend?

 

UPDATE: i have figured out how in the hex editor but when i load in game the hud gui name is blank yet the gun loads.. any idea why?


nkjellman
  • nkjellman

    OG

  • Members
  • Joined: 28 Aug 2008
  • United-States

#13

Posted 06 June 2015 - 04:35 AM

Nice tutorial man. This will come in handy when I port the update coming next week to 1.24 so we can use the new content in the GTA Online Modders Pool.

  • DrGta likes this

DrGta
  • DrGta

    Mark Chump

  • Members
  • Joined: 06 Apr 2014
  • United-States

#14

Posted 07 June 2015 - 09:46 PM Edited by DrGta, 07 June 2015 - 10:53 PM.

where is the name for the shop weapons gui stored at? i have tried changing global.txt and others and yet no avail to change the shop weapon name.. like this name


SonofUgly
  • SonofUgly

  • Feroci
  • Joined: 27 Jul 2011
  • None

#15

Posted 07 June 2015 - 10:04 PM

also how would you go about putting a weapon in a new slot on the board behind the above picture instead of replacing one?

You mean adding a weapon to the board behind the salesman, and not the DLC board on the right? No idea.

DrGta
  • DrGta

    Mark Chump

  • Members
  • Joined: 06 Apr 2014
  • United-States

#16

Posted 07 June 2015 - 10:14 PM Edited by DrGta, 07 June 2015 - 10:52 PM.

 

also how would you go about putting a weapon in a new slot on the board behind the above picture instead of replacing one?

You mean adding a weapon to the board behind the salesman, and not the DLC board on the right? No idea.

 

EDIT:

it is now fixed yet im still awaiting how to put a weapon in the new dlc slots like this one below the Hatchet. on very right?

99ehThs.jpg


SonofUgly
  • SonofUgly

  • Feroci
  • Joined: 27 Jul 2011
  • None

#17

Posted 07 June 2015 - 10:51 PM

yes i mean on the dlc board(without replacing one currently there).

Follow the first post and create a dlcpack for the weapon. shop_weapon.meta will tell it to add the weapon to ammunation.

and also i have edited all things related to "Special Carbine" in the globlal.txt it does not change the name. unless im using wrong folder? update.rpf? or x64.rpf?

Edit both of them, some of the entries are in update, but not all of it so it also uses some from x64w. You could also check to see which hashes are in x64w that aren't in the update, and then add them to update (should be easy to add entries with XBLToothPik's new tool).
  • DrGta likes this

Pi▀Wasser
  • Pi▀Wasser

    Square Civilian

  • Members
  • Joined: 06 May 2015
  • Netherlands

#18

Posted 14 June 2015 - 12:55 AM

Would this be possible with adding clothes? How would we get them?

SonofUgly
  • SonofUgly

  • Feroci
  • Joined: 27 Jul 2011
  • None

#19

Posted 14 June 2015 - 04:20 AM

Would this be possible with adding clothes?

Yeah, should be possible with vehicles, weapons, clothes, tattoos, map/interior changes/additions, and scripts/missions.

How would we get them?

No idea, haven't played around with clothes at all.

Pi▀Wasser
  • Pi▀Wasser

    Square Civilian

  • Members
  • Joined: 06 May 2015
  • Netherlands

#20

Posted 14 June 2015 - 10:57 AM

 

Would this be possible with adding clothes?

Yeah, should be possible with vehicles, weapons, clothes, tattoos, map/interior changes/additions, and scripts/missions.

How would we get them?

No idea, haven't played around with clothes at all.

 

But would there be a way. to  add them to the clothing shops?


Nima_1i
  • Nima_1i

    ni.va

  • Members
  • Joined: 16 Jun 2009

#21

Posted 09 July 2015 - 06:11 PM Edited by Nima_1i, 09 July 2015 - 07:28 PM.

Hi,

I used your tut to add a car. but the car has no sounds. could you tell me what I'm missing??

 

Edit: I figured out, thanks,

 

BTW I want to write a detailed tut about adding vehicles using dlc method & that will use parts of your tut. Do I have the permission?


SonofUgly
  • SonofUgly

  • Feroci
  • Joined: 27 Jul 2011
  • None

#22

Posted 09 July 2015 - 07:36 PM

BTW I want to write a detailed tut about adding vehicles using dlc method & that will use parts of your tut. Do I have the permission?

Sure, that's fine.

Nima_1i
  • Nima_1i

    ni.va

  • Members
  • Joined: 16 Jun 2009

#23

Posted 10 July 2015 - 07:55 AM

Have you ever tried to add audio to the dlc??


UHDFreddyEST
  • UHDFreddyEST

    Player Hater

  • Members
  • Joined: 20 Aug 2015
  • Estonia

#24

Posted 22 August 2015 - 11:24 PM

Hy,

Can, anyone make a better readme, what is include a newveh.zip. Because i do that, what it says, but i don't get that work. I must add thes files multiple place then i got it work. But if DLC go over 7gb then i dont want that i must copy that 4 or more places. 

Sorry my bad English, but i hope you understand me.
Best Regards
UHDFreddyEST


Timeless_AUT
  • Timeless_AUT

    Crackhead

  • Members
  • Joined: 13 May 2009
  • Austria

#25

Posted 23 August 2015 - 02:41 PM

at first thanks for your tutorial but I got some questions.

I wanted to add some of the new car mods as an DLC, tried to understand the files but some things are not clear to me.

I tried to add a car with there own _mods file, but I'm not sure how to add it as an DLC, because which ID do I need to use in the carcols.meta as an "kitName"? 

Where do I find the original carclos.meta and carvariations.meta for all cars? because there are many files and I couldn't find the first original file. Especially I tried to find comet2.

And one last question: how to edit the language files? Where to change the car name? I only find in the lang files the brand name. 0xF4642C6F = SonofUgly

Where do I get the hash?

I'm sorry for the many questions but I couldn't find a tutorial for adding new cars to GTA V. Or is there a tutorial?

Would be nice if I get some answers, thanks :)


enjoythekilling
  • enjoythekilling

    Player Hater

  • Members
  • Joined: 15 Apr 2015
  • None

#26

Posted 24 August 2015 - 06:16 AM Edited by enjoythekilling, 24 August 2015 - 06:21 AM.

 

at first thanks for your tutorial but I got some questions.

I wanted to add some of the new car mods as an DLC, tried to understand the files but some things are not clear to me.

I tried to add a car with there own _mods file, but I'm not sure how to add it as an DLC, because which ID do I need to use in the carcols.meta as an "kitName"? 

Where do I find the original carclos.meta and carvariations.meta for all cars? because there are many files and I couldn't find the first original file. Especially I tried to find comet2.

And one last question: how to edit the language files? Where to change the car name? I only find in the lang files the brand name. 0xF4642C6F = SonofUgly

Where do I get the hash?

I'm sorry for the many questions but I couldn't find a tutorial for adding new cars to GTA V. Or is there a tutorial?

Would be nice if I get some answers, thanks  :)

 

 

 

Hy,

Can, anyone make a better readme, what is include a newveh.zip. Because i do that, what it says, but i don't get that work. I must add thes files multiple place then i got it work. But if DLC go over 7gb then i dont want that i must copy that 4 or more places. 

Sorry my bad English, but i hope you understand me.
Best Regards
UHDFreddyEST

 

 

JulioNIB wrote an excellent tutorial on his blog which i used to add cars. Not sure if anyone knew about it but i thought i'd link it here: http://gtaxscripting...ource=BP_recent


UHDFreddyEST
  • UHDFreddyEST

    Player Hater

  • Members
  • Joined: 20 Aug 2015
  • Estonia

#27

Posted 25 August 2015 - 08:59 PM

is any video how to make a new global.gxt2 file with new vehicles enteris ?


UHDFreddyEST
  • UHDFreddyEST

    Player Hater

  • Members
  • Joined: 20 Aug 2015
  • Estonia

#28

Posted 04 September 2015 - 09:11 PM

hy.

 

btw, where i can find free vehicle id s ?


Claude_Lib
  • Claude_Lib

    Talkative like never before

  • Members
  • Joined: 26 Jun 2009
  • Russia

#29

Posted 04 September 2015 - 09:19 PM

You mean numeric IDs? I don't think the game uses them anymore, it probably calls them by their internal name rather than some number.


UHDFreddyEST
  • UHDFreddyEST

    Player Hater

  • Members
  • Joined: 20 Aug 2015
  • Estonia

#30

Posted 16 September 2015 - 09:27 PM

Hello, why i dont get dlc car tuning parts working, ? :S





2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users