From b2672b8f2d6dfd43d9849bba9b2bc5e31d52ad83 Mon Sep 17 00:00:00 2001 From: Cannibal Hunter <135169022+CannibalHunter@users.noreply.github.com> Date: Sun, 17 Mar 2024 19:30:33 -0500 Subject: [PATCH] Fingergun emote! (#1343) * lol * lets make sure it doesn't embed.. * prounugnsd * BANG! having a gun pointed at you and walking away no longer makes you say "BANG!" * waoh lower the ammo count let's not fill the mimes chatbox * no spam * change fingergun icon * inhand icon defines? * Update tgstation.dme --------- Co-authored-by: dwasint <82520990+dwasint@users.noreply.github.com> --- .../code/modules/mob/living/carbon/emote.dm | 105 ++++++++++++++++++ .../obj/weapons/guns/fingergun_emote.dmi | Bin 0 -> 653 bytes tgstation.dme | 1 + 3 files changed, 106 insertions(+) create mode 100644 monkestation/code/modules/mob/living/carbon/emote.dm create mode 100644 monkestation/icons/obj/weapons/guns/fingergun_emote.dmi diff --git a/monkestation/code/modules/mob/living/carbon/emote.dm b/monkestation/code/modules/mob/living/carbon/emote.dm new file mode 100644 index 00000000000..b30a2f4dfa6 --- /dev/null +++ b/monkestation/code/modules/mob/living/carbon/emote.dm @@ -0,0 +1,105 @@ +//Finger Guns *blows smoke off his finger tips* +/datum/emote/living/carbon/fingergun + key = "fingergun" + key_third_person = "fingerguns" + hands_use_check = TRUE + cooldown = 3 SECONDS + +/datum/emote/living/carbon/fingergun/run_emote(mob/user, params, type_override, intentional) + . = ..() + if(!.) + return + var/obj/item/gun/ballistic/fingergun_emote/N = new(user) + if(user.put_in_hands(N)) + to_chat(user, span_notice("You fold your hand into a finger gun.")) + user.manual_emote("folds [user.p_their()] hand into a finger gun.") + else + qdel(N) + to_chat(user, span_warning("You're incapable of readying a finger gun in your current state.")) + +/obj/item/ammo_casing/caseless/fingergun_bullet + name = "imaginary bullet" + desc = "Bullets are not real idiot." + projectile_type = /obj/projectile/bullet/fingergun_bullet + item_flags = DROPDEL + caliber = "bulletsarenotrealyouidiot" + custom_materials = list() + harmful = FALSE + +/obj/projectile/bullet/fingergun_bullet + name = "imaginary bullet" + desc = "Bullets are not real idiot." + icon = 'monkestation/icons/obj/weapons/guns/fingergun_emote.dmi' + icon_state = "projectile" + damage = 0 + hitsound_wall = "" + impact_effect_type = null + embedding = list(embed_chance=0) + +/obj/item/ammo_box/magazine/fingergun_emote + name = "finger gun magazine" + desc = "You should not be seeing this..." + ammo_type = /obj/item/ammo_casing/caseless/fingergun_bullet + caliber = "bulletsarenotrealyouidiot" + max_ammo = 8 + +/obj/item/gun/ballistic/fingergun_emote + name = "finger gun" + desc = "''Ya' need a count?'' ''Nah sir.'' *abruptly gets shot in the head. ''Well.. that ain't good...'' *falls over backwards ''I should'a seen this comming.''" + icon = 'monkestation/icons/obj/weapons/guns/fingergun_emote.dmi' + icon_state = "item" + lefthand_file = 'icons/mob/inhands/items_lefthand.dmi' + righthand_file = 'icons/mob/inhands/items_righthand.dmi' + inhand_icon_state = "nothing" + item_flags = DROPDEL | HAND_ITEM + force = 0 + throwforce = 0 + load_sound_volume = 0 + rack_sound_volume = 0 + lock_back_sound_volume = 0 + eject_sound_volume = 0 + bolt_drop_sound_volume = 0 + dry_fire_sound = "" + pinless = TRUE + clumsy_check = FALSE + trigger_guard = TRIGGER_GUARD_ALLOW_ALL + gun_flags = NONE + mag_type = /obj/item/ammo_box/magazine/fingergun_emote + spawnwithmagazine = TRUE + internal_magazine = TRUE + bolt_type = BOLT_TYPE_NO_BOLT + fire_delay = 0.5 + +/obj/item/gun/ballistic/fingergun_emote/shoot_live_shot(mob/living/user, pointblank = 0, atom/pbtarget = null) //mostly copied from /obj/item/gun/proc/shoot_live_shot( + if(!HAS_TRAIT(user, TRAIT_MIMING)) + user.say("'s hand flying upwards with imaginary recoil*BANG!") + if(tk_firing(user)) + visible_message( + span_danger("[src] fires itself[pointblank ? " point blank at [pbtarget]!" : "!"]"), + vision_distance = COMBAT_MESSAGE_RANGE + ) + else if(pointblank) + user.visible_message( + span_danger("[user] fires [src] point blank at [pbtarget]!"), + span_danger("You fire [src] point blank at [pbtarget]!"), + ) + to_chat(pbtarget, span_userdanger("[user] fires [src] point blank at you!")) + if(pb_knockback > 0 && ismob(pbtarget)) + var/mob/PBT = pbtarget + var/atom/throw_target = get_edge_target_turf(PBT, user.dir) + PBT.throw_at(throw_target, pb_knockback, 2) + else if(!tk_firing(user)) + user.visible_message( + span_danger("[user] fires [src]!"), + vision_distance = COMBAT_MESSAGE_RANGE, + ignored_mobs = user + ) + +/obj/item/gun/ballistic/fingergun_emote/attack_self() + return + +/obj/item/gun/ballistic/fingergun_emote/attackby() + return + +/obj/item/gun/ballistic/fingergun_emote/eject_magazine() + return diff --git a/monkestation/icons/obj/weapons/guns/fingergun_emote.dmi b/monkestation/icons/obj/weapons/guns/fingergun_emote.dmi new file mode 100644 index 0000000000000000000000000000000000000000..8c788ded6e817124e7962a5bde5e71de2481f485 GIT binary patch literal 653 zcmV;80&@L{P)V=-0C=2JR&a84_w-Y6@%7{?OD!tS%+FJ>RWQ*r;NmRLOex7wuvIWN;^NFm z%}mcIfpCgT5=&AQY!#F;OHy-{xHwZXi;5L&6%4sJ(~1&vQz2})qJpCQtkmR^%$!tQ zN|hB{{ah4Wd_B1U!p$a$%?%MP0005ZNkl%!6M{K=~0C$fl`2}w9Kvo1aLt7Sb7Bcf0ICi5QgCg zfHCH&?;eE!T5B7}v1$naHZ3n`lNwX-KI8&8(wVxm&p+RN_HiCRcPrFGH(0{n8zN#8 z7Rc+nKkPKY5q}Vod$-q6qdH(Wbc5nBXQUA&gemWS@P* zcOxQ`DQsO(83Cm<2=I#Blwge68Dj?3fnpN0(W8x6;738}6zF=o-{Ra*Guv_aU=$9c zRYAC%4s|y^b0rU+0AaMU8Nd0