Dynamic Billboard Advertising
Requirements
Section titled โRequirementsโ| Dependency | Required | Purpose |
|---|---|---|
| oxmysql | โ Yes | Stores boards, rentals, views, kiosks, reps, and settings |
| rs_ad_agency_assets | โ Yes (included) | Billboard faces, house ads, the kiosk prop, and render slots |
| Qbox, QBCore, or ESX | For charging rent | Player money, jobs, and admin groups |
| OneSync | Recommended | Lets nearby players watch a kiosk session |
| ox_target or qb-target | Optional | Target interaction with kiosks and reps |
Installation Steps
Section titled โInstallation Stepsโ1. Install the Resources
Section titled โ1. Install the ResourcesโDownload both resources from your Cfx.re Keymaster and place them in your serverโs resources directory.
resources/[retro]/rs_ad_agency/resources/[retro]/rs_ad_agency_assets/Keep the folder names exactly rs_ad_agency and rs_ad_agency_assets. Upload the rs_ad_agency/data/ads/ folder with its README.txt so your FTP client creates it.
2. Add the Resources to server.cfg
Section titled โ2. Add the Resources to server.cfgโStart the asset pack and the script after the database, your framework, and the optional target resource.
# Qbox exampleensure oxmysqlensure qbx_coreensure ox_targetensure rs_ad_agency_assetsensure rs_ad_agencyFor QBCore, start qb-core (and qb-target if used) first. For ESX, start es_extended first. rs_ad_agency_assets must always start before rs_ad_agency.
3. Set Admin Permissions
Section titled โ3. Set Admin Permissionsโadd_ace group.admin command.rsadagency allowA player is an agency admin if any of these is true:
- They have the ACE
command.rsadagency. - They have the general
commandACE, which most admin groups already have. - Qbox group
godoradmin, QBCore permissiongodoradmin, or ESX groupsuperadminoradmin.
The framework groups can be changed in AgencyConfig.Framework.
4. Restart and Let It Set Up
Section titled โ4. Restart and Let It Set UpโThe resource creates its own SQL tables automatically on the first start. There is no .sql file to import. Your database account must be able to create tables.
On the first start with a new database, six starter kiosks are placed around the map:
| Starter kiosk | Area |
|---|---|
| Ad Agency Kiosk | Rockford Hills |
| Ad Agency Kiosk | Maze Bank Arena |
| Ad Agency Kiosk | Tataviam (Route 15) |
| Ad Agency Kiosk | Harmony |
| Ad Agency Kiosk | Paleto Bay |
| Ad Agency Kiosk | Chumash |
They are ordinary placed kiosks: admins can move or remove them in game, and removed ones never come back. To begin with no kiosks, empty AgencyConfig.Kiosk.StarterLocations before the first start.
5. Place More Kiosks and Reps
Section titled โ5. Place More Kiosks and Repsโ/rsad_kiosk place [label]/rsad_npc placePlacing shows a preview: use the mouse wheel to rotate, then press Enter or left click to place. Kiosks and reps are saved in the database and restored after restarts. Both commands also take remove and list.
6. Verify
Section titled โ6. VerifyโAfter starting the server, check the following:
- The console shows no errors from
rs_ad_agencyorrs_ad_agency_assets. - Ad Agency Kiosk blips appear on the map.
- Walking up to a kiosk and pressing E (or using your target) opens the agency manager on the kiosk screen.
- Renting a board charges the configured account (bank by default).
- A saved ad appears on the real billboard, including for a second player nearby.
/adagencyadminopens the admin panel for staff.