Fixes and Upgrades Stabilized Gold Extracts
This commit is contained in:
@@ -760,9 +760,24 @@ datum/status_effect/stabilized/blue/on_remove()
|
|||||||
var/mob/living/simple_animal/familiar
|
var/mob/living/simple_animal/familiar
|
||||||
|
|
||||||
/datum/status_effect/stabilized/gold/tick()
|
/datum/status_effect/stabilized/gold/tick()
|
||||||
|
<<<<<<< HEAD
|
||||||
if(!familiar)
|
if(!familiar)
|
||||||
familiar = create_random_mob(get_turf(owner.loc), FRIENDLY_SPAWN)
|
familiar = create_random_mob(get_turf(owner.loc), FRIENDLY_SPAWN)
|
||||||
familiar.del_on_death = TRUE
|
familiar.del_on_death = TRUE
|
||||||
|
=======
|
||||||
|
var/obj/item/slimecross/stabilized/gold/linked = linked_extract
|
||||||
|
if(QDELETED(familiar))
|
||||||
|
familiar = new linked.mob_type(get_turf(owner.loc))
|
||||||
|
familiar.name = linked.mob_name
|
||||||
|
familiar.del_on_death = TRUE
|
||||||
|
familiar.copy_known_languages_from(owner, FALSE)
|
||||||
|
if(linked.saved_mind)
|
||||||
|
linked.saved_mind.transfer_to(familiar)
|
||||||
|
familiar.ckey = linked.saved_mind.key
|
||||||
|
else
|
||||||
|
if(familiar.mind)
|
||||||
|
linked.saved_mind = familiar.mind
|
||||||
|
>>>>>>> b2e9fe8... Fixes and Upgrades Stabilized Gold Extracts (#38394)
|
||||||
return ..()
|
return ..()
|
||||||
|
|
||||||
/datum/status_effect/stabilized/gold/on_remove()
|
/datum/status_effect/stabilized/gold/on_remove()
|
||||||
|
|||||||
@@ -96,6 +96,52 @@ Stabilized extracts:
|
|||||||
|
|
||||||
/obj/item/slimecross/stabilized/gold
|
/obj/item/slimecross/stabilized/gold
|
||||||
colour = "gold"
|
colour = "gold"
|
||||||
|
<<<<<<< HEAD
|
||||||
|
=======
|
||||||
|
var/mob_type
|
||||||
|
var/datum/mind/saved_mind
|
||||||
|
var/mob_name = "Familiar"
|
||||||
|
|
||||||
|
/obj/item/slimecross/stabilized/gold/proc/generate_mobtype()
|
||||||
|
var/static/list/mob_spawn_pets = list()
|
||||||
|
if(mob_spawn_pets.len <= 0)
|
||||||
|
for(var/T in typesof(/mob/living/simple_animal))
|
||||||
|
var/mob/living/simple_animal/SA = T
|
||||||
|
switch(initial(SA.gold_core_spawnable))
|
||||||
|
if(FRIENDLY_SPAWN)
|
||||||
|
mob_spawn_pets += T
|
||||||
|
mob_type = pick(mob_spawn_pets)
|
||||||
|
|
||||||
|
/obj/item/slimecross/stabilized/gold/Initialize()
|
||||||
|
..()
|
||||||
|
generate_mobtype()
|
||||||
|
|
||||||
|
/obj/item/slimecross/stabilized/gold/attack_self(mob/user)
|
||||||
|
var/choice = input(user, "Which do you want to reset?", "Familiar Adjustment") as null|anything in list("Familiar Location", "Familiar Species", "Familiar Sentience", "Familiar Name")
|
||||||
|
if(!user.canUseTopic(src, BE_CLOSE))
|
||||||
|
return
|
||||||
|
if(isliving(user))
|
||||||
|
var/mob/living/L = user
|
||||||
|
if(L.has_status_effect(/datum/status_effect/stabilized/gold))
|
||||||
|
L.remove_status_effect(/datum/status_effect/stabilized/gold)
|
||||||
|
if(choice == "Familiar Location")
|
||||||
|
to_chat(user, "<span class='notice'>You prod [src], and it shudders slightly.</span>")
|
||||||
|
START_PROCESSING(SSobj, src)
|
||||||
|
if(choice == "Familiar Species")
|
||||||
|
to_chat(user, "<span class='notice'>You squeeze [src], and a shape seems to shift around inside.</span>")
|
||||||
|
generate_mobtype()
|
||||||
|
START_PROCESSING(SSobj, src)
|
||||||
|
if(choice == "Familiar Sentience")
|
||||||
|
to_chat(user, "<span class='notice'>You poke [src], and it lets out a glowing pulse.</span>")
|
||||||
|
saved_mind = null
|
||||||
|
START_PROCESSING(SSobj, src)
|
||||||
|
if(choice == "Familiar Name")
|
||||||
|
var/newname = copytext(sanitize(input(user, "Would you like to change the name of [mob_name]", "Name change", mob_name) as null|text),1,MAX_NAME_LEN)
|
||||||
|
if(newname)
|
||||||
|
mob_name = newname
|
||||||
|
to_chat(user, "<span class='notice'>You speak softly into [src], and it shakes slightly in response.</span>")
|
||||||
|
START_PROCESSING(SSobj, src)
|
||||||
|
>>>>>>> b2e9fe8... Fixes and Upgrades Stabilized Gold Extracts (#38394)
|
||||||
|
|
||||||
/obj/item/slimecross/stabilized/oil
|
/obj/item/slimecross/stabilized/oil
|
||||||
colour = "oil"
|
colour = "oil"
|
||||||
|
|||||||
Reference in New Issue
Block a user