Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add: Specter #6581

Open
wants to merge 1 commit into
base: master220
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions code/game/machinery/vending.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2194,6 +2194,7 @@
var/static/list/available_kits = list(
"Dominator Kit" = /obj/item/storage/box/dominator_kit,
"Enforcer Kit" = /obj/item/storage/box/enforcer_kit,
"Specter Kit" = /obj/item/storage/box/specter_kit,
)
var/weapon_kit = tgui_input_list(user, "Select a weaponary kit:", "Weapon kits", available_kits)
if(!weapon_kit || !Adjacent(user) || QDELETED(I) || I.loc != user)
Expand Down
12 changes: 12 additions & 0 deletions code/game/objects/items/weapons/storage/boxes.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1465,6 +1465,18 @@
new /obj/item/ammo_box/magazine/enforcer(src)
new /obj/item/clothing/accessory/holster(src)

/obj/item/storage/box/specter_kit
name = "Specter kit"
desc = "Коробка с пистолетом Спектр, кобурой и двумя обоймами парализующих патронов"
icon_state = "box_dominator"


/obj/item/storage/box/specter_kit/populate_contents()
new /obj/item/gun/projectile/automatic/pistol/specter(src)
new /obj/item/clothing/accessory/holster(src)
new /obj/item/ammo_box/magazine/specter(src)
new /obj/item/ammo_box/magazine/specter(src)

/obj/item/storage/box/revolver_kit
name = "Revolver kit"
icon_state = "box_revolver"
Expand Down
18 changes: 18 additions & 0 deletions code/modules/projectiles/ammunition/ammo_casings.dm
Original file line number Diff line number Diff line change
Expand Up @@ -628,3 +628,21 @@
muzzle_flash_strength = MUZZLE_FLASH_STRENGTH_WEAK
muzzle_flash_range = MUZZLE_FLASH_RANGE_NORMAL
muzzle_flash_color = LIGHT_COLOR_DARKRED

/obj/item/ammo_casing/specter/laser
desc = "A specter bullet casing."
icon_state = "laser-casing"
caliber = "specter"
materials = list(MAT_METAL = 1000)
projectile_type = /obj/item/projectile/beam/specter/laser
muzzle_flash_strength = MUZZLE_FLASH_STRENGTH_WEAK
muzzle_flash_range = MUZZLE_FLASH_RANGE_NORMAL
muzzle_flash_color = LIGHT_COLOR_DARKRED

/obj/item/ammo_casing/specter/disable
desc = "A specter bullet casing."
icon_state = "stam-casing"
caliber = "specter"
materials = list(MAT_METAL = 800)
projectile_type = /obj/item/projectile/beam/specter/disabler
muzzle_flash_color = LIGHT_COLOR_LIGHTBLUE
16 changes: 16 additions & 0 deletions code/modules/projectiles/ammunition/boxes.dm
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,22 @@
icon_state = "ammobox_10incendiary"
ammo_type = /obj/item/ammo_casing/c10mm/fire

/obj/item/ammo_box/specter/laser
name = "ammo box (specter laser)"
desc = "Коробка патронов с лазерным наконечником"
icon_state = "speclaser-ammo"
origin_tech = "combat=2"
ammo_type = /obj/item/ammo_casing/specter/laser
max_ammo = 30

/obj/item/ammo_box/specter/disabler
name = "ammo box (specter disable)"
desc = "Коробка патронов с парализующим наконечником"
icon_state = "specstamina-ammo"
origin_tech = "combat=2"
ammo_type = /obj/item/ammo_casing/specter/disable
max_ammo = 30

/**
* SPEEDLOADER
*/
Expand Down
36 changes: 36 additions & 0 deletions code/modules/projectiles/ammunition/magazines.dm
Original file line number Diff line number Diff line change
Expand Up @@ -724,3 +724,39 @@
desc = "Похоже, этот расширенный магазин может принять в себя любые патроны 12-о калибра."
icon_state = "cats_mag_large"
max_ammo = 14

/obj/item/ammo_box/magazine/specter
name = "specter magazine (disable)"
desc = "Пистолетная обойма под различные типы пистолетных лазерных патронов"
icon_state = "specmag"
ammo_type = /obj/item/ammo_casing/specter/disable
max_ammo = 8
multiple_sprites = 1
caliber = "specter"
materials = list(MAT_METAL = 3000)


/obj/item/ammo_box/magazine/specter/update_overlays()
. = ..()
if(ammo_count() && is_disable())
. += image('icons/obj/weapons/ammo.dmi', icon_state = "specter-d")


/obj/item/ammo_box/magazine/specter/examine(mob/user)
. = ..()
if(get_dist(user, src) <= 2)
. += span_notice("It seems to be loaded with [is_disable() ? "disable" : "laser"] bullets.")

/obj/item/ammo_box/magazine/specter/proc/is_disable()
var/ammo = ammo_count()
if(!ammo)
return FALSE
if(istype(contents[contents.len], /obj/item/ammo_casing/specter/disable))
return TRUE
return FALSE

/obj/item/ammo_box/magazine/specter/laser
name = "specter magazine (laser)"
desc = "Пистолетная обойма под различные типы пистолетных лазерных патронов"
ammo_type = /obj/item/ammo_casing/specter/laser
materials = list(MAT_METAL = 5000)
44 changes: 44 additions & 0 deletions code/modules/projectiles/guns/projectile/pistol.dm
Original file line number Diff line number Diff line change
Expand Up @@ -192,3 +192,47 @@
burst_size = 3
fire_delay = 2
actions_types = list(/datum/action/item_action/toggle_firemode)

//Specter//
/obj/item/gun/projectile/automatic/pistol/specter
name = "Спектр"
ru_names = list(
NOMINATIVE = "Спектр",
GENITIVE = "Спектра",
DATIVE = "Спектру",
ACCUSATIVE = "Спектр",
INSTRUMENTAL = "Спектром",
PREPOSITIONAL = "Спектре"
)
desc = "Современный пистолет Спектр, модернизирован для стрельбы лазерными патронами. Поставляется только силовым структурам Нанотрейзен."
origin_tech = "combat=4;materials=2"
icon_state = "specter"
item_state = "specter"
force = 10
mag_type = /obj/item/ammo_box/magazine/specter
fire_sound = 'sound/weapons/gunshots/gunshot_lascarbine.ogg'
can_suppress = FALSE
unique_reskin = TRUE
can_flashlight = FALSE
gun_light_overlay = "specter_light"
materials = list(MAT_METAL = 1000)

/obj/item/gun/projectile/automatic/pistol/specter/update_gun_skins()
add_skin("Grey slide", "specter")
add_skin("Red slide", "specter_red")
add_skin("Green slide", "specter_green")
add_skin("Tan slide", "specter_tan")
add_skin("Green Handle", "specter_greengrip")
add_skin("Tan Handle", "specter_tangrip")
add_skin("Red Handle", "specter_redgrip")


/obj/item/gun/projectile/automatic/pistol/specter/update_icon_state()
if(current_skin)
icon_state = "[current_skin][chambered ? "" : "-e"]"
else
icon_state = "[initial(icon_state)][chambered ? "" : "-e"]"

/obj/item/gun/projectile/automatic/pistol/specter/Initialize(mapload, ...)
. = ..()
set_gun_light(new /obj/item/flashlight/seclite(src))
20 changes: 20 additions & 0 deletions code/modules/projectiles/projectile/beams.dm
Original file line number Diff line number Diff line change
Expand Up @@ -265,3 +265,23 @@
impact_effect_type = /obj/effect/temp_visual/impact_effect/blue_laser
light_color = LIGHT_COLOR_LIGHT_CYAN

/obj/item/projectile/beam/specter/laser
name = "specter laser beam"
icon_state = "laser"
damage = 25
damage_type = BURN
impact_effect_type = /obj/effect/temp_visual/impact_effect/red_laser
light_color = LIGHT_COLOR_DARKRED

/obj/item/projectile/beam/specter/disabler
name = "specter paralyzer beam"
icon_state = "omnilaser"
damage = 30
shockbull = TRUE
damage_type = STAMINA
flag = "energy"
hitsound = 'sound/weapons/plasma_cutter.ogg'
hitsound_wall = 'sound/weapons/sear.ogg'
eyeblur = 0
impact_effect_type = /obj/effect/temp_visual/impact_effect/blue_laser
light_color = LIGHT_COLOR_LIGHT_CYAN
33 changes: 33 additions & 0 deletions code/modules/research/designs/autolathe_designs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -961,6 +961,39 @@
build_path = /obj/item/ammo_box/c9mm
category = list("hacked", "Security")

/datum/design/specter/disable
name = "Ammo box (specter disable)"
id = "specter_disable"
build_type = AUTOLATHE
materials = list(MAT_METAL = 25000)
build_path = /obj/item/ammo_box/specter/disabler
category = list("initial", "Security")

/datum/design/specter/laser
name = "Ammo box (specter laser)"
id = "specter_laser"
build_type = AUTOLATHE
materials = list(MAT_METAL = 35000)
build_path = /obj/item/ammo_box/specter/laser
category = list("hacked", "Security")

/datum/design/spectermag_disabler
name = "specter magazine (disable)"
id = "spectermag_disabler"
build_type = AUTOLATHE
materials = list(MAT_METAL = 8000)
build_path = /obj/item/ammo_box/magazine/specter
category = list("initial", "Security")

//hacked autolathe recipes
/datum/design/spectermag_laser
name = "specter magazine (laser)"
id = "spectermag_laser"
build_type = AUTOLATHE
materials = list(MAT_METAL = 10000)
build_path = /obj/item/ammo_box/magazine/specter/laser
category = list("hacked", "Security")

/datum/design/knuckles
name = "Knuckles"
id = "knuckles"
Expand Down
Binary file modified icons/mob/inhands/guns_lefthand.dmi
Binary file not shown.
Binary file modified icons/mob/inhands/guns_righthand.dmi
Binary file not shown.
Binary file modified icons/obj/weapons/ammo.dmi
Binary file not shown.
Binary file modified icons/obj/weapons/projectile.dmi
Binary file not shown.