[How-To] Stream Addon Melee Weapons

Hi there guys! Today, I will be showing a tutorial on how to stream your addon melee weapons! I will release another tutorial for guns since the process for that was a bit tricky.

To do this, its recommended that you know your basics of streaming addons. I will add a template below for those who don’t want to search for these files.

Add-on Melee Weapon Temp.rar (6.8 KB)

Step 1

First, you will need to get your models and put them in your stream folder. These models must include .YDR, .YDT, and +hi.YTD files as shown, or the weapon will not show properly. If the model is named after a weapon in-game, change the name.

image

Step 2

Open the Template pack and put the files into your resource.

Step 3

Open the weapons.meta file and replace all the WEAPON_NAME and WEAPON_MODEL_HERE as shown below. It’s important that you make sure all the names match the example below, or it may not function correctly

image

Step 4

Open the rest of the meta files and replace the names as shown.

Weaponanimations.meta

Weaponarchetypes.meta

image

Pedpersonality.meta

Shop_weapon.meta

image

contentunlocks.meta

image

Step 5

Save and close everthing, and insert the resource into your server.cfg. Start your server and spawn in your weapon. Finished!

Q/A

Q: Do the slot order numbers have to be different?
A: No, though if you do use the same slot order numbers, you may force a weapon out of your inventory.

Q: Why is the pickup hash a knife?
A: FiveM has some troubles using custom pickups.meta and may cause players to crash during or post game. Using other weapon pickup hashes seem to work just fine.

Q: Can you change the weapon animations?
A: Yes! You can find more weapon animations in any weaponanimations.meta in OpenIV.

Q: Can you stream weapons that were made to be replaces?
A: Yes! With melee weapons, its simple, but with guns, it requires a bit more effort to implement.

Q: How to I spawn my weapon in?
A: Due to it being a new weapon, it will not show up anywhere in-game unless you modify a ped to have it by default. Use vMenu or Lamba to spawn it in.

I hope you guys make use of this! Sometime soon I will release a detailed tutorial for adding addon guns. Thank you for taking the time to read and enjoy!

[I cant post in the tutorials section, so if someone can move this to the tutorial section, i’d appreciate it]

15 Likes

Nice thanks this is going to help a lot

Glad someone made a topic about add-on stuff. Been waiting for some progress on this forum for like one year. Good job. We need more tutorials like this!

2 Likes

you can give me the link of this scriptScreenshot_1

what, vMenu? you can find that at https://devtesting.pizza/

1 Like

the name is not shown in the gun shop. any help?

are you setting a name to the gun? you have to do that in a LUA file, similar to settings names for your cars.

hello, thank you for your tutorial, as I could not find the weaponakp.meta said in the other tutorial I tried to do this tutorial, I managed to run the lightsaber but I try to make a katana I took the files of the machete come into play I can not take the katana he puts me on the character but impossible to use it and it is invisible would you have a solution thank you

Can someone please tell me how to add guns ? I do have stream files and empty resource file. How would I add them in server and use them ? I moved the folders into resource folders of my server. I also added their names in config.cfg but I cant use them on the server like I cant add them on my inventory

Hi, I have a question I followed your tutorial and everything works perfectly but I add a katana and when I type I have the sound of the bat and not a knife you do not know how I could adjust that? thx


From a far I have the sound of the bat and the sound of the knife

And if anyone had any idea of how I could make a weapon to style a snowball that does not do damage I try to take back the files from it but it does not work.

what about ranged weapons? a need to add a custom pistols, but this meta files works incorrect with them (right mouse btn doesnt work). Where i can find some meta’s for pistols?

Go in OpenIV and search for Weapons.meta

The first option that comes up is the base games weapons.

After a couple of months messing with add on weapons, I am Going to update this thread with more options + more of an explaination to how things are executed. Patience is requested, thank you in advanced.

2 Likes

my mistake ?

the weapon works perfectly thanks,

How do I stop people losing this weapon after they have been revived?

if you are using vMenu, you have to add it into the menu’s permissions. That involves pulling the source & modifying the validweapons.cs

Is there any way to make those addon weapons be like an item? e.g storing them into house inventories giving them to other players etc

2 Likes

I have successfully streamed new melee weapons, however, they do not have any action. They are being held as a prop rather than a weapon. Any suggestions?

I made a knife but whenever I hit something it makes the sound of a bat, how do I fix that?

Could I get the files for the whole resource for the lightsaber?