Attachments System
For this section, if you do not have the minimum knowledge, or an experienced developer, avoid modifying or integrating custom weapons to your server to avoid errors, or problems with the inventory resource, with this we make clear that a support will not help you to configure a section like this to your server.
Quasar Inventory includes many attachments by default, if not all of the current GTA V ones, but you can still add new attachments to weapons or custom weapons by following the guide below. Please note that sometimes non-customized weapons are not fully functional and this is not the fault of the inventory.
Default attachment categories
Default Categories are the spaces where you can add an attachment such as scope, suppressor, flash, clip and tint. In this we emphasize that only by these names are the slots where the attachment item goes are recognized.
Optional attachment categories
The optional categories are the name of the attachments that come configured with some custom weapons, referring to the name or category of the attachment. The optional categories are compatible with the default categories, so it is recommended not to edit these names.
Default Category | Opcional Cetegory |
---|---|
suppressor | suppressor, barrel, muzzle, tube |
flash | flashlight, light, laser |
scope | scope, stock, handguard |
clip | defaultclip, clip, extendedclip, grip, drum |
tint | weapontint, luxuryfinish, slide, frame, shell |
In this way we want to visually explain the categories in which the custom attachments will be categorized based on the default slots with the help of the previous image.
Add attachments addons
First the integration is done in qs-inventory\server\custom\misc\CreateUsableItem.lua.
frame2 is the category where the attachment will be placed, and "frame2" is used to identify this category since you cannot repeat the "frame" category on the same weapon and "frame2" is used for identification, so if you want to add more attachments, you can add the "frame3" and so on continuously
Now add the configuration to weapons.lua in the config folder.
Be careful and verify that where you bought the gun, or where you downloaded it, they give you a basic configuration where you can see the component that can be used, since this must come with the files of the gun, otherwise, the attachment will never load visually on the gun.
Last updated