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

Baylike Walls and Windows #5547

Merged
merged 58 commits into from
Jul 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
64abb63
initial commit for baylike walls and objects
Mazianni May 30, 2023
36719ef
windows and grilles
Mazianni May 31, 2023
3b3464e
icons and such
Mazianni Jun 1, 2023
f42877b
converts yet more stuff to baylike walls
Mazianni Jun 3, 2023
6fcb622
firelocks and intercoms
Mazianni Jun 3, 2023
302a254
somethings fucky chief
Mazianni Jun 4, 2023
1ade880
yet more fuckery
Mazianni Jun 5, 2023
66e581b
closet horseshit
Mazianni Jun 6, 2023
a70843f
Merge branch 'master' of https://github.com/Citadel-Station-13/Citade…
Mazianni Jun 6, 2023
dee46e7
some unit tests and more map modifications
Mazianni Jun 7, 2023
a620c9a
removes unit test that probably fucked things
Mazianni Jun 7, 2023
d421389
maybes makes smoothing shut up
Mazianni Jun 7, 2023
b63a83f
maybe it wants it backwards
Mazianni Jun 7, 2023
417452e
smoothing maybe happy now
Mazianni Jun 7, 2023
805b8f3
another try!
Mazianni Jun 7, 2023
b6329d7
smoothing soothing
Mazianni Jun 7, 2023
20b8f10
smoothly i'll squash these
Mazianni Jun 7, 2023
f4eb91e
smootheeee
Mazianni Jun 7, 2023
ddf258b
yansc
Mazianni Jun 7, 2023
59a30f1
things smooth to airlocks yeah
Mazianni Jun 7, 2023
479a72d
Merge https://github.com/Citadel-Station-13/Citadel-Station-13-RP int…
Mazianni Jun 9, 2023
5008500
tweaks and changes to maps and various other things
Mazianni Jun 12, 2023
37b4ec9
more changes! so many changes
Mazianni Jun 13, 2023
2e8d7e2
Merge branch 'master' of https://github.com/Citadel-Station-13/Citade…
Mazianni Jun 14, 2023
43ac714
ugh
Mazianni Jun 15, 2023
fcc62c4
manual merge by silicons
Jun 15, 2023
5471179
dme tweak
Mazianni Jun 15, 2023
dbc4e8a
bug fixesssss
Mazianni Jun 17, 2023
30c7a73
Merge branch 'master' of https://github.com/Citadel-Station-13/Citade…
Mazianni Jun 18, 2023
0f55992
manual merge by silicons 2
Jun 19, 2023
6d2f957
accidentally removed that dict
Jun 19, 2023
6c82d1e
tweaks
Mazianni Jun 22, 2023
071c1b3
Merge branch 'master' into great_perspective
Mazianni Jun 22, 2023
272bab6
removes extra bitflag file + fixes a merge artifact
Mazianni Jun 22, 2023
7845df9
twonks
Mazianni Jun 22, 2023
37f0f57
some turf tweaks
Mazianni Jun 22, 2023
ee6a615
smartfridge fix
Mazianni Jun 23, 2023
22e834a
fixes multi-tile doors
Mazianni Jun 23, 2023
51c306d
map tweaks
Mazianni Jun 23, 2023
93563e6
fixes
Mazianni Jun 24, 2023
5ffa43c
more fixes
Mazianni Jun 24, 2023
ef5a8cf
smartfridge fix
Mazianni Jun 25, 2023
ebd939e
unfucks crates
Mazianni Jun 25, 2023
7b486f7
requested changes + crate decal fixes
Mazianni Jun 27, 2023
ce4a4f1
Merge branch 'master' of https://github.com/Citadel-Station-13/Citade…
Mazianni Jun 27, 2023
e7d3435
recursion fix
Mazianni Jun 27, 2023
a178030
tweaks and final adjustments
Mazianni Jun 27, 2023
6514bf2
Merge branch 'master' of https://github.com/Citadel-Station-13/Citade…
Mazianni Jul 4, 2023
806111a
fixes crates and ladder in surface 3 bar on rift
Mazianni Jul 5, 2023
afe9841
fixes body bags and adjusts mining turf color
Mazianni Jul 6, 2023
873e024
euthenia fix
Mazianni Jul 6, 2023
66ede5b
requested changes
Mazianni Jul 7, 2023
5ee7928
Merge branch 'master' into great_perspective
Mazianni Jul 7, 2023
9954b50
gun closets
Mazianni Jul 7, 2023
842d07f
Merge branch 'great_perspective' of https://github.com/Mazianni/Citad…
Mazianni Jul 7, 2023
f8ad672
airlock overlays to managed globals and use SSoverlays
Jul 7, 2023
4c84253
less magic strings in animations, simplemobs can now use doors if all…
Jul 7, 2023
e36c593
I'm a silly
silicons Jul 7, 2023
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
9 changes: 7 additions & 2 deletions citadel.dme
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
#include "code\__DEFINES\appearance.dm"
#include "code\__DEFINES\automata.dm"
#include "code\__DEFINES\belly_modes_vr.dm"
#include "code\__DEFINES\bitflags.dm"
#include "code\__DEFINES\callbacks.dm"
#include "code\__DEFINES\chat.dm"
#include "code\__DEFINES\chemistry.dm"
Expand Down Expand Up @@ -205,6 +206,7 @@
#include "code\__DEFINES\languages\ids.dm"
#include "code\__DEFINES\languages\legacy.dm"
#include "code\__DEFINES\languages\translation.dm"
#include "code\__DEFINES\machines\door.dm"
#include "code\__DEFINES\mapping\levels.dm"
#include "code\__DEFINES\mapping\maploader.dm"
#include "code\__DEFINES\mapping\maps.dm"
Expand Down Expand Up @@ -1240,6 +1242,7 @@
#include "code\game\machinery\doors\airlock.dm"
#include "code\game\machinery\doors\airlock_control.dm"
#include "code\game\machinery\doors\airlock_electronics.dm"
#include "code\game\machinery\doors\airlock_subtypes.dm"
#include "code\game\machinery\doors\airlock_vr.dm"
#include "code\game\machinery\doors\alarmlock.dm"
#include "code\game\machinery\doors\blast_door.dm"
Expand Down Expand Up @@ -1534,7 +1537,6 @@
#include "code\game\objects\items\devices\holowarrant.dm"
#include "code\game\objects\items\devices\laserpointer.dm"
#include "code\game\objects\items\devices\lightreplacer.dm"
#include "code\game\objects\items\devices\locker_painter.dm"
#include "code\game\objects\items\devices\megaphone.dm"
#include "code\game\objects\items\devices\modkit.dm"
#include "code\game\objects\items\devices\multitool.dm"
Expand Down Expand Up @@ -1756,6 +1758,7 @@
#include "code\game\objects\structures\ledges.dm"
#include "code\game\objects\structures\lightpost.dm"
#include "code\game\objects\structures\loot_piles.dm"
#include "code\game\objects\structures\low_wall.dm"
#include "code\game\objects\structures\map_blocker.dm"
#include "code\game\objects\structures\medical_stand_vr.dm"
#include "code\game\objects\structures\mineral_bath.dm"
Expand All @@ -1782,7 +1785,8 @@
#include "code\game\objects\structures\windoor_assembly.dm"
#include "code\game\objects\structures\window.dm"
#include "code\game\objects\structures\window_spawner.dm"
#include "code\game\objects\structures\crates_lockers\closets.dm"
#include "code\game\objects\structures\crates_lockers\__closet.dm"
#include "code\game\objects\structures\crates_lockers\_closet_appearance_definitions.dm"
#include "code\game\objects\structures\crates_lockers\crates.dm"
#include "code\game\objects\structures\crates_lockers\largecrate.dm"
#include "code\game\objects\structures\crates_lockers\vehiclecage.dm"
Expand Down Expand Up @@ -2902,6 +2906,7 @@
#include "code\modules\mapping\map_template.dm"
#include "code\modules\mapping\minimaps.dm"
#include "code\modules\mapping\multiz_helpers.dm"
#include "code\modules\mapping\paint.dm"
#include "code\modules\mapping\shuttle.dm"
#include "code\modules\mapping\submap.dm"
#include "code\modules\mapping\submaps_legacy.dm"
Expand Down
3 changes: 3 additions & 0 deletions code/__DEFINES/_planes+layers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@
#define OBJ_PLANE -35
#define OBJ_PLANE_RENDER_TARGET "OBJ_PLANE"

#define WALL_LAYER (TURF_LAYER+0.3) //! For walls.
#define DEBRIS_LAYER (TURF_LAYER+0.4) /// Cleanable debris.
#define STAIRS_LAYER (TURF_LAYER+0.5) /// Layer for stairs.
#define DOOR_OPEN_LAYER (TURF_LAYER+0.7) /// Under all objects if opened. 2.7 due to tables being at 2.6.
Expand All @@ -184,6 +185,8 @@

#define ABOVE_JUNK_LAYER (OBJ_LAYER+0.1) /// Things that want to be slightly above common objects.
#define DOOR_CLOSED_LAYER (OBJ_LAYER+0.1) /// Doors when closed.
#define LOW_WALL_LAYER (OBJ_LAYER+0.11)
#define GRILLE_LAYER (OBJ_LAYER+0.12)
#define WINDOW_LAYER (OBJ_LAYER+0.2) /// Windows.
#define ON_WINDOW_LAYER (OBJ_LAYER+0.3) /// Ontop of a window.
#define ABOVE_WINDOW_LAYER (OBJ_LAYER+0.4) /// Above full tile windows so wall items are clickable.
Expand Down
3 changes: 3 additions & 0 deletions code/__DEFINES/bitflags.dm
Mazianni marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#define BITSHIFT_LEFT(X, N) (X << (N))
#define BITSHIFT_RIGHT(X, N) (X >> (N))
#define BITFLAG(X) BITSHIFT_LEFT(1, X)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why do we need these defines?

bitshifts are a pretty fundamental thing
i don't think it should be behind a #define, especially when it's longer to type the define out in most cases.

69 changes: 69 additions & 0 deletions code/__DEFINES/color/color.dm
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,70 @@
#define COLOR_PALE_PURPLE_GRAY "#BDA2BA"
#define COLOR_PURPLE_GRAY "#A2819E"
#define COLOR_DEEP_SKY_BLUE "#00e1ff"
#define COLOR_NAVY_BLUE "#000080"
#define COLOR_DARK_GRAY "#404040"
#define COLOR_VIOLET "#9933ff"
#define COLOR_EXPLO_VIOLET "#410083"
#define COLOR_BROWN_ORANGE "#824b28"
#define COLOR_GRAY40 "#666666"
#define COLOR_GRAY20 "#333333"
#define COLOR_GRAY15 "#151515"
#define COLOR_SEDONA "#cc6600"
#define COLOR_DARK_RED "#aa0000"
#define COLOR_PALE_PINK "#bf89ba"
#define COLOR_YELLOW_GRAY "#c9a344"
#define COLOR_PALE_YELLOW "#c1bb7a"
#define COLOR_WARM_YELLOW "#b3863c"
#define COLOR_DARK_GREEN_GRAY "#54654c"
#define COLOR_DARK_BLUE_GRAY "#3e4855"
#define COLOR_SURGERY_BLUE "#e0f2f6"
#define COLOR_SUN "#ec8b2f"
#define COLOR_BLUE_LIGHT "#33ccff"
#define COLOR_BABY_BLUE "#89cff0"
#define COLOR_ACID_CYAN "#00ffc8"
#define COLOR_GRAY80 "#cccccc"
#define COLOR_OFF_WHITE "#eeeeee"
#define COLOR_EGGSHELL "#e4e0d2"
#define COLOR_CLOSET_GOLD "#6d6133"
#define COLOR_NT_RED "#9d2300"
#define COLOR_BOTTLE_GREEN "#1f6b4f"
#define COLOR_PALE_BTL_GREEN "#57967f"
#define COLOR_GUNMETAL "#545c68"
#define COLOR_WALL_GUNMETAL "#353a42"
#define COLOR_STEEL "#a8b0b2"
#define COLOR_MUZZLE_FLASH "#ffffb2"
#define COLOR_CHESTNUT "#996633"
#define COLOR_COPPER "#b87333"
#define COLOR_BEASTY_BROWN "#663300"
#define COLOR_WHEAT "#ffff99"
#define COLOR_CYAN_BLUE "#3366cc"
#define COLOR_CYAN_DARK "#006999"
#define COLOR_LIGHT_CYAN "#66ccff"
#define COLOR_PAKISTAN_GREEN "#006600"
#define COLOR_HULL "#436b8e"
#define COLOR_AMBER "#ffbf00"
#define COLOR_COMMAND_BLUE "#46698c"
#define COLOR_SKY_BLUE "#5ca1cc"
#define COLOR_PALE_ORANGE "#b88a3b"
#define COLOR_CIVIE_GREEN "#b7f27d"
#define COLOR_TITANIUM "#d1e6e3"
#define COLOR_DARK_GUNMETAL "#4c535b"
#define COLOR_BRONZE "#8c7853"
#define COLOR_TAN "#a39682"
#define COLOR_BRASS "#b99d71"
#define COLOR_POLISHED_BRASS "#fdef6e"
#define COLOR_INDIGO "#4b0082"
#define COLOR_ALUMINIUM "#bbbbbb"
#define COLOR_CRYSTAL "#00c8a5"
#define COLOR_DIAMOND "#d8d4ea"

#define WOOD_COLOR_GENERIC "#d5a66e"
#define WOOD_COLOR_RICH "#792f27"
#define WOOD_COLOR_PALE "#d2bc9d"
#define WOOD_COLOR_PALE2 "#e6d2ba"
#define WOOD_COLOR_BLACK "#332521"
#define WOOD_COLOR_CHOCOLATE "#543c30"
#define WOOD_COLOR_YELLOW "#e3994e"

// Color defines used by the assembly detailer.
#define COLOR_ASSEMBLY_BLACK "#545454"
Expand Down Expand Up @@ -63,3 +127,8 @@
#define COLOR_DARKMODE_BACKGROUND "#202020"
#define COLOR_DARKMODE_DARKBACKGROUND "#171717"
#define COLOR_DARKMODE_TEXT "#a4bad6"

#define GLASS_COLOR "#AACCFF"
#define GLASS_COLOR_SILICATE "#7C3A9A"
#define GLASS_COLOR_TINTED "#222222"
#define GLASS_COLOR_FROSTED "#EEEEEE"
15 changes: 15 additions & 0 deletions code/__DEFINES/machines/door.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
// door do_animate animations
#define DOOR_ANIMATION_OPEN "open"
#define DOOR_ANIMATION_CLOSE "close"
#define DOOR_ANIMATION_EMAG "emag"
#define DOOR_ANIMATION_DENY "deny"
#define DOOR_ANIMATION_SPARK "spark"

// airlock var/state

#define AIRLOCK_CLOSED 1
#define AIRLOCK_CLOSING 2
#define AIRLOCK_OPEN 3
#define AIRLOCK_OPENING 4
#define AIRLOCK_DENY 5
#define AIRLOCK_EMAG 6
2 changes: 1 addition & 1 deletion code/datums/wires/airlock.dm
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@
if(WIRE_IDSCAN)
//Sending a pulse through flashes the red light on the door (if the door has power).
if(A.arePowerSystemsOn() && A.density)
A.do_animate("deny")
A.do_animate(DOOR_ANIMATION_DENY)

if(WIRE_MAIN_POWER1, WIRE_MAIN_POWER2)
//Sending a pulse through either one causes a breaker to trip, disabling the door for 10 seconds if backup power is connected, or 1 minute if not (or until backup power comes back on, whichever is shorter).
Expand Down
2 changes: 1 addition & 1 deletion code/game/gamemodes/changeling/powers/electric_lockpick.dm
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
to_chat(user, "<span class='notice'>We send an electrical pulse up our finger, and into \the [target], attempting to open it.</span>")

if(door.density && door.operable())
door.do_animate("spark")
door.do_animate(DOOR_ANIMATION_SPARK)
sleep(6)
//More typechecks, because windoors can't be locked. Fun.
if(istype(target,/obj/machinery/door/airlock))
Expand Down
2 changes: 1 addition & 1 deletion code/game/gamemodes/events.dm
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ var/hadevent = 0
for (var/obj/machinery/door/airlock/security/temp_airlock in A)
spawn(0) temp_airlock.prison_open()

for (var/obj/machinery/door/airlock/glass_security/temp_glassairlock in A)
for (var/obj/machinery/door/airlock/glass/security/temp_glassairlock in A)
spawn(0) temp_glassairlock.prison_open()

for (var/obj/machinery/door_timer/temp_timer in A)
Expand Down
18 changes: 18 additions & 0 deletions code/game/machinery/air_alarm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ GLOBAL_LIST_EMPTY(air_alarms)
TLV["other"] = list(-1.0, -1.0, 0.5, 1.0) // Partial pressure, kpa
TLV["pressure"] = list(ONE_ATMOSPHERE * 0.80, ONE_ATMOSPHERE * 0.90, ONE_ATMOSPHERE * 1.10, ONE_ATMOSPHERE * 1.20) /* kpa */
TLV["temperature"] = list(T0C - 26, T0C, T0C + 40, T0C + 66) // K
setDir(dir)

/obj/machinery/alarm/Initialize(mapload)
. = ..()
Expand Down Expand Up @@ -325,6 +326,23 @@ GLOBAL_LIST_EMPTY(air_alarms)
return TRUE
return FALSE

/obj/machinery/alarm/setDir(ndir)
. = ..()
base_pixel_x = 0
base_pixel_y = 0
var/turf/T = get_step(get_turf(src), turn(dir, 180))
if(istype(T) && T.density)
switch(dir)
if(NORTH)
base_pixel_y = -21
if(SOUTH)
base_pixel_y = 21
if(WEST)
base_pixel_x = 21
if(EAST)
base_pixel_x = -21
reset_pixel_offsets()

/obj/machinery/alarm/update_icon()
cut_overlays()

Expand Down
20 changes: 19 additions & 1 deletion code/game/machinery/camera/camera.dm
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/obj/machinery/camera
name = "security camera"
desc = "It's used to monitor rooms."
icon = 'icons/obj/monitors_vr.dmi'
icon = 'icons/obj/monitors.dmi'
icon_state = "camera"
use_power = USE_POWER_ACTIVE
idle_power_usage = 5
Expand Down Expand Up @@ -65,6 +65,7 @@
if(!c_tag)
var/area/A = get_area(src)
c_tag = "[A ? A.name : "Unknown"] #[rand(111,999)]"
update_icon()
return ..()

/obj/machinery/camera/Destroy()
Expand Down Expand Up @@ -294,6 +295,23 @@
else
icon_state = initial(icon_state)

/obj/machinery/camera/setDir(ndir)
. = ..()
base_pixel_x = 0
base_pixel_y = 0
var/turf/T = get_step(get_turf(src), turn(src.dir, 180))
for(var/obj/O in T.contents)
if(O.density)
switch(dir)
if(SOUTH)
base_pixel_y = 21
if(WEST)
base_pixel_x = 10
if(EAST)
base_pixel_x = -10
break
reset_pixel_offsets()

/obj/machinery/camera/proc/triggerCameraAlarm(duration = 0)
alarm_on = 1
camera_alarm.triggerAlarm(loc, src, duration)
Expand Down
10 changes: 10 additions & 0 deletions code/game/machinery/computer/timeclock_vr.dm
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,9 @@
makeOnDuty(params["switch-to-onduty-rank"], params["switch-to-onduty-assignment"])
usr.put_in_hands_or_drop(card)
card = null
flick(icon, "timeclock_approved")
else
flick(icon, "timeclock_denied")
update_icon()
return TRUE
if("switch-to-offduty")
Expand All @@ -142,6 +145,9 @@
makeOffDuty()
usr.put_in_hands_or_drop(card)
card = null
flick(icon, "timeclock_approved")
else
flick(icon, "timeclock_denied")
update_icon()
return TRUE

Expand Down Expand Up @@ -232,16 +238,20 @@
/obj/machinery/computer/timeclock/proc/checkFace()
if(!card)
to_chat(usr, "<span class='notice'>No ID is inserted.</span>")
flick(icon, "timeclock_denied")
return FALSE
var/mob/living/carbon/human/H = usr
if(!(istype(H)))
to_chat(usr, "<span class='warning'>Invalid user detected. Access denied.</span>")
flick(icon, "timeclock_denied")
return FALSE
else if((H.wear_mask && (H.wear_mask.inv_hide_flags & HIDEFACE)) || (H.head && (H.head.inv_hide_flags & HIDEFACE))) //Face hiding bad
to_chat(usr, "<span class='warning'>Facial recognition scan failed due to physical obstructions. Access denied.</span>")
flick(icon, "timeclock_denied")
return FALSE
else if(H.get_face_name() == "Unknown" || !(H.real_name == card.registered_name))
to_chat(usr, "<span class='warning'>Facial recognition scan failed. Access denied.</span>")
flick(icon, "timeclock_denied")
return FALSE
else
return TRUE
Expand Down
Loading