Handler for a complex singal, that is a signal that requires some additional handling.
You define such signal for example as:
#define XSIG_OUTERMOST_MOVABLE_CHANGED list(/datum/component/complexsignal/outermost_movable, "mov_outermost_changed")
When this signal gets registered at least once once to a datum the appropriate complex signal component will get registered to it.
When all instances of this signal get unregistered then the component will qdel itself unless [qdel_when_unneeded] is unset.
The intended use is for this component to keep some more complex and resource intensive handling (possibly using other signals) and then send the
actual complex signal when some conditions are met. That signal should be set to
src like this:
SEND_COMPLEX_SIGNAL(src, X_OUTERMOST_MOVABLE_CHANGED, old_outermost, new_outermost)
A single component type can be used for handling of multiple signals.
Check /datum/component/complexsignal/outermost_movable for an example.
|qdel_when_unneeded||Whether the component should qdel itself when the number of registered signals drops to zero|
|registered_signals||The complex signal types registered to this datum|
|_register||Override this to add code which happens when a complex signal is registered. If RegisterSignal is passed additional arguments those get passed
|_unregister||Override to add code which happens on unregistering a signal.|
Whether the component should qdel itself when the number of registered signals drops to zero
The complex signal types registered to this datum
Override this to add code which happens when a complex signal is registered. If RegisterSignal is passed additional arguments those get passed
override. Other arguments are the same as for .RegisterSignal.
Complex signal definitions are of the form list(component_path, string_id). The
sig_type var will in this case contain only the
not the full two-element list.
Override to add code which happens on unregistering a signal.