Skip to content

Installation

Dependencies, database, server.cfg order, and a quick test.

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:

DependencyRequired?Notes
oxmysqlYesDatabase (stats + match history)
QBCore / ESX / QboxYesSet Config.Core to match your framework
ox_libRecommendedUsed when Config.Bridge.Notify = "ox_lib"
ox_target or qb-targetRecommendedPitch NPC interaction

oxmysql is a hard dependency. Without it, the script will not start correctly.

Step 1 — Copy the resource#

  1. Place the 0r-soccer folder in your server resources directory.
  2. Keep the folder name as 0r-soccer (exports use this name).

Example:

text
resources/[0resmon]/0r-soccer

Step 2 — Start order#

In server.cfg (or your resources config), start dependencies first:

cfg
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 player
  • soccer_match_history — finished matches
  • soccer_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:

lua
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#

  1. Restart the server (or ensure 0r-soccer).
  2. Go to a pitch (Broker Park or Vespucci Beach by default).
  3. Use the NPC target option, or type /soccer.
  4. Create a lobby and start a short match.

Useful commands#

CommandDescription
/soccerOpen the soccer menu (default; change in config)
/soccer_goaldebugToggle goal debug helpers (calibration)

Common problems#

  • Check F8 / server console for errors.
  • Confirm 0r-soccer is started: ensure 0r-soccer
  • Confirm your framework resource is running.

NPC has no target option#

  • Start ox_target or qb-target.
  • Set Config.Bridge.Target correctly ("auto" usually works).

Database errors#

  • Confirm oxmysql is started and connected.
  • Check your mysql_connection_string in server.cfg.

Wrong language#

  • Set Config.Locale to a file that exists in locales/ (example: "tr").
  • Restart the resource after changing locale.