Files
Bubberstation/code/modules
SkyratBot 621af5bfb4 [MIRROR] Fixes runtimes with arm implants in general and the Vorpal Scythe in particular [MDB IGNORE] (#23130)
* Fixes runtimes with arm implants in general and the Vorpal Scythe in particular (#77595)

## About The Pull Request

Two batches of runtimes, somewhat related:

1. Being dismembered while holding an extended arm implant would
runtime, because Retract() no longer has an owner to reference when
moving the deployed item back into the implant. This, on top of
runtiming, would make the item in question be permanently stuck (and
usable) on your missing limb. (Described, along a similar but seemingly
unrelated issue with the godhand, in #76899)

Solution: Sanity check for an owner, forcemove the item into the implant
if we don't have one.

2. Spamming sheathe and unsheathe on a vorpal blade seems to
occasionally cause it to retract while it isn't in your hand.
Additionally, being self-dismembered by unsheathing an unsated vorpal
blade would trigger runtime number 1 with a vengeance, as it calls
Retract() twice in the same block.

Solution: Sanity check to make sure we do have a scythe in hand before
continuing and some other changes and minor re-structuring to more
cleanly handle losing the limb.
## Why It's Good For The Game

The less runtimes, the better.
The less people running around with scythes and energy guns super-glued
to the stump of their arm, the better.
## Changelog
🆑
fix: items implanted on arms no longer become permanently stuck in-hand
when their limb is dismembered
fix: quickly sheathing and unsheathing the vorpal scythe can no longer
bug out and prevent its effects from being applied
/🆑

---------

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

* Fixes runtimes with arm implants in general and the Vorpal Scythe in particular

---------

Co-authored-by: A miscellaneous Fern <80640114+FernandoJ8@users.noreply.github.com>
Co-authored-by: san7890 <the@ san7890.com>
2023-08-16 18:14:37 -04:00
..