[MIRROR] The AI can no longer turn off shapeshifted robots [MDB IGNORE] (#24141)

* The AI can no longer turn off shapeshifted robots (#78766)

## About The Pull Request

If you shapeshifted into a robot (beepsky, ED-209, etc.) using the
shapechange spell or other means, silicons could just turn you off. Now
all shapeshifted robots are considered to be emagged, meaning that
silicons can't interact with them. Closes #44505.
## Why It's Good For The Game

Bugfixes good
## Changelog
🆑
fix: The AI can no longer turn you off if you shapeshift into a robot.
/🆑

* The AI can no longer turn off shapeshifted robots

---------

Co-authored-by: GPeckman <21979502+GPeckman@users.noreply.github.com>
This commit is contained in:
SkyratBot
2023-10-06 14:44:28 -07:00
committed by GitHub
co-authored by GPeckman
parent 5072a5de13
commit 59fc19f174
@@ -159,6 +159,12 @@
spell_requirements &= ~(SPELL_REQUIRES_HUMAN|SPELL_REQUIRES_WIZARD_GARB)
ADD_TRAIT(new_shape, TRAIT_DONT_WRITE_MEMORY, SHAPESHIFT_TRAIT) // If you shapeshift into a pet subtype we don't want to update Poly's deathcount or something when you die
// Make sure that if you shapechanged into a bot, the AI can't just turn you off.
var/mob/living/simple_animal/bot/polymorph_bot = new_shape
if (istype(polymorph_bot))
polymorph_bot.bot_cover_flags |= BOT_COVER_EMAGGED
polymorph_bot.bot_mode_flags &= ~BOT_MODE_REMOTE_ENABLED
return new_shape
/// Actually does the un-shapeshift, from the caster. (Caster is a shapeshifted mob.)