From d7260c87b964f3637dbc23f366d874f7fcc0822a Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 03:23:47 -0400 Subject: [PATCH 1/8] Fixes admins disabling shadowlings/thralls Fixes the Shadowling Hivemind language being entirely deleted and shadowling abilities not being removed --- code/datums/mind.dm | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/code/datums/mind.dm b/code/datums/mind.dm index a0ca40d98ca..a096bd6a5f3 100644 --- a/code/datums/mind.dm +++ b/code/datums/mind.dm @@ -964,21 +964,17 @@ datum/mind special_role = null current << "Your powers have been quenched! You are no longer a shadowling!" current.spell_list.Cut() + if(current.mind) + current.mind.spell_list.Cut() message_admins("[key_name_admin(usr)] has de-shadowling'ed [current].") log_admin("[key_name(usr)] has de-shadowling'ed [current].") current.verbs -= /mob/living/carbon/human/proc/shadowling_hatch current.verbs -= /mob/living/carbon/human/proc/shadowling_ascendance - if(current.languages) - for(var/datum/language/L in current.languages) - if(L.name == "Shadowling Hivemind") - del(L) + current.remove_language("Shadowling Hivemind") else if(src in ticker.mode.shadowling_thralls) ticker.mode.shadowling_thralls -= src special_role = null - if(current.languages) - for(var/datum/language/L in current.languages) - if(L.name == "Shadowling Hivemind") - del(L) + current.remove_language("Shadowling Hivemind") current << "You have been brainwashed! You are no longer a thrall!" message_admins("[key_name_admin(usr)] has de-thrall'ed [current].") log_admin("[key_name(usr)] has de-thrall'ed [current].") From f4ee808e6aa5ce2df7558a4aabcd470012ebe59f Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 03:31:15 -0400 Subject: [PATCH 2/8] Fixes adding/removing null languages through VV These would attempt to add/remove null languages if the language selection was canceled. --- code/datums/datumvars.dm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/code/datums/datumvars.dm b/code/datums/datumvars.dm index c0bab0bb7bc..d99823a0a12 100644 --- a/code/datums/datumvars.dm +++ b/code/datums/datumvars.dm @@ -834,6 +834,9 @@ client var/new_language = input("Please choose a language to add.","Language",null) as null|anything in all_languages + if(!new_language) + return + if(!H) usr << "Mob doesn't exist anymore" return @@ -857,6 +860,9 @@ client var/datum/language/rem_language = input("Please choose a language to remove.","Language",null) as null|anything in H.languages + if(!rem_language) + return + if(!H) usr << "Mob doesn't exist anymore" return From f13dccd77682ddd6599e6a4198ba8bcac10c46e1 Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 04:01:30 -0400 Subject: [PATCH 3/8] Fixes laptop vendors asking for unneeded PINs Also fixes some minor typos in the HTML generation. --- code/modules/computer3/lapvend.dm | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/code/modules/computer3/lapvend.dm b/code/modules/computer3/lapvend.dm index 20839d6394a..a87bc08c4f0 100644 --- a/code/modules/computer3/lapvend.dm +++ b/code/modules/computer3/lapvend.dm @@ -105,9 +105,9 @@ else if(network == 3) dat += "Network card: Powernet (25)
" else - dat += "Network card: None" + dat += "Network card: None
" if (power == 0) - dat += "Power source: Regular" + dat += "Power source: Regular
" else if (power == 1) dat += "Power source: Extended (175)
" else @@ -117,10 +117,10 @@ dat += "
Vend Laptop" if(vendmode == 1) - dat += "Please swipe your card and enter your PIN to complete the transaction" + dat += "Please swipe your card to complete the transaction" if(vendmode == 3) - dat += "Please swipe your card and enter your PIN to be finish returning your computer
" + dat += "Please swipe your card to finish returning your computer
" dat += "Cancel" @@ -214,8 +214,10 @@ var/obj/item/weapon/card/id/C = I visible_message("[usr] swipes a card through [src].") if(vendor_account) - var/attempt_pin = input("Enter pin code", "Vendor transaction") as num - var/datum/money_account/D = attempt_account_access(C.associated_account_number, attempt_pin, 2) + var/datum/money_account/D = attempt_account_access_nosec(C.associated_account_number) + if(D && D.security_level) + var/attempt_pin = input("Enter pin code", "Vendor transaction") as num + D = attempt_account_access(C.associated_account_number, attempt_pin, 2) if(D) var/transaction_amount = total() if(transaction_amount <= D.money) From 9f1f0a9cfa901e0d6709466db4a051f1b627fc61 Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 04:35:10 -0400 Subject: [PATCH 4/8] Fixes quick-equipped accessories lingering in hands --- code/modules/clothing/clothing.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm index 4e868b7765c..8fc29d7f268 100644 --- a/code/modules/clothing/clothing.dm +++ b/code/modules/clothing/clothing.dm @@ -387,7 +387,7 @@ BLIND // can't see anything if(istype(I, /obj/item/clothing/accessory)) var/obj/item/clothing/accessory/A = I if(can_attach_accessory(A)) - user.drop_item() + user.unEquip(I) // Make absolutely sure this accessory is removed from hands accessories += A A.on_attached(src, user) From 755467ac20cad880ca3b8a5a1a8e08d0b1bb8316 Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 05:35:18 -0400 Subject: [PATCH 5/8] Fixes examining those with limb stumps/accessories Limb stumps would show as "He has a limb stump on his limb stump", and accessories would be lowercased and worded poorly. --- .../clothing/under/accessories/accessory.dm | 21 ++++++++++++++++++- .../mob/living/carbon/human/examine.dm | 4 ++-- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/code/modules/clothing/under/accessories/accessory.dm b/code/modules/clothing/under/accessories/accessory.dm index 055e7e0dc65..e43b72a499c 100644 --- a/code/modules/clothing/under/accessories/accessory.dm +++ b/code/modules/clothing/under/accessories/accessory.dm @@ -325,4 +325,23 @@ /obj/item/clothing/accessory/petcollar/attack_self(mob/user as mob) tagname = copytext(sanitize(input(user, "Would you like to change the name on the tag?", "Name your new pet", "Spot") as null|text),1,MAX_NAME_LEN) - name = "[initial(name)] - [tagname]" \ No newline at end of file + name = "[initial(name)] - [tagname]" + +/proc/english_accessory_list(obj/item/clothing/under/U) + if(!istype(U) || !U.accessories.len) + return + var/list/A = U.accessories + var/total = A.len + if (total == 1) + return "\a [A[1]]" + else if (total == 2) + return "\a [A[1]] and \a [A[2]]" + else + var/output = "" + var/index = 1 + var/comma_text = ", " + while (index < total) + output += "\a [A[index]][comma_text]" + index++ + + return "[output]and \a [A[index]]" diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm index 06186ea604a..96d9f6ddc0e 100644 --- a/code/modules/mob/living/carbon/human/examine.dm +++ b/code/modules/mob/living/carbon/human/examine.dm @@ -68,7 +68,7 @@ if(istype(w_uniform,/obj/item/clothing/under)) var/obj/item/clothing/under/U = w_uniform if(U.accessories.len) - tie_msg += " with [lowertext(english_list(U.accessories))]" + tie_msg += " with [english_accessory_list(U)]" if(w_uniform.blood_DNA) msg += "[t_He] [t_is] wearing \icon[w_uniform] [w_uniform.gender==PLURAL?"some":"a"] blood-stained [w_uniform.name][tie_msg]!\n" @@ -280,7 +280,7 @@ continue for(var/obj/item/organ/external/temp in organs) - if(temp) + if(temp && !temp.is_stump()) if(temp.status & ORGAN_ROBOT) if(!(temp.brute_dam + temp.burn_dam)) if(!(species.flags & IS_SYNTHETIC)) From 887a4bad03b9f28b10dc04d7b4a8fc48b822a6c4 Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 05:48:03 -0400 Subject: [PATCH 6/8] Fixes corgis consuming food at warp speed Also fixes a small issue with the code that restores corgi health when they eat. --- code/modules/reagents/reagent_containers/food/snacks.dm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/code/modules/reagents/reagent_containers/food/snacks.dm b/code/modules/reagents/reagent_containers/food/snacks.dm index da6bb4a97c9..35439d27c02 100644 --- a/code/modules/reagents/reagent_containers/food/snacks.dm +++ b/code/modules/reagents/reagent_containers/food/snacks.dm @@ -239,15 +239,13 @@ /obj/item/weapon/reagent_containers/food/snacks/attack_animal(mob/M) if(isanimal(M)) + M.changeNext_move(CLICK_CD_MELEE) if(iscorgi(M)) if(bitecount >= 4) M.visible_message("[M] [pick("burps from enjoyment", "yaps for more", "woofs twice", "looks at the area where \the [src] was")].","You swallow up the last part of \the [src].") playsound(src.loc,'sound/items/eatfood.ogg', rand(10,50), 1) var/mob/living/simple_animal/pet/corgi/C = M - if (C.health <= C.maxHealth + 5) - C.health += 5 - else - C.health = C.maxHealth + C.health = min(C.health + 5, C.maxHealth) del(src) else M.visible_message("[M] takes a bite of \the [src].","You take a bite of \the [src].") From 8ab18c27d81cba9dc9e18f0c9739f3cb1d57d4bf Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 06:18:18 -0400 Subject: [PATCH 7/8] Fixes some Stat procs statting to the wrong panel --- code/modules/mob/mob.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index db1fda16915..442a9d32346 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -998,6 +998,8 @@ var/list/slot_equipment_priority = list( \ else stat(null, "processScheduler is not running.") + statpanel("Status") // Switch to the Status panel again, for the sake of the lazy Stat procs + /mob/proc/add_stings_to_statpanel(var/list/stings) for(var/obj/effect/proc_holder/changeling/S in stings) From f84e7e8e8d90f77c2d5599edf75dbbbe14b2e24d Mon Sep 17 00:00:00 2001 From: Krausus Date: Sat, 30 May 2015 06:25:46 -0400 Subject: [PATCH 8/8] Fixes losing items when dismantling machine frames --- code/game/machinery/constructable_frame.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/game/machinery/constructable_frame.dm b/code/game/machinery/constructable_frame.dm index a0bf06314d5..b0c1ff709ea 100644 --- a/code/game/machinery/constructable_frame.dm +++ b/code/game/machinery/constructable_frame.dm @@ -123,8 +123,8 @@ user << "You remove the circuit board." else user << "You remove the circuit board and other components." - for(var/obj/item/weapon/W in components) - W.loc = src.loc + for(var/obj/item/I in components) + I.loc = src.loc desc = initial(desc) req_components = null components = null