This commit is contained in:
Flint
2020-02-07 22:35:57 -06:00
parent c229ca50c3
commit ad3115af02
9 changed files with 100 additions and 27 deletions
+1
View File
@@ -156,6 +156,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
#define TRAIT_NOFLASH "noflash" //Makes you immune to flashes
#define TRAIT_XENO_IMMUNE "xeno_immune"//prevents xeno huggies implanting skeletons
#define TRAIT_NAIVE "naive"
#define TRAIT_GUNFLIP "gunflip"
//non-mob traits
#define TRAIT_PARALYSIS "paralysis" //Used for limb-based paralysis, where replacing the limb will fix it
+2 -1
View File
@@ -97,7 +97,8 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_PASSTABLE" = TRAIT_PASSTABLE,
"TRAIT_NOFLASH" = TRAIT_NOFLASH,
"TRAIT_XENO_IMMUNE" = TRAIT_XENO_IMMUNE,
"TRAIT_NAIVE" = TRAIT_NAIVE
"TRAIT_NAIVE" = TRAIT_NAIVE,
"TRAIT_GUNFLIP" = TRAIT_GUNFLIP
),
/obj/item/bodypart = list(
"TRAIT_PARALYSIS" = TRAIT_PARALYSIS
-25
View File
@@ -553,31 +553,6 @@
/obj/item/ammo_casing/shotgun
))
/obj/item/storage/belt/holster
name = "shoulder holster"
desc = "A holster to carry a handgun and ammo. WARNING: Badasses only."
icon_state = "holster"
item_state = "holster"
alternate_worn_layer = UNDER_SUIT_LAYER
/obj/item/storage/belt/holster/ComponentInitialize()
. = ..()
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
STR.max_items = 3
STR.max_w_class = WEIGHT_CLASS_NORMAL
STR.set_holdable(list(
/obj/item/gun/ballistic/automatic/pistol,
/obj/item/gun/ballistic/revolver,
/obj/item/ammo_box,
/obj/item/gun/energy/e_gun/mini
))
/obj/item/storage/belt/holster/full/PopulateContents()
var/static/items_inside = list(
/obj/item/gun/ballistic/revolver/detective = 1,
/obj/item/ammo_box/c38 = 2)
generate_items_inside(items_inside,src)
/obj/item/storage/belt/fannypack
name = "fannypack"
desc = "A dorky fannypack for keeping small items in."
@@ -0,0 +1,82 @@
/obj/item/storage/belt/holster
name = "shoulder holster"
desc = "A rather plain but still badass looking holster."
icon_state = "holster"
item_state = "holster"
alternate_worn_layer = UNDER_SUIT_LAYER
/obj/item/storage/belt/holster/equipped(mob/user, slot)
. = ..()
if(ishuman(user) && slot == ITEM_SLOT_BELT)
ADD_TRAIT(user, TRAIT_GUNFLIP, CLOTHING_TRAIT)
/obj/item/storage/belt/holster/dropped(mob/user)
. = ..()
REMOVE_TRAIT(user, TRAIT_GUNFLIP, CLOTHING_TRAIT)
/obj/item/storage/belt/holster/ComponentInitialize()
. = ..()
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
STR.max_items = 1
STR.max_w_class = WEIGHT_CLASS_NORMAL
STR.set_holdable(list(
/obj/item/gun/ballistic/automatic/pistol,
/obj/item/gun/ballistic/revolver,
/obj/item/gun/energy/e_gun/mini,
/obj/item/gun/energy/disabler,
/obj/item/gun/energy/pulse/carbine,
/obj/item/gun/energy/dueling
))
/obj/item/storage/belt/holster/detective
name = "detective's holster"
desc = "A holster to carry a handgun and ammo. WARNING: Badasses only."
/obj/item/storage/belt/holster/detective/ComponentInitialize()
. = ..()
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
STR.max_items = 3
STR.max_w_class = WEIGHT_CLASS_NORMAL
STR.set_holdable(list(
/obj/item/gun/ballistic/revolver,
/obj/item/ammo_box,
/obj/item/gun/energy/disabler,
/obj/item/gun/energy/dueling
))
/obj/item/storage/belt/holster/detective/full/PopulateContents()
var/static/items_inside = list(
/obj/item/gun/ballistic/revolver/detective = 1,
/obj/item/ammo_box/c38 = 2)
generate_items_inside(items_inside,src)
/obj/item/storage/belt/holster/chameleon
name = "syndicate holster"
desc = "A hip holster that uses chameleon technology to disguise itself and any guns in it."
icon_state = "syndicate_holster"
item_state = "syndicate_holster"
var/datum/action/item_action/chameleon/change/chameleon_action
/obj/item/storage/belt/holster/chameleon/Initialize()
. = ..()
chameleon_action = new(src)
chameleon_action.chameleon_type = /obj/item/storage/belt
chameleon_action.chameleon_name = "Belt"
chameleon_action.initialize_disguises()
/obj/item/storage/belt/chameleon/ComponentInitialize()
. = ..()
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
STR.silent = TRUE
/obj/item/storage/belt/holster/chameleon/emp_act(severity)
. = ..()
if(. & EMP_PROTECT_SELF)
return
chameleon_action.emp_randomise()
/obj/item/storage/belt/chameleon/broken/Initialize()
. = ..()
chameleon_action.emp_randomise(INFINITY)
@@ -200,7 +200,7 @@
new /obj/item/holosign_creator/security(src)
new /obj/item/reagent_containers/spray/pepper(src)
new /obj/item/clothing/suit/armor/vest/det_suit(src)
new /obj/item/storage/belt/holster/full(src)
new /obj/item/storage/belt/holster/detective/full(src)
new /obj/item/pinpointer/crew(src)
new /obj/item/twohanded/binoculars(src)
new /obj/item/storage/box/rxglasses/spyglasskit(src)
@@ -85,6 +85,7 @@
var/tac_reloads = TRUE //Snowflake mechanic no more.
///Whether the gun can be sawn off by sawing tools
var/can_be_sawn_off = FALSE
var/flip_cooldown = 0
/obj/item/gun/ballistic/Initialize()
. = ..()
@@ -339,6 +340,12 @@
return ..()
/obj/item/gun/ballistic/attack_self(mob/living/user)
if(HAS_TRAIT(user, TRAIT_GUNFLIP))
if(flip_cooldown <= world.time)
flip_cooldown = (world.time + 30)
user.visible_message("<span class='notice'>[user] spins the [src] around their finger by the trigger. Thats pretty badass.</span>")
playsound(src, 'sound/items/handling/ammobox_pickup.ogg', 20, FALSE)
return
if(!internal_magazine && magazine)
if(!magazine.ammo_count())
eject_magazine(user)
+6
View File
@@ -632,6 +632,12 @@ GLOBAL_LIST_INIT(uplink_items, subtypesof(/datum/uplink_item))
surplus = 10
exclude_modes = list(/datum/game_mode/nuclear/clown_ops)
/datum/uplink_item/stealthy_weapons/holster
name = "Syndicate Holster"
desc = "A useful little device that allows for inconspicuous carrying of guns using chameleon technology. It also allows for badass gun-spinning."
item = /obj/item/storage/belt/holster/chameleon
cost = 1
// Ammunition
/datum/uplink_item/ammo
category = "Ammunition"
Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

+1
View File
@@ -1064,6 +1064,7 @@
#include "code\game\objects\items\storage\briefcase.dm"
#include "code\game\objects\items\storage\fancy.dm"
#include "code\game\objects\items\storage\firstaid.dm"
#include "code\game\objects\items\storage\holsters.dm"
#include "code\game\objects\items\storage\lockbox.dm"
#include "code\game\objects\items\storage\secure.dm"
#include "code\game\objects\items\storage\sixpack.dm"