mirror of
https://github.com/Citadel-Station-13/Citadel-Station-13-RP.git
synced 2026-08-22 10:06:58 +01:00
- all cells in the game are now small, medium, large - super, hyper capacity cells, device, and weapon cells are all removed - cells now have standardized variants, some of which are printable by R&D - energy weapons rebalanced - **advanced energy guns and stun revolvers removed** - use the new modular weapon system and microfission cells. --------- Co-authored-by: silicons <silicons@silicons.dev>
48 lines
1.3 KiB
Plaintext
48 lines
1.3 KiB
Plaintext
//* This file is explicitly licensed under the MIT license. *//
|
|
//* Copyright (c) 2024 Citadel Station Developers *//
|
|
|
|
/// key value id = middleware instance
|
|
GLOBAL_LIST_INIT(game_preference_middleware, init_game_preference_middleware())
|
|
|
|
/proc/init_game_preference_middleware()
|
|
var/list/keyed_middleware = list()
|
|
for(var/datum/game_preference_middleware/middleware as anything in subtypesof(/datum/game_preference_middleware))
|
|
middleware = new middleware
|
|
keyed_middleware[middleware.key] = middleware
|
|
GLOB.game_preference_middleware = keyed_middleware
|
|
return keyed_middleware
|
|
|
|
/datum/game_preference_middleware
|
|
/// category name
|
|
var/name
|
|
/// key
|
|
var/key
|
|
|
|
/**
|
|
* return TRUE to stop handling
|
|
*
|
|
* we assume the 'usr' has been validated by the prefs datum!
|
|
*/
|
|
/datum/game_preference_middleware/proc/handle_topic(datum/game_preferences/prefs, action, list/params)
|
|
return FALSE
|
|
|
|
/**
|
|
* when we want to reset whatever this handles
|
|
*/
|
|
/datum/game_preference_middleware/proc/handle_reset(datum/game_preferences/prefs)
|
|
prefs.mark_dirty()
|
|
return
|
|
|
|
/**
|
|
* sanitize everything
|
|
*/
|
|
/datum/game_preference_middleware/proc/handle_sanitize(datum/game_preferences/prefs)
|
|
prefs.mark_dirty()
|
|
return
|
|
|
|
/**
|
|
* on initial load
|
|
*/
|
|
/datum/game_preference_middleware/proc/on_initial_load(datum/game_preferences/prefs)
|
|
return
|