Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Security level refactor, also GLOB.marine_main_ship is dead #17148

Open
wants to merge 40 commits into
base: master
Choose a base branch
from

Conversation

Neocloudy
Copy link
Contributor

@Neocloudy Neocloudy commented Feb 17, 2025

About The Pull Request

Forgive me. Both for the potential code fuckups and the fact the first commit for this dates back to June 2024. It's another one of my refactors that I start and then don't PR for months.

On security levels

Security levels are now handled on a subsystem that reads subtypes of /datum/security_level, instead of every security level being hardcoded into a big switch block. This is a port of TG's security level backend, essentially.

Quite a bit can be changed about them by coders (or VV users). Flags exist for how it can be set by players, if it has delta alert traits (entails a state of emergency), and vars exist for some customization (announcement card colors, status display icons, fire alarm light colors, lowering/raising body and sound, config entries).

Signals are now used for any world objects that react to the sec level changing, instead of the previous implementation of doing all that in the proc where security level changing is handled.

GLOB.marine_main_ship is gone

GLOB.marine_main_ship is dead, the vars it was holding are split into two GLOBAL_DATUMs (orbital_cannon and rail_gun) for our shipside fire support and a GLOBAL_VAR for emergency maints.

Why It's Good For The Game

Hopefully better code.

Changelog

🆑
refactor: Refactored security levels and removed GLOB.marine_main_ship. Please report any weird behavior with security levels, or the systems affected by this removal (OB, railgun, maint all access, keycard authentication).
/:cl:

Neocloudy added 30 commits June 22, 2024 03:53
…el, improved announcements, unhardcoded status display stuff, slightly less hardcoded fire alarm stuff, improved doc
@github-actions github-actions bot added Refactor Improves underlying code to make systems more modular and functional. and removed Refactor Improves underlying code to make systems more modular and functional. labels Feb 17, 2025
@TiviPlus TiviPlus added the Refactor Improves underlying code to make systems more modular and functional. label Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactor Improves underlying code to make systems more modular and functional.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants