Features

Call Desk

Calling a doctor, the law, a smith, the coach, a vet or the undertaker from the book, how responders take calls, and Config.Cagri.

Call Desk (cagri) lets a player call a service. The call goes to every player in the game whose job answers that service and who is on duty. The first responder who takes it gets a route to the caller.

#What the player can do

Caller:

  • Pick a service, add a quick reason or a short note (up to 140 letters) and send the call. The page shows how many players of that service are on duty.
  • See their own calls, who took them, and cancel a call.

Responder (a player on duty whose job is listed in a service's jobs):

  • See the open calls of their services with the distance to the caller.
  • Take a call. The caller is told who is on the way and the responder gets a route on the map.
  • Draw the route again, and close the call when done. The caller is told the call is finished.

The caller's position is read by the server when the call is made. If a responder leaves the game, the call opens again for others. If the caller leaves, the call is dropped.

The Physician app's "Call a doctor" button opens this app on the doctor service.

#What it needs

Nothing but the jobs. No signal, money or items. Calls are kept in memory only and are not written to the database.

#Settings

apps/cagri/config.lua (Config.Cagri):

Key Default What it does
Enabled true Turns the app on
ExpireMinutes 20 An open or taken call is dropped after this
Cooldown 45 Seconds between two calls of one character
MaxOpen 2 Calls one character can have waiting at once
OnDutyOnly true Only players on duty get calls, see the open calls and can take one
Services six services, see below What can be called and which jobs answer

A service has an id, the name shown to players, art (the drawing: doctor, sheriff, smith, coach, vet or undertaker) and jobs, the framework job names that answer it.

Service Jobs that answer by default
doctor doctor, medic
sheriff sheriff, deputy, marshal, police, lawman, vallaw, rholaw, blklaw, strlaw, stdenlaw
smith blacksmith, smith
coach coach, stagecoach, taxi
vet vet, veterinarian
undertaker undertaker

Match the job names to your server. The sheriff line holds the VORP and RSG law jobs:

lua{ id = 'sheriff', name = 'Serif', art = 'sheriff', jobs = { 'sheriff', 'deputy', 'marshal', 'police', 'lawman', 'vallaw', 'rholaw', 'blklaw', 'strlaw', 'stdenlaw' } },

With OnDutyOnly = true only players on duty get calls, see the open calls and can take one. On RSG the duty comes from the core's own duty flag. On VORP it comes from the duty switch of the Official Ledger for the jobs listed in Config.MDT.Jobs. A job with neither always answers. Taking a call while off duty answers "Go on duty first." With false every player with a listed job gets the call.