Files
Matt Atlas e0aa218843 Shell May Cry: A comprehensive rework of synthetics. (#20721)
https://www.youtube.com/watch?v=9mPvZ96pHJI

A pull request commissioned by the Synthetic Lore Team to
comprehensively rework synthetics (read: IPCs) and how they work in
Aurora. The objective is to make IPCs as unique as possible from humans,
upgrading the robotic feel and atmosphere, while also preserving a good
sense of balance in-game.

Key features:

- A comprehensive expansion of synthetic organs, all of which now
fulfill a purpose: hydraulics, cooling units, power systems, actuators,
diagnostics units.
- Customizable organs with benefits and drawbacks, such as with cooling
units and power systems.
- Unique ways to repair the organs and more involved steps.
- Unique damage mechanics - every organ has wiring and electronics which
affect its functioning, and they are defended by plating which provides
natural armour.
- Improved and immersive diagnostics.
- Unique features, benefits, and drawbacks for every IPC frame.
- A rework of the positronic brain, which can be either destroyed or
shut down, alongside effects caused by low integrity.
- A rework of how EMPs affect IPC organs.
- Non-binary damage states for each organ.

To-do:

- [x] Finish the unique features for each frame.
- [x] Look into if mechanical synthskin is possible.
- [x] Power system.
- [x] Posibrain mechanics.
- [ ] Passive cooling expansion.
- [x] EMP mechanics.
- [x] Repair mechanics.
- [x] Mob weight mechanics.
- [ ] Gurney for heavy mobs.
- [x] New augments.
- [ ] IPC tag scanning and flashing.

---------

Signed-off-by: Werner <1331699+Arrow768@users.noreply.github.com>
Co-authored-by: Matt Atlas <liermattia@gmail.com>
Co-authored-by: Geeves <22774890+Geevies@users.noreply.github.com>
Co-authored-by: Werner <1331699+Arrow768@users.noreply.github.com>
2025-12-21 16:26:23 +00:00

66 lines
3.4 KiB
Plaintext

#define ORGAN_CAN_FEEL_PAIN(organ) !BP_IS_ROBOTIC(organ) && (!organ.species || !(organ.species.flags & NO_PAIN))
#define ORGAN_IS_DISLOCATED(organ) (organ.dislocated > 0)
#define SOCKET_UNSHIELDED 0
#define SOCKET_SHIELDED 1
#define SOCKET_FULLSHIELDED 2
// Heart signals
/**
* Raised on an entity whose heart is attempting to pump blood.
* The original heart is passed in and null checked, so Registers won't need to check it elsewhere.
* I have no way of making the heart variables private set, so the onus is on you dear contributor not to set them by event. I've set aside three variables for you to touch instead.
* "recent_pump" controls interactions with things like CPR, stabilizer harness
* "pulse_mod" at this step is equal to 1x, use this to insert any desired pump rate modifications.
* "min_efficiency" controls the Floor of heart pump rate, particularly when its stopped. Default is 0.5x with CPR, 0.3x without
*/
#define COMSIG_HEART_PUMP_EVENT "heart_pump_event"
/**
* Raised on an entity whose blood is attempting to circulate oxygen through the body.
* "blood_volume" is the percentage of blood vs max blood, between 0 and 100. Don't put it outside those bounds.
* "blood_volume_mod" is the ratio of oxygen loss to health loss, representing how damaged the circulatory system is as a whole. You can safely multiply against this to include your own modifiers.
* "oxygenated_add" represents the ratio of internal blood oxygenation to external oxygenation. Such as from Dexalin and Dexplus. Defaults to 0, so additive identity applies.
*/
#define COMSIG_BLOOD_OXYGENATION_EVENT "blood_oxygenation_event"
/**
* Raised on a heart that is calculating its pulse.
* "pulse_mod" Additive modifier on the pulse rate, which is an integer. Tightly control this and use it miserly.
* "is_stable" boolean used by Inaprovaline, but can be used here by anything you want.
* "oxy" ratio of blood oxygenation to blood volume.
* "circulation" the percentage of blood remaining in the body from 0 to 100.
*/
#define COMSIG_HEART_PULSE_EVENT "heart_pulse_event"
/**
* Raised on a heart that is calculating the effects of bleeds.
*/
#define COMSIG_HEART_BLEED_EVENT "heart_bleed_event"
// Liver signals
/**
* Raised on an entity whose liver is attempting to filter blood.
*/
#define COMSIG_LIVER_FILTER_EVENT "liver_filter_event"
/**
* Raised on an entity with the gravity weakness feature that is about to take damage from said weakness.
* Set the canceled variable to true in order to negate said weakness.
*/
#define COMSIG_GRAVITY_WEAKNESS_EVENT "gravity_weakness_event"
/// Raised external organ (a limb) takes damage. Used for the synthetic endoskeleton at the moment. Must supply damage.
#define COMSIG_EXTERNAL_ORGAN_DAMAGE "machine_internal_damage"
/// Sent when the burst damage is cleared by the posibrain.
#define COMSIG_SYNTH_EMP_DAMAGE_CLEARED "emp_damage_cleared"
/// Sent when the synthetic enters self-preservation mode. Must supply a TRUE/FALSE state.
#define COMSIG_SYNTH_SET_SELF_PRESERVATION "synth_self_preservation_set"
/// Sent when endoskeleton repair is done. Must supply a number of damage healed.
#define COMSIG_SYNTH_ENDOSKELETON_REPAIR "synth_endoskeleton_repair"
/// Sent when a full endoskeleton repair is done. Unlike the normal one, also restores max_damage to initial state. No extra arguments.
#define COMSIG_SYNTH_ENDOSKELETON_FULL_REPAIR "synth_endoskeleton_full_repair"