From 902b270ab17d02b6c5f25d473f2652dace274770 Mon Sep 17 00:00:00 2001 From: datlo Date: Thu, 24 Oct 2019 20:31:54 +0200 Subject: [PATCH 1/2] His grace action button now links the box --- .../items/weapons/storage/artistic_toolbox.dm | 60 ++++++++++--------- 1 file changed, 32 insertions(+), 28 deletions(-) diff --git a/code/game/objects/items/weapons/storage/artistic_toolbox.dm b/code/game/objects/items/weapons/storage/artistic_toolbox.dm index 0d8613cce4a..dfdf57f4b47 100644 --- a/code/game/objects/items/weapons/storage/artistic_toolbox.dm +++ b/code/game/objects/items/weapons/storage/artistic_toolbox.dm @@ -26,41 +26,45 @@ if(istype(M)) to_chat(user, "His Grace [flags & NODROP ? "releases from" : "binds to"] your hand!") flags ^= NODROP + else if(!activated && loc == user) + link_user(user) else to_chat(user, "You can't seem to understand what this does.") /obj/item/storage/toolbox/green/memetic/attack_hand(mob/living/carbon/user) - if(loc == user) - if(!activated) - if(ishuman(user) && !user.HasDisease(new /datum/disease/memetic_madness(0))) - activated = TRUE - user.ForceContractDisease(new /datum/disease/memetic_madness(0)) - for(var/datum/disease/memetic_madness/DD in user.viruses) - DD.progenitor = src - servantlinks.Add(DD) - break - force += 4 - throwforce += 4 - SEND_SOUND(user, 'sound/goonstation/effects/screech.ogg') - shake_camera(user, 20, 1) - var/acount = 0 - var/amax = rand(10, 15) - var/up_and_down - var/asize = 1 - while(acount <= amax) - up_and_down += "a" - if(acount > (amax * 0.5)) - asize-- - else - asize++ - acount++ - to_chat(user, "[up_and_down]") - to_chat(user, "His Grace accepts thee, spread His will! All who look close to the Enlightened may share His gifts.") - original_owner = user - return + if(!activated && loc == user) + link_user(user) + return ..() +/obj/item/storage/toolbox/green/memetic/proc/link_user(mob/living/carbon/user) + if(ishuman(user) && !user.HasDisease(new /datum/disease/memetic_madness(0))) + activated = TRUE + user.ForceContractDisease(new /datum/disease/memetic_madness(0)) + for(var/datum/disease/memetic_madness/DD in user.viruses) + DD.progenitor = src + servantlinks.Add(DD) + break + force += 4 + throwforce += 4 + SEND_SOUND(user, 'sound/goonstation/effects/screech.ogg') + shake_camera(user, 20, 1) + var/acount = 0 + var/amax = rand(10, 15) + var/up_and_down + var/asize = 1 + while(acount <= amax) + up_and_down += "a" + if(acount > (amax * 0.5)) + asize-- + else + asize++ + acount++ + to_chat(user, "[up_and_down]") + to_chat(user, "His Grace accepts thee, spread His will! All who look close to the Enlightened may share His gifts.") + original_owner = user + /obj/item/storage/toolbox/green/memetic/attackby(obj/item/I, mob/user) if(activated) if(istype(I, /obj/item/grab)) From 6368447f83ffd2d7a9249904366e559734ce035c Mon Sep 17 00:00:00 2001 From: datlo Date: Thu, 24 Oct 2019 20:41:36 +0200 Subject: [PATCH 2/2] Add nodrop notification --- code/game/objects/items/weapons/storage/artistic_toolbox.dm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/code/game/objects/items/weapons/storage/artistic_toolbox.dm b/code/game/objects/items/weapons/storage/artistic_toolbox.dm index dfdf57f4b47..48d59ad8830 100644 --- a/code/game/objects/items/weapons/storage/artistic_toolbox.dm +++ b/code/game/objects/items/weapons/storage/artistic_toolbox.dm @@ -27,7 +27,8 @@ to_chat(user, "His Grace [flags & NODROP ? "releases from" : "binds to"] your hand!") flags ^= NODROP else if(!activated && loc == user) - link_user(user) + if(link_user(user)) + to_chat(user, "Call to His Grace again if you wish it bound to your hand!") else to_chat(user, "You can't seem to understand what this does.") @@ -64,6 +65,8 @@ to_chat(user, "[up_and_down]") to_chat(user, "His Grace accepts thee, spread His will! All who look close to the Enlightened may share His gifts.") original_owner = user + return TRUE + return FALSE /obj/item/storage/toolbox/green/memetic/attackby(obj/item/I, mob/user) if(activated)