SleepyCode
Home
AboutBlogSubscriptionDocs
Cart0
SleepyCode
Cart0
  1. Home
  2. /
  3. Guides
8 min read

Guide · June 28, 2026

How to Install SleepyCode Bus Job on FiveM ESX

Step-by-step install guide for SC Bus Job - ESX public transport script for FiveM. Dependencies, server.cfg, pay-per-stop config and multipliers.

SC Bus Job is a public-transport roleplay script for FiveM ESX servers. Players pick up NPC passengers at configurable bus stops, follow routes, and earn per-stop pay with night and weekend multipliers. The script tracks smooth driving, accidents, and speeding - rewarding careful drivers with bonus pay.

Framework: ESX Legacy 1.20 or higher only. This script does not support QBCore, QBox, or Standalone.

Dependencies

ResourceMinimum version
ESX Legacy1.20
ox_liblatest
ox_targetlatest
oxmysqllatest

All three overextended resources are available at github.com/overextended.

Installation Steps

1. Download and place the resource

After purchasing from the SleepyCode store and downloading via Keymaster, extract the folder and place it in your server's resources directory.

2. Add to server.cfg

Dependencies must start before the script:

ensure ox_lib
ensure ox_target
ensure oxmysql
ensure sc_busdriver

3. Database tables

No manual SQL import is required. The script automatically creates all necessary database tables on its first launch.

4. Configure the script

Two config files to edit:

  • config.lua - client-side settings (distances, payment, penalties, zones)
  • config_server.lua - server-side settings

5. Restart and test in-game

After a server restart, head to the job NPC location defined in Config.Zone.Job and the ox_target label should appear.

Job & Check Settings

lua
Config.Job      = "unemployed"  -- ESX job name required to use the script
Config.CheckJob = true          -- set false to allow any player to work as a driver
Config.Debug    = true          -- enable server console debug output

Set Config.CheckJob = false if you want the bus job to be available to all players regardless of their ESX job.

Payment Structure

lua
Config.Payment = {
  Stop      = { Min = 35, Max = 55 },   -- base pay per completed bus stop
  Passenger = { Min = 8,  Max = 15 },   -- extra pay per passenger on board
  Bonus     = { Min = 150, Max = 300 }, -- bonus at the end of a completed route
  Perfect   = 200,                       -- additional bonus for a perfect route score
  Night     = 1.5,                       -- pay multiplier between 22:00-06:00
  Weekend   = 1.25,                      -- pay multiplier on Saturday and Sunday
}

A driver completing a stop with 5 passengers during a Friday night shift earns roughly:

  • Stop pay: ~45 base
  • Passenger bonus: ~55 (5 × ~11)
  • Night multiplier ×1.5 applied to total

Penalty System

lua
Config.Penalty = {
  Accident          = 50,   -- fine per accident
  Missed            = 75,   -- fine for missing a bus stop
  Speed             = 25,   -- fine per speeding violation
  Damage            = 100,  -- fine for vehicle damage
  DamageThreshold   = 50,   -- damage level before fine triggers
  MaxDamageReduction = 0.60, -- penalties can reduce pay by at most 60%
  StopTimeout       = 100,  -- fine if stop time limit expires
}

Speed Limit & Driving Score

lua
Config.SpeedLimit            = 110   -- km/h - exceeding this triggers a speeding fine
Config.SmoothDrivingThreshold = 95   -- score required for a "perfect route" bonus
Config.MaxAcceleration       = 5.0   -- sudden acceleration threshold

Stop Time Limit

lua
Config.StopTimeLimit = 300  -- seconds the driver has to reach the next stop

If a driver fails to reach the next stop within 300 seconds, they receive the StopTimeout penalty fine.

NPC Passengers

lua
Config.NPC = {
  SpawnDistance = 200,  -- how far NPCs spawn from the stop (metres)
  MinSpawn      = 2,    -- minimum waiting passengers at each stop
  MaxSpawn      = 8,    -- maximum waiting passengers at each stop
  LineSpacing   = 1.2,  -- spacing between queued NPCs (metres)
  MaxExitPerStop = 5,   -- max NPCs that exit at any single stop
}

Cooldowns

All cooldowns are in milliseconds:

lua
Config.Cooldown = {
  Spawn  = 3000,  -- delay between bus spawns
  Delete = 2000,  -- delay before bus is deleted on return
  Route  = 2500,  -- cooldown between route actions
  Stop   = 1000,  -- cooldown between stop actions
}

Zone Coordinates

lua
Config.Zone = {
  Job         = vec4(451.24, -629.42, 28.53, 260.03),  -- NPC and ox_target location
  Spawn       = vec4(459.36, -649.14, 28.13, 212.80),  -- where the bus spawns
  ReturnPoint = vec4(459.36, -649.14, 28.13, 212.80),  -- where drivers return the bus
}

To move the job to a different part of the map, update all three vec4 coordinates in this section.

Bus Outline Colour

lua
Config.BusOutline = { R = 255, G = 220, B = 0, A = 255 }  -- yellow highlight

Interaction Distances

lua
Config.Distance = {
  Interact = 50.0,  -- radius of the job interaction zone
  Spawn    = 5.0,   -- minimum distance from other vehicles before bus spawns
  Stop     = 15.0,  -- radius for detecting when a player reaches a bus stop
  Accident = 10.0,  -- radius used for accident detection
}

Routes

Bus routes are defined in bus-job-vehicle-routes. Each route specifies a list of stops with coordinates. You can add custom routes or modify existing stops by editing the routes file directly.

Common Issues

Job NPC not appearing - Check that ox_target starts before sc_busdriver in server.cfg.

Players can't pick up the job - If Config.CheckJob = true, the player's ESX job name must match the value in Config.Job.

Database table missing - Let the resource start at least once and check the server console for any oxmysql errors. The table is created automatically.

Bus not spawning - Make sure there is enough space at Config.Zone.Spawn. Another vehicle within 5 metres will block the spawn.

Support

Join the SleepyCode Discord at discord.gg/qCDt8u7Efg for help. Include your ESX Legacy version, ox_lib version, and any console errors. Purchase the script at sleepycode.eu/scripts.

The catalogue

Every script for ESX and QBCore, in one place.

Browse scripts

On this page

  1. 01Dependencies
  2. 02Installation Steps
  3. 03Job & Check Settings
  4. 04Payment Structure
  5. 05Penalty System
  6. 06Speed Limit & Driving Score
  7. 07Stop Time Limit
  8. 08NPC Passengers
  9. 09Cooldowns
  10. 10Zone Coordinates
  11. 11Bus Outline Colour
  12. 12Interaction Distances
  13. 13Routes
  14. 14Common Issues
  15. 15Support
Next

More guides

  • How to Install SleepyCode Garages V1 on FiveM ESXFull installation guide for SC Garages V1 - ESX garage system for FiveM. SQL setup, dependencies, config.lua options, commands and showroom.Read →
  • How to Set Up the SleepyCode Advent Calendar on FiveMSetup guide for SC Advent Calendar - FiveM seasonal reward script with 24 daily gifts. Dependencies, config.lua reward types and Discord webhook.Read →
Ready when you are

Put your server on something that holds up

150+ servers run our resources - ESX, QBCore and standalone. Once the payment clears, the package is waiting in Keymaster.

Browse the catalogueAsk on Discord ↗
  • Delivered instantly
  • Support with no expiry
  • 100+ reviews
  • Payment via Tebex

SleepyCode

FiveM Scripts

Checkout is run by Tebex Limited - they handle payment, invoicing and refunds. © 2026

Community

  • Discord
  • YouTube
  • X (Twitter)

Navigation

  • Home
  • All Scripts
  • ESX Scripts
  • QBCore Scripts
  • Free Scripts
  • About
  • Blog
  • Documentation
  • Support

Legal

  • Privacy Policy
  • Tebex Privacy Policy
  • Terms of Service
  • Impressum

© 2026 SleepyCode. Not affiliated with Rockstar Games or Take-Two Interactive.

Powered byTebex