Files
Bubberstation/code/modules/unit_tests/abductor_baton_spell.dm
MrMelbert 7721e96d3d Abductor / general "Summon Item" spell QoL (#77419)
## About The Pull Request

- Abductor Baton Recall now starts linked to the Abductor's Baton
- Did some misc. spell changed to the abductor baton recall to make it
less spell-like
- Fixes Instant Summon's name not changing to "Recall whatever item"
when an item is marked
- Instant Summons now displays the item marked on the button 

## Why It's Good For The Game

Having to mark the abductor baton is bad UX, when making it start marked
is pretty trivial.

Also this just helps it be a lot more obvious what is linked to what if
you end up having more than one instant summons known.

## Changelog

🆑 Melbert
qol: Abductor Baton Recall now starts linked to their baton, and you can
no longer unlink your baton
qol: Instant Summons now shows what item is marked over the icon
fix: Fixes Instant Summon's name not updating when marking an item
/🆑
2023-08-08 17:56:21 +01:00

20 lines
1.2 KiB
Plaintext

/// Tests that abductors get their baton recall spell when being equipped
/datum/unit_test/abductor_baton_spell
/datum/unit_test/abductor_baton_spell/Run()
// Test abductor agents get a linked "summon item" spell that marks their baton.
var/mob/living/carbon/human/ayy = allocate(/mob/living/carbon/human/consistent)
ayy.equipOutfit(/datum/outfit/abductor/agent)
var/datum/action/cooldown/spell/summonitem/abductor/summon = locate() in ayy.actions
TEST_ASSERT_NOTNULL(summon, "Abductor agent does not have summon item spell.")
TEST_ASSERT(istype(summon.marked_item, /obj/item/melee/baton/abductor), "Abductor agent's summon item spell did not mark their baton.")
// Also test abductor solo agents also get the spell.
var/mob/living/carbon/human/ayy_two = allocate(/mob/living/carbon/human/consistent)
ayy_two.equipOutfit(/datum/outfit/abductor/scientist/onemanteam)
var/datum/action/cooldown/spell/summonitem/abductor/summon_two = locate() in ayy_two.actions
TEST_ASSERT_NOTNULL(summon_two, "Abductor solo agent does not have summon item spell.")
TEST_ASSERT(istype(summon_two.marked_item, /obj/item/melee/baton/abductor), "Abductor solo agent's summon item spell did not mark their baton.")