Installation#
This page explains how to install 0r-soccer on your FiveM server.
Requirements#
Make sure these resources are installed and started before 0r-soccer:
| Dependency | Required? | Notes |
|---|---|---|
| oxmysql | Yes | Database (stats + match history) |
| QBCore / ESX / Qbox | Yes | Set Config.Core to match your framework |
| ox_lib | Recommended | Used when Config.Bridge.Notify = "ox_lib" |
| ox_target or qb-target | Recommended | Pitch NPC interaction |
oxmysql is a hard dependency. Without it, the script will not start correctly.
Step 1 — Copy the resource#
- Place the
0r-soccerfolder in your serverresourcesdirectory. - Keep the folder name as
0r-soccer(exports use this name).
Example:
resources/[0resmon]/0r-soccer
Step 2 — Start order#
In server.cfg (or your resources config), start dependencies first:
ensure oxmysql
ensure ox_lib
ensure qb-core
ensure qb-target
ensure 0r-soccer
If you use ESX, start es_extended instead of qb-core.
If you use ox_target, you can skip qb-target.
Step 3 — Database#
You do not need to run an SQL file manually.
On first start, the script creates these tables automatically:
soccer_player_stats— goals, assists, matches per playersoccer_match_history— finished matchessoccer_match_participants— players in each match
Your MySQL connection must already work through oxmysql.
Step 4 — Basic config#
Open config.lua and set at least:
Config.Core = "QBCore" -- or "ESX"
Config.Locale = "en" -- en, tr, pt, es, de
Config.Bridge = {
Notify = "ox_lib", -- ox_lib | qbcore | esx | auto
Target = "auto", -- auto | ox_target | qb-target | qtarget
}
More options are explained in Configuration.
Step 5 — Test in-game#
- Restart the server (or
ensure 0r-soccer). - Go to a pitch (Broker Park or Vespucci Beach by default).
- Use the NPC target option, or type
/soccer. - Create a lobby and start a short match.
Useful commands#
| Command | Description |
|---|---|
/soccer | Open the soccer menu (default; change in config) |
/soccer_goaldebug | Toggle goal debug helpers (calibration) |
Common problems#
Menu does not open#
- Check F8 / server console for errors.
- Confirm
0r-socceris started:ensure 0r-soccer - Confirm your framework resource is running.
NPC has no target option#
- Start
ox_targetorqb-target. - Set
Config.Bridge.Targetcorrectly ("auto"usually works).
Database errors#
- Confirm
oxmysqlis started and connected. - Check your
mysql_connection_stringinserver.cfg.
Wrong language#
- Set
Config.Localeto a file that exists inlocales/(example:"tr"). - Restart the resource after changing locale.