Files
Bubberstation/code/__DEFINES/guardian_defines.dm
SkyratBot 42d245a4be [MIRROR] Basic Guardians/Holoparasites [MDB IGNORE] (#24921)
* Basic Guardians/Holoparasites (#79473)

## About The Pull Request

Fixes #79485
Fixes #77552

Converts Guardians (aka Holoparasites) into Basic Mobs.
Changes a bunch of their behaviours into actions or components which we
can reuse.
Replaces some verbs it would give to you and hide in the status panel
with action buttons that you may be able to find more quickly.

They _**should**_ work basically like they did before but a bit
smoother. It is not unlikely that I made some changes by accident or
just by changing framework though.

My one creative touch was adding random name suggestions.
The Wizard federation have a convention of naming their arcane spirit
guardians by combining a colour and a major arcana of the tarot. The
Syndicate of course won't truck with any of that mystical claptrap and
for their codenames use the much more sensible construction of a colour
and a gamepiece.

This lets you be randomly assigned such creative names as "Sparkling
Hermit", "Bloody Queen", "Blue World", or "Purple Diamond".
You can of course still ignore this entirely and type "The Brapmaster"
into the box if so desired.

I made _one_ other intentional change, which is to swap to Mothblocks'
nice leash component instead of instantly teleporting guardians back to
you when they are pulled out of the edge of their range. They should now
be "dragged" along behind you until they can't path, at which point they
will teleport. This should make the experience a bit less disorienting,
you have the recall button if you _want_ to instantly catch up.

This is unfortunately a bumper-sized PR because it did not seem
plausible to not do all of it at once, but I can make a project branch
for atomisation if people think this is too much of a pain in the ass to
review.

Other changes:
- Some refactoring to how the charge action works so I could
individually override "what you can hit" and "what happens when you hit"
instead of those being the same proc
- Lightning Guardian damage chain is now a component
- Explosive Guardian explosive trap is now a component
- Added even more arguments to the Healing Touch component to allow it
to heal tox/oxy damage and require a specific click modifier
- Life Link component which implements the Guardian behaviour of using
another mob as your health bar
- Moved some stuff about deciding what guardians look and are described
like into a theming datum
- Added a generic proc which can return whether your mob is meant to
apply some kind of damage multiplier to a certain damage type. It's not
perfect because I couldn't figure out how ot cram limb modifiers in
there, which is where most of it is on carbons. Oh well.
- Riders of vehicles now inherit all movement traits of those vehicles,
so riding a charging holoparasite will let you cross chasms. Also works
if you piggyback someone with wings, probably.

## Changelog

🆑
refactor: Guardians/Powerminers/Holoparasites now use the basic mob
framework. Please report any unexpected changes or behaviour.
qol: The verbs used to communicate with, recall, or banish your Guardian
are now action buttons.
balance: If (as a Guardian) your host moves slightly out of range you
will now be dragged back into range if possible, rather than being
instantly teleported to them.
balance: Protectors now have a shorter leash range rather than a longer
one, in order to more easily take advantage of their ability to drag
their charge out of danger.
balance: Ranged Guardians can now hold down the mouse button to fire
automatically.
balance: People riding vehicles or other mobs now inherit all of their
movement traits, so riding a flying mob (or vehicle, if we have any of
those) will allow you to cross chasms and lava safely.
/🆑

---------

Co-authored-by: san7890 <the@ san7890.com>

* Basic Guardians/Holoparasites

* Modular

---------

Co-authored-by: Jacquerel <hnevard@gmail.com>
Co-authored-by: san7890 <the@ san7890.com>
Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com>
2023-11-11 07:07:34 -05:00

31 lines
1000 B
Plaintext

#define GUARDIAN_THEME_TECH "tech"
#define GUARDIAN_THEME_MAGIC "magic"
#define GUARDIAN_THEME_CARP "carp"
#define GUARDIAN_THEME_MINER "miner"
#define GUARDIAN_MAGIC "magic"
#define GUARDIAN_TECH "tech"
#define GUARDIAN_ASSASSIN "assassin"
#define GUARDIAN_CHARGER "charger"
#define GUARDIAN_DEXTROUS "dextrous"
#define GUARDIAN_EXPLOSIVE "explosive"
#define GUARDIAN_GASEOUS "gaseous"
#define GUARDIAN_GRAVITOKINETIC "gravitokinetic"
#define GUARDIAN_LIGHTNING "lightning"
#define GUARDIAN_PROTECTOR "protector"
#define GUARDIAN_RANGED "ranged"
#define GUARDIAN_STANDARD "standard"
#define GUARDIAN_SUPPORT "support"
/// List of all guardians currently extant
GLOBAL_LIST_EMPTY(parasites)
/// Assoc list of guardian theme singletons
GLOBAL_LIST_INIT(guardian_themes, list(
GUARDIAN_THEME_TECH = new /datum/guardian_fluff/tech,
GUARDIAN_THEME_MAGIC = new /datum/guardian_fluff,
GUARDIAN_THEME_CARP = new /datum/guardian_fluff/carp,
GUARDIAN_THEME_MINER = new /datum/guardian_fluff/miner,
))