Configure
This page shows you how to add your own custom weapons to the damage config.
KYROS Weapon Repair Script Documentation
Overview
The KYROS Weapon Repair Script provides an easy-to-use solution for repairing weapons within a FiveM server using the ox_inventory system. The script features a customizable configuration, progress bar/circle repair animations, language support, and options for various repair mechanics, such as requiring a weapon repair kit.
Installation
Download and Extract the Script
Download the KYROS weapon repair script and extract it into your FiveM resources folder.
Add to Server Configuration
Add
start kyros-repairin yourserver.cfgto start the script.
Ensure Dependencies
Make sure you have the following resources:
ox_inventoryox_libOptional:
esxif usingesxnotification system.
Configuration (config.lua)
The config.lua file allows you to configure various aspects of the weapon repair system.
General Settings
requireditem: Item needed for repairs. Default is'money'.requireditemamount: Amount of the required item for repairs. Default is1000.repairtime: Time taken to repair the weapon (in milliseconds). Default is5000.repairItem: The item required to repair the weapon. Default is'gunrepairkit'.requireGunRepairKit: Whether a gun repair kit is required for repairs. Default istrue.progressType: Choose between'bar'or'circle'for the repair progress display.progressPosition: Position of the progress circle. Use'middle'or'bottom'(only ifprogressType == 'circle').targetUI: UI for target interaction, choose between'ox_target'and'text_ui'.notificationSystem: Choose between'esx'and'ox'notification systems.
Language Settings
languages: Configures the text displayed for each language supported by the script.English (
en) and Spanish (es) are included by default.Add new languages as needed.
currentLanguage: Set the default language for the script (e.g.,'en'for English,'es'for Spanish).
Weapon Specific Requirements
require: Defines specific repair requirements for certain weapons. You can set the required item, amount, and repair time for specific weapons:['WEAPON_PISTOL'] = { requireditem = 'money', requireditemamount = 1200, repairtime = 8000 }
Locations
Define the repair locations in the locations table. Each location has the following properties:
coords: The coordinates of the repair bench.heading: The heading of the repair bench.spawnprop: Whether the repair bench prop should spawn.free: Whether repairs at this location are free.
Example:
{
coords = vector3(-922.4052, -2989.9075, 18.8454),
heading = 239.3186,
spawnprop = true,
free = false
}How to Add Custom Weapons
Edit the Config File: Add specific weapons and their repair requirements in the
requiresection.['WEAPON_SMG'] = { requireditem = 'black_money', requireditemamount = 2000, repairtime = 10000 }Add More Languages: Update the
languagestable to add support for additional languages.['fr'] = { repairingWeapon = 'Réparation de l\'arme', missingItems = 'Articles manquants', ... }
Last updated
