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

TWEAK: Merc kits and some fixes #1798

Merged
merged 20 commits into from
Jan 15, 2024
Merged
Show file tree
Hide file tree
Changes from 8 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
3 changes: 3 additions & 0 deletions code/modules/admin/admin_verbs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,9 @@ var/global/list/admin_verbs_spawn = list(
/datum/admins/proc/spawn_atom, // allows us to spawn instances,
/datum/admins/proc/spawn_artifact,
/client/proc/spawn_chemdisp_cartridge,
// [SIERRA-ADD] - admin_verbs
/client/proc/respawn_as_self,
// [/SIERRA-ADD]
LordNest marked this conversation as resolved.
Show resolved Hide resolved
/datum/admins/proc/mass_debug_closet_icons
)
var/global/list/admin_verbs_server = list(
Expand Down
17 changes: 17 additions & 0 deletions code/modules/mob/living/carbon/human/inventory.dm
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,23 @@ This saves us from having to call add_fingerprint() any time something is put in
update_inv_l_hand(0)
else
update_inv_r_hand(0)
// [SIERRA-ADD]
LordNest marked this conversation as resolved.
Show resolved Hide resolved
// Try put it in their toolbelt
if(istype(src.belt, /obj/item/storage))
var/obj/item/storage/belt = src.belt
if(belt.can_be_inserted(I, null, 1) && belt.handle_item_insertion(I))
return
// Try put it in their backpack
if(istype(src.back, /obj/item/storage))
var/obj/item/storage/backpack = src.back
if(backpack.can_be_inserted(I, null, 1) && backpack.handle_item_insertion(I))
return

// Try to place it in any item that can store stuff, on the mob.
for(var/obj/item/storage/S in src.contents)
if(S.can_be_inserted(I, null, 1) && S.handle_item_insertion(I))
return
// [/SIERRA-ADD]
else
to_chat(H, SPAN_WARNING("You are unable to equip that."))

Expand Down
Binary file added maps/sierra/icons/obj/target.dmi
Binary file not shown.
Binary file modified maps/sierra/icons/turf/decals.dmi
Binary file not shown.
21 changes: 21 additions & 0 deletions maps/sierra/items/modular_computer.dm
Original file line number Diff line number Diff line change
Expand Up @@ -174,3 +174,24 @@
/obj/item/modular_computer/pda/wrist/lila/black
icon_state = "wrist-lila-black"
icon_state_unpowered = "wrist-lila-black"

// Laptop icon override

/obj/item/modular_computer/laptop
icon = 'maps/sierra/icons/obj/modular_laptop.dmi'

/obj/item/modular_computer/laptop/verb/rotatelaptop()
set name = "Rotate laptop"
set category = "Object"
set src in view(1)

if(usr.stat == DEAD)
if(!round_is_spooky())
to_chat(src, "<span class='warning'>The veil is not thin enough for you to do that.</span>")
return

src.set_dir(turn(src.dir, -90))

/obj/item/modular_computer/laptop/update_verbs()
..()
verbs |= /obj/item/modular_computer/laptop/verb/rotatelaptop
LordNest marked this conversation as resolved.
Show resolved Hide resolved
2 changes: 1 addition & 1 deletion maps/sierra/job/jobs_command.dm
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@

minimum_character_age = list(SPECIES_HUMAN = 30)
ideal_character_age = 40
outfit_type = /singleton/hierarchy/outfit/job/sierra/crew/research/iaa
outfit_type = /singleton/hierarchy/outfit/job/sierra/crew/command/iaa
allowed_branches = list(
/datum/mil_branch/employee
)
Expand Down
2 changes: 1 addition & 1 deletion maps/sierra/job/outfits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ Keeping them simple for now, just spawning with basic EC uniforms, and pretty mu
..()
BACKPACK_OVERRIDE_SECURITY

/singleton/hierarchy/outfit/job/sierra/crew/research/iaa
/singleton/hierarchy/outfit/job/sierra/crew/command/iaa
name = OUTFIT_JOB_NAME("Internal Affairs Agent - Sierra")
l_ear = /obj/item/device/radio/headset/ia
uniform = /obj/item/clothing/under/rank/internalaffairs/plain/nt
Expand Down
1 change: 1 addition & 0 deletions maps/sierra/sierra.dm
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@
#include "../../mods/_maps/sentinel/_map_sentinel.dme"
#include "../../mods/_maps/farfleet/_map_farfleet.dme"

#include "../../mods/admin_verbs/_admin_verbs.dme"
#include "../../mods/antagonists/_antagonists.dme"
#include "../../mods/bluespace_kitty/_bluespace_kitty.dme"
#include "../../mods/fancy_sofas/_fancy_sofas.dme"
Expand Down
8 changes: 8 additions & 0 deletions maps/sierra/structures/closets/_closets_appearances.dm
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,14 @@
"atmos" = COLOR_COMMAND_BLUE
)

/singleton/closet_appearance/secure_closet/sierra/engineering/infotech
color = COLOR_GUNMETAL
extra_decals = list(
"stripe_vertical_mid_partial" = COLOR_PALE_ORANGE,
"stripe_vertical_right_partial" = COLOR_PALE_ORANGE,
"eng_narrow" = COLOR_PALE_ORANGE
)

/singleton/closet_appearance/secure_closet/sierra/engineering/ce
color = COLOR_OFF_WHITE
extra_decals = list(
Expand Down
21 changes: 21 additions & 0 deletions maps/sierra/structures/closets/engineering.dm
Original file line number Diff line number Diff line change
Expand Up @@ -131,3 +131,24 @@
/obj/item/taperoll/atmos,
/obj/item/device/scanner/gas
)

/obj/structure/closet/secure_closet/infotech_sierra
name = "information technician locker"
req_access = list(access_network_admin)
closet_appearance = /singleton/closet_appearance/secure_closet/sierra/engineering/infotech

/obj/structure/closet/secure_closet/infotech_sierra/WillContain()
return list(
/obj/item/storage/box/PDAs,
/obj/item/modular_computer/laptop/preset/custom_loadout/standard,
/obj/item/modular_computer/tablet/preset/custom_loadout/standard,
/obj/item/clothing/glasses/hud/it,
/obj/item/device/multitool,
/obj/item/clothing/gloves/insulated,
/obj/item/device/flashlight/upgraded,
/obj/item/storage/belt/utility/full,
/obj/item/clothing/head/beret/engineering,
/obj/item/device/radio/headset/headset_eng,
/obj/item/device/radio/headset/headset_eng/alt,
/obj/item/stack/cable_coil = 2
)
134 changes: 134 additions & 0 deletions maps/sierra/structures/other.dm
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,137 @@
new /obj/item/book/manual/nt_tc(src)
new /obj/item/book/manual/military_law(src)
update_icon()

// Targets, the things that actually get shot!
/obj/item/target
name = "shooting target"
desc = "A shooting target."
icon = 'maps/sierra/icons/obj/target.dmi'
icon_state = "target_h"
density = FALSE
var/hp = 1800
var/icon/virtualIcon
var/list/bulletholes = list()

/obj/item/target/use_tool(obj/item/W, mob/living/user, list/click_params)
. = ..()
if(isWelder(W))
var/obj/item/weldingtool/WT = W
if(WT.remove_fuel(0, user))
overlays.Cut()
LordNest marked this conversation as resolved.
Show resolved Hide resolved
bulletholes.Cut()
hp = initial(hp)
to_chat(usr, "<span class='notice'>You slice off [src]'s uneven chunks of aluminium and scorch marks.</span>")
return


/obj/item/target/syndicate
icon_state = "target_s"
desc = "A shooting target that looks like a hostile agent."
hp = 2600 // i guess syndie targets are sturdier?

/obj/item/target/alien
icon_state = "target_q"
desc = "A shooting target with a threatening silhouette."
hp = 2350 // alium onest too kinda

/obj/item/target/bullet_act(obj/item/projectile/Proj)
var/p_x = Proj.p_x + pick(0,0,0,0,0,-1,1) // really ugly way of coding "sometimes offset Proj.p_x!"
var/p_y = Proj.p_y + pick(0,0,0,0,0,-1,1)
var/decaltype = 1 // 1 - scorch, 2 - bullet
LordNest marked this conversation as resolved.
Show resolved Hide resolved

if(istype(/obj/item/projectile/bullet, Proj))
decaltype = 2


virtualIcon = new(icon, icon_state)

if( virtualIcon.GetPixel(p_x, p_y) ) // if the located pixel isn't blank (null)

hp -= Proj.damage
if(hp <= 0)
for(var/mob/O in oviewers())
if ((O.client && !( O.blinded )))
to_chat(O, "<span class='warning'>\The [src] breaks into tiny pieces and collapses!</span>")
qdel(src)

// Create a temporary object to represent the damage
var/obj/bmark = new
bmark.pixel_x = p_x
bmark.pixel_y = p_y
bmark.icon = 'icons/effects/effects.dmi'
bmark.layer = ABOVE_OBJ_LAYER
bmark.icon_state = "scorch"

if(decaltype == 1)
// Energy weapons are hot. they scorch!

// offset correction
bmark.pixel_x--
bmark.pixel_y--

if(Proj.damage >= 20 || istype(Proj, /obj/item/projectile/beam/practice))
bmark.icon_state = "scorch"
bmark.set_dir(pick(NORTH,SOUTH,EAST,WEST)) // random scorch design


else
bmark.icon_state = "light_scorch"
else

// Bullets are hard. They make dents!
bmark.icon_state = "dent"

if(Proj.damage >= 10 && bulletholes.len <= 35) // maximum of 35 bullet holes
if(decaltype == 2) // bullet
if(prob(Proj.damage+30)) // bullets make holes more commonly!
new/datum/bullethole(src, bmark.pixel_x, bmark.pixel_y) // create new bullet hole
else // Lasers!
if(prob(Proj.damage-10)) // lasers make holes less commonly
new/datum/bullethole(src, bmark.pixel_x, bmark.pixel_y) // create new bullet hole

// draw bullet holes
for(var/datum/bullethole/B in bulletholes)

virtualIcon.DrawBox(null, B.b1x1, B.b1y, B.b1x2, B.b1y) // horizontal line, left to right
virtualIcon.DrawBox(null, B.b2x, B.b2y1, B.b2x, B.b2y2) // vertical line, top to bottom

overlays += bmark // add the decal
LordNest marked this conversation as resolved.
Show resolved Hide resolved

icon = virtualIcon // apply bulletholes over decals

return

return PROJECTILE_CONTINUE // the bullet/projectile goes through the target!


// Small memory holder entity for transparent bullet holes
/datum/bullethole
// First box
var/b1x1 = 0
var/b1x2 = 0
var/b1y = 0

// Second box
var/b2x = 0
var/b2y1 = 0
var/b2y2 = 0

/datum/bullethole/New(obj/item/target/Target, pixel_x = 0, pixel_y = 0)
if(!Target) return
LordNest marked this conversation as resolved.
Show resolved Hide resolved

// Randomize the first box
b1x1 = pixel_x - pick(1,1,1,1,2,2,3,3,4)
b1x2 = pixel_x + pick(1,1,1,1,2,2,3,3,4)
b1y = pixel_y
if(prob(35))
b1y += rand(-4,4)

// Randomize the second box
b2x = pixel_x
if(prob(35))
b2x += rand(-4,4)
b2y1 = pixel_y + pick(1,1,1,1,2,2,3,3,4)
b2y2 = pixel_y - pick(1,1,1,1,2,2,3,3,4)

Target.bulletholes.Add(src)
51 changes: 40 additions & 11 deletions maps/sierra/z1-z5_sierra.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -24513,6 +24513,15 @@
},
/turf/simulated/floor/tiled/techfloor/grid,
/area/maintenance/fourthdeck/aft)
"dDg" = (
/obj/floor_decal/industrial/warning{
dir = 5
},
/obj/item/target/alien,
/turf/simulated/floor/reinforced{
map_airless = 1
},
/area/space)
"dDh" = (
/turf/simulated/wall/prepainted,
/area/vacant/utility)
Expand Down Expand Up @@ -73498,6 +73507,11 @@
/obj/floor_decal/corner/darkblue/bordercorner2{
dir = 1
},
/obj/machinery/light_switch{
dir = 4;
pixel_x = -23;
pixel_y = 5
},
/turf/simulated/floor/tiled/dark,
/area/crew_quarters/heads/office/iaa/high_sec)
"kWB" = (
Expand Down Expand Up @@ -73537,6 +73551,12 @@
},
/turf/simulated/floor/plating,
/area/shield/thirddeck)
"kXa" = (
/obj/item/target,
/turf/simulated/floor/reinforced{
map_airless = 1
},
/area/space)
"kXd" = (
/obj/structure/cable/green{
d1 = 4;
Expand Down Expand Up @@ -76062,6 +76082,11 @@
/obj/floor_decal/corner/darkblue/border,
/obj/floor_decal/borderfloorblack/corner2,
/obj/floor_decal/corner/darkblue/bordercorner2,
/obj/machinery/light_switch{
dir = 1;
pixel_x = -9;
pixel_y = -21
},
/turf/simulated/floor/tiled/dark,
/area/crew_quarters/heads/office/iaa/high_sec)
"lrH" = (
Expand Down Expand Up @@ -76592,18 +76617,11 @@
/turf/simulated/floor/plating,
/area/medical/virology/atmos)
"lvu" = (
/obj/structure/closet/toolcloset,
/obj/item/storage/belt,
/obj/item/stack/cable_coil{
pixel_x = 3;
pixel_y = -7
},
/obj/item/device/multitool,
/obj/structure/extinguisher_cabinet{
pixel_x = 24;
dir = 8
},
/obj/item/clothing/glasses/hud/it,
/obj/structure/closet/secure_closet/infotech_sierra,
/turf/simulated/floor/tiled/techfloor/grid,
/area/tcommsat/computer)
"lvv" = (
Expand Down Expand Up @@ -79466,6 +79484,11 @@
/obj/floor_decal/corner/darkblue/bordercorner2{
dir = 5
},
/obj/machinery/light_switch{
pixel_x = 24;
dir = 8;
pixel_y = -5
},
/turf/simulated/floor/tiled/dark,
/area/crew_quarters/heads/office/iaa/high_sec)
"lPF" = (
Expand Down Expand Up @@ -123027,6 +123050,12 @@
/obj/floor_decal/industrial/hatch/yellow,
/turf/simulated/floor/tiled/techfloor/grid,
/area/maintenance/fourthdeck/aft)
"stv" = (
/obj/item/target/syndicate,
/turf/simulated/floor/reinforced{
map_airless = 1
},
/area/space)
"stw" = (
/turf/simulated/wall/r_wall/hull,
/area/crew_quarters/garden_room)
Expand Down Expand Up @@ -290968,7 +290997,7 @@ rtT
rtT
rtT
uYw
uYw
stv
qPH
rox
sqc
Expand Down Expand Up @@ -291171,7 +291200,7 @@ rpE
qMW
uYw
uYw
uYw
kXa
aif
aAp
rsp
Expand Down Expand Up @@ -291371,7 +291400,7 @@ aTh
tXe
tXe
vDB
lQM
dDg
uYw
pJv
bYb
Expand Down
Loading
Loading