Files
Bubberstation/code/datums/components
Seth Scherer a3add37618 Refactors the forensics component into a datum (#66809)
About The Pull Request

This was doing things component really shouldn't be doing, and now all
of its behaviour is contained onto a datum, as it should've been the
whole time
Why It's Good For The CODEBASE

some things just really shouldn't be components, this was made back when DCS was first implemented and just thrown in because it was the new hot thing i guess, but datumized forensics makes far more sense, AND doesn't use GetComponent

TODO:

    More thorough testing to make sure nothing broke

Changelog

🆑
refactor: Turned the forensics component into a datum.
/🆑
2022-05-16 16:33:59 +12:00
..
2022-05-08 10:24:44 -07:00
2022-03-31 14:05:55 +13:00
2022-03-31 14:05:55 +13:00
2022-04-01 21:07:46 -04:00
2022-04-01 21:07:46 -04:00
2022-01-13 23:44:45 -06:00
2021-12-24 12:00:24 -08:00
2021-12-24 12:00:24 -08:00
2021-12-24 12:00:24 -08:00
2022-04-01 21:07:46 -04:00

Datum Component System (DCS)

Concept

Loosely adapted from /vg/. This is an entity component system for adding behaviours to datums when inheritance doesn't quite cut it. By using signals and events instead of direct inheritance, you can inject behaviours without hacky overloads. It requires a different method of thinking, but is not hard to use correctly. If a behaviour can have application across more than one thing. Make it generic, make it a component. Atom/mob/obj event? Give it a signal, and forward it's arguments with a SendSignal() call. Now every component that want's to can also know about this happening.

HackMD page for an introduction to the system as a whole.

See/Define signals and their arguments in __DEFINES\components.dm