Fishing
Installation

Installation

Prerequisites

  • A working QBX Core server
  • A running MySQL/MariaDB instance
  • The following resources installed and started:
    • qbx_core
    • ox_lib
    • ox_inventory
    • ox_target
    • oxmysql

Steps

1. Drop the resource folder

Place the medit8z_fishing folder into resources/[scripts]/.

2. Merge items into Ox Inventory

Open the shipped medit8z_fishing/items.lua and merge all 86 entries into:

resources/[ox]/ox_inventory/data/items.lua

The set covers 1 fishing journal, 5 rods, 5 reels, 4 lines, 16 baits, 14 lures, 4 tackle boxes, and 35 fish species.

⚠️

Several items have server.export hooks pointing at medit8z_fishing.useFishingJournal, medit8z_fishing.useFishingRod, and medit8z_fishing.useTackleBox. Preserve these exactly as written — the inventory uses them to route item-use events back into the resource.

3. Copy the icons

Copy every PNG (86 files) from medit8z_fishing/images/ into:

resources/[ox]/ox_inventory/web/images/

4. Ensure the resource

Confirm [scripts] is ensured in server.cfg (default in a Qbox install), or add an explicit line:

ensure medit8z_fishing

Database

All 16 tables are created automatically on first start. server/db_init.lua reads schema.sql at runtime — no manual SQL import is required.

Tables created (all prefixed medit8z_fishing_):

players, skills, catches, encyclopedia, achievements, challenges,
prices, leaderboards, weekly_stats, titles, location_visits,
rarity_counts, boat_rentals, location_stats, equipment, challenge_tracking

To do a clean reset, drop all medit8z_fishing_* tables and restart — they will be recreated.

Fishing license

Casting requires the fishing flag in QBX player metadata. Either route it through your City Hall license vendor (default price $2,500) or grant manually for testing:

exports.qbx_core:GetPlayer(source).Functions.SetMetaData('licences', { fishing = true })

Verifying the install

On first start, you should see:

[medit8z_fishing] schema.sql executed (16 statements, 0 failed)
[medit8z_fishing] Server initialized

If you see schema.sql not found - tables will NOT be created, the resource folder is incomplete — re-upload it.

To smoke-test in-game:

  1. Grant yourself the fishing license.
  2. Spawn or buy a fishing_rod_bamboo, fishing_reel_basic, fishing_line_mono, and bait_worm.
  3. Walk to a fishing spot and use the rod.
  4. Use the fishing_journal item — the NUI should open with stats, encyclopedia, and challenges populated.