mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-17 11:05:16 +01:00
switchblade can now be used to butcher and slice necks, icon updates when you toggle it on (#59990)
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
This commit is contained in:
@@ -360,6 +360,7 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301
|
||||
/obj/item/switchblade
|
||||
name = "switchblade"
|
||||
icon_state = "switchblade"
|
||||
base_icon_state = "switchblade"
|
||||
lefthand_file = 'icons/mob/inhands/weapons/swords_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/weapons/swords_righthand.dmi'
|
||||
desc = "A sharp, concealable, spring-loaded knife."
|
||||
@@ -378,19 +379,25 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301
|
||||
|
||||
/obj/item/switchblade/Initialize()
|
||||
. = ..()
|
||||
AddElement(/datum/element/update_icon_updates_onmob)
|
||||
AddComponent(/datum/component/butchering, 7 SECONDS, 100)
|
||||
set_extended(extended)
|
||||
|
||||
/obj/item/switchblade/attack_self(mob/user)
|
||||
playsound(src.loc, 'sound/weapons/batonextend.ogg', 50, TRUE)
|
||||
set_extended(!extended)
|
||||
|
||||
/obj/item/switchblade/update_icon_state()
|
||||
icon_state = "[base_icon_state][extended ? "_ext" : ""]"
|
||||
return ..()
|
||||
|
||||
/obj/item/switchblade/proc/set_extended(new_extended)
|
||||
extended = new_extended
|
||||
update_icon_state()
|
||||
if(extended)
|
||||
force = 20
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
throwforce = 23
|
||||
icon_state = "switchblade_ext"
|
||||
attack_verb_continuous = list("slashes", "stabs", "slices", "tears", "lacerates", "rips", "dices", "cuts")
|
||||
attack_verb_simple = list("slash", "stab", "slice", "tear", "lacerate", "rip", "dice", "cut")
|
||||
hitsound = 'sound/weapons/bladeslice.ogg'
|
||||
@@ -399,7 +406,6 @@ for further reading, please see: https://github.com/tgstation/tgstation/pull/301
|
||||
force = 3
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
throwforce = 5
|
||||
icon_state = "switchblade"
|
||||
attack_verb_continuous = list("stubs", "pokes")
|
||||
attack_verb_simple = list("stub", "poke")
|
||||
hitsound = 'sound/weapons/genhit.ogg'
|
||||
|
||||
Reference in New Issue
Block a user