Skip to content

five-on-it / packages/protocol/src/cops

packages/protocol/src/cops ​

Players as the police, the prison transport and the bounty board (the ten-star build's F phase, GAME_DESIGN §12, §13), on the wire:

  • the client's CopCommand: a cop player's order (P1's phone: a cruiser, a roadblock, a drone or SWAT after a robber; P2's map: the same at a point), a text frame the server checks like any input (a cop's, the dispatcher's for a point, within the team's budget and cool-down, rate-limited, a robber the police know of);
  • the client's RoleCommand: the role a run's player takes in their team (P2, P3), while the run gathers or counts down;
  • the client's BountiesCommand: the bounty board switched on or off (M9);
  • the server's CopsMessage to one player, sent when it changes: their dispatch (a cop's: the team's budget, the orders' costs and cool-downs, the last order's answer, the cuffs' progress, the suspects where the police last placed them, the backup out), the prison transports they ride or could stop (a captive's, their crew's: where the van is, where it goes, whether it stands still, the rear doors' progress) and the bounty board (whether theirs is on, the bounties of the room, a carrier's place within 300 m).

Type Aliases ​

Variables ​

Functions ​