WhereiamL
fivez_darts

Integration

Dependencies, the scrap economy and optional perks / logging.

dependencies

need these:

optional:

  • fivez_perks, gives perk xp on arcade games
  • fivez_logs, logs the scrap economy

both optional ones are checked at runtime, it runs fine without them.

economy

the currency is the ox_inventory scrap item:

  • arcade charges entryCost and pays scrap + perk xp when you finish.
  • 1v1 and tournaments escrow each player's stake / entry and pay the pot to the winner (minus an optional cut).

all of it is server-side and atomic. the entry comes out up front, the pot sits in escrow, and a cancel / drop / draw refunds the held stake. set wager.item in config.lua to use a different item.

what it saves

made on first start:

  • fivez_darts_scores, arcade personal bests
  • fivez_darts_stats, wins / losses / games / elo per player
  • boards.json, the boards you placed with /dartcreate, with stable ids
  • board.json, the visual calibration (geometry / cam / dart pose) from /dartstune

how it syncs

the board, darts and scoreboard stay in sync without networked entities:

  • the props are spawned locally on each client from the synced hit data.
  • match info rides a GlobalState entry that only writes when something changes.
  • hit / clear events only go to players inside syncRadius, off a server-side coord cache, not a broadcast to everyone.
  • the db only gets touched at the end of a match, never per throw.

so you get live spectating with no entity churn and no per-tick traffic.

On this page