From b7b4bf1a61dba4353b29b9b4e6d7ce32cf463b3e Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 14:51:53 -0400 Subject: [PATCH 01/22] Update magweapon.dm --- .../projectiles/guns/ballistic/magweapon.dm | 232 ++++++++++++++++-- 1 file changed, 217 insertions(+), 15 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 017a9dd52d..275b003fea 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -1,3 +1,185 @@ +//Stollen vars so this all work for real - Copy pasted addtion + +/obj/item/ammo_casing/mag/ + var/e_cost = 50 + +/obj/item/gun/mag + var/obj/item/stock_parts/cell/cell //What type of power cell this uses + var/cell_type = /obj/item/stock_parts/cell + var/modifystate = 0 + var/list/ammo_type = list(/obj/item/ammo_casing/mag) + var/can_charge = 1 //Can it be charged in a recharger? + var/charge_sections = 4 + ammo_x_offset = 2 + var/old_ratio = 0 // stores the gun's previous ammo "ratio" to see if it needs an updated iconn + var/charge_tick = 0 + var/charge_delay = 4 + var/dead_cell = FALSE //set to true so the gun is given an empty cell + var/spawnwithmagazine = TRUE + var/mag_type = /obj/item/ammo_box/magazine/m10mm //Removes the need for max_ammo and caliber info + var/obj/item/ammo_box/magazine/magazine + var/casing_ejector = TRUE //whether the gun ejects the chambered casing + +/obj/item/gun/mag/Initialize() + . = ..() + if(!spawnwithmagazine) + update_icon() + return + if (!magazine) + magazine = new mag_type(src) + chamber_round() + update_icon() + +/obj/item/gun/mag/process_chamber(empty_chamber = 1) + var/obj/item/ammo_casing/AC = chambered //Find chambered round + if(istype(AC)) //there's a chambered round + if(casing_ejector) + AC.forceMove(drop_location()) //Eject casing onto ground. + AC.bounce_away(TRUE) + chambered = null + else if(empty_chamber) + chambered = null + chamber_round() + +/obj/item/gun/mag/proc/chamber_round() + if (chambered || !magazine) + return + else if (magazine.ammo_count()) + chambered = magazine.get_round() + chambered.forceMove(src) + +/obj/item/gun/mag/can_shoot() + if(!magazine || !magazine.ammo_count(0)) + return 0 + return 1 + +/obj/item/gun/mag/attackby(obj/item/A, mob/user, params) + ..() + if (istype(A, /obj/item/ammo_box/magazine)) + var/obj/item/ammo_box/magazine/AM = A + if (!magazine && istype(AM, mag_type)) + if(user.transferItemToLoc(AM, src)) + magazine = AM + to_chat(user, "You load a new magazine into \the [src].") + if(magazine.ammo_count()) + playsound(src, "gun_insert_full_magazine", 70, 1) + if(!chambered) + chamber_round() + addtimer(CALLBACK(GLOBAL_PROC, .proc/playsound, src, 'sound/weapons/gun_chamber_round.ogg', 100, 1), 3) + else + playsound(src, "gun_insert_empty_magazine", 70, 1) + A.update_icon() + update_icon() + return 1 + else + to_chat(user, "You cannot seem to get \the [src] out of your hands!") + return + else if (magazine) + to_chat(user, "There's already a magazine in \the [src].") + +//ATTACK HAND IGNORING PARENT RETURN VALUE + +/obj/item/gun/mag/attack_self(mob/living/user) + var/obj/item/ammo_casing/AC = chambered //Find chambered round + if(magazine) + magazine.forceMove(drop_location()) + user.put_in_hands(magazine) + magazine.update_icon() + if(magazine.ammo_count()) + playsound(src, 'sound/weapons/gun_magazine_remove_full.ogg', 70, 1) + else + playsound(src, "gun_remove_empty_magazine", 70, 1) + magazine = null + to_chat(user, "You pull the magazine out of \the [src].") + else if(chambered) + AC.forceMove(drop_location()) + AC.bounce_away() + chambered = null + to_chat(user, "You unload the round from \the [src]'s chamber.") + playsound(src, "gun_slide_lock", 70, 1) + else + to_chat(user, "There's no magazine in \the [src].") + update_icon() + return + + +/obj/item/gun/mag/examine(mob/user) + ..() + to_chat(user, "It has [get_ammo()] round\s remaining.") + +/obj/item/gun/mag/proc/get_ammo(countchambered = 1) + var/boolets = 0 //mature var names for mature people + if (chambered && countchambered) + boolets++ + if (magazine) + boolets += magazine.ammo_count() + return boolets + +/obj/item/gun/mag/emp_act(severity) + . = ..() + if(!(. & EMP_PROTECT_CONTENTS)) + cell.use(round(cell.charge / severity)) + recharge_newshot() //and try to charge a new shot + +/obj/item/gun/mag/get_cell() + return cell + +/obj/item/gun/mag/Initialize() + . = ..() + if(cell_type) + cell = new cell_type(src) + else + cell = new(src) + if(!dead_cell) + cell.give(cell.maxcharge) + update_ammo_types() + recharge_newshot(TRUE) + +/obj/item/gun/mag/proc/update_ammo_types() + var/obj/item/ammo_casing/mag/shot + for (var/i = 1, i <= ammo_type.len, i++) + var/shottype = ammo_type[i] + shot = new shottype(src) + ammo_type[i] = shot + fire_sound = shot.fire_sound + fire_delay = shot.delay + +/obj/item/gun/mag/Destroy() + QDEL_NULL(cell) + STOP_PROCESSING(SSobj, src) + return ..() + +/obj/item/gun/mag/can_shoot() + var/obj/item/ammo_casing/mag/ = ammo_type + return !QDELETED(cell) ? (cell.charge >= mag.e_cost) : FALSE + +/obj/item/gun/mag/recharge_newshot(no_cyborg_drain) + if (!ammo_type || !cell) + return + if(!chambered) + var/obj/item/ammo_casing/energy/AC = ammo_type + if(cell.charge >= AC.e_cost) //if there's enough power in the cell cell... + chambered = AC //...prepare a new shot based on the current ammo type selected + if(!chambered.BB) + chambered.newshot() + +/obj/item/gun/mag/process_chamber() + if(chambered && !chambered.BB) //if BB is null, i.e the shot has been fired... + var/obj/item/ammo_casing/mag/ = chambered + cell.use(mag.e_cost)//... drain the cell cell + chambered = null //either way, released the prepared shot + recharge_newshot() //try to charge a new shot + +/obj/item/gun/mag/update_icon(force_update) + if(QDELETED(src)) + return + ..() + var/ratio = CEILING(CLAMP(cell.charge / cell.maxcharge, 0, 1) * charge_sections, 1) + if(ratio == old_ratio && !force_update) + return + old_ratio = ratio + cut_overlays() + ///////XCOM X9 AR/////// /obj/item/gun/ballistic/automatic/x9 //will be adminspawn only so ERT or something can use them @@ -55,7 +237,7 @@ /obj/item/projectile/bullet/nlmags //non-lethal boolets icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "magjectile-nl" - damage = 0 + damage = 2 knockdown = 0 stamina = 25 armour_penetration = -10 @@ -67,18 +249,20 @@ /////actual ammo///// -/obj/item/ammo_casing/caseless/amags +/obj/item/ammo_casing/mag/amags desc = "A ferromagnetic slug intended to be launched out of a compatible weapon." caliber = "mags" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" + e_cost = 50 projectile_type = /obj/item/projectile/bullet/mags -/obj/item/ammo_casing/caseless/anlmags +/obj/item/ammo_casing/mag/anlmags desc = "A specialized ferromagnetic slug designed with a less-than-lethal payload." caliber = "mags" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" + e_cost = 50 projectile_type = /obj/item/projectile/bullet/nlmags //////magazines///// @@ -87,7 +271,7 @@ name = "magpistol magazine (non-lethal disabler)" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "nlmagmag" - ammo_type = /obj/item/ammo_casing/caseless/anlmags + ammo_type = /obj/item/ammo_casing/mag/anlmags caliber = "mags" max_ammo = 15 multiple_sprites = 2 @@ -96,11 +280,11 @@ name = "magpistol magazine (lethal)" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "smallmagmag" - ammo_type = /obj/item/ammo_casing/caseless/amags + ammo_type = /obj/item/ammo_casing/mag/amags //////the gun itself////// -/obj/item/gun/ballistic/automatic/pistol/mag +/obj/item/gun/ballistic/mag/pistol/mag name = "magpistol" desc = "A handgun utilizing maglev technologies to propel a ferromagnetic slug to extreme velocities." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' @@ -108,12 +292,13 @@ force = 10 fire_sound = 'sound/weapons/magpistol.ogg' mag_type = /obj/item/ammo_box/magazine/mmag/small +// cell_type = /obj/item/stock_parts/cell/magpistal can_suppress = 0 casing_ejector = 0 fire_delay = 2 recoil = 0.2 -/obj/item/gun/ballistic/automatic/pistol/mag/update_icon() +/obj/item/gun/mag/automatic/pistol/mag/update_icon() ..() if(magazine) cut_overlays() @@ -122,9 +307,16 @@ cut_overlays() icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" +//////the cell//////////// + +/obj/item/stock_parts/cell/magpistal + name = "magpistal hyper power cell" + desc = "A small hyper cell, used in the mag pistal" + maxcharge = 3500 //70 shots before recharge + ///research memes/// -/obj/item/gun/ballistic/automatic/pistol/mag/nopin +/obj/item/gun/mag/automatic/pistol/mag/nopin pin = null spawnwithmagazine = FALSE @@ -134,7 +326,7 @@ id = "magpisol" build_type = PROTOLATHE materials = list(MAT_METAL = 7500, MAT_GLASS = 1000, MAT_URANIUM = 1000, MAT_TITANIUM = 5000, MAT_SILVER = 2000) - build_path = /obj/item/gun/ballistic/automatic/pistol/mag/nopin + build_path = /obj/item/gun/mag/automatic/pistol/mag/nopin category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -210,7 +402,7 @@ /obj/item/projectile/bullet/nlmagrifle //non-lethal boolets icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "magjectile-large-nl" - damage = 0 + damage = 2 knockdown = 0 stamina = 25 armour_penetration = -10 @@ -221,18 +413,20 @@ ///ammo casings/// -/obj/item/ammo_casing/caseless/amagm +/obj/item/ammo_casing/energy/mag/amagm desc = "A large ferromagnetic slug intended to be launched out of a compatible weapon." caliber = "magm" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" + e_cost = 50 projectile_type = /obj/item/projectile/bullet/magrifle -/obj/item/ammo_casing/caseless/anlmagm +/obj/item/ammo_casing/energy/mag/anlmagm desc = "A large, specialized ferromagnetic slug designed with a less-than-lethal payload." caliber = "magm" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" + e_cost = 50 projectile_type = /obj/item/projectile/bullet/nlmagrifle ///magazines/// @@ -241,7 +435,7 @@ name = "magrifle magazine (non-lethal disabler)" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mediummagmag" - ammo_type = /obj/item/ammo_casing/caseless/anlmagm + ammo_type = /obj/item/ammo_casing/energy/mag/anlmagm caliber = "magm" max_ammo = 24 multiple_sprites = 2 @@ -250,18 +444,19 @@ name = "magrifle magazine (lethal)" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mediummagmag" - ammo_type = /obj/item/ammo_casing/caseless/amagm + ammo_type = /obj/item/ammo_casing/energy/mag/amagm max_ammo = 24 ///the gun itself/// -/obj/item/gun/ballistic/automatic/magrifle +/obj/item/gun/mag/automatic/magrifle name = "\improper Magnetic Rifle" desc = "A simple upscalling of the technologies used in the magpistol, the magrifle is capable of firing slightly larger slugs in bursts. Compatible with the magpistol's slugs." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "magrifle" item_state = "arg" slot_flags = 0 + cell_type = /obj/item/stock_parts/cell/magrifle mag_type = /obj/item/ammo_box/magazine/mmag fire_sound = 'sound/weapons/magrifle.ogg' can_suppress = 0 @@ -271,6 +466,13 @@ recoil = 0.15 casing_ejector = 0 +//////the cell//////////// + +/obj/item/stock_parts/cell/magrifle + name = "magrifle hyper power cell" + desc = "A small hyper cell, used in the mag rifle" + maxcharge = 2400 //48 shots before recharge + ///research/// /obj/item/gun/ballistic/automatic/magrifle/nopin From 59226233f854df53604967254a02fa089ec4373b Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 14:52:46 -0400 Subject: [PATCH 02/22] Update recharger.dm --- code/game/machinery/recharger.dm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/game/machinery/recharger.dm b/code/game/machinery/recharger.dm index 94b6eee8aa..d44053f433 100755 --- a/code/game/machinery/recharger.dm +++ b/code/game/machinery/recharger.dm @@ -15,7 +15,9 @@ /obj/item/gun/energy, /obj/item/melee/baton, /obj/item/ammo_box/magazine/recharge, - /obj/item/modular_computer)) + /obj/item/modular_computer, + /obj/item/gun/mag/automatic/pistol/mag, + /obj/item/gun/mag/automatic/magrifle)) /obj/machinery/recharger/RefreshParts() for(var/obj/item/stock_parts/capacitor/C in component_parts) From c59cb823bb522034f343859ed7ea1459b65f71f2 Mon Sep 17 00:00:00 2001 From: Useroth Date: Sun, 28 Apr 2019 21:14:11 +0200 Subject: [PATCH 03/22] Let's try like this. --- .../code/modules/projectiles/guns/ballistic/magweapon.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 275b003fea..2a8bbb6877 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -150,7 +150,7 @@ return ..() /obj/item/gun/mag/can_shoot() - var/obj/item/ammo_casing/mag/ = ammo_type + var/obj/item/ammo_casing/mag/mag = ammo_type return !QDELETED(cell) ? (cell.charge >= mag.e_cost) : FALSE /obj/item/gun/mag/recharge_newshot(no_cyborg_drain) @@ -165,7 +165,7 @@ /obj/item/gun/mag/process_chamber() if(chambered && !chambered.BB) //if BB is null, i.e the shot has been fired... - var/obj/item/ammo_casing/mag/ = chambered + var/obj/item/ammo_casing/mag/mag = chambered cell.use(mag.e_cost)//... drain the cell cell chambered = null //either way, released the prepared shot recharge_newshot() //try to charge a new shot From 0fa3fb6aca7b138681b33b420dc44cf2db98b14f Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 16:46:12 -0400 Subject: [PATCH 04/22] Update magweapon.dm --- .../projectiles/guns/ballistic/magweapon.dm | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 2a8bbb6877..b13f564f73 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -16,7 +16,7 @@ var/charge_delay = 4 var/dead_cell = FALSE //set to true so the gun is given an empty cell var/spawnwithmagazine = TRUE - var/mag_type = /obj/item/ammo_box/magazine/m10mm //Removes the need for max_ammo and caliber info + var/mag_type = /obj/item/ammo_box/magazine/mmag //Removes the need for max_ammo and caliber info var/obj/item/ammo_box/magazine/magazine var/casing_ejector = TRUE //whether the gun ejects the chambered casing @@ -284,7 +284,7 @@ //////the gun itself////// -/obj/item/gun/ballistic/mag/pistol/mag +/obj/item/gun/mag/pistol/mag name = "magpistol" desc = "A handgun utilizing maglev technologies to propel a ferromagnetic slug to extreme velocities." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' @@ -292,13 +292,13 @@ force = 10 fire_sound = 'sound/weapons/magpistol.ogg' mag_type = /obj/item/ammo_box/magazine/mmag/small -// cell_type = /obj/item/stock_parts/cell/magpistal + cell_type = /obj/item/stock_parts/cell/magpistal can_suppress = 0 casing_ejector = 0 fire_delay = 2 recoil = 0.2 -/obj/item/gun/mag/automatic/pistol/mag/update_icon() +/obj/item/gun/mag/pistol/mag/update_icon() ..() if(magazine) cut_overlays() @@ -316,7 +316,7 @@ ///research memes/// -/obj/item/gun/mag/automatic/pistol/mag/nopin +/obj/item/gun/mag/pistol/mag/nopin pin = null spawnwithmagazine = FALSE @@ -326,7 +326,7 @@ id = "magpisol" build_type = PROTOLATHE materials = list(MAT_METAL = 7500, MAT_GLASS = 1000, MAT_URANIUM = 1000, MAT_TITANIUM = 5000, MAT_SILVER = 2000) - build_path = /obj/item/gun/mag/automatic/pistol/mag/nopin + build_path = /obj/item/gun/mag/pistol/mag/nopin category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -449,7 +449,7 @@ ///the gun itself/// -/obj/item/gun/mag/automatic/magrifle +/obj/item/gun/mag/magrifle name = "\improper Magnetic Rifle" desc = "A simple upscalling of the technologies used in the magpistol, the magrifle is capable of firing slightly larger slugs in bursts. Compatible with the magpistol's slugs." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' @@ -475,7 +475,7 @@ ///research/// -/obj/item/gun/ballistic/automatic/magrifle/nopin +/obj/item/gun/mag/magrifle/nopin pin = null spawnwithmagazine = FALSE @@ -485,7 +485,7 @@ id = "magrifle" build_type = PROTOLATHE materials = list(MAT_METAL = 10000, MAT_GLASS = 2000, MAT_URANIUM = 2000, MAT_TITANIUM = 10000, MAT_SILVER = 4000, MAT_GOLD = 2000) - build_path = /obj/item/gun/ballistic/automatic/magrifle/nopin + build_path = /obj/item/gun/mag/magrifle/nopin category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY From 8055d21c0cca74d91274a0fff4abb673d722e175 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 16:46:33 -0400 Subject: [PATCH 05/22] Update recharger.dm --- code/game/machinery/recharger.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/game/machinery/recharger.dm b/code/game/machinery/recharger.dm index d44053f433..6c703f5763 100755 --- a/code/game/machinery/recharger.dm +++ b/code/game/machinery/recharger.dm @@ -16,8 +16,8 @@ /obj/item/melee/baton, /obj/item/ammo_box/magazine/recharge, /obj/item/modular_computer, - /obj/item/gun/mag/automatic/pistol/mag, - /obj/item/gun/mag/automatic/magrifle)) + /obj/item/gun/mag/pistol/mag, + /obj/item/gun/mag/magrifle)) /obj/machinery/recharger/RefreshParts() for(var/obj/item/stock_parts/capacitor/C in component_parts) From bec3cf89676144ebb481025fe1aa15daf6b2b4c8 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 21:24:45 -0400 Subject: [PATCH 06/22] Update magweapon.dm --- .../projectiles/guns/ballistic/magweapon.dm | 491 +++++++----------- 1 file changed, 180 insertions(+), 311 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index b13f564f73..76450156d9 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -102,7 +102,6 @@ update_icon() return - /obj/item/gun/mag/examine(mob/user) ..() to_chat(user, "It has [get_ammo()] round\s remaining.") @@ -220,113 +219,127 @@ w_class = WEIGHT_CLASS_BULKY weapon_weight = WEAPON_HEAVY -////////XCOM2 Magpistol///////// +///ammo/// -//////projectiles////// +/obj/item/ammo_casing/caseless/mag_e + var/energy_cost = 0 -/obj/item/projectile/bullet/mags +/obj/item/ammo_casing/caseless/mag_e/amagm_e + desc = "A large ferromagnetic slug intended to be launched out of a compatible weapon." + caliber = "magm" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile" - damage = 15 - armour_penetration = 10 - light_range = 2 - speed = 0.6 - range = 25 - light_color = LIGHT_COLOR_RED + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/magrifle + energy_cost = 300 -/obj/item/projectile/bullet/nlmags //non-lethal boolets +/obj/item/ammo_casing/caseless/mag_e/anlmagm_e + desc = "A large, specialized ferromagnetic slug designed with a less-than-lethal payload." + caliber = "magm" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile-nl" - damage = 2 - knockdown = 0 - stamina = 25 - armour_penetration = -10 - light_range = 2 - speed = 0.7 - range = 25 - light_color = LIGHT_COLOR_BLUE + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/nlmagrifle + energy_cost = 300 - -/////actual ammo///// - -/obj/item/ammo_casing/mag/amags +/obj/item/ammo_casing/caseless/mag_e/amags desc = "A ferromagnetic slug intended to be launched out of a compatible weapon." caliber = "mags" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" - e_cost = 50 projectile_type = /obj/item/projectile/bullet/mags + energy_cost = 200 -/obj/item/ammo_casing/mag/anlmags +/obj/item/ammo_casing/caseless/mag_e/anlmags desc = "A specialized ferromagnetic slug designed with a less-than-lethal payload." caliber = "mags" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" - e_cost = 50 projectile_type = /obj/item/projectile/bullet/nlmags + energy_cost = 200 -//////magazines///// +///magazines/// -/obj/item/ammo_box/magazine/mmag/small +/obj/item/ammo_box/magazine/mmag_e/ + name = "magrifle magazine (non-lethal disabler)" + desc = "A 24-round magazine for the non-lethal Magrifle." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mediummagmag" + ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmagm_e + caliber = "magm" + max_ammo = 24 + multiple_sprites = 2 + +/obj/item/ammo_box/magazine/mmag_e/lethal + name = "magrifle magazine (lethal)" + desc = "A 24-round magazine for the lethal Magrifle." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mediummagmag" + ammo_type = /obj/item/ammo_casing/caseless/mag_e/amagm_e + max_ammo = 24 + +/obj/item/ammo_box/magazine/mmag_e/small name = "magpistol magazine (non-lethal disabler)" + desc = "A 15-round magazine for the non-lethal Magpistol." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "nlmagmag" - ammo_type = /obj/item/ammo_casing/mag/anlmags + ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmags caliber = "mags" max_ammo = 15 multiple_sprites = 2 -/obj/item/ammo_box/magazine/mmag/small/lethal +/obj/item/ammo_box/magazine/mmag_e/small/lethal name = "magpistol magazine (lethal)" + desc = "A 15-round magazine for the lethal Magpistol." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "smallmagmag" - ammo_type = /obj/item/ammo_casing/mag/amags + ammo_type = /obj/item/ammo_casing/caseless/mag_e/amags -//////the gun itself////// +///cells/// -/obj/item/gun/mag/pistol/mag - name = "magpistol" - desc = "A handgun utilizing maglev technologies to propel a ferromagnetic slug to extreme velocities." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magpistol" - force = 10 - fire_sound = 'sound/weapons/magpistol.ogg' - mag_type = /obj/item/ammo_box/magazine/mmag/small - cell_type = /obj/item/stock_parts/cell/magpistal - can_suppress = 0 - casing_ejector = 0 - fire_delay = 2 - recoil = 0.2 +/obj/item/stock_parts/cell/magrifle_e + name = "magrifle power supply" + maxcharge = 14400 -/obj/item/gun/mag/pistol/mag/update_icon() - ..() - if(magazine) - cut_overlays() - add_overlay("magpistol-magazine") - else - cut_overlays() - icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" +/obj/item/stock_parts/cell/magpistol_e + name = "magpistol power supply" + maxcharge = 6000 -//////the cell//////////// +///sci designs/// -/obj/item/stock_parts/cell/magpistal - name = "magpistal hyper power cell" - desc = "A small hyper cell, used in the mag pistal" - maxcharge = 3500 //70 shots before recharge +/datum/design/magrifle_e + name = "Magrifle" + desc = "An upscaled Magpistol in rifle form." + id = "magrifle_e" + build_type = PROTOLATHE + materials = list(MAT_METAL = 10000, MAT_GLASS = 2000, MAT_URANIUM = 2000, MAT_TITANIUM = 10000, MAT_SILVER = 4000, MAT_GOLD = 2000) + build_path = /obj/item/gun/ballistic/automatic/magrifle_e/nopin + category = list("Weapons") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY -///research memes/// +/datum/design/mag_magrifle_e + name = "Magrifle Magazine (Lethal)" + desc = "A 24-round magazine for the Magrifle." + id = "mag_magrifle_e" + build_type = PROTOLATHE + materials = list(MAT_METAL = 8000, MAT_SILVER = 1000) + build_path = /obj/item/ammo_box/magazine/mmag_e/lethal + category = list("Ammo") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY -/obj/item/gun/mag/pistol/mag/nopin - pin = null - spawnwithmagazine = FALSE +/datum/design/mag_magrifle_e/nl + name = "Magrifle Magazine (Non-Lethal)" + desc = "A 24- round non-lethal magazine for the Magrifle." + id = "mag_magrifle_nl_e" + materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) + build_path = /obj/item/ammo_box/magazine/mmag_e + departmental_flags = DEPARTMENTAL_FLAG_SECURITY -/datum/design/magpistol +/datum/design/magpistol_e name = "Magpistol" desc = "A weapon which fires ferromagnetic slugs." id = "magpisol" build_type = PROTOLATHE materials = list(MAT_METAL = 7500, MAT_GLASS = 1000, MAT_URANIUM = 1000, MAT_TITANIUM = 5000, MAT_SILVER = 2000) - build_path = /obj/item/gun/mag/pistol/mag/nopin + build_path = /obj/item/gun/ballistic/automatic/pistol/mag_e/nopin category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -336,7 +349,7 @@ id = "mag_magpistol" build_type = PROTOLATHE materials = list(MAT_METAL = 4000, MAT_SILVER = 500) - build_path = /obj/item/ammo_box/magazine/mmag/small/lethal + build_path = /obj/item/ammo_box/magazine/mmag_e/small/lethal category = list("Ammo") departmental_flags = DEPARTMENTAL_FLAG_SECURITY @@ -345,119 +358,19 @@ desc = "A 14 round non-lethal magazine for the Magpistol." id = "mag_magpistol_nl" materials = list(MAT_METAL = 3000, MAT_SILVER = 250, MAT_TITANIUM = 250) - build_path = /obj/item/ammo_box/magazine/mmag/small + build_path = /obj/item/ammo_box/magazine/mmag_e/small departmental_flags = DEPARTMENTAL_FLAG_SECURITY -//////toy memes///// +///magrifle/// -/obj/item/projectile/bullet/reusable/foam_dart/mag - name = "magfoam dart" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile-toy" - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - light_range = 2 - light_color = LIGHT_COLOR_YELLOW - -/obj/item/ammo_casing/caseless/foam_dart/mag - name = "magfoam dart" - desc = "A foam dart with fun light-up projectiles powered by magnets!" - projectile_type = /obj/item/projectile/bullet/reusable/foam_dart/mag - -/obj/item/ammo_box/magazine/internal/shot/toy/mag - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - max_ammo = 14 - -/obj/item/gun/ballistic/shotgun/toy/mag - name = "foam force magpistol" - desc = "A fancy toy sold alongside light-up foam force darts. Ages 8 and up." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "toymag" - item_state = "gun" - mag_type = /obj/item/ammo_box/magazine/internal/shot/toy/mag - fire_sound = 'sound/weapons/magpistol.ogg' - slot_flags = SLOT_BELT - w_class = WEIGHT_CLASS_SMALL - -/obj/item/ammo_box/foambox/mag - name = "ammo box (Magnetic Foam Darts)" - icon = 'icons/obj/guns/toy.dmi' - icon_state = "foambox" - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - max_ammo = 42 - -//////Magrifle////// - -///projectiles/// - -/obj/item/projectile/bullet/magrifle - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile-large" - damage = 20 - armour_penetration = 25 - light_range = 3 - speed = 0.7 - range = 35 - light_color = LIGHT_COLOR_RED - -/obj/item/projectile/bullet/nlmagrifle //non-lethal boolets - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile-large-nl" - damage = 2 - knockdown = 0 - stamina = 25 - armour_penetration = -10 - light_range = 3 - speed = 0.65 - range = 35 - light_color = LIGHT_COLOR_BLUE - -///ammo casings/// - -/obj/item/ammo_casing/energy/mag/amagm - desc = "A large ferromagnetic slug intended to be launched out of a compatible weapon." - caliber = "magm" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "mag-casing-live" - e_cost = 50 - projectile_type = /obj/item/projectile/bullet/magrifle - -/obj/item/ammo_casing/energy/mag/anlmagm - desc = "A large, specialized ferromagnetic slug designed with a less-than-lethal payload." - caliber = "magm" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "mag-casing-live" - e_cost = 50 - projectile_type = /obj/item/projectile/bullet/nlmagrifle - -///magazines/// - -/obj/item/ammo_box/magazine/mmag/ - name = "magrifle magazine (non-lethal disabler)" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "mediummagmag" - ammo_type = /obj/item/ammo_casing/energy/mag/anlmagm - caliber = "magm" - max_ammo = 24 - multiple_sprites = 2 - -/obj/item/ammo_box/magazine/mmag/lethal - name = "magrifle magazine (lethal)" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "mediummagmag" - ammo_type = /obj/item/ammo_casing/energy/mag/amagm - max_ammo = 24 - -///the gun itself/// - -/obj/item/gun/mag/magrifle +/obj/item/gun/ballistic/automatic/magrifle_e name = "\improper Magnetic Rifle" desc = "A simple upscalling of the technologies used in the magpistol, the magrifle is capable of firing slightly larger slugs in bursts. Compatible with the magpistol's slugs." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "magrifle" item_state = "arg" slot_flags = 0 - cell_type = /obj/item/stock_parts/cell/magrifle - mag_type = /obj/item/ammo_box/magazine/mmag + mag_type = /obj/item/ammo_box/magazine/mmag_e fire_sound = 'sound/weapons/magrifle.ogg' can_suppress = 0 burst_size = 3 @@ -465,69 +378,111 @@ spread = 5 recoil = 0.15 casing_ejector = 0 + var/obj/item/stock_parts/cell/cell + var/cell_type = /obj/item/stock_parts/cell/magrifle_e + var/dead_cell = FALSE -//////the cell//////////// +/obj/item/gun/ballistic/automatic/magrifle_e/can_shoot() + if(QDELETED(cell)) + return 0 -/obj/item/stock_parts/cell/magrifle - name = "magrifle hyper power cell" - desc = "A small hyper cell, used in the mag rifle" - maxcharge = 2400 //48 shots before recharge + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + if(!shot) + return 0 + if(cell.charge < shot.energy_cost*burst_size) + return 0 + . = ..() -///research/// +/obj/item/gun/ballistic/automatic/magrifle_e/shoot_live_shot() + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + cell.use(shot.energy_cost) + . = ..() -/obj/item/gun/mag/magrifle/nopin +/obj/item/gun/ballistic/automatic/magrifle_e/emp_act(severity) + . = ..() + if(!(. & EMP_PROTECT_CONTENTS)) + cell.use(round(cell.charge / severity)) + +/obj/item/gun/ballistic/automatic/magrifle_e/get_cell() + return cell + +/obj/item/gun/ballistic/automatic/magrifle_e/Initialize() + . = ..() + if(cell_type) + cell = new cell_type(src) + else + cell = new(src) + + if(!dead_cell) + cell.give(cell.maxcharge) + +/obj/item/gun/ballistic/automatic/magrifle_e/nopin pin = null spawnwithmagazine = FALSE -/datum/design/magrifle - name = "Magrifle" - desc = "An upscaled Magpistol in rifle form." - id = "magrifle" - build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 2000, MAT_URANIUM = 2000, MAT_TITANIUM = 10000, MAT_SILVER = 4000, MAT_GOLD = 2000) - build_path = /obj/item/gun/mag/magrifle/nopin - category = list("Weapons") - departmental_flags = DEPARTMENTAL_FLAG_SECURITY +///magpistol/// -/datum/design/mag_magrifle - name = "Magrifle Magazine (Lethal)" - desc = "A 24-round magazine for the Magrifle." - id = "mag_magrifle" - build_type = PROTOLATHE - materials = list(MAT_METAL = 8000, MAT_SILVER = 1000) - build_path = /obj/item/ammo_box/magazine/mmag/lethal - category = list("Ammo") - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -/datum/design/mag_magrifle/nl - name = "Magrifle Magazine (Non-Lethal)" - desc = "A 24- round non-lethal magazine for the Magrifle." - id = "mag_magrifle_nl" - materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) - build_path = /obj/item/ammo_box/magazine/mmag - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -///foamagrifle/// - -/obj/item/ammo_box/magazine/toy/foamag - name = "foam force magrifle magazine" +/obj/item/gun/ballistic/automatic/pistol/mag_e + name = "magpistol" + desc = "A handgun utilizing maglev technologies to propel a ferromagnetic slug to extreme velocities." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "foamagmag" - max_ammo = 24 - multiple_sprites = 2 - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - materials = list(MAT_METAL = 200) + icon_state = "magpistol" + force = 10 + fire_sound = 'sound/weapons/magpistol.ogg' + mag_type = /obj/item/ammo_box/magazine/mmag_e/small + can_suppress = 0 + casing_ejector = 0 + fire_delay = 2 + recoil = 0.2 + var/obj/item/stock_parts/cell/cell + var/cell_type = /obj/item/stock_parts/cell/magpistol_e + var/dead_cell = FALSE -/obj/item/gun/ballistic/automatic/magrifle/toy - name = "foamag rifle" - desc = "A foam launching magnetic rifle. Ages 8 and up." - icon_state = "foamagrifle" - obj_flags = 0 - mag_type = /obj/item/ammo_box/magazine/toy/foamag - casing_ejector = FALSE - spread = 60 - w_class = WEIGHT_CLASS_BULKY - weapon_weight = WEAPON_HEAVY +/obj/item/gun/ballistic/automatic/pistol/mag_e/can_shoot() + if(QDELETED(cell)) + return 0 + + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + if(!shot) + return 0 + if(cell.charge < shot.energy_cost) + return 0 + . = ..() + +/obj/item/gun/ballistic/automatic/pistol/mag_e/shoot_live_shot() + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + cell.use(shot.energy_cost) + . = ..() + +/obj/item/gun/ballistic/automatic/pistol/mag_e/emp_act(severity) + . = ..() + if(!(. & EMP_PROTECT_CONTENTS)) + cell.use(round(cell.charge / severity)) + +/obj/item/gun/ballistic/automatic/pistol/mag_e/get_cell() + return cell + +/obj/item/gun/ballistic/automatic/pistol/mag_e/Initialize() + . = ..() + if(cell_type) + cell = new cell_type(src) + else + cell = new(src) + if(!dead_cell) + cell.give(cell.maxcharge) + +/obj/item/gun/ballistic/automatic/pistol/mag_e/update_icon() + ..() + if(magazine) + cut_overlays() + add_overlay("magpistol-magazine") + else + cut_overlays() + icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" + +/obj/item/gun/ballistic/automatic/pistol/mag_e/nopin + pin = null + spawnwithmagazine = FALSE /* // TECHWEBS IMPLEMENTATION @@ -542,93 +497,7 @@ research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) export_price = 5000 - -//////Hyper-Burst Rifle////// - -///projectiles/// - -/obj/item/projectile/bullet/mags/hyper - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile" - damage = 10 - armour_penetration = 10 - stamina = 10 - forcedodge = TRUE - range = 6 - light_range = 1 - light_color = LIGHT_COLOR_RED - -/obj/item/projectile/bullet/mags/hyper/inferno - icon_state = "magjectile-large" - stamina = 0 - forcedodge = FALSE - range = 25 - light_range = 4 - -/obj/item/projectile/bullet/mags/hyper/inferno/on_hit(atom/target, blocked = FALSE) - ..() - explosion(target, -1, 1, 2, 4, 5) - return 1 - -///ammo casings/// - -/obj/item/ammo_casing/caseless/ahyper - desc = "A large block of speciallized ferromagnetic material designed to be fired out of the experimental Hyper-Burst Rifle." - caliber = "hypermag" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "hyper-casing-live" - projectile_type = /obj/item/projectile/bullet/mags/hyper - pellets = 12 - variance = 40 - -/obj/item/ammo_casing/caseless/ahyper/inferno - projectile_type = /obj/item/projectile/bullet/mags/hyper/inferno - pellets = 1 - variance = 0 - -///magazines/// - -/obj/item/ammo_box/magazine/mhyper - name = "hyper-burst rifle magazine" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "hypermag-4" - ammo_type = /obj/item/ammo_casing/caseless/ahyper - caliber = "hypermag" - desc = "A magazine for the Hyper-Burst Rifle. Loaded with a special slug that fragments into 12 smaller shards which can absolutely puncture anything, but has rather short effective range." - max_ammo = 4 - -/obj/item/ammo_box/magazine/mhyper/update_icon() - ..() - icon_state = "hypermag-[ammo_count() ? "4" : "0"]" - -/obj/item/ammo_box/magazine/mhyper/inferno - name = "hyper-burst rifle magazine (inferno)" - ammo_type = /obj/item/ammo_casing/caseless/ahyper/inferno - desc = "A magazine for the Hyper-Burst Rifle. Loaded with a special slug that violently reacts with whatever surface it strikes, generating a massive amount of heat and light." - -///gun itself/// - -/obj/item/gun/ballistic/automatic/hyperburst - name = "\improper Hyper-Burst Rifle" - desc = "An extremely beefed up version of a stolen Nanotrasen weapon prototype, this 'rifle' is more like a cannon, with an extremely large bore barrel capable of generating several smaller magnetic 'barrels' to simultaneously launch multiple projectiles at once." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "hyperburst" - item_state = "arg" - slot_flags = 0 - mag_type = /obj/item/ammo_box/magazine/mhyper - fire_sound = 'sound/weapons/magburst.ogg' - can_suppress = 0 - burst_size = 1 - fire_delay = 40 - recoil = 2 - casing_ejector = 0 - weapon_weight = WEAPON_HEAVY - -/obj/item/gun/ballistic/automatic/hyperburst/update_icon() - ..() - icon_state = "hyperburst[magazine ? "-[get_ammo()]" : ""][chambered ? "" : "-e"]" - -///toy memes/// +//Toy Memes /obj/item/projectile/beam/lasertag/mag //the projectile, compatible with regular laser tag armor icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' From a9aa85530503b34eb776d101f66b5ae7531e0ea6 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 21:25:18 -0400 Subject: [PATCH 07/22] Update recharger.dm --- code/game/machinery/recharger.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/game/machinery/recharger.dm b/code/game/machinery/recharger.dm index 6c703f5763..927608d3d5 100755 --- a/code/game/machinery/recharger.dm +++ b/code/game/machinery/recharger.dm @@ -16,8 +16,8 @@ /obj/item/melee/baton, /obj/item/ammo_box/magazine/recharge, /obj/item/modular_computer, - /obj/item/gun/mag/pistol/mag, - /obj/item/gun/mag/magrifle)) + /obj/item/gun/ballistic/automatic/magrifle_e, + /obj/item/gun/ballistic/automatic/pistol/mag_e)) /obj/machinery/recharger/RefreshParts() for(var/obj/item/stock_parts/capacitor/C in component_parts) From fb7a129ca573b477c64d797b2763152050b9f685 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 21:56:48 -0400 Subject: [PATCH 08/22] Update magweapon.dm --- .../projectiles/guns/ballistic/magweapon.dm | 86 +++++++++++++++++++ 1 file changed, 86 insertions(+) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index adffe54761..e6ef3e36e4 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -532,6 +532,92 @@ research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) export_price = 5000 + +//////Hyper-Burst Rifle////// + +///projectiles/// + +/obj/item/projectile/bullet/mags/hyper + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile" + damage = 10 + armour_penetration = 10 + stamina = 10 + forcedodge = TRUE + range = 6 + light_range = 1 + light_color = LIGHT_COLOR_RED + +/obj/item/projectile/bullet/mags/hyper/inferno + icon_state = "magjectile-large" + stamina = 0 + forcedodge = FALSE + range = 25 + light_range = 4 + +/obj/item/projectile/bullet/mags/hyper/inferno/on_hit(atom/target, blocked = FALSE) + ..() + explosion(target, -1, 1, 2, 4, 5) + return 1 + +///ammo casings/// + +/obj/item/ammo_casing/caseless/ahyper + desc = "A large block of speciallized ferromagnetic material designed to be fired out of the experimental Hyper-Burst Rifle." + caliber = "hypermag" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "hyper-casing-live" + projectile_type = /obj/item/projectile/bullet/mags/hyper + pellets = 12 + variance = 40 + +/obj/item/ammo_casing/caseless/ahyper/inferno + projectile_type = /obj/item/projectile/bullet/mags/hyper/inferno + pellets = 1 + variance = 0 + +///magazines/// + +/obj/item/ammo_box/magazine/mhyper + name = "hyper-burst rifle magazine" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "hypermag-4" + ammo_type = /obj/item/ammo_casing/caseless/ahyper + caliber = "hypermag" + desc = "A magazine for the Hyper-Burst Rifle. Loaded with a special slug that fragments into 12 smaller shards which can absolutely puncture anything, but has rather short effective range." + max_ammo = 4 + +/obj/item/ammo_box/magazine/mhyper/update_icon() + ..() + icon_state = "hypermag-[ammo_count() ? "4" : "0"]" + +/obj/item/ammo_box/magazine/mhyper/inferno + name = "hyper-burst rifle magazine (inferno)" + ammo_type = /obj/item/ammo_casing/caseless/ahyper/inferno + desc = "A magazine for the Hyper-Burst Rifle. Loaded with a special slug that violently reacts with whatever surface it strikes, generating a massive amount of heat and light." + +///gun itself/// + +/obj/item/gun/ballistic/automatic/hyperburst + name = "\improper Hyper-Burst Rifle" + desc = "An extremely beefed up version of a stolen Nanotrasen weapon prototype, this 'rifle' is more like a cannon, with an extremely large bore barrel capable of generating several smaller magnetic 'barrels' to simultaneously launch multiple projectiles at once." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "hyperburst" + item_state = "arg" + slot_flags = 0 + mag_type = /obj/item/ammo_box/magazine/mhyper + fire_sound = 'sound/weapons/magburst.ogg' + can_suppress = 0 + burst_size = 1 + fire_delay = 40 + recoil = 2 + casing_ejector = 0 + weapon_weight = WEAPON_HEAVY + +/obj/item/gun/ballistic/automatic/hyperburst/update_icon() + ..() + icon_state = "hyperburst[magazine ? "-[get_ammo()]" : ""][chambered ? "" : "-e"]" + //Toy Memes /obj/item/projectile/beam/lasertag/mag //the projectile, compatible with regular laser tag armor From ad2cacb59ea4ad9d5308cb2f2cbc73f746e7fc69 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 22:05:53 -0400 Subject: [PATCH 09/22] toys --- .../projectiles/guns/ballistic/magweapon.dm | 148 ++++++++++-------- 1 file changed, 85 insertions(+), 63 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index e6ef3e36e4..82b9e94ada 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -196,29 +196,6 @@ spread = 30 //should be 40 for XCOM memes, but since its adminspawn only, might as well make it useable recoil = 1 -///toy memes/// - -/obj/item/ammo_box/magazine/toy/x9 - name = "foam force X9 magazine" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "toy9magazine" - max_ammo = 30 - multiple_sprites = 2 - materials = list(MAT_METAL = 200) - -/obj/item/gun/ballistic/automatic/x9/toy - name = "\improper Foam Force X9" - desc = "An old but reliable assault rifle made for combat against unknown enemies. Appears to be hastily converted. Ages 8 and up." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "toy9" - can_suppress = 0 - obj_flags = 0 - mag_type = /obj/item/ammo_box/magazine/toy/x9 - casing_ejector = 0 - spread = 90 //MAXIMUM XCOM MEMES (actually that'd be 180 spread) - w_class = WEIGHT_CLASS_BULKY - weapon_weight = WEAPON_HEAVY - ///ammo/// /obj/item/ammo_casing/caseless/mag_e @@ -336,17 +313,17 @@ /datum/design/magpistol_e name = "Magpistol" desc = "A weapon which fires ferromagnetic slugs." - id = "magpisol" + id = "magpisol_e" build_type = PROTOLATHE materials = list(MAT_METAL = 7500, MAT_GLASS = 1000, MAT_URANIUM = 1000, MAT_TITANIUM = 5000, MAT_SILVER = 2000) build_path = /obj/item/gun/ballistic/automatic/pistol/mag_e/nopin category = list("Weapons") departmental_flags = DEPARTMENTAL_FLAG_SECURITY -/datum/design/mag_magpistol +/datum/design/mag_magpistol_e name = "Magpistol Magazine" desc = "A 14 round magazine for the Magpistol." - id = "mag_magpistol" + id = "mag_magpistol_e" build_type = PROTOLATHE materials = list(MAT_METAL = 4000, MAT_SILVER = 500) build_path = /obj/item/ammo_box/magazine/mmag_e/small/lethal @@ -356,46 +333,11 @@ /datum/design/mag_magpistol/nl name = "Magpistol Magazine (Non-Lethal)" desc = "A 14 round non-lethal magazine for the Magpistol." - id = "mag_magpistol_nl" + id = "mag_magpistol_nl_e" materials = list(MAT_METAL = 3000, MAT_SILVER = 250, MAT_TITANIUM = 250) build_path = /obj/item/ammo_box/magazine/mmag_e/small departmental_flags = DEPARTMENTAL_FLAG_SECURITY -/obj/item/projectile/bullet/reusable/foam_dart/mag - name = "magfoam dart" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile-toy" - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - light_range = 2 - light_color = LIGHT_COLOR_YELLOW - -/obj/item/ammo_casing/caseless/foam_dart/mag - name = "magfoam dart" - desc = "A foam dart with fun light-up projectiles powered by magnets!" - projectile_type = /obj/item/projectile/bullet/reusable/foam_dart/mag - -/obj/item/ammo_box/magazine/internal/shot/toy/mag - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - max_ammo = 14 - -/obj/item/gun/ballistic/shotgun/toy/mag - name = "foam force magpistol" - desc = "A fancy toy sold alongside light-up foam force darts. Ages 8 and up." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "toymag" - item_state = "gun" - mag_type = /obj/item/ammo_box/magazine/internal/shot/toy/mag - fire_sound = 'sound/weapons/magpistol.ogg' - slot_flags = SLOT_BELT - w_class = WEIGHT_CLASS_SMALL - -/obj/item/ammo_box/foambox/mag - name = "ammo box (Magnetic Foam Darts)" - icon = 'icons/obj/guns/toy.dmi' - icon_state = "foambox" - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - max_ammo = 42 - ///////////////// Mag rifle///////////////// /obj/item/gun/ballistic/automatic/magrifle_e @@ -528,7 +470,7 @@ display_name = "Magnetic Weapons" description = "Weapons using magnetic technology" prereq_ids = list("weaponry", "adv_weaponry", "emp_adv") - design_ids = list("magrifle", "magpisol", "mag_magrifle", "mag_magrifle_nl", "mag_magpistol", "mag_magpistol_nl") + design_ids = list("magrifle_e", "magpisol_e", "mag_magrifle_e", "mag_magrifle_nl_e", "mag_magpistol_e", "mag_magpistol_nl_e") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) export_price = 5000 @@ -656,3 +598,83 @@ /obj/item/stock_parts/cell/toymagburst name = "toy mag burst rifle power supply" maxcharge = 4000 + +///foamagrifles/// + +/obj/item/gun/ballistic/automatic/magrifle/toy + name = "foamag rifle" + desc = "A foam launching magnetic rifle. Ages 8 and up." + icon_state = "foamagrifle" + obj_flags = 0 + mag_type = /obj/item/ammo_box/magazine/toy/foamag + casing_ejector = FALSE + spread = 60 + w_class = WEIGHT_CLASS_BULKY + weapon_weight = WEAPON_HEAVY + +/obj/item/gun/ballistic/shotgun/toy/mag + name = "foam force magpistol" + desc = "A fancy toy sold alongside light-up foam force darts. Ages 8 and up." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "toymag" + item_state = "gun" + mag_type = /obj/item/ammo_box/magazine/internal/shot/toy/mag + fire_sound = 'sound/weapons/magpistol.ogg' + slot_flags = SLOT_BELT + w_class = WEIGHT_CLASS_SMALL + +/obj/item/gun/ballistic/automatic/x9/toy + name = "\improper Foam Force X9" + desc = "An old but reliable assault rifle made for combat against unknown enemies. Appears to be hastily converted. Ages 8 and up." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "toy9" + can_suppress = 0 + obj_flags = 0 + mag_type = /obj/item/ammo_box/magazine/toy/x9 + casing_ejector = 0 + spread = 90 //MAXIMUM XCOM MEMES (actually that'd be 180 spread) + w_class = WEIGHT_CLASS_BULKY + weapon_weight = WEAPON_HEAVY + +//Toy bullet-things + +/obj/item/projectile/bullet/reusable/foam_dart/mag + name = "magfoam dart" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile-toy" + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag + light_range = 2 + light_color = LIGHT_COLOR_YELLOW + +/obj/item/ammo_casing/caseless/foam_dart/mag + name = "magfoam dart" + desc = "A foam dart with fun light-up projectiles powered by magnets!" + projectile_type = /obj/item/projectile/bullet/reusable/foam_dart/mag + +/obj/item/ammo_box/magazine/internal/shot/toy/mag + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag + max_ammo = 14 + +/obj/item/ammo_box/magazine/toy/foamag + name = "foam force magrifle magazine" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "foamagmag" + max_ammo = 24 + multiple_sprites = 2 + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag + materials = list(MAT_METAL = 200) + +/obj/item/ammo_box/foambox/mag + name = "ammo box (Magnetic Foam Darts)" + icon = 'icons/obj/guns/toy.dmi' + icon_state = "foambox" + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag + max_ammo = 42 + +/obj/item/ammo_box/magazine/toy/x9 + name = "foam force X9 magazine" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "toy9magazine" + max_ammo = 30 + multiple_sprites = 2 + materials = list(MAT_METAL = 200) From 9ff3918ffdca6a5456f7b4771a342b6087a69f61 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 22:25:19 -0400 Subject: [PATCH 10/22] Update magweapon.dm --- .../projectiles/guns/ballistic/magweapon.dm | 70 +++++++++++++++++++ 1 file changed, 70 insertions(+) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 82b9e94ada..712dd9729d 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -196,6 +196,76 @@ spread = 30 //should be 40 for XCOM memes, but since its adminspawn only, might as well make it useable recoil = 1 +////bullets/// + +/obj/item/projectile/bullet/mags + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile" + damage = 15 + armour_penetration = 10 + light_range = 2 + speed = 0.6 + range = 25 + light_color = LIGHT_COLOR_RED + +/obj/item/projectile/bullet/nlmags //non-lethal boolets + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile-nl" + damage = 2 + knockdown = 0 + stamina = 25 + armour_penetration = -10 + light_range = 2 + speed = 0.7 + range = 25 + light_color = LIGHT_COLOR_BLUE + +////bullets/// + +/obj/item/projectile/bullet/mags + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile" + damage = 15 + armour_penetration = 10 + light_range = 2 + speed = 0.6 + range = 25 + light_color = LIGHT_COLOR_RED + +/obj/item/projectile/bullet/nlmags //non-lethal boolets + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile-nl" + damage = 2 + knockdown = 0 + stamina = 25 + armour_penetration = -10 + light_range = 2 + speed = 0.7 + range = 25 + light_color = LIGHT_COLOR_BLUE + +/obj/item/projectile/bullet/magrifle + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile-large" + damage = 20 + armour_penetration = 25 + light_range = 3 + speed = 0.7 + range = 35 + light_color = LIGHT_COLOR_RED + +/obj/item/projectile/bullet/nlmagrifle //non-lethal boolets + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile-large-nl" + damage = 2 + knockdown = 0 + stamina = 25 + armour_penetration = -10 + light_range = 3 + speed = 0.65 + range = 35 + light_color = LIGHT_COLOR_BLUE + ///ammo/// /obj/item/ammo_casing/caseless/mag_e From f6bb8b6aefcaed749df49668d32a580abdad6c99 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 22:33:58 -0400 Subject: [PATCH 11/22] Update magweapon.dm --- .../code/modules/projectiles/guns/ballistic/magweapon.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 712dd9729d..c5d47de86c 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -16,7 +16,7 @@ var/charge_delay = 4 var/dead_cell = FALSE //set to true so the gun is given an empty cell var/spawnwithmagazine = TRUE - var/mag_type = /obj/item/ammo_box/magazine/mmag //Removes the need for max_ammo and caliber info + var/mag_type = /obj/item/ammo_box/magazine/mmag_e //Removes the need for max_ammo and caliber info var/obj/item/ammo_box/magazine/magazine var/casing_ejector = TRUE //whether the gun ejects the chambered casing From bc251b59aa4a1767a6bfdaa06359cec78fb79d03 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 22:43:01 -0400 Subject: [PATCH 12/22] Update magweapon.dm --- .../projectiles/guns/ballistic/magweapon.dm | 716 ++++++------------ 1 file changed, 216 insertions(+), 500 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index c5d47de86c..13e1c0007c 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -1,184 +1,3 @@ -//Stollen vars so this all work for real - Copy pasted addtion - -/obj/item/ammo_casing/mag/ - var/e_cost = 50 - -/obj/item/gun/mag - var/obj/item/stock_parts/cell/cell //What type of power cell this uses - var/cell_type = /obj/item/stock_parts/cell - var/modifystate = 0 - var/list/ammo_type = list(/obj/item/ammo_casing/mag) - var/can_charge = 1 //Can it be charged in a recharger? - var/charge_sections = 4 - ammo_x_offset = 2 - var/old_ratio = 0 // stores the gun's previous ammo "ratio" to see if it needs an updated iconn - var/charge_tick = 0 - var/charge_delay = 4 - var/dead_cell = FALSE //set to true so the gun is given an empty cell - var/spawnwithmagazine = TRUE - var/mag_type = /obj/item/ammo_box/magazine/mmag_e //Removes the need for max_ammo and caliber info - var/obj/item/ammo_box/magazine/magazine - var/casing_ejector = TRUE //whether the gun ejects the chambered casing - -/obj/item/gun/mag/Initialize() - . = ..() - if(!spawnwithmagazine) - update_icon() - return - if (!magazine) - magazine = new mag_type(src) - chamber_round() - update_icon() - -/obj/item/gun/mag/process_chamber(empty_chamber = 1) - var/obj/item/ammo_casing/AC = chambered //Find chambered round - if(istype(AC)) //there's a chambered round - if(casing_ejector) - AC.forceMove(drop_location()) //Eject casing onto ground. - AC.bounce_away(TRUE) - chambered = null - else if(empty_chamber) - chambered = null - chamber_round() - -/obj/item/gun/mag/proc/chamber_round() - if (chambered || !magazine) - return - else if (magazine.ammo_count()) - chambered = magazine.get_round() - chambered.forceMove(src) - -/obj/item/gun/mag/can_shoot() - if(!magazine || !magazine.ammo_count(0)) - return 0 - return 1 - -/obj/item/gun/mag/attackby(obj/item/A, mob/user, params) - ..() - if (istype(A, /obj/item/ammo_box/magazine)) - var/obj/item/ammo_box/magazine/AM = A - if (!magazine && istype(AM, mag_type)) - if(user.transferItemToLoc(AM, src)) - magazine = AM - to_chat(user, "You load a new magazine into \the [src].") - if(magazine.ammo_count()) - playsound(src, "gun_insert_full_magazine", 70, 1) - if(!chambered) - chamber_round() - addtimer(CALLBACK(GLOBAL_PROC, .proc/playsound, src, 'sound/weapons/gun_chamber_round.ogg', 100, 1), 3) - else - playsound(src, "gun_insert_empty_magazine", 70, 1) - A.update_icon() - update_icon() - return 1 - else - to_chat(user, "You cannot seem to get \the [src] out of your hands!") - return - else if (magazine) - to_chat(user, "There's already a magazine in \the [src].") - -//ATTACK HAND IGNORING PARENT RETURN VALUE - -/obj/item/gun/mag/attack_self(mob/living/user) - var/obj/item/ammo_casing/AC = chambered //Find chambered round - if(magazine) - magazine.forceMove(drop_location()) - user.put_in_hands(magazine) - magazine.update_icon() - if(magazine.ammo_count()) - playsound(src, 'sound/weapons/gun_magazine_remove_full.ogg', 70, 1) - else - playsound(src, "gun_remove_empty_magazine", 70, 1) - magazine = null - to_chat(user, "You pull the magazine out of \the [src].") - else if(chambered) - AC.forceMove(drop_location()) - AC.bounce_away() - chambered = null - to_chat(user, "You unload the round from \the [src]'s chamber.") - playsound(src, "gun_slide_lock", 70, 1) - else - to_chat(user, "There's no magazine in \the [src].") - update_icon() - return - -/obj/item/gun/mag/examine(mob/user) - ..() - to_chat(user, "It has [get_ammo()] round\s remaining.") - -/obj/item/gun/mag/proc/get_ammo(countchambered = 1) - var/boolets = 0 //mature var names for mature people - if (chambered && countchambered) - boolets++ - if (magazine) - boolets += magazine.ammo_count() - return boolets - -/obj/item/gun/mag/emp_act(severity) - . = ..() - if(!(. & EMP_PROTECT_CONTENTS)) - cell.use(round(cell.charge / severity)) - recharge_newshot() //and try to charge a new shot - -/obj/item/gun/mag/get_cell() - return cell - -/obj/item/gun/mag/Initialize() - . = ..() - if(cell_type) - cell = new cell_type(src) - else - cell = new(src) - if(!dead_cell) - cell.give(cell.maxcharge) - update_ammo_types() - recharge_newshot(TRUE) - -/obj/item/gun/mag/proc/update_ammo_types() - var/obj/item/ammo_casing/mag/shot - for (var/i = 1, i <= ammo_type.len, i++) - var/shottype = ammo_type[i] - shot = new shottype(src) - ammo_type[i] = shot - fire_sound = shot.fire_sound - fire_delay = shot.delay - -/obj/item/gun/mag/Destroy() - QDEL_NULL(cell) - STOP_PROCESSING(SSobj, src) - return ..() - -/obj/item/gun/mag/can_shoot() - var/obj/item/ammo_casing/mag/mag = ammo_type - return !QDELETED(cell) ? (cell.charge >= mag.e_cost) : FALSE - -/obj/item/gun/mag/recharge_newshot(no_cyborg_drain) - if (!ammo_type || !cell) - return - if(!chambered) - var/obj/item/ammo_casing/energy/AC = ammo_type - if(cell.charge >= AC.e_cost) //if there's enough power in the cell cell... - chambered = AC //...prepare a new shot based on the current ammo type selected - if(!chambered.BB) - chambered.newshot() - -/obj/item/gun/mag/process_chamber() - if(chambered && !chambered.BB) //if BB is null, i.e the shot has been fired... - var/obj/item/ammo_casing/mag/mag = chambered - cell.use(mag.e_cost)//... drain the cell cell - chambered = null //either way, released the prepared shot - recharge_newshot() //try to charge a new shot - -/obj/item/gun/mag/update_icon(force_update) - if(QDELETED(src)) - return - ..() - var/ratio = CEILING(CLAMP(cell.charge / cell.maxcharge, 0, 1) * charge_sections, 1) - if(ratio == old_ratio && !force_update) - return - old_ratio = ratio - cut_overlays() - ///////XCOM X9 AR/////// /obj/item/gun/ballistic/automatic/x9 //will be adminspawn only so ERT or something can use them @@ -196,7 +15,32 @@ spread = 30 //should be 40 for XCOM memes, but since its adminspawn only, might as well make it useable recoil = 1 -////bullets/// +///toy memes/// + +/obj/item/ammo_box/magazine/toy/x9 + name = "foam force X9 magazine" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "toy9magazine" + max_ammo = 30 + multiple_sprites = 2 + materials = list(MAT_METAL = 200) + +/obj/item/gun/ballistic/automatic/x9/toy + name = "\improper Foam Force X9" + desc = "An old but reliable assault rifle made for combat against unknown enemies. Appears to be hastily converted. Ages 8 and up." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "toy9" + can_suppress = 0 + obj_flags = 0 + mag_type = /obj/item/ammo_box/magazine/toy/x9 + casing_ejector = 0 + spread = 90 //MAXIMUM XCOM MEMES (actually that'd be 180 spread) + w_class = WEIGHT_CLASS_BULKY + weapon_weight = WEAPON_HEAVY + +////////XCOM2 Magpistol///////// + +//////projectiles////// /obj/item/projectile/bullet/mags icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' @@ -220,29 +64,138 @@ range = 25 light_color = LIGHT_COLOR_BLUE -////bullets/// -/obj/item/projectile/bullet/mags - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile" - damage = 15 - armour_penetration = 10 - light_range = 2 - speed = 0.6 - range = 25 - light_color = LIGHT_COLOR_RED +/////actual ammo///// -/obj/item/projectile/bullet/nlmags //non-lethal boolets +/obj/item/ammo_casing/caseless/amags + desc = "A ferromagnetic slug intended to be launched out of a compatible weapon." + caliber = "mags" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile-nl" - damage = 2 - knockdown = 0 - stamina = 25 - armour_penetration = -10 + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/mags + +/obj/item/ammo_casing/caseless/anlmags + desc = "A specialized ferromagnetic slug designed with a less-than-lethal payload." + caliber = "mags" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/nlmags + +//////magazines///// + +/obj/item/ammo_box/magazine/mmag/small + name = "magpistol magazine (non-lethal disabler)" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "nlmagmag" + ammo_type = /obj/item/ammo_casing/caseless/anlmags + caliber = "mags" + max_ammo = 15 + multiple_sprites = 2 + +/obj/item/ammo_box/magazine/mmag/small/lethal + name = "magpistol magazine (lethal)" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "smallmagmag" + ammo_type = /obj/item/ammo_casing/caseless/amags + +//////the gun itself////// + +/obj/item/gun/ballistic/automatic/pistol/mag + name = "magpistol" + desc = "A handgun utilizing maglev technologies to propel a ferromagnetic slug to extreme velocities." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magpistol" + force = 10 + fire_sound = 'sound/weapons/magpistol.ogg' + mag_type = /obj/item/ammo_box/magazine/mmag/small + can_suppress = 0 + casing_ejector = 0 + fire_delay = 2 + recoil = 0.2 + +/obj/item/gun/ballistic/automatic/pistol/mag/update_icon() + ..() + if(magazine) + cut_overlays() + add_overlay("magpistol-magazine") + else + cut_overlays() + icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" + +///research memes/// + +/obj/item/gun/ballistic/automatic/pistol/mag/nopin + pin = null + spawnwithmagazine = FALSE + +/datum/design/magpistol + name = "Magpistol" + desc = "A weapon which fires ferromagnetic slugs." + id = "magpisol" + build_type = PROTOLATHE + materials = list(MAT_METAL = 7500, MAT_GLASS = 1000, MAT_URANIUM = 1000, MAT_TITANIUM = 5000, MAT_SILVER = 2000) + build_path = /obj/item/gun/ballistic/automatic/pistol/mag/nopin + category = list("Weapons") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/mag_magpistol + name = "Magpistol Magazine" + desc = "A 14 round magazine for the Magpistol." + id = "mag_magpistol" + build_type = PROTOLATHE + materials = list(MAT_METAL = 4000, MAT_SILVER = 500) + build_path = /obj/item/ammo_box/magazine/mmag/small/lethal + category = list("Ammo") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/mag_magpistol/nl + name = "Magpistol Magazine (Non-Lethal)" + desc = "A 14 round non-lethal magazine for the Magpistol." + id = "mag_magpistol_nl" + materials = list(MAT_METAL = 3000, MAT_SILVER = 250, MAT_TITANIUM = 250) + build_path = /obj/item/ammo_box/magazine/mmag/small + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +//////toy memes///// + +/obj/item/projectile/bullet/reusable/foam_dart/mag + name = "magfoam dart" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magjectile-toy" + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag light_range = 2 - speed = 0.7 - range = 25 - light_color = LIGHT_COLOR_BLUE + light_color = LIGHT_COLOR_YELLOW + +/obj/item/ammo_casing/caseless/foam_dart/mag + name = "magfoam dart" + desc = "A foam dart with fun light-up projectiles powered by magnets!" + projectile_type = /obj/item/projectile/bullet/reusable/foam_dart/mag + +/obj/item/ammo_box/magazine/internal/shot/toy/mag + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag + max_ammo = 14 + +/obj/item/gun/ballistic/shotgun/toy/mag + name = "foam force magpistol" + desc = "A fancy toy sold alongside light-up foam force darts. Ages 8 and up." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "toymag" + item_state = "gun" + mag_type = /obj/item/ammo_box/magazine/internal/shot/toy/mag + fire_sound = 'sound/weapons/magpistol.ogg' + slot_flags = SLOT_BELT + w_class = WEIGHT_CLASS_SMALL + +/obj/item/ammo_box/foambox/mag + name = "ammo box (Magnetic Foam Darts)" + icon = 'icons/obj/guns/toy.dmi' + icon_state = "foambox" + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag + max_ammo = 42 + +//////Magrifle////// + +///projectiles/// /obj/item/projectile/bullet/magrifle icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' @@ -266,158 +219,50 @@ range = 35 light_color = LIGHT_COLOR_BLUE -///ammo/// +///ammo casings/// -/obj/item/ammo_casing/caseless/mag_e - var/energy_cost = 0 - -/obj/item/ammo_casing/caseless/mag_e/amagm_e +/obj/item/ammo_casing/caseless/amagm desc = "A large ferromagnetic slug intended to be launched out of a compatible weapon." caliber = "magm" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" projectile_type = /obj/item/projectile/bullet/magrifle - energy_cost = 300 -/obj/item/ammo_casing/caseless/mag_e/anlmagm_e +/obj/item/ammo_casing/caseless/anlmagm desc = "A large, specialized ferromagnetic slug designed with a less-than-lethal payload." caliber = "magm" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" projectile_type = /obj/item/projectile/bullet/nlmagrifle - energy_cost = 300 - -/obj/item/ammo_casing/caseless/mag_e/amags - desc = "A ferromagnetic slug intended to be launched out of a compatible weapon." - caliber = "mags" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "mag-casing-live" - projectile_type = /obj/item/projectile/bullet/mags - energy_cost = 200 - -/obj/item/ammo_casing/caseless/mag_e/anlmags - desc = "A specialized ferromagnetic slug designed with a less-than-lethal payload." - caliber = "mags" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "mag-casing-live" - projectile_type = /obj/item/projectile/bullet/nlmags - energy_cost = 200 ///magazines/// -/obj/item/ammo_box/magazine/mmag_e/ +/obj/item/ammo_box/magazine/mmag/ name = "magrifle magazine (non-lethal disabler)" - desc = "A 24-round magazine for the non-lethal Magrifle." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mediummagmag" - ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmagm_e + ammo_type = /obj/item/ammo_casing/caseless/anlmagm caliber = "magm" max_ammo = 24 multiple_sprites = 2 -/obj/item/ammo_box/magazine/mmag_e/lethal +/obj/item/ammo_box/magazine/mmag/lethal name = "magrifle magazine (lethal)" - desc = "A 24-round magazine for the lethal Magrifle." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mediummagmag" - ammo_type = /obj/item/ammo_casing/caseless/mag_e/amagm_e + ammo_type = /obj/item/ammo_casing/caseless/amagm max_ammo = 24 -/obj/item/ammo_box/magazine/mmag_e/small - name = "magpistol magazine (non-lethal disabler)" - desc = "A 15-round magazine for the non-lethal Magpistol." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "nlmagmag" - ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmags - caliber = "mags" - max_ammo = 15 - multiple_sprites = 2 +///the gun itself/// -/obj/item/ammo_box/magazine/mmag_e/small/lethal - name = "magpistol magazine (lethal)" - desc = "A 15-round magazine for the lethal Magpistol." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "smallmagmag" - ammo_type = /obj/item/ammo_casing/caseless/mag_e/amags - -///cells/// - -/obj/item/stock_parts/cell/magrifle_e - name = "magrifle power supply" - maxcharge = 14400 - -/obj/item/stock_parts/cell/magpistol_e - name = "magpistol power supply" - maxcharge = 6000 - -///sci designs/// - -/datum/design/magrifle_e - name = "Magrifle" - desc = "An upscaled Magpistol in rifle form." - id = "magrifle_e" - build_type = PROTOLATHE - materials = list(MAT_METAL = 10000, MAT_GLASS = 2000, MAT_URANIUM = 2000, MAT_TITANIUM = 10000, MAT_SILVER = 4000, MAT_GOLD = 2000) - build_path = /obj/item/gun/ballistic/automatic/magrifle_e/nopin - category = list("Weapons") - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -/datum/design/mag_magrifle_e - name = "Magrifle Magazine (Lethal)" - desc = "A 24-round magazine for the Magrifle." - id = "mag_magrifle_e" - build_type = PROTOLATHE - materials = list(MAT_METAL = 8000, MAT_SILVER = 1000) - build_path = /obj/item/ammo_box/magazine/mmag_e/lethal - category = list("Ammo") - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -/datum/design/mag_magrifle_e/nl - name = "Magrifle Magazine (Non-Lethal)" - desc = "A 24- round non-lethal magazine for the Magrifle." - id = "mag_magrifle_nl_e" - materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) - build_path = /obj/item/ammo_box/magazine/mmag_e - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -/datum/design/magpistol_e - name = "Magpistol" - desc = "A weapon which fires ferromagnetic slugs." - id = "magpisol_e" - build_type = PROTOLATHE - materials = list(MAT_METAL = 7500, MAT_GLASS = 1000, MAT_URANIUM = 1000, MAT_TITANIUM = 5000, MAT_SILVER = 2000) - build_path = /obj/item/gun/ballistic/automatic/pistol/mag_e/nopin - category = list("Weapons") - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -/datum/design/mag_magpistol_e - name = "Magpistol Magazine" - desc = "A 14 round magazine for the Magpistol." - id = "mag_magpistol_e" - build_type = PROTOLATHE - materials = list(MAT_METAL = 4000, MAT_SILVER = 500) - build_path = /obj/item/ammo_box/magazine/mmag_e/small/lethal - category = list("Ammo") - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -/datum/design/mag_magpistol/nl - name = "Magpistol Magazine (Non-Lethal)" - desc = "A 14 round non-lethal magazine for the Magpistol." - id = "mag_magpistol_nl_e" - materials = list(MAT_METAL = 3000, MAT_SILVER = 250, MAT_TITANIUM = 250) - build_path = /obj/item/ammo_box/magazine/mmag_e/small - departmental_flags = DEPARTMENTAL_FLAG_SECURITY - -///////////////// Mag rifle///////////////// - -/obj/item/gun/ballistic/automatic/magrifle_e +/obj/item/gun/ballistic/automatic/magrifle name = "\improper Magnetic Rifle" desc = "A simple upscalling of the technologies used in the magpistol, the magrifle is capable of firing slightly larger slugs in bursts. Compatible with the magpistol's slugs." icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "magrifle" item_state = "arg" slot_flags = 0 - mag_type = /obj/item/ammo_box/magazine/mmag_e + mag_type = /obj/item/ammo_box/magazine/mmag fire_sound = 'sound/weapons/magrifle.ogg' can_suppress = 0 burst_size = 3 @@ -425,125 +270,76 @@ spread = 5 recoil = 0.15 casing_ejector = 0 - var/obj/item/stock_parts/cell/cell - var/cell_type = /obj/item/stock_parts/cell/magrifle_e - var/dead_cell = FALSE -/obj/item/gun/ballistic/automatic/magrifle_e/can_shoot() - if(QDELETED(cell)) - return 0 +///research/// - var/obj/item/ammo_casing/caseless/mag_e/shot = chambered - if(!shot) - return 0 - if(cell.charge < shot.energy_cost*burst_size) - return 0 - . = ..() - -/obj/item/gun/ballistic/automatic/magrifle_e/shoot_live_shot() - var/obj/item/ammo_casing/caseless/mag_e/shot = chambered - cell.use(shot.energy_cost) - . = ..() - -/obj/item/gun/ballistic/automatic/magrifle_e/emp_act(severity) - . = ..() - if(!(. & EMP_PROTECT_CONTENTS)) - cell.use(round(cell.charge / severity)) - -/obj/item/gun/ballistic/automatic/magrifle_e/get_cell() - return cell - -/obj/item/gun/ballistic/automatic/magrifle_e/Initialize() - . = ..() - if(cell_type) - cell = new cell_type(src) - else - cell = new(src) - - if(!dead_cell) - cell.give(cell.maxcharge) - -/obj/item/gun/ballistic/automatic/magrifle_e/nopin +/obj/item/gun/ballistic/automatic/magrifle/nopin pin = null spawnwithmagazine = FALSE -///magpistol/// +/datum/design/magrifle + name = "Magrifle" + desc = "An upscaled Magpistol in rifle form." + id = "magrifle" + build_type = PROTOLATHE + materials = list(MAT_METAL = 10000, MAT_GLASS = 2000, MAT_URANIUM = 2000, MAT_TITANIUM = 10000, MAT_SILVER = 4000, MAT_GOLD = 2000) + build_path = /obj/item/gun/ballistic/automatic/magrifle/nopin + category = list("Weapons") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY -/obj/item/gun/ballistic/automatic/pistol/mag_e - name = "magpistol" - desc = "A handgun utilizing maglev technologies to propel a ferromagnetic slug to extreme velocities." +/datum/design/mag_magrifle + name = "Magrifle Magazine (Lethal)" + desc = "A 24-round magazine for the Magrifle." + id = "mag_magrifle" + build_type = PROTOLATHE + materials = list(MAT_METAL = 8000, MAT_SILVER = 1000) + build_path = /obj/item/ammo_box/magazine/mmag/lethal + category = list("Ammo") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/mag_magrifle/nl + name = "Magrifle Magazine (Non-Lethal)" + desc = "A 24- round non-lethal magazine for the Magrifle." + id = "mag_magrifle_nl" + materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) + build_path = /obj/item/ammo_box/magazine/mmag + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +///foamagrifle/// + +/obj/item/ammo_box/magazine/toy/foamag + name = "foam force magrifle magazine" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magpistol" - force = 10 - fire_sound = 'sound/weapons/magpistol.ogg' - mag_type = /obj/item/ammo_box/magazine/mmag_e/small - can_suppress = 0 - casing_ejector = 0 - fire_delay = 2 - recoil = 0.2 - var/obj/item/stock_parts/cell/cell - var/cell_type = /obj/item/stock_parts/cell/magpistol_e - var/dead_cell = FALSE + icon_state = "foamagmag" + max_ammo = 24 + multiple_sprites = 2 + ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag + materials = list(MAT_METAL = 200) -/obj/item/gun/ballistic/automatic/pistol/mag_e/can_shoot() - if(QDELETED(cell)) - return 0 - - var/obj/item/ammo_casing/caseless/mag_e/shot = chambered - if(!shot) - return 0 - if(cell.charge < shot.energy_cost) - return 0 - . = ..() - -/obj/item/gun/ballistic/automatic/pistol/mag_e/shoot_live_shot() - var/obj/item/ammo_casing/caseless/mag_e/shot = chambered - cell.use(shot.energy_cost) - . = ..() - -/obj/item/gun/ballistic/automatic/pistol/mag_e/emp_act(severity) - . = ..() - if(!(. & EMP_PROTECT_CONTENTS)) - cell.use(round(cell.charge / severity)) - -/obj/item/gun/ballistic/automatic/pistol/mag_e/get_cell() - return cell - -/obj/item/gun/ballistic/automatic/pistol/mag_e/Initialize() - . = ..() - if(cell_type) - cell = new cell_type(src) - else - cell = new(src) - if(!dead_cell) - cell.give(cell.maxcharge) - -/obj/item/gun/ballistic/automatic/pistol/mag_e/update_icon() - ..() - if(magazine) - cut_overlays() - add_overlay("magpistol-magazine") - else - cut_overlays() - icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" - -/obj/item/gun/ballistic/automatic/pistol/mag_e/nopin - pin = null - spawnwithmagazine = FALSE +/obj/item/gun/ballistic/automatic/magrifle/toy + name = "foamag rifle" + desc = "A foam launching magnetic rifle. Ages 8 and up." + icon_state = "foamagrifle" + obj_flags = 0 + mag_type = /obj/item/ammo_box/magazine/toy/foamag + casing_ejector = FALSE + spread = 60 + w_class = WEIGHT_CLASS_BULKY + weapon_weight = WEAPON_HEAVY /* // TECHWEBS IMPLEMENTATION -*/ +// /datum/techweb_node/magnetic_weapons id = "magnetic_weapons" display_name = "Magnetic Weapons" description = "Weapons using magnetic technology" prereq_ids = list("weaponry", "adv_weaponry", "emp_adv") - design_ids = list("magrifle_e", "magpisol_e", "mag_magrifle_e", "mag_magrifle_nl_e", "mag_magpistol_e", "mag_magpistol_nl_e") + design_ids = list("magrifle", "magpisol", "mag_magrifle", "mag_magrifle_nl", "mag_magpistol", "mag_magpistol_nl") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) export_price = 5000 - +*/ //////Hyper-Burst Rifle////// @@ -630,7 +426,7 @@ ..() icon_state = "hyperburst[magazine ? "-[get_ammo()]" : ""][chambered ? "" : "-e"]" -//Toy Memes +///toy memes/// /obj/item/projectile/beam/lasertag/mag //the projectile, compatible with regular laser tag armor icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' @@ -668,83 +464,3 @@ /obj/item/stock_parts/cell/toymagburst name = "toy mag burst rifle power supply" maxcharge = 4000 - -///foamagrifles/// - -/obj/item/gun/ballistic/automatic/magrifle/toy - name = "foamag rifle" - desc = "A foam launching magnetic rifle. Ages 8 and up." - icon_state = "foamagrifle" - obj_flags = 0 - mag_type = /obj/item/ammo_box/magazine/toy/foamag - casing_ejector = FALSE - spread = 60 - w_class = WEIGHT_CLASS_BULKY - weapon_weight = WEAPON_HEAVY - -/obj/item/gun/ballistic/shotgun/toy/mag - name = "foam force magpistol" - desc = "A fancy toy sold alongside light-up foam force darts. Ages 8 and up." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "toymag" - item_state = "gun" - mag_type = /obj/item/ammo_box/magazine/internal/shot/toy/mag - fire_sound = 'sound/weapons/magpistol.ogg' - slot_flags = SLOT_BELT - w_class = WEIGHT_CLASS_SMALL - -/obj/item/gun/ballistic/automatic/x9/toy - name = "\improper Foam Force X9" - desc = "An old but reliable assault rifle made for combat against unknown enemies. Appears to be hastily converted. Ages 8 and up." - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "toy9" - can_suppress = 0 - obj_flags = 0 - mag_type = /obj/item/ammo_box/magazine/toy/x9 - casing_ejector = 0 - spread = 90 //MAXIMUM XCOM MEMES (actually that'd be 180 spread) - w_class = WEIGHT_CLASS_BULKY - weapon_weight = WEAPON_HEAVY - -//Toy bullet-things - -/obj/item/projectile/bullet/reusable/foam_dart/mag - name = "magfoam dart" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "magjectile-toy" - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - light_range = 2 - light_color = LIGHT_COLOR_YELLOW - -/obj/item/ammo_casing/caseless/foam_dart/mag - name = "magfoam dart" - desc = "A foam dart with fun light-up projectiles powered by magnets!" - projectile_type = /obj/item/projectile/bullet/reusable/foam_dart/mag - -/obj/item/ammo_box/magazine/internal/shot/toy/mag - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - max_ammo = 14 - -/obj/item/ammo_box/magazine/toy/foamag - name = "foam force magrifle magazine" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "foamagmag" - max_ammo = 24 - multiple_sprites = 2 - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - materials = list(MAT_METAL = 200) - -/obj/item/ammo_box/foambox/mag - name = "ammo box (Magnetic Foam Darts)" - icon = 'icons/obj/guns/toy.dmi' - icon_state = "foambox" - ammo_type = /obj/item/ammo_casing/caseless/foam_dart/mag - max_ammo = 42 - -/obj/item/ammo_box/magazine/toy/x9 - name = "foam force X9 magazine" - icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' - icon_state = "toy9magazine" - max_ammo = 30 - multiple_sprites = 2 - materials = list(MAT_METAL = 200) From 22912832d75a87e40cf3628a24af7e1b57215600 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 22:46:50 -0400 Subject: [PATCH 13/22] Create magweapon_energy.dm --- .../guns/ballistic/magweapon_energy.dm | 279 ++++++++++++++++++ 1 file changed, 279 insertions(+) create mode 100644 modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm new file mode 100644 index 0000000000..7324ad1024 --- /dev/null +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm @@ -0,0 +1,279 @@ +///ammo/// + +/obj/item/ammo_casing/caseless/mag_e + var/energy_cost = 0 + +/obj/item/ammo_casing/caseless/mag_e/amagm_e + desc = "A large ferromagnetic slug intended to be launched out of a compatible weapon." + caliber = "magm" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/magrifle + energy_cost = 300 + +/obj/item/ammo_casing/caseless/mag_e/anlmagm_e + desc = "A large, specialized ferromagnetic slug designed with a less-than-lethal payload." + caliber = "magm" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/nlmagrifle + energy_cost = 300 + +/obj/item/ammo_casing/caseless/mag_e/amags + desc = "A ferromagnetic slug intended to be launched out of a compatible weapon." + caliber = "mags" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/mags + energy_cost = 200 + +/obj/item/ammo_casing/caseless/mag_e/anlmags + desc = "A specialized ferromagnetic slug designed with a less-than-lethal payload." + caliber = "mags" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mag-casing-live" + projectile_type = /obj/item/projectile/bullet/nlmags + energy_cost = 200 + +///magazines/// + +/obj/item/ammo_box/magazine/mmag_e/ + name = "magrifle magazine (non-lethal disabler)" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mediummagmag" + ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmagm_e + caliber = "magm" + max_ammo = 24 + multiple_sprites = 2 + +/obj/item/ammo_box/magazine/mmag_e/lethal + name = "magrifle magazine (lethal)" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "mediummagmag" + ammo_type = /obj/item/ammo_casing/caseless/mag_e/amagm_e + max_ammo = 24 + + +/obj/item/ammo_box/magazine/mmag_e/small + name = "magpistol magazine (non-lethal disabler)" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "nlmagmag" + ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmags + caliber = "mags" + max_ammo = 15 + multiple_sprites = 2 + +/obj/item/ammo_box/magazine/mmag_e/small/lethal + name = "magpistol magazine (lethal)" + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "smallmagmag" + ammo_type = /obj/item/ammo_casing/caseless/mag_e/amags + +///cells/// + +/obj/item/stock_parts/cell/magrifle_e + name = "magrifle power supply" + maxcharge = 14400 + +/obj/item/stock_parts/cell/magpistol_e + name = "magpistol power supply" + maxcharge = 6000 + +///sci designs/// + +/datum/design/magrifle_e + name = "Magrifle" + desc = "An upscaled Magpistol in rifle form." + id = "magrifle_e" + build_type = PROTOLATHE + materials = list(MAT_METAL = 10000, MAT_GLASS = 2000, MAT_URANIUM = 2000, MAT_TITANIUM = 10000, MAT_SILVER = 4000, MAT_GOLD = 2000) + build_path = /obj/item/gun/ballistic/automatic/magrifle_e/nopin + category = list("Weapons") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/mag_magrifle_e + name = "Magrifle Magazine (Lethal)" + desc = "A 24-round magazine for the Magrifle." + id = "mag_magrifle_e" + build_type = PROTOLATHE + materials = list(MAT_METAL = 8000, MAT_SILVER = 1000) + build_path = /obj/item/ammo_box/magazine/mmag_e/lethal + category = list("Ammo") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/mag_magrifle_e/nl + name = "Magrifle Magazine (Non-Lethal)" + desc = "A 24- round non-lethal magazine for the Magrifle." + id = "mag_magrifle_nl" + materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) + build_path = /obj/item/ammo_box/magazine/mmag_e + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/magpistol_e + name = "Magpistol" + desc = "A weapon which fires ferromagnetic slugs." + id = "magpistol_e" + build_type = PROTOLATHE + materials = list(MAT_METAL = 7500, MAT_GLASS = 1000, MAT_URANIUM = 1000, MAT_TITANIUM = 5000, MAT_SILVER = 2000) + build_path = /obj/item/gun/ballistic/automatic/pistol/mag_e/nopin + category = list("Weapons") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/mag_magpistol_e + name = "Magpistol Magazine" + desc = "A 14 round magazine for the Magpistol." + id = "mag_magpistol_e" + build_type = PROTOLATHE + materials = list(MAT_METAL = 4000, MAT_SILVER = 500) + build_path = /obj/item/ammo_box/magazine/mmag_e/small/lethal + category = list("Ammo") + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/datum/design/mag_magpistol_e/nl + name = "Magpistol Magazine (Non-Lethal)" + desc = "A 14 round non-lethal magazine for the Magpistol." + id = "mag_magpistol_e_nl" + materials = list(MAT_METAL = 3000, MAT_SILVER = 250, MAT_TITANIUM = 250) + build_path = /obj/item/ammo_box/magazine/mmag_e/small + departmental_flags = DEPARTMENTAL_FLAG_SECURITY + +/* +// TECHWEBS IMPLEMENTATION +*/ + +/datum/techweb_node/magnetic_weapons + id = "magnetic_weapons" + display_name = "Magnetic Weapons" + description = "Weapons using magnetic technology" + prereq_ids = list("weaponry", "adv_weaponry", "emp_adv") + design_ids = list("magrifle_e", "magpisol_e", "mag_magrifle_e", "mag_magrifle_nl", "mag_magpistol_e", "mag_magpistol_nl") + research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) + export_price = 5000 + +///magrifle/// + +/obj/item/gun/ballistic/automatic/magrifle_e + name = "\improper Magnetic Rifle" + desc = "A simple upscalling of the technologies used in the magpistol, the magrifle is capable of firing slightly larger slugs in bursts. Compatible with the magpistol's slugs." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magrifle" + item_state = "arg" + slot_flags = 0 + mag_type = /obj/item/ammo_box/magazine/mmag_e + fire_sound = 'sound/weapons/magrifle.ogg' + can_suppress = 0 + burst_size = 3 + fire_delay = 2 + spread = 5 + recoil = 0.15 + casing_ejector = 0 + var/obj/item/stock_parts/cell/cell + var/cell_type = /obj/item/stock_parts/cell/magrifle_e + var/dead_cell = FALSE + + +/obj/item/gun/ballistic/automatic/magrifle_e/can_shoot() + if(QDELETED(cell)) + return 0 + + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + if(!shot) + return 0 + if(cell.charge < shot.energy_cost*burst_size) + return 0 + . = ..() + +/obj/item/gun/ballistic/automatic/magrifle_e/shoot_live_shot() + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + cell.use(shot.energy_cost) + . = ..() + +/obj/item/gun/ballistic/automatic/magrifle_e/emp_act(severity) + . = ..() + if(!(. & EMP_PROTECT_CONTENTS)) + cell.use(round(cell.charge / severity)) + +/obj/item/gun/ballistic/automatic/magrifle_e/get_cell() + return cell + +/obj/item/gun/ballistic/automatic/magrifle_e/Initialize() + . = ..() + if(cell_type) + cell = new cell_type(src) + else + cell = new(src) + + if(!dead_cell) + cell.give(cell.maxcharge) + +/obj/item/gun/ballistic/automatic/magrifle_e/nopin + pin = null + spawnwithmagazine = FALSE + + +///magpistol/// + +/obj/item/gun/ballistic/automatic/pistol/mag_e + name = "magpistol" + desc = "A handgun utilizing maglev technologies to propel a ferromagnetic slug to extreme velocities." + icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' + icon_state = "magpistol" + force = 10 + fire_sound = 'sound/weapons/magpistol.ogg' + mag_type = /obj/item/ammo_box/magazine/mmag_e/small + can_suppress = 0 + casing_ejector = 0 + fire_delay = 2 + recoil = 0.2 + var/obj/item/stock_parts/cell/cell + var/cell_type = /obj/item/stock_parts/cell/magpistol_e + var/dead_cell = FALSE + +/obj/item/gun/ballistic/automatic/pistol/mag_e/can_shoot() + if(QDELETED(cell)) + return 0 + + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + if(!shot) + return 0 + if(cell.charge < shot.energy_cost) + return 0 + . = ..() + +/obj/item/gun/ballistic/automatic/pistol/mag_e/shoot_live_shot() + var/obj/item/ammo_casing/caseless/mag_e/shot = chambered + cell.use(shot.energy_cost) + . = ..() + +/obj/item/gun/ballistic/automatic/pistol/mag_e/emp_act(severity) + . = ..() + if(!(. & EMP_PROTECT_CONTENTS)) + cell.use(round(cell.charge / severity)) + +/obj/item/gun/ballistic/automatic/pistol/mag_e/get_cell() + return cell + +/obj/item/gun/ballistic/automatic/pistol/mag_e/Initialize() + . = ..() + if(cell_type) + cell = new cell_type(src) + else + cell = new(src) + + if(!dead_cell) + cell.give(cell.maxcharge) + + +/obj/item/gun/ballistic/automatic/pistol/mag_e/update_icon() + ..() + if(magazine) + cut_overlays() + add_overlay("magpistol-magazine") + else + cut_overlays() + icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" + + +/obj/item/gun/ballistic/automatic/pistol/mag_e/nopin + pin = null + spawnwithmagazine = FALSE From a52dab3e0085c872894b9b0cf8076e272fb79ef4 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 22:47:55 -0400 Subject: [PATCH 14/22] Update tgstation.dme --- tgstation.dme | 1 + 1 file changed, 1 insertion(+) diff --git a/tgstation.dme b/tgstation.dme index 5b4c4eabe5..1729380f50 100755 --- a/tgstation.dme +++ b/tgstation.dme @@ -2954,6 +2954,7 @@ #include "modular_citadel\code\modules\projectiles\guns\ballistic\flechette.dm" #include "modular_citadel\code\modules\projectiles\guns\ballistic\handguns.dm" #include "modular_citadel\code\modules\projectiles\guns\ballistic\magweapon.dm" +#include "modular_citadel\code\modules\projectiles\guns\ballistic\magweapon_energy.dm" #include "modular_citadel\code\modules\projectiles\guns\ballistic\revolver.dm" #include "modular_citadel\code\modules\projectiles\guns\ballistic\rifles.dm" #include "modular_citadel\code\modules\projectiles\guns\ballistic\spinfusor.dm" From e51cdf98b24d6ef1eadb6bc5b9bfc3a2a9f5e344 Mon Sep 17 00:00:00 2001 From: Useroth Date: Mon, 29 Apr 2019 04:58:26 +0200 Subject: [PATCH 15/22] Fixed the calibers up. --- .../projectiles/guns/ballistic/magweapon_energy.dm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm index 7324ad1024..37a6fd59e3 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm @@ -5,7 +5,7 @@ /obj/item/ammo_casing/caseless/mag_e/amagm_e desc = "A large ferromagnetic slug intended to be launched out of a compatible weapon." - caliber = "magm" + caliber = "mag_e" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" projectile_type = /obj/item/projectile/bullet/magrifle @@ -13,7 +13,7 @@ /obj/item/ammo_casing/caseless/mag_e/anlmagm_e desc = "A large, specialized ferromagnetic slug designed with a less-than-lethal payload." - caliber = "magm" + caliber = "mag_e" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" projectile_type = /obj/item/projectile/bullet/nlmagrifle @@ -21,7 +21,7 @@ /obj/item/ammo_casing/caseless/mag_e/amags desc = "A ferromagnetic slug intended to be launched out of a compatible weapon." - caliber = "mags" + caliber = "mag_e" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" projectile_type = /obj/item/projectile/bullet/mags @@ -29,7 +29,7 @@ /obj/item/ammo_casing/caseless/mag_e/anlmags desc = "A specialized ferromagnetic slug designed with a less-than-lethal payload." - caliber = "mags" + caliber = "mag_e" icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mag-casing-live" projectile_type = /obj/item/projectile/bullet/nlmags @@ -42,7 +42,7 @@ icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "mediummagmag" ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmagm_e - caliber = "magm" + caliber = "mag_e" max_ammo = 24 multiple_sprites = 2 @@ -59,7 +59,7 @@ icon = 'modular_citadel/icons/obj/guns/cit_guns.dmi' icon_state = "nlmagmag" ammo_type = /obj/item/ammo_casing/caseless/mag_e/anlmags - caliber = "mags" + caliber = "mag_e" max_ammo = 15 multiple_sprites = 2 From 514e15ee6c4758c948f7dbe0455b2ecdcbc0a03b Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 23:32:38 -0400 Subject: [PATCH 16/22] Update magweapon.dm --- .../code/modules/projectiles/guns/ballistic/magweapon.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 13e1c0007c..4ff4f572fc 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -122,7 +122,7 @@ cut_overlays() icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" -///research memes/// +///*research memes/// /obj/item/gun/ballistic/automatic/pistol/mag/nopin pin = null @@ -155,7 +155,7 @@ materials = list(MAT_METAL = 3000, MAT_SILVER = 250, MAT_TITANIUM = 250) build_path = /obj/item/ammo_box/magazine/mmag/small departmental_flags = DEPARTMENTAL_FLAG_SECURITY - +*/ //////toy memes///// /obj/item/projectile/bullet/reusable/foam_dart/mag @@ -271,7 +271,7 @@ recoil = 0.15 casing_ejector = 0 -///research/// +/*//research/// /obj/item/gun/ballistic/automatic/magrifle/nopin pin = null @@ -304,7 +304,7 @@ materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) build_path = /obj/item/ammo_box/magazine/mmag departmental_flags = DEPARTMENTAL_FLAG_SECURITY - +/* ///foamagrifle/// /obj/item/ammo_box/magazine/toy/foamag From c5f3f678247f9b69f7344c6c921defaa2fcd9d19 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 23:33:31 -0400 Subject: [PATCH 17/22] Update magweapon.dm --- .../code/modules/projectiles/guns/ballistic/magweapon.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 4ff4f572fc..226d982991 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -122,8 +122,8 @@ cut_overlays() icon_state = "[initial(icon_state)][chambered ? "" : "-e"]" -///*research memes/// - +///research memes/// +/* /obj/item/gun/ballistic/automatic/pistol/mag/nopin pin = null spawnwithmagazine = FALSE From b51751dfa8143614f99060fa97ede5f277f0d290 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 23:38:34 -0400 Subject: [PATCH 18/22] Update magweapon_energy.dm --- .../code/modules/projectiles/guns/ballistic/magweapon_energy.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm index 37a6fd59e3..ba853f3670 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm @@ -104,7 +104,7 @@ /datum/design/mag_magrifle_e/nl name = "Magrifle Magazine (Non-Lethal)" desc = "A 24- round non-lethal magazine for the Magrifle." - id = "mag_magrifle_nl" + id = "mag_magrifle_e_nl" materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) build_path = /obj/item/ammo_box/magazine/mmag_e departmental_flags = DEPARTMENTAL_FLAG_SECURITY From d136d9574386c1d4ac4cab5548c1e086e5b53b54 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 23:56:39 -0400 Subject: [PATCH 19/22] Update magweapon.dm --- .../code/modules/projectiles/guns/ballistic/magweapon.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 226d982991..409b8eecaf 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -271,7 +271,8 @@ recoil = 0.15 casing_ejector = 0 -/*//research/// +/* +//research/// /obj/item/gun/ballistic/automatic/magrifle/nopin pin = null @@ -326,7 +327,6 @@ spread = 60 w_class = WEIGHT_CLASS_BULKY weapon_weight = WEAPON_HEAVY - /* // TECHWEBS IMPLEMENTATION // From 5430454c7323e03110e9eb0327c0ce307a4fb3fa Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Sun, 28 Apr 2019 23:59:29 -0400 Subject: [PATCH 20/22] Update magweapon.dm --- .../code/modules/projectiles/guns/ballistic/magweapon.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm index 409b8eecaf..b3af722332 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon.dm @@ -305,7 +305,7 @@ materials = list(MAT_METAL = 6000, MAT_SILVER = 500, MAT_TITANIUM = 500) build_path = /obj/item/ammo_box/magazine/mmag departmental_flags = DEPARTMENTAL_FLAG_SECURITY -/* +*/ ///foamagrifle/// /obj/item/ammo_box/magazine/toy/foamag From 4492e60a9faacd2f12acc738cbaf0915e5a80b76 Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Mon, 29 Apr 2019 00:02:53 -0400 Subject: [PATCH 21/22] typo --- .../code/modules/projectiles/guns/ballistic/magweapon_energy.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm index ba853f3670..7140fda076 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm @@ -146,7 +146,7 @@ display_name = "Magnetic Weapons" description = "Weapons using magnetic technology" prereq_ids = list("weaponry", "adv_weaponry", "emp_adv") - design_ids = list("magrifle_e", "magpisol_e", "mag_magrifle_e", "mag_magrifle_nl", "mag_magpistol_e", "mag_magpistol_nl") + design_ids = list("magrifle_e", "magpistol_e", "mag_magrifle_e", "mag_magrifle_nl", "mag_magpistol_e", "mag_magpistol_nl") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) export_price = 5000 From 60a9544a6bd1f25c9f602f71ea86c262d4f5e05d Mon Sep 17 00:00:00 2001 From: Trilbyspaceclone <30435998+Trilbyspaceclone@users.noreply.github.com> Date: Mon, 29 Apr 2019 00:19:47 -0400 Subject: [PATCH 22/22] Update magweapon_energy.dm --- .../code/modules/projectiles/guns/ballistic/magweapon_energy.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm index 7140fda076..90dd577c4b 100644 --- a/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm +++ b/modular_citadel/code/modules/projectiles/guns/ballistic/magweapon_energy.dm @@ -146,7 +146,7 @@ display_name = "Magnetic Weapons" description = "Weapons using magnetic technology" prereq_ids = list("weaponry", "adv_weaponry", "emp_adv") - design_ids = list("magrifle_e", "magpistol_e", "mag_magrifle_e", "mag_magrifle_nl", "mag_magpistol_e", "mag_magpistol_nl") + design_ids = list("magrifle_e", "magpistol_e", "mag_magrifle_e", "mag_magrifle_e_nl", "mag_magpistol_e", "mag_magpistol_e_nl") research_costs = list(TECHWEB_POINT_TYPE_GENERIC = 2500) export_price = 5000