mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 03:27:05 +01:00
WT Rework and Nerf (#20536)
* Reworks and nerfs WTs * Removes some duplicate comments * Makes WT ammo box's normal sized items because I forgot to at first * Adds a var to WT mags to check if they are being loaded to prevent people from queueing up multiple reload processes at once * Sanity checks work properly now * Implements changes requested, empty magazines now available from RND, ammo crate contains 5 full magazines, mag size set back to 20, magazines made normal sized items and fit in assault belt * Update code/__HELPERS/mob_helpers.dm Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> * Update code/__HELPERS/mob_helpers.dm Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> * Magazines fit in security webbings * I forgot a comma * Apply suggestions from code review Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com> * Applying various reviewer suggestions * Applies various suggestions * removes moving_do_after now that its a param * Apply suggestions from code review Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com> * solves the merge conflict hopefully * step one of trying to fix conflict again * step two hopefully fixes conflict * Delete ammo.dmi * Merge branch 'master' into wt-rework * Apply suggestions from code review Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com> * Applying various reviewer suggestions * Revert "Applying various reviewer suggestions" This reverts commit7081e9aa2b. * Revert "Apply suggestions from code review" This reverts commit96dab4f8b8. * Revert "Merge branch 'master' into wt-rework" This reverts commit6906a67654. * Merge branch 'master' into wt-rework * please god work * Update code/modules/projectiles/ammunition.dm * Update code/modules/projectiles/ammunition/magazines.dm --------- Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com> Co-authored-by: S34N <12197162+S34NW@users.noreply.github.com> Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com> Co-authored-by: Farie82 <farie82@users.noreply.github.com>
This commit is contained in:
co-authored by
Henri215
S34N
SteelSlayer
Farie82
parent
8b7f4c8b69
commit
49b26c4eba
@@ -52,6 +52,8 @@
|
||||
/obj/item/ammo_casing/attackby(obj/item/I as obj, mob/user as mob, params)
|
||||
if(istype(I, /obj/item/ammo_box))
|
||||
var/obj/item/ammo_box/box = I
|
||||
if(box.slow_loading)
|
||||
return
|
||||
if(isturf(loc))
|
||||
var/boolets = 0
|
||||
for(var/obj/item/ammo_casing/bullet in loc)
|
||||
@@ -130,10 +132,11 @@
|
||||
var/multi_sprite_step = AMMO_MULTI_SPRITE_STEP_NONE // see update_icon_state() for details
|
||||
var/caliber
|
||||
var/multiload = 1
|
||||
var/slow_loading = FALSE
|
||||
var/list/initial_mats //For calculating refund values.
|
||||
|
||||
/obj/item/ammo_box/New()
|
||||
..()
|
||||
/obj/item/ammo_box/Initialize(mapload)
|
||||
. = ..()
|
||||
for(var/i in 1 to max_ammo)
|
||||
stored_ammo += new ammo_type(src)
|
||||
update_appearance(UPDATE_DESC|UPDATE_ICON)
|
||||
|
||||
@@ -65,6 +65,30 @@
|
||||
ammo_type = /obj/item/ammo_casing/n762
|
||||
max_ammo = 14
|
||||
|
||||
/obj/item/ammo_box/wt550
|
||||
name = "ammo box (4.6x30mm)"
|
||||
icon_state = "riflebox"
|
||||
origin_tech = "combat=2"
|
||||
ammo_type = /obj/item/ammo_casing/c46x30mm
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
max_ammo = 20
|
||||
multiload = 0
|
||||
|
||||
/obj/item/ammo_box/wt550/wtap
|
||||
name = "ammo box (Armor Piercing 4.6x30mm)"
|
||||
icon_state = "wtbox_AP"
|
||||
ammo_type = /obj/item/ammo_casing/c46x30mm/ap
|
||||
|
||||
/obj/item/ammo_box/wt550/wtic
|
||||
name = "ammo box (Incendiary 4.6x30mm)"
|
||||
icon_state = "wtbox_inc"
|
||||
ammo_type = /obj/item/ammo_casing/c46x30mm/inc
|
||||
|
||||
/obj/item/ammo_box/wt550/wttx
|
||||
name = "ammo box (Toxin Tipped 4.6x30mm)"
|
||||
icon_state = "wtbox_tox"
|
||||
ammo_type = /obj/item/ammo_casing/c46x30mm/tox
|
||||
|
||||
/obj/item/ammo_box/laser
|
||||
name = "ammo box (laser)"
|
||||
icon_state = "laserbox"
|
||||
|
||||
@@ -154,8 +154,8 @@
|
||||
max_ammo = 6
|
||||
multiload = 0
|
||||
|
||||
/obj/item/ammo_box/magazine/internal/rus357/New()
|
||||
..()
|
||||
/obj/item/ammo_box/magazine/internal/rus357/Initialize(mapload)
|
||||
. = ..()
|
||||
stored_ammo.Cut() // We only want 1 bullet in there
|
||||
stored_ammo += new ammo_type(src)
|
||||
|
||||
@@ -258,6 +258,37 @@
|
||||
caliber = "4.6x30mm"
|
||||
max_ammo = 20
|
||||
multi_sprite_step = 4
|
||||
multiload = 0
|
||||
slow_loading = TRUE
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
///A var to check if the mag is being loaded
|
||||
var/being_loaded = FALSE
|
||||
/// There are two reloading processes ongoing so cancel them
|
||||
var/double_loaded = FALSE
|
||||
|
||||
/obj/item/ammo_box/magazine/wt550m9/attackby(obj/item/A, mob/user, params)
|
||||
if(istype(A, /obj/item/ammo_casing))
|
||||
var/obj/item/ammo_casing/AC = A
|
||||
if(give_round(AC))
|
||||
user.drop_item()
|
||||
AC.loc = src
|
||||
return
|
||||
if(istype(A, /obj/item/ammo_box/wt550) || istype(A, /obj/item/ammo_box/magazine/wt550m9))
|
||||
to_chat(user, "<span class='notice'>You begin to load the magazine with [A].</span>")
|
||||
var/obj/item/ammo_box/AB = A
|
||||
for(var/obj/item/ammo_casing/AC in AB.stored_ammo)
|
||||
if(length(stored_ammo) >= max_ammo)
|
||||
to_chat(user, "<span class='notice'>You stop loading the magazine with [A].</span>")
|
||||
break
|
||||
if(do_after_once(user, 0.5 SECONDS, target = src, allow_moving = TRUE, must_be_held = TRUE, attempt_cancel_message = "<span class='notice'>You stop loading the magazine with [A].</span>"))
|
||||
src.give_round(AC)
|
||||
AB.stored_ammo -= AC
|
||||
update_mat_value()
|
||||
update_appearance(UPDATE_DESC|UPDATE_ICON_STATE)
|
||||
AB.update_appearance(UPDATE_DESC|UPDATE_ICON_STATE)
|
||||
playsound(src, 'sound/weapons/gun_interactions/bulletinsert.ogg', 50, 1)
|
||||
else
|
||||
break
|
||||
|
||||
/obj/item/ammo_box/magazine/wt550m9/wtap
|
||||
name = "wt550 magazine (Armour Piercing 4.6x30mm)"
|
||||
@@ -274,6 +305,16 @@
|
||||
icon_state = "46x30mmtI"
|
||||
ammo_type = /obj/item/ammo_casing/c46x30mm/inc
|
||||
|
||||
/obj/item/ammo_box/magazine/wt550m9/empty
|
||||
name = "wt550 magazine (4.6x30mm)"
|
||||
icon_state = "46x30mmt"
|
||||
ammo_type = /obj/item/ammo_casing/c46x30mm
|
||||
|
||||
/obj/item/ammo_box/magazine/wt550m9/empty/Initialize(mapload)
|
||||
. = ..()
|
||||
stored_ammo.Cut()
|
||||
update_appearance(UPDATE_DESC|UPDATE_ICON)
|
||||
|
||||
/obj/item/ammo_box/magazine/uzim9mm
|
||||
name = "uzi magazine (9mm)"
|
||||
icon_state = "uzi9mm"
|
||||
|
||||
@@ -146,37 +146,59 @@
|
||||
category = list("Weapons")
|
||||
|
||||
//WT550 Mags
|
||||
|
||||
/datum/design/mag_oldsmg
|
||||
name = "WT-550 Auto Gun Magazine (4.6x30mm)"
|
||||
desc = "A 20 round magazine for the out of date security WT-550 Auto Rifle"
|
||||
id = "mag_oldsmg"
|
||||
req_tech = list("combat" = 1, "materials" = 1)
|
||||
build_type = PROTOLATHE
|
||||
materials = list(MAT_METAL = 4000)
|
||||
build_path = /obj/item/ammo_box/magazine/wt550m9
|
||||
materials = list(MAT_METAL = 10000)
|
||||
build_path = /obj/item/ammo_box/magazine/wt550m9/empty
|
||||
category = list("Weapons")
|
||||
|
||||
/datum/design/mag_oldsmg/ap_mag
|
||||
name = "WT-550 Auto Gun Armour Piercing Magazine (4.6x30mm AP)"
|
||||
desc = "A 20 round armour piercing magazine for the out of date security WT-550 Auto Rifle"
|
||||
id = "mag_oldsmg_ap"
|
||||
/datum/design/box_oldsmg
|
||||
name = "WT-550 Auto Gun Ammo Box (4.6x30mm)"
|
||||
desc = "A box of 20 rounds for the out of date security WT-550 Auto Rifle"
|
||||
id = "box_oldsmg"
|
||||
req_tech = list("combat" = 1, "materials" = 1)
|
||||
build_type = PROTOLATHE
|
||||
materials = list(MAT_METAL = 4000)
|
||||
build_path = /obj/item/ammo_box/wt550
|
||||
category = list("Weapons")
|
||||
|
||||
/datum/design/box_oldsmg/ap_box
|
||||
name = "WT-550 Auto Gun Armour Piercing Ammo Box (4.6x30mm AP)"
|
||||
desc = "A box of 20 armour piercing rounds for the out of date security WT-550 Auto Rifle"
|
||||
id = "box_oldsmg_ap"
|
||||
materials = list(MAT_METAL = 6000, MAT_SILVER = 600)
|
||||
build_path = /obj/item/ammo_box/magazine/wt550m9/wtap
|
||||
build_path = /obj/item/ammo_box/wt550/wtap
|
||||
category = list("Weapons")
|
||||
|
||||
/datum/design/mag_oldsmg/ic_mag
|
||||
name = "WT-550 Auto Gun Incendiary Magazine (4.6x30mm IC)"
|
||||
desc = "A 20 round armour piercing magazine for the out of date security WT-550 Auto Rifle"
|
||||
id = "mag_oldsmg_ic"
|
||||
/datum/design/box_oldsmg/ic_box
|
||||
name = "WT-550 Auto Gun Incendiary Ammo Box (4.6x30mm IC)"
|
||||
desc = "A box of 20 armour piercing rounds for the out of date security WT-550 Auto Rifle"
|
||||
id = "box_oldsmg_ic"
|
||||
materials = list(MAT_METAL = 6000, MAT_SILVER = 600, MAT_GLASS = 1000)
|
||||
build_path = /obj/item/ammo_box/magazine/wt550m9/wtic
|
||||
build_path = /obj/item/ammo_box/wt550/wtic
|
||||
category = list("Weapons")
|
||||
|
||||
/datum/design/mag_oldsmg/tx_mag
|
||||
name = "WT-550 Auto Gun Uranium Magazine (4.6x30mm TX)"
|
||||
desc = "A 20 round uranium tipped magazine for the out of date security WT-550 Auto Rifle"
|
||||
id = "mag_oldsmg_tx"
|
||||
/datum/design/box_oldsmg/tx_box
|
||||
name = "WT-550 Auto Gun Uranium Ammo Box (4.6x30mm TX)"
|
||||
desc = "A box of 20 uranium tipped rounds for the out of date security WT-550 Auto Rifle"
|
||||
id = "box_oldsmg_tx"
|
||||
materials = list(MAT_METAL = 6000, MAT_SILVER = 600, MAT_URANIUM = 2000)
|
||||
build_path = /obj/item/ammo_box/magazine/wt550m9/wttx
|
||||
build_path = /obj/item/ammo_box/wt550/wttx
|
||||
category = list("Weapons")
|
||||
|
||||
/datum/design/mag_laser
|
||||
name = "Laser Rifle Projector Magazine"
|
||||
desc = "A 20 round encased projector magazine for the IK Laser Rifle series"
|
||||
id = "mag_laser"
|
||||
build_type = PROTOLATHE
|
||||
req_tech = list("combat" = 4, "powerstorage" = 4)
|
||||
materials = list(MAT_METAL = 4000, MAT_PLASMA = 600)
|
||||
build_path = /obj/item/ammo_box/magazine/laser
|
||||
category = list("Weapons")
|
||||
|
||||
/datum/design/mag_laser
|
||||
name = "Laser Rifle Projector Ammunition"
|
||||
|
||||
@@ -249,6 +249,7 @@
|
||||
/datum/supply_packs/security/armory/wt550ammo
|
||||
name = "WT-550 Rifle Ammo Crate"
|
||||
contains = list(/obj/item/ammo_box/magazine/wt550m9,
|
||||
/obj/item/ammo_box/magazine/wt550m9,
|
||||
/obj/item/ammo_box/magazine/wt550m9,
|
||||
/obj/item/ammo_box/magazine/wt550m9,
|
||||
/obj/item/ammo_box/magazine/wt550m9,)
|
||||
|
||||
Reference in New Issue
Block a user