* Drastic Lag Mitigation Subsystem: SSlag_switch (#59717)
Requested by oranges and inspired by the upcoming event. A new subsyetem, non-processing (for now), aimed at providing some toggle switches that can be flipped as a last ditch effort to save some CPU cycles by sacrificing some non-critical mechanics. Below you can see each individual toggle.
Screenshot of the admin panel:
image
Surely there are more opportunities for toggles I missed, but adding new ones is not very difficult at all.
Why It's Good For The Game
Better performance during extreme pop, I hope.
Changelog
cl
code: Introduces the Lag Switch subsystem for when a smoother experience is worth trading a few bells and whistles for. Performance enhancement measures can be togged by admins with the Show Lag Switches admin verb or enabled automatically at a pop amount set via config.
config: Added a new config var: number/auto_lag_switch_pop
* Drastic Lag Mitigation Subsystem: SSlag_switch
* mirrored the changes to the modular file
Co-authored-by: Wayland-Smithy <64715958+Wayland-Smithy@users.noreply.github.com>
Co-authored-by: Useroth <37159550+Useroth@users.noreply.github.com>
* Admin QOL: Adds a speech prefix for ghosted admins to talk through their linked body (#59762)
One of the more annoying parts of sending in a centcom official or ERT as an admin is the fact that sometimes you need to keep in touch with them- especially when you're supporting a response team with multiple people, and sending them headset messages one-by-one or using command reports won't cut it. In these cases, I spawn myself in at centcom (or use the body I made for briefing) and talk on the Centcom radio freq, but this sucks because while you're in the body, you can't watch what they're doing because you're not a ghost!
So this PR adds a special speech prefix for admin ghosts, :j, which tries to relay your chat message to your linked body if one exists, instead of sending it to deadchat.
* Admin QOL: Adds a speech prefix for ghosted admins to talk through their linked body
Co-authored-by: Ryll Ryll <3589655+Ryll-Ryll@users.noreply.github.com>
* fixes issue with ghosts being able to affect the world, oversight from the crossed refactor (#59010)
* as anything in _SendSignal
* Revert "as anything in _SendSignal"
This reverts commit 350c4b33d975d25003afb2cab2458a3026676559.
* ghosts can no longer affect the world (hopefully)
* fixes issue with ghosts being able to affect the world, oversight from the crossed refactor
Co-authored-by: Kylerace <kylerlumpkin1@gmail.com>
* Layer overhaul (#57915)
## About The Pull Request
Changes up some layer and plane defines for no particular reason lol
## Why It's Good For The Game
Planes actually override layers, and layers control ordering within planes. A lot of the usage of plane and layer was wholly unnecessary. This refactor helps future maintainability while also being needed staging for _future features._
* Layer overhaul
* aaaaaaaaa
a
Co-authored-by: Rob Bailey <actioninja@gmail.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
* Observers can now use emojis at the start of messages without the risk of triggering admin commands. (#57433)
Added a client.holder check to the line about radio extensions for admin chat and deadchat commands. It means common observers can finally spam dchat with plushie emoji. Admin observers still have to deadmin before using emojis safely, until someone takes the time to refactor saycode mods so these admin commands only acept the comma prefix (luckily, observer/get_message_mods() doesn't trim the message).
* Non-admin observers can now use emoji that start with d or p at the beginning of a message without admin command warnings.
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
* Allows ghosts to start messages with asterisks in deadchat again (#57159)
#56519 had noble goals in trying to make emote code more robust for
ghosts, but in doing so it undid #47144, which was made to allow people
to start messages with asterisks in deadchat without getting hassled by
the game thinking you're emoting. This re-limits the emote checker to
the only two emotes ghosts have ever had, *spin and *flip.
* Allows ghosts to start messages with asterisks in deadchat again
Co-authored-by: Ryll Ryll <3589655+Ryll-Ryll@users.noreply.github.com>
* You no longer need to hold shift to open the context menu as a ghost (#56646)
* You no longer need to hold shift to open the context menu as a ghost
Co-authored-by: Qustinnus <Floydje123@hotmail.com>
* Fixes emote runtime / changes how emotes work for ghosts (#56519)
* Fixes / refactors emotes
Crack emote no longer runtimes
Ghosts can use help emote
Exhale / inhale emote only work for living
Move beep emote living subtype
Help emote no longer tells you that you can't use it
* Remove var in arguments
Lint
* Replace loop with join
* Fixes emote runtime / changes how emotes work for ghosts
Co-authored-by: Gamer025 <33846895+Gamer025@users.noreply.github.com>
* Fixes and refactors death examine code (#55907)
Examine death bodies should now display the correct text
Changed the logic so that the message tells you if the players is:
- Still in his body (`[t_He] [t_is] limp and unresponsive; there are no signs of life...`) or
- A ghost that could enter the body again (`[t_He] [t_is] limp and unresponsive; there are no signs of life and [t_his] soul has departed, but the link is not yet fully broken...`) or
- No ghost, that can reenter the body and no key (`[t_He] [t_is] limp and unresponsive; there are no signs of life and [t_his] soul has lost the will to live...`)
Also refactored the code a bit:
- Moved the death examine message generation to a proc so that you can work with returns
- Removed pushed_do_not_resuscitate since its not needed this way
* Fixes and refactors death examine code
Co-authored-by: Gamer025 <33846895+Gamer025@users.noreply.github.com>
* Specifies if DNR was pushed in body examine text (#55399)
Adds the examine text " and [t_his] soul has lost the will to live..." instead of the usual "soul departed" message if the person hits DNR.
* Specifies if DNR was pushed in body examine text
Co-authored-by: Emmanuel S <mrdoomboyo@gmail.com>
* Fixes GC for observers and new players, and tons of loose references to stuff that shouldnt be (#55563)
I've done this on a signal because atom_hud is applied very loosely in some contexes, and the objects themselves dont have an easy way to track back into what huds they're affected by, so this seemed the best. Properly cleans up next_time_allowed, which was missing.
Update: I discovered this is also an issue for a lot of simple mobs, such as slimes and bots and such. So fixing this is huge
* Fixes GC for observers and new players, and tons of loose references to stuff that shouldnt be
Co-authored-by: Azarak <azarak10@gmail.com>
* Converts A && A.B into A?.B (#54342)
Implements the ?. operator, replacing code like A && A.B with A?.B
BYOND Ref:
When reading A?.B, it's equivalent to A && A.B except that A is only evaluated once, even if it's a complex expression like a proc call.
* Converts all A && A.B into A?.B
Co-authored-by: ZeWaka <zewakagamer@gmail.com>
* Enforce preserving parent proc return values across ui_act call stacks (#53964)
All ui_act procs should call parent by default. All procs should preserve the value of the parent proc when it's TRUTHY and pass it down the call stack. No UI should be interactible when its flags or state indicate it should not be, except when explicity overriden by child procs intentionally disregarding parent return values to achieve a specific goal.
* Enforce preserving parent proc return values across ui_act call stacks
Co-authored-by: Timberpoes <silent_insomnia_pp@hotmail.co.uk>
* Optimize stat panel and fix guardian verbs (#53463)
Optimizes stat panel code for better performance, including icon caching and removing some unnecessary processing
Also fixes#53432fix#53381fix#53724
Changelog
add: icons are back on alt clicks
fix: horrible performance from alt clicking turfs with multiple objects
tweak:browser should notify the SS when it's ready to receive data
* Update statbrowser.html
* Apply suggestions from code review
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@ users.noreply.github.com>
* hidden = TRUE
* almost ready
* Browser should notify when ready to receive data
* Apply MSO's suggestions
* reset cache if something in it gets deleted
* Fix runtime
* fix my stupid code
* send href_token when adding admin tabs
* fix an issue with cyborg suit topic
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@ users.noreply.github.com>
* Optimize stat panel and fix guardian verbs
Co-authored-by: Couls <coul422@gmail.com>
Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@ users.noreply.github.com>
* Smooth Movement: Resurrection: Resurgence: Revengeance 4: The Return of Smooth Movement: Smooth Edition Director's Cut (#52515)
Automatic glide size adjustment based on move delay.
Essentially a port of https://github.com/yogstation13/Yogstation/pull/8132 but that was mostly my code with some fixes.
Why again? well it turns out the recent byond fixes to glide size actually worked and solved the issues that were unsolvable.
https://file.house/0B3u.mp4
Glide size no longer incorrectly scales at fps, so it works as intended at any framerate with the only stuttering being normal byond suck stuttering.
* Smooth Movement: Resurrection: Resurgence: Revengeance 4: The Return of Smooth Movement: Smooth Edition Director's Cut
Co-authored-by: Rob Bailey <actioninja@gmail.com>
* Overlay lighting component (#52413)
Sparks no longer lag, projectile beams move super smoothly, same with mobs and whatnot. This also allows for easy expansion into directional lights, field-of-view, wee-woo rotating lights or whatever.
It does have a downside: things right-clicked or checked through the alt+click tab will show the light overlay:
This is a BYOND limitation, very well worth it IMO.
🆑
add: Smooth movable lighting system implemented. Projectiles, sparks, thrown flashlights or moving mobs with lights should be much smoother and less laggy.
balance: Light sources no longer stack in range, though they still do in intensity.
/🆑
* Overlay lighting component
Co-authored-by: Rohesie <rohesie@gmail.com>
* [Ready] CDN browser assets! (#52681)
Rewrites the asset_cache system to handle sending assets to a CDN via a webroot.
see https://github.com/MrStonedOne/tgstation/blob/asset-cdn/code/modules/asset_cache/readme.md
Fixed a lot of bugs with assets, removed some dead code.
Changes:
Moved asset cache code to transport datums, the currently loaded one is located at SSassets.transport, asset cache calls made before the config is loaded use the simple browse_rsc transport.
Added subsystem call for when the config loads or reloads.
Added a webroot CDN asset transport. assets are saved to a file in a format based on the file's hash (currently md5).
Assets that don't use get_asset_url or get_url_mappings (such as browser assets referred to by static html files like changelog.html or static css files) can be saved to browse_rsc even when in cdn asset mode by setting legacy to TRUE on the datum returned by register_assets
Added a system for saving assets on a cdn in a hash based namespace (folder), assets within the same namespace will always be able to refer to each other by relative names. (used to allow cdn'ing font awesome without having to make something that regenerates it's css files.).
The simple/namespaced asset cache datum helper will handle generating a namespace composed of the combined md5 of everything in the same datum, as well as registering them properly.
Moved external resource from a snowflake loaded file to a config entry, added it to resources.txt
To ensure the system breaks in local testing in any situation that wouldn't work in cdn mode, the simple transport will mutate the filenames of non-legacy and non-namespaced assets and return this with get_asset_url.
Simple transport's passive send of all roundstart assets to all clients is now a config that defaults to off. this is to break race conditions during local testings from devs accidentally relying on this instead of using send() properly.
cl
refactor: Interface assets (js/css/images) can now be managed using an external webserver instead of byond's one at a time file transfer queue.
admin: Adds admin verb toggle-cdn that allows admins to disable the external webserver asset transport and revert to the old system. Useful if the webserver backing this goes down (thanks cloudflare).
config: New config file, resources.txt, (must be loaded by an $include statement from the main config)
server: The external_rsc_urls.txt config has been moved to the main config system.
/cl
Porting notes:
Interface webpages must refer to their assets (css/js/image/etc) by a generated url, or the asset must register itself as a legacy asset. The system is designed to break in localtest (on simple/legacy mode) in most situations that would break in cdn mode.
Requires latest tgui.
The webserver must set the proper CORS headers for font files or font awesome (and other fonts) won't load.
/tg/'s webserver config: https://gist.github.com/MrStonedOne/523388b2f161af832292d98a8aad0eae
* [Ready] CDN browser assets!
Co-authored-by: Kyle Spier-Swenson <kyleshome@gmail.com>
* Refactors area stuff (#52751)
-bitfielded a bunch of bools on /area, I left some untouched cus they get called a lot
-Unused vars
-Fixed a var pretending to be a fake bool
-Probably more
* Refactors area stuff
Co-authored-by: TiviPlus <57223640+TiviPlus@users.noreply.github.com>
* new roles
* Madness rename
* hop judgement override
* hop vote fixed, travis happy
* hop fixed
* Update code/modules/mafia/_defines.dm
Co-authored-by: Fikou <piotrbryla@onet.pl>
* highly experimental random setup system
* hop cannot reveal before any voting is possible, lmao
* this shit actually works lmfao
* removes forced_setup, nightmare detection immune
* whoop
* removes setups!
* OK, finally kind of done with all this minus the incoming reviews
* adds hop's ability to their text, removes old var
* bundle?
* Update tgui.bundle.js
* role fixes (roleblock not working on a few)
* eep
* fuck
* potato's review
* Update tgui.bundle.js
* ffff
* bundle
* rohesie's review
* eureka
* updates doc, removes debug stuff
Co-authored-by: Fikou <piotrbryla@onet.pl>