CR-Fishing

Fishing Script Configuration Guide

Overview

This document provides a detailed guide to configuring the fishing script for your FiveM server. The script supports fishing shops, buy/sell menus, and customizable fishing zones, compatible with frameworks like ESX, QBCore, and QBox.

Installation

  1. Download the script and place it in your server's resources folder.

  2. Add ensure cr-fishing to your server.cfg.

  3. Configure the script by editing the provided configuration file.

Configuration

The configuration is defined in a Lua file with several tables under _CR.Config. Below, each table is explained with its properties and usage.

Main Configuration (_CR.Config.Main)

Defines general settings for the script, including the framework, ped, and blip and other settings.

Property
Type
Description
Default Value

Framework

String

The game framework to use. Options: esx, qbcore, qbox.

qbox

locals

String

The language locale for translations. Currently supports only en. Add more in the locales folder.

en

debug

Boolean

Enables debug mode for zones and view checks (increases resource usage to ~0.05ms on client).

false

zone

String

Zone handling method. Options: cr (all frameworks), ox (only ESXorqbox`).

cr

pedModel

String

The ped model for the fishing shop NPC.

a_m_m_tourist_01

pedCoords

Vector3

Coordinates for the fishing shop ped.

vector3(-1320.354, -1321.592, 4.761)

pedHeading

Float

The heading (rotation) of the ped.

117.967

pedBlip

Table

Blip settings for the fishing shop.

See below

randomTimer

Table

Minigame timer range (seconds).

{ min = 5, max = 10 }

blipFishZone

Table

Blip settings for fishing zones.

See below

blipStandingZone

Table

Blip settings for standing zones.

See below

Ped Blip Settings (pedBlip)

Property
Type
Description
Default

sprite

Number

Blip icon type.

211

color

Number

Blip color.

3

name

String

Blip name displayed on the map.

"Fishing Shop"

scale

Number

Blip size.

1

display

Number

Blip display type.

4

radius

Float

Blip radius (in meters).

10.0

radiusAlpha

Number

Transparency of the radius circle (0-255).

128

radiusColor

Number

Color of the radius circle.

2

Fishing Zone Blip (blipFishZone)

Property
Type
Description
Default

sprite

Number

Blip icon type.

371

color

Number

Blip color.

3

name

String

Blip name displayed on the map.

"Fishing Zone"

scale

Number

Blip size.

0.5

display

Number

Blip display type.

4

radius

Float

Blip radius (in meters).

30.0

radiusAlpha

Number

Transparency of the radius circle (0-255).

128

radiusColor

Number

Color of the radius circle.

3

Standing Zone Blip (blipStandingZone)

Property
Type
Description
Default

sprite

Number

Blip icon type.

280

color

Number

Blip color.

2

name

String

Blip name displayed on the map.

"Fishing Standing Area"

scale

Number

Blip size.

0.4

display

Number

Blip display type.

4

radius

Float

Blip radius (in meters).

15.0

radiusAlpha

Number

Transparency of the radius circle (0-255).

128

radiusColor

Number

Color of the radius circle.

2

Buy Menu (_CR.Config.BuyMenu)

Defines items available for purchase at the fishing shop.

Property
Type
Description
Example

id

Number

Unique item ID.

1

name

String

Item name (used in inventory).

fishing_rod

label

String

Display name for the item.

Fishing Rod

price

Number

Purchase price.

1200

buyMax

Number

Maximum quantity that can be bought at once.

1

image

String

Path to the item image in the web folder.

/web/buy/FISHING_ROD.png

Sell Menu (_CR.Config.SellMenu)

Defines items that players can sell at the fishing shop.

Property
Type
Description
Example

id

Number

Unique item ID.

1

name

String

Item name (used in inventory).

snapper_fish

label

String

Display name for the item.

Snapper

price

Number

Selling price.

1200

sellMax

Number

Maximum quantity that can be sold at once.

1

image

String

Path to the item image in the web folder.

/web/sell/snapper_fish.png

Fishing Zones (_CR.Config.FishingZones)

Defines fishing zones where players can fish, including standing areas.

Property
Type
Description
Example

zoneId

Number

Unique ID for the fishing zone.

1

zoneName

String

Name of the fishing zone.

Fishing Zone 1

zoneCoords

Vector3

Center coordinates of the fishing zone (sphere type).

vector3(-1879.118, -1299.589, -9.720)

standingZone

Table

Poly zone coordinates for the standing area.

{ vector3(-1866.144, -1237.632, 8.9), ... }

standingHeadingPos

Float

Heading for the player in the standing zone.

141.641

blipCoords

Vector3

Coordinates for the zone blip.

vector3(-1879.118, -1299.589, -9.720)

zoneRadius

Float

Radius of the fishing zone (in meters).

30.0

Notes:

  • For cr zones, use the provided format. For ox zones (ESX/QBox only), convert to ox.lib zone format.

  • Ensure images for buy/sell menus are placed in the specified web folders.

Performance

  • Normal operation: 0.0ms (client/server).

  • Debug mode: 0.05ms (client).

Troubleshooting

  • Blips not appearing: Verify sprite, color, and display values. Ensure coordinates are correct.

  • Zone issues: Check zone setting (cr or ox) and framework compatibility.

  • Images not loading: Confirm image paths in BuyMenu and SellMenu match the web folder structure.

Last updated