Kills /obj/item/melee/transforming, replaces it with a transforming weapon component (#60761)

This PR kills off the transforming subtype of /obj/item/melee and replaces it with a component to handle the transforming behavior, /datum/component/transforming.

The transforming component handles updating the variables of an item when it's transformed. Things like force, sharpness, whetstone force bonus, and attack verbs. Similar to the two-handed component, but instead of transforming into a two-hander it remains a one handed weapon.

The "nemesis" behavior (dealing addition damage to certain factions) of the transforming subtype was moved to the cleaving saw only, since it was the only transforming item that used it. In the future, this can be made into a bespoke element/component as well.

The following weapons and items have been updated to use this component:

    Energy Swords / Sabers / Bananium Energy Sword
    Energy Circular Saw
    Energy Dagger
    Energy Axe
    Toy Energy Sword
    Holographic Energy Sword
    Switchblade
    Advanced Medical Tools (Laser scalpel, Mechanical Pinches, Searing Tool)
    Advanced Engineering Tools (Hand Drill, Jaws of Life / Syndicate Jaws of Life)
    Combat Wrench
    Cleaving Saw
    Telescopic Batons / Contractor Batons
    Roasting Stick
    Telescopic Riot Shield
    Energy Shield / Bananium Energy Shield

This PR also touches up the code around the various above items.
This commit is contained in:
MrMelbert
2021-08-23 13:45:54 -05:00
committed by GitHub
parent d8a1f27fff
commit b3e8eebdc9
76 changed files with 1084 additions and 835 deletions
@@ -67,7 +67,7 @@
for(var/i in 1 to 3)
new /obj/item/clothing/suit/armor/tdome/red(src)
for(var/i in 1 to 3)
new /obj/item/melee/transforming/energy/sword/saber(src)
new /obj/item/melee/energy/sword/saber(src)
for(var/i in 1 to 3)
new /obj/item/gun/energy/laser(src)
for(var/i in 1 to 3)
@@ -86,7 +86,7 @@
for(var/i in 1 to 3)
new /obj/item/clothing/suit/armor/tdome/green(src)
for(var/i in 1 to 3)
new /obj/item/melee/transforming/energy/sword/saber(src)
new /obj/item/melee/energy/sword/saber(src)
for(var/i in 1 to 3)
new /obj/item/gun/energy/laser(src)
for(var/i in 1 to 3)
@@ -187,7 +187,7 @@
var/can_transfer = TRUE //if golems can switch bodies to this new shell
var/mob/living/owner = null //golem's owner if it has one
short_desc = "You are a Free Golem. Your family worships The Liberator."
flavour_text = "In his infinite and divine wisdom, he set your clan free to travel the stars with a single declaration: \"Yeah go do whatever.\""
flavour_text = "In his infinite and divine wisdom, he set your clan free to travel the stars with a single declaration: \"Yeah go do whatever.\""
/obj/effect/mob_spawn/human/golem/Initialize(mapload, datum/species/golem/species = null, mob/creator = null)
if(species) //spawners list uses object name to register so this goes before ..()
@@ -488,7 +488,7 @@
/datum/outfit/syndicate_empty/battlecruiser/assault/captain
name = "Syndicate Battlecruiser Captain"
l_pocket = /obj/item/melee/transforming/energy/sword/saber/red
l_pocket = /obj/item/melee/energy/sword/saber/red
r_pocket = /obj/item/melee/classic_baton/telescopic
suit = /obj/item/clothing/suit/armor/vest/capcarapace/syndicate
suit_store = /obj/item/gun/ballistic/revolver/mateba