Files
Bubberstation/code/datums/mocking/client.dm
SkyratBot fcf387a003 [MIRROR] Fix ambience pref not being toggleable in game (#28245)
* Fix ambience pref not being toggleable in game (#84087)

## About The Pull Request

The only time people were added to the ambience SS's list is when you
log in, meaning if you toggle the preference on/off mid game, it does
nothing.

Fixes #61495

## Changelog

🆑 Melbert
fix: Enabling or disabling ambience mid round will properly enable or
disable ambience
qol: Added descriptions differentiating "Ship ambience" from "ambience"
/🆑

* Fix ambience pref not being toggleable in game

---------

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
2024-06-19 10:03:24 +05:30

54 lines
1.2 KiB
Plaintext

/// This should match the interface of /client wherever necessary.
/datum/client_interface
/// Player preferences datum for the client
var/datum/preferences/prefs
/// The view of the client, similar to /client/var/view.
var/view = "15x15"
/// View data of the client, similar to /client/var/view_size.
var/datum/view_data/view_size
/// Objects on the screen of the client
var/list/screen = list()
/// The mob the client controls
var/mob/mob
/// The ckey for this mock interface
var/ckey = "mockclient"
/// The key for this mock interface
var/key = "mockclient"
/// client prefs
var/fps
var/hotkeys
var/tgui_say
var/typing_indicators
/datum/client_interface/New()
..()
var/static/mock_client_uid = 0
mock_client_uid++
src.key = "[key]_[mock_client_uid]"
ckey = ckey(key)
#ifdef UNIT_TESTS // otherwise this shit can leak into production servers which is drather bad
GLOB.directory[ckey] = src
#endif
/datum/client_interface/Destroy(force)
GLOB.directory -= ckey
return ..()
/datum/client_interface/proc/IsByondMember()
return FALSE
/datum/client_interface/proc/set_macros()
return
/datum/client_interface/proc/update_ambience_pref()
return