Skip to content

Commit

Permalink
Weapons added v0.7 (#10)
Browse files Browse the repository at this point in the history
* Desword scum

* progress

* iconing

* umm

* mmmm

* Fix

* shields and blades

* belt check

* security.dmi resolve

* fixing parent issue

* resolve

* resooolve

* Flags fixed

* Weapons in progress

* rapier tweak

* w

* w

* sledgehammer fix

* new laser beam visual

* cycler

* fix

* belt

* Create belt.dmi

* Update includes.dm

* Update includes.dm

* fix shields

* Update shield.dm

* Update shield.dm

* fixes

* iconing

* overley fix

* tweak

* ballistic upd

* energy sprite&logic tweak

* modularity in module

* Update errata.dm

* study the blade

* uh

* secure hop gun

* baton&katana tweaks

* upd

* upd

* Update packs.dm

* Update packs.dm

* Update packs.dm

* Update packs.dm

* Update energy.dmi

* tasering

Snacherprod port from tg
Shocker - reference with special sound

* Update blades.dmi

* progress

* else

* more rifles

* another content pack

* fix

* syringegun sprites from tg

* pin tweak & guninhands mess

* new buldog desc

* stunsword update

* Update baton.dm

* blocks more noticeable

* centcom_mindshield to guns

centcom_mindshield new proc for stealth

* uh

---------

Co-authored-by: Blundir <[email protected]>
Co-authored-by: Blundir <[email protected]>
  • Loading branch information
3 people authored Aug 21, 2024
1 parent b3cf7e8 commit 1e0ec39
Show file tree
Hide file tree
Showing 106 changed files with 3,366 additions and 42 deletions.
12 changes: 12 additions & 0 deletions code/game/objects/items.dm
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
///Sound uses when dropping the item, or when its thrown.
var/drop_sound

///Dripstation edit
///Sound which is produced when blocking an attack
var/block_sound

var/w_class = WEIGHT_CLASS_NORMAL
var/slot_flags = 0 //This is used to determine on which slots an item can fit.
pass_flags = PASSTABLE
Expand Down Expand Up @@ -126,6 +130,11 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
var/block_chance = 0
var/hit_reaction_chance = 0 //If you want to have something unrelated to blocking/armour piercing etc. Maybe not needed, but trying to think ahead/allow more freedom

///Effect of blocking, Dripstation edit
var/block_effect = /obj/effect/temp_visual/block
var/block_color = COLOR_YELLOW
//Dripstation edit end

//The list of slots by priority. equip_to_appropriate_slot() uses this list. Doesn't matter if a mob type doesn't have a slot.
var/list/slot_equipment_priority = null // for default list, see /mob/proc/equip_to_appropriate_slot()

Expand Down Expand Up @@ -522,6 +531,9 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
return 1
if(prob(final_block_chance))
owner.visible_message(span_danger("[owner] blocks [attack_text] with [src]!"))
var/owner_turf = get_turf(owner) //dripstation edit
new block_effect(owner_turf, block_color) //dripstation edit
playsound(src, block_sound, 70, vary = TRUE) //dripstation edit
return 1
return 0

Expand Down
4 changes: 4 additions & 0 deletions code/game/objects/items/shields.dm
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
max_integrity = 75
var/obj/item/stack/sheet/mineral/repair_material = /obj/item/stack/sheet/mineral/titanium

/*
/obj/item/shield/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
if(transparent && (hitby.pass_flags & PASSGLASS))
return FALSE
Expand All @@ -37,6 +38,7 @@
if(attack_type == LEAP_ATTACK)
final_block_chance = 100
return ..()
*/

/obj/item/shield/riot/attackby(obj/item/W, mob/user, params)
if(istype(W, /obj/item/melee/baton))
Expand Down Expand Up @@ -218,11 +220,13 @@
. = ..()
icon_state = "[base_icon_state]0"

/*
/obj/item/shield/energy/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
return 0
/obj/item/shield/energy/IsReflect()
return (active)
*/

/obj/item/shield/energy/attack_self(mob/living/carbon/human/user)
if(clumsy_check && HAS_TRAIT(user, TRAIT_CLUMSY) && prob(50))
Expand Down
4 changes: 4 additions & 0 deletions code/game/objects/items/storage/belt.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1190,8 +1190,12 @@

/obj/item/storage/belt/sabre/update_icon(updates=ALL)
. = ..()
/* Dripstation edit
icon_state = "sheath"
item_state = "sheath"
*/
icon_state = initial(icon_state)
item_state = initial(item_state)
if(contents.len)
icon_state += "-sabre"
item_state += "-sabre"
Expand Down
2 changes: 2 additions & 0 deletions code/game/objects/items/teleprod.dm
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
SEND_SIGNAL(M, COMSIG_LIVING_MINOR_SHOCK)
do_teleport(M, get_turf(M), 15, channel = TELEPORT_CHANNEL_BLUESPACE)

/* dripstation edit
/obj/item/melee/baton/cattleprod/attackby(obj/item/I, mob/user, params)//handles sticking a crystal onto a stunprod to make a teleprod
if(istype(I, /obj/item/stack/ore/bluespace_crystal))
if(!cell)
Expand All @@ -41,3 +42,4 @@
user.visible_message(span_warning("You can't put the crystal onto the stunprod while it has a power cell installed!"))
else
return ..()
*/
22 changes: 22 additions & 0 deletions code/modules/cargo/packs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -297,13 +297,15 @@
/obj/item/gun/energy/disabler)
crate_name = "disabler crate"

/*
/datum/supply_pack/security/energypistol
name = "Energy Pistol Single-Pack"
desc = "Contains one energy pistol for personal defense, capable of firing both lethal and nonlethal blasts of light. Requires Security access to open."
cost = 700
access_view = ACCESS_SECURITY
small_item = TRUE
contains = list(/obj/item/gun/energy/e_gun/mini)
*/

/datum/supply_pack/security/forensics
name = "Forensics Crate"
Expand Down Expand Up @@ -553,6 +555,26 @@
crate_name = "energy gun crate"
crate_type = /obj/structure/closet/crate/secure/plasma

//Dripstation
/datum/supply_pack/security/armory/laser //dripstation mooving lethals to the armory
name = "Lethal E-gun Crate"
desc = "Contains three lethal energy guns. Requires Armory access to open."
cost = 1500
contains = list(/obj/item/gun/energy/e_gun/ancient,
/obj/item/gun/energy/e_gun/ancient,
/obj/item/gun/energy/e_gun/ancient)
crate_name = "lethal e-gun crate"

/datum/supply_pack/security/armory/reallaser
name = "Lasers Crate"
desc = "Contains three lethal, high-energy laser guns. Requires Armory access to open."
cost = 5000
contains = list(/obj/item/gun/energy/laser,
/obj/item/gun/energy/laser,
/obj/item/gun/energy/laser)
crate_name = "laser crate"
//Dripstation end

/datum/supply_pack/security/armory/mindshield
name = "Mindshield Implants Crate"
desc = "Prevent against radical thoughts with three Mindshield implants. Requires Armory access to open."
Expand Down
2 changes: 2 additions & 0 deletions code/modules/jobs/job_types/warden.dm
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@
/obj/item/storage/box/flashbangs = 10,
/obj/item/storage/box/rubbershot = 10,
/obj/effect/spawner/lootdrop/techshell = 10,
/obj/item/storage/box/laserbuckshot = 10, //dripstation edit
/obj/item/storage/belt/sabre/stunsword = 5, //dripstation edit
/obj/item/storage/box/lethalshot = 5
)

Expand Down
2 changes: 2 additions & 0 deletions code/modules/projectiles/boxes_magazines/external/lmg.dm
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
//L6 SAW

/* Dripstation edit
/obj/item/ammo_box/magazine/mm712x82
name = "box magazine (7.12x82mm)"
desc = "A 50-round box magazine designed for the L6 Saw."
Expand Down Expand Up @@ -35,3 +36,4 @@
/obj/item/ammo_box/magazine/mm712x82/update_icon_state()
. = ..()
icon_state = "a762[sprite_designation]-[round(ammo_count(),10)]"
*/
3 changes: 3 additions & 0 deletions code/modules/projectiles/guns/ballistic/automatic.dm
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,10 @@

/obj/item/gun/ballistic/automatic/l6_saw/update_overlays()
. = ..()
/* dripstation edit
. += "l6_door_[cover_open ? "open" : "closed"]"
*/
. += "[initial(item_state)]_door_[cover_open ? "open" : "closed"]" // Dripstation edit


/obj/item/gun/ballistic/automatic/l6_saw/afterattack(atom/target as mob|obj|turf, mob/living/user as mob|obj, flag, params)
Expand Down
2 changes: 2 additions & 0 deletions code/modules/projectiles/guns/energy.dm
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@
return
item_state = "[initial(icon_state)][modifystate ? "[shot.select_name]" : ""][ratio]"

/* Dripstation edit
/obj/item/gun/energy/update_overlays()
if(QDELETED(src))
return
Expand All @@ -193,6 +194,7 @@
charge_overlay.pixel_x = ammo_x_offset * (i - 1)
charge_overlay.pixel_y = ammo_y_offset * (i - 1)
. += charge_overlay
*/

///Used by update_icon_state() and update_overlays()
/obj/item/gun/energy/proc/get_charge_ratio()
Expand Down
2 changes: 2 additions & 0 deletions code/modules/projectiles/projectile/energy/stun.dm
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/*
/obj/projectile/energy/electrode
name = "electrode"
icon_state = "spark"
Expand Down Expand Up @@ -33,3 +34,4 @@
/obj/projectile/energy/electrode/on_range() //to ensure the bolt sparks when it reaches the end of its range if it didn't hit a target yet
do_sparks(1, TRUE, src)
..()
*/
2 changes: 2 additions & 0 deletions code/modules/reagents/chemistry/reagents/food_reagents.dm
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,7 @@
taste_description = "scorching agony"
metabolization_rate = 6 * REAGENTS_METABOLISM

/* dripstation edit
/datum/reagent/consumable/condensedcapsaicin/reaction_mob(mob/living/M, methods=TOUCH, reac_volume)
if(!ishuman(M) && !ismonkey(M))
return
Expand Down Expand Up @@ -341,6 +342,7 @@
victim.Paralyze(14 SECONDS)
M.adjustStaminaLoss(5)
victim.update_damage_hud()
*/

/datum/reagent/consumable/condensedcapsaicin/on_mob_life(mob/living/carbon/M)
if(prob(15))
Expand Down
43 changes: 43 additions & 0 deletions modular_dripstation/code/datums/reagent/condensed_capsaicin.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
/datum/reagent/consumable/condensedcapsaicin/reaction_mob(mob/living/M, methods=TOUCH, reac_volume)
if(!ishuman(M) && !ismonkey(M))
return

var/mob/living/carbon/victim = M
if(methods & (TOUCH|VAPOR))
//check for protection
var/mouth_covered = victim.is_mouth_covered()
var/eyes_covered = victim.is_eyes_covered()

//actually handle the pepperspray effects
if ( eyes_covered && mouth_covered )
return
else if ( mouth_covered ) // Reduced effects if partially protected
if(prob(50))
victim.emote("scream")
victim.adjust_eye_blur(14)
victim.blind_eyes(10)
victim.set_confusion_if_lower(10 SECONDS)
victim.damageoverlaytemp = 75
victim.Knockdown(6 SECONDS)
M.adjustStaminaLoss(5)
return
else if ( eyes_covered ) // Eye cover is better than mouth cover
if(prob(20))
victim.emote("cough")
victim.adjust_eye_blur(4)
victim.set_confusion_if_lower(5 SECONDS)
victim.damageoverlaytemp = 50
M.adjustStaminaLoss(5)
return
else // Oh dear :D
if(prob(60))
victim.emote("scream")
else
victim.emote("cough")
victim.adjust_eye_blur(14)
victim.blind_eyes(10)
victim.set_confusion_if_lower(12 SECONDS)
victim.damageoverlaytemp = 100
victim.Knockdown(14 SECONDS)
M.adjustStaminaLoss(10)
victim.update_damage_hud()
15 changes: 14 additions & 1 deletion modular_dripstation/code/game/effects/temporary_visuals/misc.dm
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,17 @@
. = ..()
pixel_x = rand(-4,0)
pixel_y = rand(8,12)
animate(src, pixel_y = pixel_y + 16, alpha = 0, time = duration)
animate(src, pixel_y = pixel_y + 16, alpha = 0, time = duration)

/obj/effect/temp_visual/block //color is white by default, set to whatever is needed
name = "blocking glow"
icon_state = "block"
icon = 'modular_dripstation/icons/effects/effects.dmi'
duration = 6.7

/obj/effect/temp_visual/block/Initialize(mapload, set_color)
if(set_color)
add_atom_colour(set_color, FIXED_COLOUR_PRIORITY)
. = ..()
pixel_x = rand(-12, 12)
pixel_y = rand(-9, 0)
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/obj/effect/projectile/impact/laser/hitscan
name = "laser impact"
icon_state = "impact_laser_red"
icon = 'modular_dripstation/icons/effects/projectiles/impact.dmi'

/obj/effect/projectile/tracer/laser/hitscan
name = "laser tracer"
icon_state = "tracer_laser_red"
icon = 'modular_dripstation/icons/effects/projectiles/tracer.dmi'

/obj/effect/projectile/muzzle/laser/hitscan
name = "laser muzzle"
icon_state = "muzzle_laser_red"
icon = 'modular_dripstation/icons/effects/projectiles/muzzle.dmi'

/obj/effect/projectile/impact/laser/hitscan/sniper
name = "sniper laser impact"
icon_state = "impact_scc"
icon = 'modular_dripstation/icons/effects/projectiles/impact.dmi'

/obj/effect/projectile/tracer/laser/hitscan/sniper
name = "sniper laser tracer"
icon_state = "beam_scc"
icon = 'modular_dripstation/icons/effects/projectiles/tracer.dmi'

/obj/effect/projectile/muzzle/laser/hitscan/sniper
name = "sniper laser muzzle"
icon_state = "muzzle_scc"
icon = 'modular_dripstation/icons/effects/projectiles/muzzle.dmi'

/obj/effect/projectile/impact/bfg
name = "bfg impact"
icon_state = "bfg"
icon = 'modular_dripstation/icons/effects/projectiles/impact.dmi'

/obj/effect/projectile/tracer/bfg
name = "bfg tracer"
icon_state = "bfg"
icon = 'modular_dripstation/icons/effects/projectiles/tracer.dmi'

/obj/effect/projectile/muzzle/bfg
name = "bfg muzzle"
icon_state = "bfg"
icon = 'modular_dripstation/icons/effects/projectiles/muzzle.dmi'
Loading

0 comments on commit 1e0ec39

Please sign in to comment.