diff --git a/code/__DEFINES/traits.dm b/code/__DEFINES/traits.dm index e1fc8fa001..b1696e6ed0 100644 --- a/code/__DEFINES/traits.dm +++ b/code/__DEFINES/traits.dm @@ -221,6 +221,7 @@ #define TRAIT_NO_INTERNALS "no-internals" #define TRAIT_NO_ALCOHOL "alcohol_intolerance" #define TRAIT_MUTATION_STASIS "mutation_stasis" //Prevents processed genetics mutations from processing. +#define TRAIT_FAST_PUMP "fast_pump" // common trait sources #define TRAIT_GENERIC "generic" @@ -246,6 +247,7 @@ #define BLOODSUCKER_TRAIT "bloodsucker" #define SHOES_TRAIT "shoes" //inherited from your sweet kicks #define GLOVE_TRAIT "glove" //inherited by your cool gloves +#define BOOK_TRAIT "granter (book)" // knowledge is power // unique trait sources, still defines #define STATUE_MUTE "statue" diff --git a/code/game/objects/items/granters.dm b/code/game/objects/items/granters.dm index 9749bae313..7f84b56914 100644 --- a/code/game/objects/items/granters.dm +++ b/code/game/objects/items/granters.dm @@ -57,6 +57,35 @@ on_reading_finished(user) reading = FALSE return TRUE +///TRAITS/// + +/obj/item/book/granter/trait + var/granted_trait + var/traitname = "being cool" + +/obj/item/book/granter/trait/already_known(mob/user) + if(!granted_trait) + return TRUE + if(HAS_TRAIT(user, granted_trait)) + to_chat(user, "You already have all the insight you need about [traitname].") + return TRUE + return FALSE + +/obj/item/book/granter/trait/on_reading_start(mob/user) + to_chat(user, "You start reading about [traitname]...") + +/obj/item/book/granter/trait/on_reading_finished(mob/user) + to_chat(user, "You feel like you've got a good handle on [traitname]!") + ADD_TRAIT(user, granted_trait, BOOK_TRAIT) + +/obj/item/book/granter/trait/rifleman + name = "\proper the Neo-Russian Rifleman\'s Primer" + desc = "A book with stains of vodka and...blood? The back is hard to read, but says something about bolt-actions. Or pump-actions. Both, maybe." + oneuse = FALSE + granted_trait = TRAIT_FAST_PUMP + traitname = "riflery" + icon_state = "book1" + remarks = list("One smooth motion...", "Palm the bolt...", "Push up, rotate back, push forward, down...", "Don't slap yourself with the bolt...", "Wait, what's this about pumping?") ///ACTION BUTTONS/// diff --git a/code/modules/projectiles/guns/ballistic/shotgun.dm b/code/modules/projectiles/guns/ballistic/shotgun.dm index 7fb17ced57..a4424d5e88 100644 --- a/code/modules/projectiles/guns/ballistic/shotgun.dm +++ b/code/modules/projectiles/guns/ballistic/shotgun.dm @@ -41,7 +41,10 @@ to_chat(user, "You're too exhausted for that.")//CIT CHANGE - ditto return//CIT CHANGE - ditto pump(user, TRUE) - recentpump = world.time + 10 + if(HAS_TRAIT(user, TRAIT_FAST_PUMP)) + recentpump = world.time + 2 + else + recentpump = world.time + 10 if(istype(user))//CIT CHANGE - makes pumping shotguns cost a lil bit of stamina. user.adjustStaminaLossBuffered(2) //CIT CHANGE - DITTO. make this scale inversely to the strength stat when stats/skills are added return diff --git a/code/modules/uplink/uplink_items/uplink_devices.dm b/code/modules/uplink/uplink_items/uplink_devices.dm index 194281ded6..cda83cf684 100644 --- a/code/modules/uplink/uplink_items/uplink_devices.dm +++ b/code/modules/uplink/uplink_items/uplink_devices.dm @@ -188,6 +188,16 @@ item = /obj/item/healthanalyzer/rad_laser cost = 3 +/datum/uplink_item/device_tools/riflery_primer + name = "Riflery Primer" + desc = "An old book with blood and vodka stains on it. Freshly pulled from a dusty crate in some old warehouse, \ + this primer of questionable worth and value is rumored to increase your rifle-bolt-working and/or shotgun \ + racking fivefold. Then again, the techniques here only work on bolt-actions and pump-actions..." + item = /obj/item/book/granter/trait/rifleman + cost = 3 + restricted_roles = list("Operative") // i want it to be surplusable but i also want it to be mostly nukie only, please advise + surplus = 90 + /datum/uplink_item/device_tools/stimpack name = "Stimpack" desc = "Stimpacks, the tool of many great heroes, make you nearly immune to stuns and knockdowns for about \