Installation
This page walks through a complete install. It takes a few minutes and needs no database changes.
Before you start
Section titled “Before you start”Check that your server has:
- ESX (
es_extended), QBCore (qb-core) or QBX (qbx_core) already running. - PolyZone installed.
ox_targetorqb-targetinstalled.- A boxing ring in your map at the coordinates you plan to use. The default coordinates are listed in Configuration.
-
Copy the script folder into your server
resourcesfolder. This guide calls itkivo-boxing. Any folder name works as long asserver.cfguses the same name.resources/[kivo]/kivo-boxing/Config.luafxmanifest.luaclient/server/ui/ -
Make sure PolyZone is in your resources and its folder is named exactly
PolyZone(capital P and Z). The script loads PolyZone files by that folder name, and Linux servers care about capital letters. -
Add the resources to
server.cfgin this order:ensure PolyZone# Your framework: keep only the one you useensure es_extended# ensure qb-core# ensure qbx_core# Your target resource: keep only the one you useensure ox_target# ensure qb-target# Optional, used for notifications when presentensure ox_libensure kivo-boxingIf you start whole folders such as
ensure [qb], keepkivo-boxingbelow them. -
Open
Config.luaand set debug mode tofalsefor a live server:Config.Debug = falseWhile
Config.Debugistrue, signing up starts a fight against an AI opponent immediately, and zone outlines are drawn in the world. See Configuration. -
If your ring is not at the default location, update the coordinates in
Config.lua. Follow Ring and zone setup. -
Restart the server, or run
ensure kivo-boxingin the server console after the other resources are up. -
Test with two players. Walk to the bouncer, use your target key on him, and choose the sign-up option. Have the second player do the same within the search time. Both players should be moved into the ring.
PolyZone
Section titled “PolyZone”Kivo Boxing uses PolyZone to define the ring area and the spectator area. The manifest lists it as a required dependency. If PolyZone is missing, misnamed or fails to start, the server console reports a dependency error and kivo-boxing does not start.
Framework support
Section titled “Framework support”| Framework | Resource name checked | Status |
|---|---|---|
| ESX | es_extended |
Supported |
| QBCore | qb-core |
Supported |
| QBX | qbx_core |
Supported (QBX support was added in a recent update) |
How it works:
- The script looks for these resources by name. If you renamed your framework resource, it will not be detected.
- The framework is used to read the character name shown on the scoreboard. QBCore and QBX use the character first and last name. ESX uses the name ESX returns for the player. If no name can be read, the scoreboard shows
Playerfollowed by the server id. - The script checks the framework once, when it starts. Start the framework first.
- Apart from the names and the bouncer interaction, the boxing logic does not depend on the framework.
Target resource support
Section titled “Target resource support”| Resource | Used when |
|---|---|
ox_target |
It is running. Checked first. |
qb-target |
ox_target is not running and qb-target is. |
If neither is running, the bouncer appears but cannot be used. The client console (F8) shows a red message that no targeting resource was found.
Like the framework, the target resource is detected once at start. If you restart your target resource, restart kivo-boxing afterwards.
Notifications
Section titled “Notifications”Players get notifications for sign-up, cancelled sign-up, a busy arena, and the match result.
- If
ox_libis running, they useox_libnotifications. - If not, they appear as chat messages.
You do not have to change anything for either case.
Updating
Section titled “Updating”- Stop the script, or stop the server.
- Replace the folder contents with the new version.
- Copy your own values back into the new
Config.lua. Do not overwrite your coordinates with the defaults. - Start the script again.
