Configuration & Policies
Relevant source files
The following files were used as context for generating this wiki page:
BandaStation utilizes a multi-layered configuration system to manage server behavior, gameplay rules, and administrative policies. The system consists of flat text configuration files for core engine settings, structured TOML files for specific gameplay mechanics like job distribution, and JSON-based templates for in-game documentation and administrative forms.
The primary configuration entry point is config/config.txt, which includes modular sub-configs and defines global variables ranging from networking limits to round-specific timers. Policies are enforced through automated systems like the Panic Bunker and age-based job restrictions, ensuring server stability and role-play quality.
Core Server Configuration
The server's behavior is primarily governed by config/config.txt. This file defines fundamental constants for the BYOND environment and specific gameplay loops.
Master Controller and Performance
The Master Controller (MC) manages timed tasks such as lighting updates and atmospherics. The server adjusts its tick rate dynamically based on player population to maintain performance.
Sources: config/config.txt:310-332
Networking and Security
The configuration implements strict rate limiting and security checks to prevent denial-of-service attacks and unauthorized access.
| Option | Default/Limit | Description |
|---|---|---|
SECOND_TOPIC_LIMIT | 10 | Max interface clicks per second per client. |
MINUTE_TOPIC_LIMIT | 200 | Max interface clicks per minute (notifies admins). |
SECOND_CLICK_LIMIT | 15 | Max in-game object clicks per second. |
UPLOAD_LIMIT | 524,288 bytes | Max file size for standard client uploads. |
TGUI_MAX_CHUNK_COUNT | 32 | Max number of 1kb chunks for large UI payloads. |
Sources: config/config.txt:269-286, config/config.txt:399-417
Job and Access Policies
Job availability and requirements are managed through config/jobconfig.toml and enforced by the database. These policies control player progression and ensure critical roles are filled by experienced players.
Requirement Enforcement
The server checks multiple variables before allowing a player to join a specific role:
- Playtime Requirements: Measured in minutes of total living time.
- Account Age: Measured in days since the BYOND account was created.
- Character Age: In-game years for the specific character.
- Human Authority: Restricts specific Command roles (Captain, HoP, etc.) to human characters only.
Sources: config/jobconfig.toml:5-12
Job Configuration Example
[CAPTAIN]
"Human Authority Whitelist Setting" = "HUMANS_ONLY"
"Playtime Requirements" = 180
"Required Account Age" = 14
"Spawn Positions" = 1
"Total Positions" = 1
Sources: config/jobconfig.toml:44-49
Administrative and Connection Policies
Connection policies protect the server from ban evasion and low-effort spam through various "Bunker" systems.
Panic Bunker
The Panic Bunker restricts entry based on database records of a player's history. If PANIC_BUNKER is enabled, the server rejects connections from ckeys (BYOND accounts) that have not been seen before or do not meet living time requirements.
Sources: config/config.txt:203-228
Administrative Tools
The server supports both legacy text-based admin files and SQL-based permissions. The ADMIN_LEGACY_SYSTEM flag determines if admins.txt is used. Modern features like Admin 2FA (Two-Factor Authentication) can be enabled via URL redirection.
Sources: config/config.txt:39-49, config/config.txt:342-345
Database and Schema Policies
BandaStation uses a MySQL/MariaDB backend for persistent data. Any changes to game logic that require new data storage must be accompanied by a schema revision in the database.
Schema Versioning
Versions are tracked via major and minor integers stored in the schema_revision_220 table. Developers must increment these values when modifying tables such as minesweeper (tracking mini-game scores) or budget (managing in-game currency/donations).
| Table | Purpose | Key Fields |
|---|---|---|
ckey_whitelist | Stores players allowed to bypass bunkers. | ckey, is_valid, date_end |
admin_wl | SQL-based admin permissions. | ckey, admin_rank, flags |
schema_revision_220 | Tracks database versioning. | major, minor, date |
Sources: SQL/bandastation/database_changelog.md:1-68
Document Templates (Blanks)
The config/blanks.json file contains standardized HTML templates used for in-game paperwork. These "blanks" enforce corporate roleplay standards by providing formatted forms for departments.
Departmental Form Categories
- Command: Access requests, job applications, job terminations, and official orders.
- Security: Arrest warrants, search warrants, and execution orders.
- Medical: Autopsy reports, death certificates, and medical prescriptions.
- Litigation: Civil/Criminal complaints and court summons for high-intensity legal roleplay.
Sources: config/blanks.json:1-100
Conclusion
The Configuration & Policies system provides a modular framework for server administration. By separating engine settings (config.txt), gameplay restrictions (jobconfig.toml), and legal templates (blanks.json), BandaStation allows for granular control over the player experience while maintaining high performance through dynamic Master Controller scaling and strict network rate limits.