Skip to content

10% off shop orders, applied at checkoutBlack Friday: 30% off until Dec 1Server templatesServer templates

RPScripts

SM Hunting for FiveM: Setup & Source Notes

By Lena

Illustration of a hunting rifle and a deer silhouette at a misty forest edge with a glowing hunting zone
On this page

SM Hunting is a QBCore hunting resource by ScienceDestroy; the manifest names sm-scripts as author and reports version 1.0.0. Players start a hunt at a marker, hunt animals spawned in a zone and harvest them for meat, leather, feathers and cash. The README describes configurable hunting areas, animal spawning, rewards and a weapon-license check. The last commit is from January 2025, and the repository does not state a license.

Requirements

The README lists only qb-core. Harvesting uses a 3D text prompt and the E key, so no target resource is needed. The license check reads the weapon entry in the player's licences metadata.

Installation

  1. Copy the sm_hunting folder into your resources and add ensure sm_hunting to server.cfg.
  2. Add the entries meat, leather and feathers from shared/items.lua to qb-core/shared/items.lua. Copy the entries only, because the file is written as a full QBCore.Shared.Items table.
  3. Optional: add setr disableNativeAnimalSpawns true to stop native animal spawns.
  4. Restart the server.

Configuration

config.lua sets the zone center (Config.HuntingZone), Config.SpawnRadius and Config.ZoneCheckRadius, the start and end markers, Config.MaxAnimals (10 by default) and the spawn chances for deer, rabbit, mountain lion and crow. The amounts of meat, leather, feathers and cash per animal are not in the config; they sit in the rewards table in server/hunting_server.lua.

The item labels in shared/items.lua and the reward notification in the server file are in Russian, and Config.Lang is set to ru. Translate them before release if your players need another language.

For a hunting job with bait, skinning and a taxidermist who buys the materials, QBCore VIP Hunting takes a different approach and needs qb-target and PolyZone.

Setup and checks

The server event hunting:harvestAnimal pays out for any reward type the client sends. It does not check that the player is hunting, is near a dead animal or is within a cooldown, so a modified client could trigger it repeatedly. Add those checks on the server before release. Confirm the item names and inventory behavior before opening the hunting area. Test collection twice on the same animal, attempts without a license and a full inventory. The optional disableNativeAnimalSpawns setting affects native animal spawning; do not enable it without checking your other wildlife resources.

Sources

Original source

Related server guide