beyond-all-reason / beyond-all-reason/RecoilEngine

Let everybody pause; add `gadget:AllowPause(playerID, paused)`

Open
#1,067 0 comments 0 reactions 0 assignees View on GitHub
area: Lua API enhancement
Dominant language
C++
Stars
679
Forks
290
Avg merge
3d 2h
Merged PRs (30d)
40

Description

Bill of materials to be done before starting this ticket:
* #1372

----

Right now the engine hardcodes it so that players, and only players, can pause (i.e. specs can't pause, and you can't block a player from pausing). The engine should expose an interface for games to decide that instead:
* a basecontent gadget, or perhaps a default in case the game doesn't return an explicit true/false, that keeps current behaviour blocks it for spectators.
* most games would probably want to allow the host/boss of a room to pause even if he's a spectator.
* you could make it so everybody has 3 pauses.
* you could make it so that in a tournament, the players can't pause, only the judge.
* this would probably have to be a synced interface so replay watchers would be exempt and always able to pause.
* this would probably have to be a synced interface so you could even do something silly like make people pay metal for pausing.

A synced `Spring.SetPause(bool)` would be good too.

Contributor guide

Open the contributing guide

Research direction

Review prerequisite issue #1372 and the proposed gadget:AllowPause(playerID, paused) interface first. Clarify whether the synced Spring.SetPause(bool) API is also required; done means games can control who pauses while replay watchers remain exempt and current behavior has a default.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
api, game-dev
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.