Manualbiome (#11216)

This commit is contained in:
Kashargul
2025-07-21 22:37:45 +02:00
committed by GitHub
parent afa0b4bfdb
commit f39fdae47c
280 changed files with 18208 additions and 17558 deletions

View File

@@ -1,7 +1,6 @@
# Template file for your new component
See _component.dm for detailed explanations
See \_component.dm for detailed explanations
```dm
/datum/component/mycomponent

View File

@@ -4,6 +4,6 @@
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.](https://hackmd.io/@tgstation/SignalsComponentsElements)
### [HackMD page for an introduction to the system as a whole.](https://hackmd.io/@tgstation/SignalsComponentsElements)
### See/Define signals and their arguments in [__DEFINES\components.dm](../../__DEFINES/components.dm)
### See/Define signals and their arguments in [\_\_DEFINES\components.dm](../../__DEFINES/components.dm)

View File

@@ -1,7 +1,6 @@
# Template file for your new element
See _element.dm for detailed explanations
See \_element.dm for detailed explanations
```dm
/datum/element/myelement

View File

@@ -34,7 +34,7 @@ GLOBAL_LIST_INIT(unique_gamma_loot,list(\
UnregisterSignal(target, COMSIG_LOOT_REWARD)
/// Calculates and drops loot, the source's turf is where it will be dropped, L is the searching mob, and searched_by is a passed list for storing who has searched a loot pile.
/datum/element/lootable/proc/loot(atom/source,mob/living/L,var/list/searched_by, wake_chance)
/datum/element/lootable/proc/loot(atom/source,mob/living/L,var/list/searched_by, wake_chance = 0)
SIGNAL_HANDLER
// The loot's all gone.
if(loot_depletion && loot_left <= 0)
@@ -91,6 +91,10 @@ GLOBAL_LIST_INIT(unique_gamma_loot,list(\
if("alium")
final_message = span_alium(final_message)
to_chat(L, span_info(final_message))
var/disturbed_sleep = rand(1,100) //spawning of mobs, for now only the trash panda.
if(disturbed_sleep <= wake_chance)
new /mob/living/simple_mob/animal/passive/raccoon(get_turf(source))
source.visible_message("A raccoon jumps out of the trash!.")
// Check if we should delete on depletion
if(!loot_depletion)