Commit Graph

31 Commits

Author SHA1 Message Date
VMSolidus 7aeab49ce5 Datum Destroy Optimizing (#22693)
Some concerns were brought up about the potential for performance
concerns with wrapping Destroy() in a try catch. So let me make a trade.
/datum is the parent of all objects in existence, and is spending a
large chunk of time on proc overhead for 2.6 million qdel'ed objects.

<img width="1196" height="811" alt="image"
src="https://github.com/user-attachments/assets/06ca1596-2d56-40ca-9ec6-9215ed02113c"
/>

I'll trade you a faster global destroy() for the better logging so I can
finish destroying the garbage collector lag.

The cost reduction is from 0.01209ms per datum to 0.007525ms per datum,
about a 28% time saving.
2026-06-19 16:08:15 +00:00
VMSolidus 206bb29d52 Final Mob Destroy Audit (#22728)
I've audited the entire destroy path between datum and human, this time
paying attention to byond's built-in vars to make sure that the built-in
refs are correctly being cleared. I've also gone and corrected some
null-access mistakes, which are most prominently caused by as anything
casts not being null checked, since as anything allows null entries in a
list to be read.

By far the worst offender I've found was the lack of clearing of the
atom.underlays var, which contains a list of refs. And when searching
for uses of this var across the repo, I've discovered it's associated
with an overwhelming majority of the remaining objects still in the hard
del trackers.
2026-06-19 14:18:33 +00:00
Wildkins 84d3a447ab Lag War Day 2: TGUI performance improvements (#21848)
<img width="707" height="659" alt="image"
src="https://github.com/user-attachments/assets/6c8db0bf-dec6-40f2-86e8-120531fa5693"
/>

the traitor uplink is causing a genuine hostage situation to the server
by simply being open due to the frankly insane amount of data that it
builds and ships every single UI process tick (which is very often!!!)

i've never been ragebaited by a single .dm file before so hard in my
entire developer career so I simply neutered it into using static data
and hit the commit button. it might break, if it does we're burning it
to the ground and remaking it. genuinely heinous crimes going on there

In addition I'm porting:

* [Fix several SHOULD_NOT_SLEEP hits in SStgui.update_uis()
tgstation/tgstation#75411](https://github.com/tgstation/tgstation/pull/75411)
* [Moves ui references from the tgui subsystem to datums themselves
tgstation/tgstation#76215](https://github.com/tgstation/tgstation/pull/76215)
* [Fixes some spurious runtimes in SStgui procs
tgstation/tgstation#76251](https://github.com/tgstation/tgstation/pull/76251)
* [Fixes tgui_open_uis tracking
tgstation/tgstation#77101](https://github.com/tgstation/tgstation/pull/77101)

moving ui references to the datums themselves is a pretty nice
performance boost because otherwise we have to iterate across all open
uis every time a list input closes which sucks! the rest are just fixes
to that original PR.

thank you for your attention to this matter
2026-02-14 02:17:23 +00:00
Wildkins 3d183d7262 Begin, the Lag Wars Have (#21839)
<img width="700" height="848" alt="image"
src="https://github.com/user-attachments/assets/e0db50af-35db-43c7-b78e-6c1ea5ac569c"
/>

you take a tiny little two year LOA and this happens
this PR hits some large lag culprits:
- UpdateOverlays() getting spammed by human/update_icon. This was 0.85%
of server CPU time during the event. Doesn't sound like a whole lot but
it's insane. 99% of it was caused by sloppy duplicate calls of
update_icon in set_dir (as well as update icon itself!). Refactored to
stop that
- Makes Follow menu update manually, which cuts down on the 2.8 million
REF() calls it made during the event. This was ~1% of CPU time including
ui_data as well.
- Gets rid of a bunch of random runtimes and some lighting-related
harddels.
- NanoUIs now clean themselves up when their owner qdels rather than
forcing the owner to do REF(src) and close all matching UIs. saves us
~0.1% server cpu time! wowza!
2026-02-09 23:20:48 +00:00
Fluffy be92376296 Verbs subsystem (#20333)
What it says on the can; now we can better compensate for processing
spikes by queueing and accounting for verb times (assuming we actually
use this framework to invoke the bulk of them). I have added its use to
some of them, more can be ported as time goes on, eventually everything
but the most trivial ones should go through this.

No player facing changes. Hopefully.

Praise be the omnissiah.
2025-01-13 12:17:37 +00:00
Fluffy 513facdb0d Refactored deletion observables to use the COMSIG_QDELETING signal (#20121)
Refactored deletion observables to use the COMSIG_QDELETING signal
instead, removed the observable.
2024-11-04 21:51:18 +00:00
Fluffy 7cc7778131 Various VV work and fixes (#19288)
Refactored various procs used by VV: Header generation, dropdown menu
generation, moved various things around, some defines.
Fixed VV to be able to edit associative lists.
Fixed VV to be able to make a list ex nihilo on a var.
Removed various dropdown menus that didn't exist anymore and were doing
nothing.
Fixed add verb option to not wipe the already existing verbs of the mob.
Fixed a runtime error on some lists view building that were not handled
correctly.
Fixed an issue with build mode not having the correct permissions for
devs.
Fixed an issue with editing a list referenced by a key in another list
via the edit referenced object option.
Added DF_VAR_EDITED flag.
2024-09-23 19:26:17 +00:00
Fluffy 0ae0b10764 Refactored all the backslash ref and ref() calls to use REF() instead (#19847)
Refactored all the backslash ref and ref() calls to use REF() instead.
Added a linting for raw ref proc calls.
2024-09-13 10:17:32 +00:00
Fluffy 41a05bc196 Refactored the abstract meta propriety (#19797)
Refactored the abstract meta propriety into defines.
It's now more easy to spot/see abstract types thanks to the macro that
defines them.
Added a check on initialization of atoms to avoid spawning abstract
types.
Made the spawn_atom proc check for abstractness.
Made the spawn_atom proc use tgui_list for types list shorter than 1000
elements, which enables to search in them. It's too laggy on larger
lists so above 1000 it uses the builtin input.
Made the spawn_atom use a list subtraction instead of a double list,
it's lighter on memory and processing.
2024-08-23 10:49:28 +00:00
Fluffy 947487ba62 Updated the Datum Component System and dcs signals handling (#19625)
Updated the Datum Component System and dcs signals handling
2024-07-20 17:33:21 +00:00
Fluffy 1f759338d8 Processing subsystems improvements (#18961)
Refactored the use of the isprocessing var into the datum flag
DF_ISPROCESSING.
Updated SSprocessing and SSmachinery to have a constant fire rate.
Updated gas cooler to be time-constant thanks to the above.
2024-04-20 20:16:08 +02:00
Fluffy ab23fbdb70 Function overloads condensation (#18939)
Unified most of the procs into one definition, so there are no duplicate
around the codebase.
Marked some of the above as overridable if a good enough case can be
made for them (eg. external dependency or unlikely to be used).
2024-04-19 21:19:41 +00:00
Fluffy 9bb5a8ea09 Made the Destroy proc not sleepable (#18940)
Made the Destroy proc not sleepable

---------

Co-authored-by: FluffyGhost <FluffyGhost>
2024-04-16 20:03:23 +00:00
Matt Atlas 57067892d8 Ports the weather system from Nebula. (#18706)
* part 1

* compiles?

* IT WORKS

* vis contents

* fixes

* umbrelloid

* umbrella 2

* dsasdd

* stuff

* lmao

---------

Co-authored-by: Matt Atlas <liermattia@gmail.com>
2024-03-24 14:05:00 +00:00
Fluffy e9a699c911 Update reftracking (#18631)
* Atomization

* changelog

* sdf

---------

Co-authored-by: FluffyGhost <FluffyGhost>
2024-03-21 19:02:55 +00:00
Fluffy 0f68816354 Timer subsystem update, second try (#18547)
* sdafsa

* sdfa
2024-02-29 18:30:04 +00:00
Fluffy a483708104 sdfaasd (#18411) 2024-02-18 00:40:01 +00:00
Fluffy ca6b04e1d7 Updated SSgarbage (#18173)
* pain

* sadfas

* sdfa

* sdfasf

* sfa

* sdf

* might the lord have mercy on our soul

* i cri everidai

* adeste fideles

* sdf

* where will this lead, what's coming next, from your inventions

* dear lord

* gjvhk

* i cri everidai

* fsgf

* sdfa

* sdaf

* hiuhi
2024-01-15 14:08:27 +00:00
Fluffy e867030c2e Update MC (#18112)
* sdf

* fsda

* fuck

* fuck2

* toolz

* sdaf

* sdfa

* saf

* sdfa

* sdfa

* sdf

* sdfa

* temp rename

* temp rename

* temp rename

* sdaf

* the pain is immensurable in the land of byond

* the curse of rah

* safd

* sadf

* sadf

* gf

* asf

* fssdfa

* sfd

* sadf

* sfda

* brah

* brah

* it's easier for you to fix this

* ffs

* brah

* brah
2024-01-06 17:03:57 +01:00
Matt Atlas cadd19beac Ports the TG globals controller and converts globals. (#18057)
* SDQL2 update

* fix that verb

* cl

* fix that

* toworld

* this is pointless

* update info

* siiiiick..

* vv edit update

* fix that

* fix editing vars

* fix VV

* Port the /TG/ globals controller.

* part 1

* part 2

* oops

* part 3

* Hollow Purple

* sadas

* bsbsdb

* muda na agaki ta

* ids 1-15

* 16-31

* 41-75

* bring me back to how things used to be before i lost it all

* the strength of mayhem

* final touches

* cl

* protect some vars

* update sdql2 to use glob

* stuff?

* forgot that is not defined there

* whoops

* observ

* but it never gets better

* a

---------

Co-authored-by: Matt Atlas <liermattia@gmail.com>
2023-12-26 01:16:02 +00:00
Matt Atlas 12487c94bb Updates SDQL2 to the latest TG version and adds variable protection. (#17997)
* SDQL2 update

* fix that verb

* cl

* fix that

* toworld

* this is pointless

* update info

* siiiiick..

* vv edit update

* fix that

* fix editing vars

* fix VV

* discord protection

---------

Co-authored-by: Matt Atlas <liermattia@gmail.com>
2023-12-25 17:10:35 +00:00
Fluffy 97db278cab Reference tracking tweaks (#17725)
* Atomization

* sdfas

* sdf

* Update html/changelogs/FluffyGhost-reference_tracking_tweaks.yml

Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>

---------

Co-authored-by: FluffyGhost <FluffyGhost>
Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>
2023-11-06 16:48:46 +00:00
Matt Atlas 31956c7eb0 Rock the UI Away - Removes VueUI and adds TGUI (#16509)
* tgui the beginning

* binaries and the like

* Bring in the last of it

* Example radio UI

* delete example

* NTOS Main Menu, start on manifest, tgui states

* tasks.json

* gunnery ui pt 1

* okay

* fix everything

* scss update

* oops

* manifest gigablast

* downloader part 1

* download prt 2

* NTOSDownloader final

* mfw committing to_worlds

* gunnery console pt2

* i cooked

* targeting (finished)

* one vueui down

* voting ui almost done

* MY MIND FEELS LIKE AN ARCH ENEMYYYY

* voting ui down

* photocopier

* ntos config + download fixes

* photocopier 2

* refactor define

* NTOS client manager + fixes

* fax machine final (it also uses toner now)

* marching forwards... left behind...

* ntnrc part 1

* canister

* add quotes

* portable pumps pt1 + more backgrounds

* oops

* finish the portable pump

* freezers

so I'll keep on pushing forward... you haven't seen the last of me... oooooooh...

* doors ui pt1

* finish doors UI (forgive me wildkins it's a bit of shitcode)

* vitals monitor, make things use labeled lists, new backgrounds

* mais j'envoyé aucun mayday...

* maglock pt1

* pour ça je me suis perdu...

* infrared

* fix that

* prox sensor pt1

* prox sensor

* signaler (this was actually pretty hard)

* atmos control pt1

* atmos control pt1.1

* atmos pt 2

* fuel injector

* multitool UI

* jammer

* list viewer

* APC

* portgen

* targeting console updates + SMES ui

* new themes, shield generator

* supermatter

* Add ore detector and (shitty) NTNet Relay

* orderterminal pt1

* orderterminal pt2

* smartfridge

* Add (air-)tank GUI update ore detector size

* Adds Transfer Valves

* Add AtmoScrubber

* analyzer pt1

* weapons analyzer pt2

* bodyscanner pt1

* bodyscanner pt2

* fix this shitcode

* seed storage

* appearance changer

* appearance changer final

* sleeper pt1

* sleeper

* gps

* vehicles

* chem dispenser

* lily request

* holopad

* tgui modules pt1

* ppanel

* damage menu

* fixes

* im here too now

* follow menu, search bars

* quikpay

* quikpay fixes

* circuit printer

* ppanel

* ppanel updates

* pai

* turret controls (i want to kill myself)

* tweak

* remove the boardgame

* guntracker

* implant tracker

* penal mechs

come close to me, come close to me

* chem codex

* pai radio

* doorjack

* pai directives

* signaler removal, sensors

* ghost spawner

* spawnpoint

* fixes

* teleporter

* one more to the chopping block

* account database

* remove divider

* scanner, atmos

* latejoin ui pt1

* latejoin

* records pt1

* RECORDS UI DONE

* delete interpreter & records

* CHAT FUCKING CLIENT

* data updates

* fix some things

* final UI, log

* basic nanoui fix

* antag panel

* remove vueui

* atm update

* vending update

* warrants, cameras

* ntmonitor

* time comes for all

* preserve this legacy

* bring that back (oops)

* rcon, ui auto update for computer UIs, remove rcon computers

* alarm monitoring (a bit broke and also todo: add custom alarm monitoring programs to a few consoles)

* A LIKE SUPREME

* a

* power monitor

* lights on

* fuck this code, fuck nanoui modules, and fuck nanoui

* LEAVE IT OH SO FAR BEHIND

* fix alarm monitoring for synths

* I SAW IN YOU WHAT LIFE WAS MISSING

* comms console

* idcard and record updates

* turn the light on

* arcade

* pt2

* news browser

* static

* crusher

* f

* COULD I JUST SLEIGH THE GOLD FROM THE BALLS? I'M SO FRUSTRATED OH COULD YOU TELL? IF I HEAR ONE MORE VUEUI OR ONE NANOUI I'M GONNA LOSE IT SO LET ME GOOOOOOOOOOOOOOOOO

* codeowners & suit sensors

* html ui style removal

* make lint happy

* resist and disorder

* i slowly get up and turn off the noise, already fed up...

* pleaseeeeeeeeeeeeeee

* THE CREDIT LARP IS NECESSARY

* i hold the keys

* RISE UP

* fix that?

* harry's suggestions xoxo

* runtime fix pt2

* You are the only thing that I still care about

* adds build workflow

* Update update_tgui.yml

* adds some needed steps

* ATM

* misc fixes and tweaks

* fixes 2

* make newscasters usable and fix use power on freezers

* turret control is clearer

---------

Co-authored-by: John Wildkins <john.wildkins@gmail.com>
Co-authored-by: Matt Atlas <liermattia@gmail.com>
Co-authored-by: harryob <55142896+harryob@users.noreply.github.com>
Co-authored-by: Werner <Arrow768@users.noreply.github.com>
Co-authored-by: Geeves <ggrobler447@gmail.com>
Co-authored-by: harryob <me@harryob.live>
2023-06-25 19:03:33 +02:00
Wildkins 9f1bdd2847 Exoplanet Overhaul: The Shape of Things to Come (#16216)
* the end of the beginning

* SPEED

* SPEED

* we real speed

* fix ore gen

* re-organize exoplanet stuff

* reorg and rename defines, fix ores

* Everything Else

* 1.2.0+a3 rust_g

* fix merge

* get rid of noise maps

* fix adhomai, delete random maps

* make adhomai poggers or something idk

* debug

* crystal planet, misc bugfixes

* fixes

* log

* change mineral gen to make adhomai work

* try this

* huh

* huhw

* rust_g 1.2.0+a4

* port adhomai changes to correct file

* fix for rock nomad

* bugfixes
2023-04-25 13:48:54 +00:00
Wildkins 3f4786ab23 Fix several hard-dels, add harddel ref tracking (#16174) 2023-04-10 20:42:20 +00:00
Wildkins 2fcfa8adb7 Ports /tg/ spatial grid system, refactors telecomms, destroys lag (#15140) 2022-12-09 12:35:33 +01:00
Wildkins d20dae5f9e Add waitfor=FALSE to visible_message (#13885) 2022-05-14 03:34:54 +02:00
Matt Atlas 0a162f61ee Ports Components from TG: "I don't actually know what I'm doing" edition (#8890)
God is with us.
2020-05-19 20:59:50 +02:00
Karolis 1c00ae02d3 pAIs, Computers and ntIRC (#8757)
#8005 just revived.

Tasks to acomplish while here:

Fix merge conflicts

    Add ntIRC direct messaging

Things I migth consider adding in future PR:

    Porting IRC to VueUI
    Porting File Manager to VueUI.
2020-05-08 13:58:34 +03:00
mikomyazaki 6074224d00 dreamchecker (#8233)
Implements dreamchecker plus fixes all errors
2020-02-16 20:42:32 +02:00
Lohikar 38a3dc55aa Unify datum definitions (#3991)
Unifies all datum vars into a single file & moves all datum procs that made sense into that same file.
2017-12-23 21:29:17 +02:00