Merge branch 'ambientocclusion' of https://github.com/Markolie/Paradise into lighting

This commit is contained in:
Mark van Alphen
2019-04-22 18:52:55 +02:00
68 changed files with 310 additions and 123 deletions
+8 -3
View File
@@ -11,7 +11,8 @@ Pipelines + Other Objects -> Pipe network
GLOBAL_DATUM_INIT(pipe_icon_manager, /datum/pipe_icon_manager, new())
/obj/machinery/atmospherics
anchored = 1
layer = 2.4 //under wires with their 2.44
layer = GAS_PIPE_HIDDEN_LAYER //under wires
plane = FLOOR_PLANE
idle_power_usage = 0
active_power_usage = 0
power_channel = ENVIRON
@@ -61,10 +62,14 @@ GLOBAL_DATUM_INIT(pipe_icon_manager, /datum/pipe_icon_manager, new())
// Icons/overlays/underlays
/obj/machinery/atmospherics/update_icon()
return null
var/turf/T = loc
if(level == 2 || !T.intact)
plane = GAME_PLANE
else
plane = FLOOR_PLANE
/obj/machinery/atmospherics/proc/update_pipe_image()
pipe_image = image(src, loc, layer = 20, dir = dir) //the 20 puts it above Byond's darkness (not its opacity view)
pipe_image = image(src, loc, layer = ABOVE_HUD_LAYER, dir = dir) //the 20 puts it above Byond's darkness (not its opacity view)
pipe_image.plane = HUD_PLANE
/obj/machinery/atmospherics/proc/check_icon_cache(var/safety = 0)
@@ -112,6 +112,8 @@
..()
/obj/machinery/atmospherics/binary/circulator/update_icon()
..()
if(stat & (BROKEN|NOPOWER))
icon_state = "circ[side]-p"
else if(last_pressure_delta > 0)
@@ -71,6 +71,8 @@
add_underlay(T, node2, dir)
/obj/machinery/atmospherics/binary/dp_vent_pump/update_icon(var/safety = 0)
..()
if(!check_icon_cache())
return
@@ -28,6 +28,7 @@
return ..()
/obj/machinery/atmospherics/binary/passive_gate/update_icon()
..()
icon_state = "[on ? "on" : "off"]"
/obj/machinery/atmospherics/binary/passive_gate/update_underlays()
@@ -39,6 +39,8 @@ Thus, the two variables affect pump operation are set in New():
on = 1
/obj/machinery/atmospherics/binary/pump/update_icon()
..()
if(!powered())
icon_state = "off"
else
@@ -16,6 +16,8 @@
icon_state = "map_valve1"
/obj/machinery/atmospherics/binary/valve/update_icon(animation)
..()
if(animation)
flick("valve[src.open][!src.open]",src)
else
@@ -43,6 +43,8 @@ Thus, the two variables affect pump operation are set in New():
set_frequency(frequency)
/obj/machinery/atmospherics/binary/volume_pump/update_icon()
..()
if(!powered())
icon_state = "off"
else
@@ -72,6 +72,8 @@
update_ports()
/obj/machinery/atmospherics/omni/update_icon()
..()
if(stat & NOPOWER)
overlays = overlays_off
on = 0
@@ -83,8 +85,6 @@
underlays = underlays_current
return
/obj/machinery/atmospherics/omni/proc/error_check()
return
@@ -40,6 +40,8 @@ Filter types:
radio_connection = SSradio.add_object(src, frequency, RADIO_ATMOSIA)
/obj/machinery/atmospherics/trinary/filter/update_icon()
..()
if(flipped)
icon_state = "m"
else
@@ -17,6 +17,8 @@
flipped = 1
/obj/machinery/atmospherics/trinary/mixer/update_icon(safety = 0)
..()
if(flipped)
icon_state = "m"
else
@@ -135,6 +135,7 @@
/obj/machinery/atmospherics/trinary/tvalve/digital/update_icon()
..()
if(!powered())
icon_state = "tvalvenopower"
@@ -13,6 +13,8 @@
var/current_heat_capacity = 50000 //totally random
/obj/machinery/atmospherics/unary/cold_sink/update_icon()
..()
if(node)
icon_state = "intact_[on?("on"):("off")]"
else
@@ -20,8 +22,6 @@
on = 0
return
/obj/machinery/atmospherics/unary/cold_sink/process_atmos()
..()
if(!on)
@@ -9,12 +9,12 @@
var/update_cycle
/obj/machinery/atmospherics/unary/generator_input/update_icon()
..()
if(node)
icon_state = "intact"
else
icon_state = "exposed"
return
/obj/machinery/atmospherics/unary/generator_input/proc/return_exchange_air()
return air_contents
@@ -13,13 +13,13 @@
burn_state = LAVA_PROOF
/obj/machinery/atmospherics/unary/heat_exchanger/update_icon()
..()
if(node)
icon_state = "intact"
else
icon_state = "exposed"
return
/obj/machinery/atmospherics/unary/heat_exchanger/atmos_init()
if(!partner)
var/partner_connect = turn(dir,180)
@@ -13,6 +13,8 @@
var/current_heat_capacity = 50000 //totally random
/obj/machinery/atmospherics/unary/heat_reservoir/update_icon()
..()
if(node)
icon_state = "intact_[on?("on"):("off")]"
else
@@ -20,8 +22,6 @@
on = 0
return
/obj/machinery/atmospherics/unary/heat_reservoir/process_atmos()
..()
if(!on)
@@ -38,6 +38,8 @@
return ..()
/obj/machinery/atmospherics/unary/outlet_injector/update_icon()
..()
if(!powered())
icon_state = "off"
else
@@ -14,6 +14,8 @@
var/oxygen_content = 10
/obj/machinery/atmospherics/unary/oxygen_generator/update_icon()
..()
if(node)
icon_state = "intact_[on?("on"):("off")]"
else
@@ -21,8 +23,6 @@
on = 0
return
/obj/machinery/atmospherics/unary/oxygen_generator/New()
..()
@@ -18,6 +18,7 @@
return ..()
/obj/machinery/atmospherics/unary/portables_connector/update_icon()
..()
icon_state = "connector"
/obj/machinery/atmospherics/unary/portables_connector/update_underlays()
@@ -11,10 +11,12 @@
desc = "Transfers heat to and from an area"
/obj/machinery/atmospherics/unary/thermal_plate/update_icon()
var/prefix=""
..()
var/prefix = ""
//var/suffix="_idle" // Also available: _heat, _cool
if(level == 1 && istype(loc, /turf/simulated))
prefix="h"
prefix = "h"
icon_state = "[prefix]off"
/obj/machinery/atmospherics/unary/thermal_plate/process_atmos()
@@ -77,6 +77,10 @@
air_contents.volume = 1000
/obj/machinery/atmospherics/unary/vent_pump/update_icon(var/safety = 0)
..()
plane = FLOOR_PLANE
if(!check_icon_cache())
return
@@ -91,6 +91,10 @@
return 1
/obj/machinery/atmospherics/unary/vent_scrubber/update_icon(var/safety = 0)
..()
plane = FLOOR_PLANE
if(!check_icon_cache())
return
+2
View File
@@ -55,6 +55,8 @@
node.update_underlays()
/obj/machinery/atmospherics/pipe/cap/update_icon(var/safety = 0)
..()
if(!check_icon_cache())
return
+2
View File
@@ -116,6 +116,8 @@
node3.update_underlays()
/obj/machinery/atmospherics/pipe/manifold/update_icon(var/safety = 0)
..()
if(!check_icon_cache())
return
+2
View File
@@ -90,6 +90,8 @@
node4.update_underlays()
/obj/machinery/atmospherics/pipe/manifold4w/update_icon(var/safety = 0)
..()
if(!check_icon_cache())
return
@@ -137,6 +137,8 @@
node2.update_underlays()
/obj/machinery/atmospherics/pipe/simple/update_icon(var/safety = 0)
..()
if(!check_icon_cache())
return
@@ -28,6 +28,8 @@
icon_state = "map_universal"
/obj/machinery/atmospherics/pipe/simple/hidden/universal/update_icon(var/safety = 0)
..()
if(!check_icon_cache())
return
@@ -39,6 +39,8 @@
icon_state = "map_universal"
/obj/machinery/atmospherics/pipe/simple/visible/universal/update_icon(var/safety = 0)
..()
if(!check_icon_cache())
return
+3 -1
View File
@@ -6,7 +6,9 @@
#define PLANE_SPACE -95
#define PLANE_SPACE_PARALLAX -90
#define GAME_PLANE 0
#define FLOOR_PLANE -2
#define GAME_PLANE -1
#define BLACKNESS_PLANE 0 //To keep from conflicts with SEE_BLACKNESS internals
#define SPACE_LAYER 1.8
//#define TURF_LAYER 2 //For easy recordkeeping; this is a byond define
+4 -1
View File
@@ -401,4 +401,7 @@
#define GHOST_ORBIT_TRIANGLE "triangle"
#define GHOST_ORBIT_HEXAGON "hexagon"
#define GHOST_ORBIT_SQUARE "square"
#define GHOST_ORBIT_PENTAGON "pentagon"
#define GHOST_ORBIT_PENTAGON "pentagon"
// Filters
#define FILTER_AMBIENT_OCCLUSION filter(type="drop_shadow", x=0, y=-2, size=4, border=4, color="#04080FAA")
+4 -2
View File
@@ -29,10 +29,12 @@
#define UI_DARKMODE 131072
#define DISABLE_KARMA 262144
#define CHAT_NO_MENTORTICKETLOGS 524288
#define TYPING_ONCE 1048576
#define AMBIENT_OCCLUSION 2097152
#define TOGGLES_DEFAULT (CHAT_OOC|CHAT_DEAD|CHAT_GHOSTEARS|CHAT_GHOSTSIGHT|CHAT_PRAYER|CHAT_RADIO|CHAT_LOOC|MEMBER_PUBLIC|DONATOR_PUBLIC)
#define TOGGLES_TOTAL 4194304 // If you add or remove a preference toggle above, make sure you update this define with the total value of the toggles combined.
#define TOGGLES_DEFAULT (CHAT_OOC|CHAT_DEAD|CHAT_GHOSTEARS|CHAT_GHOSTSIGHT|CHAT_PRAYER|CHAT_RADIO|CHAT_LOOC|MEMBER_PUBLIC|DONATOR_PUBLIC|AMBIENT_OCCLUSION)
// Admin attack logs filter system, see /proc/add_attack_logs and /proc/msg_admin_attack
#define ATKLOG_ALL 0
+1 -1
View File
@@ -114,7 +114,7 @@
return
if(QDELETED(A))
return
if((A.smooth & SMOOTH_TRUE) || (A.smooth & SMOOTH_MORE))
if(A.smooth & (SMOOTH_TRUE | SMOOTH_MORE))
var/adjacencies = calculate_adjacencies(A)
if(A.smooth & SMOOTH_DIAGONAL)
+14
View File
@@ -2029,3 +2029,17 @@ var/mob/dview/dview_mob = new
/proc/pass()
return
/proc/params2turf(scr_loc, turf/origin, client/C)
if(!scr_loc)
return null
var/tX = splittext(scr_loc, ",")
var/tY = splittext(tX[2], ":")
var/tZ = origin.z
tY = tY[1]
tX = splittext(tX[1], ":")
tX = tX[1]
var/list/actual_view = getviewsize(C ? C.view : world.view)
tX = Clamp(origin.x + text2num(tX) - round(actual_view[1] / 2) - 1, 1, world.maxx)
tY = Clamp(origin.y + text2num(tY) - round(actual_view[2] / 2) - 1, 1, world.maxy)
return locate(tX, tY, tZ)
+20 -2
View File
@@ -399,7 +399,25 @@
icon_state = "passage0"
plane = CLICKCATCHER_PLANE
mouse_opacity = MOUSE_OPACITY_OPAQUE
screen_loc = "CENTER-7,CENTER-7"
screen_loc = "CENTER"
#define MAX_SAFE_BYOND_ICON_SCALE_TILES (MAX_SAFE_BYOND_ICON_SCALE_PX / world.icon_size)
#define MAX_SAFE_BYOND_ICON_SCALE_PX (33 * 32) //Not using world.icon_size on purpose.
/obj/screen/click_catcher/proc/UpdateGreed(view_size_x = 15, view_size_y = 15)
var/icon/newicon = icon('icons/mob/screen_gen.dmi', "catcher")
var/ox = min(MAX_SAFE_BYOND_ICON_SCALE_TILES, view_size_x)
var/oy = min(MAX_SAFE_BYOND_ICON_SCALE_TILES, view_size_y)
var/px = view_size_x * world.icon_size
var/py = view_size_y * world.icon_size
var/sx = min(MAX_SAFE_BYOND_ICON_SCALE_PX, px)
var/sy = min(MAX_SAFE_BYOND_ICON_SCALE_PX, py)
newicon.Scale(sx, sy)
icon = newicon
screen_loc = "CENTER-[(ox-1)*0.5],CENTER-[(oy-1)*0.5]"
var/matrix/M = new
M.Scale(px/sx, py/sy)
transform = M
/obj/screen/click_catcher/Click(location, control, params)
var/list/modifiers = params2list(params)
@@ -407,6 +425,6 @@
var/mob/living/carbon/C = usr
C.swap_hand()
else
var/turf/T = screen_loc2turf(modifiers["screen-loc"], get_turf(usr))
var/turf/T = params2turf(modifiers["screen-loc"], get_turf(usr))
T.Click(location, control, params)
return 1
-2
View File
@@ -40,7 +40,6 @@
using.icon = ui_style
using.icon_state = "swap_1"
using.screen_loc = ui_swaphand1
using.layer = 19
static_inventory += using
using = new /obj/screen/swap_hand()
@@ -48,7 +47,6 @@
using.icon = ui_style
using.icon_state = "swap_2"
using.screen_loc = ui_swaphand2
using.layer = 19
static_inventory += using
mymob.zone_sel = new /obj/screen/zone_sel()
+1
View File
@@ -54,6 +54,7 @@
icon_state = "default"
screen_loc = "CENTER-7,CENTER-7"
layer = FULLSCREEN_LAYER
plane = FULLSCREEN_PLANE
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
var/severity = 0
+25 -4
View File
@@ -38,6 +38,8 @@
var/obj/screen/movable/action_button/hide_toggle/hide_actions_toggle
var/action_buttons_hidden = 0
var/list/obj/screen/plane_master/plane_masters = list() // see "appearance_flags" in the ref, assoc list of "[plane]" = object
/mob/proc/create_mob_hud()
if(client && !hud_used)
hud_used = new /datum/hud(src)
@@ -47,6 +49,11 @@
hide_actions_toggle = new
hide_actions_toggle.InitialiseIcon(mymob)
for(var/mytype in subtypesof(/obj/screen/plane_master))
var/obj/screen/plane_master/instance = new mytype()
plane_masters["[instance.plane]"] = instance
instance.backdrop(mymob)
/datum/hud/Destroy()
if(mymob.hud_used == src)
mymob.hud_used = null
@@ -83,14 +90,16 @@
nightvisionicon = null
devilsouldisplay = null
QDEL_LIST_ASSOC_VAL(plane_masters)
mymob = null
return ..()
/datum/hud/proc/show_hud(version = 0)
if(!ismob(mymob))
return 0
return FALSE
if(!mymob.client)
return 0
return FALSE
mymob.client.screen = list()
@@ -162,13 +171,25 @@
mymob.update_action_buttons(1)
reorganize_alerts()
reload_fullscreen()
plane_masters_update()
/datum/hud/proc/plane_masters_update()
// Plane masters are always shown to OUR mob, never to observers
for(var/thing in plane_masters)
var/obj/screen/plane_master/PM = plane_masters[thing]
PM.backdrop(mymob)
mymob.client.screen += PM
/datum/hud/human/show_hud(version = 0)
..()
. = ..()
if(!.)
return
hidden_inventory_update()
/datum/hud/robot/show_hud(version = 0)
..()
. = ..()
if(!.)
return
update_robot_modules_display()
/datum/hud/proc/hidden_inventory_update()
+34
View File
@@ -0,0 +1,34 @@
/obj/screen/plane_master
screen_loc = "CENTER"
icon_state = "blank"
appearance_flags = PLANE_MASTER|NO_CLIENT_COLOR
blend_mode = BLEND_OVERLAY
var/show_alpha = 255
var/hide_alpha = 0
/obj/screen/plane_master/proc/Show(override)
alpha = override || show_alpha
/obj/screen/plane_master/proc/Hide(override)
alpha = override || hide_alpha
//Why do plane masters need a backdrop sometimes? Read http://www.byond.com/forum/?post=2141928
//Trust me, you need one. Period. If you don't think you do, you're doing something extremely wrong.
/obj/screen/plane_master/proc/backdrop(mob/mymob)
/obj/screen/plane_master/floor
name = "floor plane master"
plane = FLOOR_PLANE
appearance_flags = PLANE_MASTER
blend_mode = BLEND_OVERLAY
/obj/screen/plane_master/game_world
name = "game world plane master"
plane = GAME_PLANE
appearance_flags = PLANE_MASTER //should use client color
blend_mode = BLEND_OVERLAY
/obj/screen/plane_master/game_world/backdrop(mob/mymob)
filters -= FILTER_AMBIENT_OCCLUSION
if(istype(mymob) && mymob.client && mymob.client.prefs && (mymob.client.prefs.toggles & AMBIENT_OCCLUSION))
filters += FILTER_AMBIENT_OCCLUSION
+2 -2
View File
@@ -226,8 +226,8 @@
A.screen_loc = "CENTER[x]:16,SOUTH+[y]:7"
else
A.screen_loc = "CENTER+[x]:16,SOUTH+[y]:7"
A.layer = 20
A.plane = HUD_PLANE
A.layer = ABOVE_HUD_LAYER
A.plane = ABOVE_HUD_PLANE
x++
if(x == 4)
+10 -6
View File
@@ -10,7 +10,7 @@
name = ""
icon = 'icons/mob/screen_gen.dmi'
layer = HUD_LAYER_SCREEN
plane = HUD_PLANE
plane = ABOVE_HUD_PLANE
unacidable = 1
var/obj/master = null //A reference to the object in the slot. Grabs or items, generally.
var/datum/hud/hud = null
@@ -47,7 +47,8 @@
/obj/screen/drop
name = "drop"
icon_state = "act_drop"
layer = 19
layer = HUD_LAYER
plane = HUD_PLANE
/obj/screen/drop/Click()
usr.drop_item_v()
@@ -143,8 +144,9 @@
name = "resist"
icon = 'icons/mob/screen_midnight.dmi'
icon_state = "act_resist"
layer = 19
layer = HUD_LAYER
plane = HUD_PLANE
/obj/screen/resist/Click()
if(isliving(usr))
var/mob/living/L = usr
@@ -327,7 +329,8 @@
/obj/screen/inventory
var/slot_id //The indentifier for the slot. It has nothing to do with ID cards.
var/list/object_overlays = list()
layer = 19
layer = HUD_LAYER
plane = HUD_PLANE
/obj/screen/inventory/MouseEntered()
..()
@@ -417,7 +420,8 @@
return 1
/obj/screen/swap_hand
layer = 19
layer = HUD_LAYER
plane = HUD_PLANE
name = "swap hand"
/obj/screen/swap_hand/Click()
+2 -2
View File
@@ -65,8 +65,8 @@ var/const/tk_maxrange = 15
flags = NOBLUDGEON | ABSTRACT | DROPDEL
//item_state = null
w_class = WEIGHT_CLASS_GIGANTIC
layer = 20
plane = HUD_PLANE
layer = ABOVE_HUD_LAYER
plane = ABOVE_HUD_PLANE
var/last_throw = 0
var/atom/movable/focus = null
+1
View File
@@ -16,6 +16,7 @@
// area from any other instances already present (meaning you can have
// separate APCs, and so on)
var/there_can_be_many = 0
plane = BLACKNESS_PLANE //Keeping this on the default plane, GAME_PLANE, will make area overlays fail to render on FLOOR_PLANE.
/area/New()
+2 -1
View File
@@ -1,5 +1,6 @@
/atom
layer = 2
layer = TURF_LAYER
plane = GAME_PLANE
var/level = 2
var/flags = NONE
var/flags_2 = NONE
+8 -8
View File
@@ -67,32 +67,32 @@ datum/hSB
P.wear_suit.plane = initial(P.wear_suit.plane)
P.wear_suit = null
P.wear_suit = new/obj/item/clothing/suit/space(P)
P.wear_suit.layer = 20
P.wear_suit.plane = HUD_PLANE
P.wear_suit.layer = ABOVE_HUD_LAYER
P.wear_suit.plane = ABOVE_HUD_PLANE
if(P.head)
P.head.loc = P.loc
P.head.layer = initial(P.head.layer)
P.head.plane = initial(P.head.plane)
P.head = null
P.head = new/obj/item/clothing/head/helmet/space(P)
P.head.layer = 20
P.head.plane = HUD_PLANE
P.head.layer = ABOVE_HUD_LAYER
P.head.plane = ABOVE_HUD_PLANE
if(P.wear_mask)
P.wear_mask.loc = P.loc
P.wear_mask.layer = initial(P.wear_mask.layer)
P.wear_mask.plane = initial(P.wear_mask.plane)
P.wear_mask = null
P.wear_mask = new/obj/item/clothing/mask/gas(P)
P.wear_mask.layer = 20
P.wear_mask.plane = HUD_PLANE
P.wear_mask.layer = ABOVE_HUD_LAYER
P.wear_mask.plane = ABOVE_HUD_PLANE
if(P.back)
P.back.loc = P.loc
P.back.layer = initial(P.back.layer)
P.back.plane = initial(P.back.plane)
P.back = null
P.back = new/obj/item/tank/jetpack(P)
P.back.layer = 20
P.back.plane = HUD_PLANE
P.back.layer = ABOVE_HUD_LAYER
P.back.plane = ABOVE_HUD_PLANE
P.internal = P.back
if("hsbmetal")
var/obj/item/stack/sheet/hsb = new/obj/item/stack/sheet/metal
@@ -107,6 +107,8 @@ var/list/possibleShadowlingNames = list("U'ruan", "Y`shej", "Nex", "Hel-uae", "N
H.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/collective_mind(null))
H.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/shadowling_regenarmor(null))
H.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/shadowling_extend_shuttle(null))
QDEL_NULL(H.hud_used)
H.hud_used = new /datum/hud/human(H, ui_style2icon(H.client.prefs.UI_style), H.client.prefs.UI_style_color, H.client.prefs.UI_style_alpha)
H.hud_used.show_hud(H.hud_used.hud_version)
+1
View File
@@ -3,6 +3,7 @@
icon = 'icons/obj/device.dmi'
icon_state = "motion3"
layer = 3
plane = FLOOR_PLANE
anchored = 1.0
armor = list(melee = 50, bullet = 20, laser = 20, energy = 20, bomb = 0, bio = 0, rad = 0)
var/uses = 20
+1
View File
@@ -44,6 +44,7 @@ var/list/holopads = list()
idle_power_usage = 5
active_power_usage = 100
layer = TURF_LAYER+0.1 //Preventing mice and drones from sneaking under them.
plane = FLOOR_PLANE
armor = list(melee = 50, bullet = 20, laser = 20, energy = 20, bomb = 0, bio = 0, rad = 0)
var/list/masters = list()//List of living mobs that use the holopad
var/list/holorays = list()//Holoray-mob link.
+1
View File
@@ -3,6 +3,7 @@
desc = "It's useful for igniting plasma."
icon = 'icons/obj/stationobjs.dmi'
icon_state = "igniter1"
plane = FLOOR_PLANE
armor = list(melee = 50, bullet = 30, laser = 70, energy = 50, bomb = 20, bio = 0, rad = 0)
var/id = null
var/on = 1.0
+2 -2
View File
@@ -183,8 +183,8 @@
qdel(I)
qdel(J)
H.icon = HI
H.layer = 25
H.plane = HUD_PLANE
H.layer = ABOVE_HUD_LAYER
H.plane = ABOVE_HUD_PLANE
usr.mapobjs += H
#else
+1
View File
@@ -16,6 +16,7 @@
return FALSE
/obj/effect/decal
plane = FLOOR_PLANE
var/no_scoop = FALSE //if it has this, don't let it be scooped up
var/no_clear = FALSE //if it has this, don't delete it when its' scooped up
var/list/scoop_reagents = null
@@ -37,4 +37,5 @@
/obj/effect/temp_visual/cult/turf/open/floor
icon_state = "floorglow"
duration = 5
duration = 5
plane = FLOOR_PLANE
@@ -151,8 +151,8 @@
src.boxes.screen_loc = "[tx]:,[ty] to [mx],[my]"
for(var/obj/O in src.contents)
O.screen_loc = "[cx],[cy]"
O.layer = 20
O.plane = HUD_PLANE
O.layer = ABOVE_HUD_LAYER
O.plane = ABOVE_HUD_PLANE
cx++
if(cx > mx)
cx = tx
@@ -171,8 +171,8 @@
ND.sample_object.mouse_opacity = MOUSE_OPACITY_OPAQUE
ND.sample_object.screen_loc = "[cx]:16,[cy]:16"
ND.sample_object.maptext = "<font color='white'>[(ND.number > 1)? "[ND.number]" : ""]</font>"
ND.sample_object.layer = 20
ND.sample_object.plane = HUD_PLANE
ND.sample_object.layer = ABOVE_HUD_LAYER
ND.sample_object.plane = ABOVE_HUD_PLANE
cx++
if(cx > (4+cols))
cx = 4
@@ -182,8 +182,8 @@
O.mouse_opacity = MOUSE_OPACITY_OPAQUE //This is here so storage items that spawn with contents correctly have the "click around item to equip"
O.screen_loc = "[cx]:16,[cy]:16"
O.maptext = ""
O.layer = 20
O.plane = HUD_PLANE
O.layer = ABOVE_HUD_LAYER
O.plane = ABOVE_HUD_PLANE
cx++
if(cx > (4+cols))
cx = 4
@@ -332,8 +332,8 @@
if(ismob(loc))
W.dropped(usr)
if(ismob(new_location))
W.layer = 20
W.plane = HUD_PLANE
W.layer = ABOVE_HUD_LAYER
W.plane = ABOVE_HUD_PLANE
else
W.layer = initial(W.layer)
W.plane = initial(W.plane)
@@ -447,17 +447,18 @@
else
verbs -= /obj/item/storage/verb/toggle_gathering_mode
src.boxes = new /obj/screen/storage( )
src.boxes.name = "storage"
src.boxes.master = src
src.boxes.icon_state = "block"
src.boxes.screen_loc = "7,7 to 10,8"
src.boxes.layer = 19
src.closer = new /obj/screen/close( )
src.closer.master = src
src.closer.icon_state = "x"
src.closer.layer = 20
src.closer.plane = HUD_PLANE
boxes = new /obj/screen/storage( )
boxes.name = "storage"
boxes.master = src
boxes.icon_state = "block"
boxes.screen_loc = "7,7 to 10,8"
boxes.layer = HUD_LAYER
boxes.plane = HUD_PLANE
closer = new /obj/screen/close( )
closer.master = src
closer.icon_state = "x"
closer.layer = ABOVE_HUD_LAYER
closer.plane = ABOVE_HUD_PLANE
orient2hud()
/obj/item/storage/Destroy()
@@ -469,7 +470,7 @@
return ..()
/obj/item/storage/emp_act(severity)
if(!istype(src.loc, /mob/living))
if(!istype(loc, /mob/living))
for(var/obj/O in contents)
O.emp_act(severity)
..()
+1
View File
@@ -113,6 +113,7 @@
anchored = TRUE
density = FALSE
layer = TURF_LAYER
plane = FLOOR_PLANE
icon_state = "weeds"
max_integrity = 15
var/obj/structure/alien/weeds/node/linked_node = null
+1
View File
@@ -7,6 +7,7 @@
anchored = 1.0
armor = list(melee = 50, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0)
layer = 2.3 //under pipes
plane = FLOOR_PLANE
// flags = CONDUCT
/obj/structure/lattice/New()
+1 -1
View File
@@ -17,7 +17,7 @@ var/list/icons_to_ignore_at_floor_init = list("damaged1","damaged2","damaged3","
name = "floor"
icon = 'icons/turf/floors.dmi'
icon_state = "dont_use_this_floor"
plane = FLOOR_PLANE
var/icon_regular_floor = "floor" //used to remember what icon the tile should have by default
var/icon_plating = "plating"
thermal_conductivity = 0.040
+14 -4
View File
@@ -333,6 +333,8 @@
if(!prefs)
prefs = new /datum/preferences(src)
preferences_datums[ckey] = prefs
else
prefs.parent = src
prefs.last_ip = address //these are gonna be used for banning
prefs.last_id = computer_id //these are gonna be used for banning
if(world.byond_version >= 511 && byond_version >= 511 && prefs.clientfps)
@@ -393,10 +395,8 @@
if(establish_db_connection())
to_chat(src,"<span class='notice'>You have enabled karma gains.")
if(!void)
void = new()
screen += void
generate_clickcatcher()
apply_clickcatcher()
if(!winexists(src, "asset_cache_browser")) // The client is using a custom skin, tell them.
to_chat(src, "<span class='warning'>Unable to access asset cache browser, if you are using a custom skin file, please allow DS to download the updated version, if you are not, then make a bug report. This is not a critical issue but can cause issues with resource downloading, as it is impossible to know when extra resources arrived to you.</span>")
@@ -772,3 +772,13 @@
winset(src, "rpane.changelog", "background-color=#40628a;text-color=#FFFFFF")
else
winset(src, "rpane.changelog", "background-color=none;text-color=#000000")
/client/proc/generate_clickcatcher()
if(!void)
void = new()
screen += void
/client/proc/apply_clickcatcher()
generate_clickcatcher()
var/list/actualview = getviewsize(view)
void.UpdateGreed(actualview[1],actualview[2])
+10 -17
View File
@@ -183,7 +183,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
// 0 = character settings, 1 = game preferences
var/current_tab = TAB_CHAR
// OOC Metadata:
// OOC Metadata:
var/metadata = ""
var/slot_name = ""
@@ -452,6 +452,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
dat += "<b>Donator Publicity:</b> <a href='?_src_=prefs;preference=donor_public'><b>[(toggles & DONATOR_PUBLIC) ? "Public" : "Hidden"]</b></a><br>"
dat += "<b>Fancy NanoUI:</b> <a href='?_src_=prefs;preference=nanoui'>[(nanoui_fancy) ? "Yes" : "No"]</a><br>"
dat += "<b>FPS:</b> <a href='?_src_=prefs;preference=clientfps;task=input'>[clientfps]</a><br>"
dat += "<b>Ambient Occlusion:</b> <a href='?_src_=prefs;preference=ambientocclusion'><b>[toggles & AMBIENT_OCCLUSION ? "Enabled" : "Disabled"]</b></a><br>"
dat += "<b>Ghost Ears:</b> <a href='?_src_=prefs;preference=ghost_ears'><b>[(toggles & CHAT_GHOSTEARS) ? "All Speech" : "Nearest Creatures"]</b></a><br>"
dat += "<b>Ghost Sight:</b> <a href='?_src_=prefs;preference=ghost_sight'><b>[(toggles & CHAT_GHOSTSIGHT) ? "All Emotes" : "Nearest Creatures"]</b></a><br>"
dat += "<b>Ghost Radio:</b> <a href='?_src_=prefs;preference=ghost_radio'><b>[(toggles & CHAT_GHOSTRADIO) ? "All Chatter" : "Nearest Speakers"]</b></a><br>"
@@ -1921,22 +1922,6 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
if(world.byond_version >= 511 && user.client && user.client.byond_version >= 511)
parent.fps = clientfps
/*
if("skin_style")
var/skin_style_name = input(user, "Select a new skin style") as null|anything in list("default1", "default2", "default3")
if(!skin_style_name) return
*/
/* if("spawnpoint")
var/list/spawnkeys = list()
for(var/S in spawntypes)
spawnkeys += S
var/choice = input(user, "Where would you like to spawn when latejoining?") as null|anything in spawnkeys
if(!choice || !spawntypes[choice])
spawnpoint = "Arrivals Shuttle"
return
spawnpoint = choice */
else
switch(href_list["preference"])
if("publicity")
@@ -2081,6 +2066,14 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
if(href_list["tab"])
current_tab = text2num(href_list["tab"])
if("ambientocclusion")
toggles ^= AMBIENT_OCCLUSION
if(parent && parent.screen && parent.screen.len)
var/obj/screen/plane_master/game_world/PM = locate(/obj/screen/plane_master/game_world) in parent.screen
PM.filters -= FILTER_AMBIENT_OCCLUSION
if(toggles & AMBIENT_OCCLUSION)
PM.filters += FILTER_AMBIENT_OCCLUSION
ShowChoices(user)
return 1
@@ -18,7 +18,7 @@
ghost_anonsay,
exp,
clientfps,
atklog
atklog,
FROM [format_table_name("player")]
WHERE ckey='[C.ckey]'"}
)
@@ -55,7 +55,7 @@
ooccolor = sanitize_hexcolor(ooccolor, initial(ooccolor))
UI_style = sanitize_inlist(UI_style, list("White", "Midnight"), initial(UI_style))
default_slot = sanitize_integer(default_slot, 1, max_save_slots, initial(default_slot))
toggles = sanitize_integer(toggles, 0, 2097151, initial(toggles))
toggles = sanitize_integer(toggles, 0, TOGGLES_TOTAL, initial(toggles))
sound = sanitize_integer(sound, 0, 65535, initial(sound))
UI_style_color = sanitize_hexcolor(UI_style_color, initial(UI_style_color))
UI_style_alpha = sanitize_integer(UI_style_alpha, 0, 255, initial(UI_style_alpha))
@@ -230,7 +230,6 @@
to_chat(usr, "<span class='notice'>You have disabled karma gains.")
else
to_chat(usr, "<span class='notice'>You have enabled karma gains.")
return
/client/verb/toggle_popup_limiter()
set name = "Toggle Text Popup Limiter"
@@ -242,4 +241,4 @@
to_chat(usr, "<span class='notice'>You have enabled text popup limiting.")
else
to_chat(usr, "<span class='notice'>You have disabled text popup limiting.")
return
+2 -1
View File
@@ -58,7 +58,8 @@
blueeffect.screen_loc = "WEST,SOUTH to EAST,NORTH"
blueeffect.icon = 'icons/effects/effects.dmi'
blueeffect.icon_state = "shieldsparkles"
blueeffect.layer = 17
blueeffect.layer = FLASH_LAYER
blueeffect.plane = FULLSCREEN_PLANE
blueeffect.mouse_opacity = MOUSE_OPACITY_TRANSPARENT
M.client.screen += blueeffect
sleep(20)
+4 -4
View File
@@ -38,8 +38,8 @@
if(!l_hand && has_left_hand())
W.forceMove(src) //TODO: move to equipped?
l_hand = W
W.layer = 20 //TODO: move to equipped?
W.plane = HUD_PLANE //TODO: move to equipped?
W.layer = ABOVE_HUD_LAYER //TODO: move to equipped?
W.plane = ABOVE_HUD_PLANE //TODO: move to equipped?
W.equipped(src,slot_l_hand)
if(pulling == W)
stop_pulling()
@@ -54,8 +54,8 @@
if(!r_hand && has_right_hand())
W.forceMove(src)
r_hand = W
W.layer = 20
W.plane = HUD_PLANE
W.layer = ABOVE_HUD_LAYER
W.plane = ABOVE_HUD_PLANE
W.equipped(src,slot_r_hand)
if(pulling == W)
stop_pulling()
@@ -202,8 +202,8 @@
W.screen_loc = null
W.loc = src
W.equipped(src, slot)
W.layer = 20
W.plane = HUD_PLANE
W.layer = ABOVE_HUD_LAYER
W.plane = ABOVE_HUD_PLANE
switch(slot)
if(slot_back)
@@ -248,8 +248,8 @@
var/obj/item/clothing/ears/offear/O = new(W)
O.loc = src
r_ear = O
O.layer = 20
O.plane = HUD_PLANE
O.layer = ABOVE_HUD_LAYER
O.plane = ABOVE_HUD_PLANE
update_inv_ears(redraw_mob)
if(slot_r_ear)
r_ear = W
@@ -257,8 +257,8 @@
var/obj/item/clothing/ears/offear/O = new(W)
O.loc = src
l_ear = O
O.layer = 20
O.plane = HUD_PLANE
O.layer = ABOVE_HUD_LAYER
O.plane = ABOVE_HUD_PLANE
update_inv_ears(redraw_mob)
if(slot_glasses)
glasses = W
@@ -55,24 +55,24 @@
if(!module_state_1)
O.mouse_opacity = initial(O.mouse_opacity)
module_state_1 = O
O.layer = 20
O.plane = HUD_PLANE
O.layer = ABOVE_HUD_LAYER
O.plane = ABOVE_HUD_PLANE
O.screen_loc = inv1.screen_loc
contents += O
set_actions(O)
else if(!module_state_2)
O.mouse_opacity = initial(O.mouse_opacity)
module_state_2 = O
O.layer = 20
O.plane = HUD_PLANE
O.layer = ABOVE_HUD_LAYER
O.plane = ABOVE_HUD_PLANE
O.screen_loc = inv2.screen_loc
contents += O
set_actions(O)
else if(!module_state_3)
O.mouse_opacity = initial(O.mouse_opacity)
module_state_3 = O
O.layer = 20
O.plane = HUD_PLANE
O.layer = ABOVE_HUD_LAYER
O.plane = ABOVE_HUD_PLANE
O.screen_loc = inv3.screen_loc
contents += O
set_actions(O)
@@ -114,7 +114,9 @@ var/list/robot_verbs_default = list(
robot_modules_background = new()
robot_modules_background.icon_state = "block"
robot_modules_background.layer = 19 //Objects that appear on screen are on layer 20, UI should be just below it.
robot_modules_background.layer = HUD_LAYER //Objects that appear on screen are on layer 20, UI should be just below it.
robot_modules_background.plane = HUD_PLANE
ident = rand(1, 999)
rename_character(null, get_default_name())
update_icons()
@@ -534,8 +534,8 @@
W.forceMove(src)
W.equipped(src, slot)
W.layer = 20
W.plane = HUD_PLANE
W.layer = ABOVE_HUD_LAYER
W.plane = ABOVE_HUD_PLANE
switch(slot)
if(slot_collar)
+4 -4
View File
@@ -334,15 +334,15 @@
else if(h_user.l_store == src)
h_user.unEquip(src)
B.loc = h_user
B.layer = 20
B.plane = HUD_PLANE
B.layer = ABOVE_HUD_LAYER
B.plane = ABOVE_HUD_PLANE
h_user.l_store = B
h_user.update_inv_pockets()
else if(h_user.r_store == src)
h_user.unEquip(src)
B.loc = h_user
B.layer = 20
B.plane = HUD_PLANE
B.layer = ABOVE_HUD_LAYER
B.plane = ABOVE_HUD_PLANE
h_user.r_store = B
h_user.update_inv_pockets()
else if(h_user.head == src)
@@ -604,6 +604,32 @@
M.emote("laugh")
return list(effect, update_flags)
/datum/reagent/rotatium //Rotatium. Fucks up your rotation and is hilarious
name = "Rotatium"
id = "rotatium"
description = "A constantly swirling, oddly colourful fluid. Causes the consumer's sense of direction and hand-eye coordination to become wild."
reagent_state = LIQUID
color = "#AC88CA" //RGB: 172, 136, 202
metabolization_rate = 0.6 * REAGENTS_METABOLISM
taste_message = "spinning"
/datum/reagent/rotatium/on_mob_life(mob/living/carbon/M)
if(M.hud_used)
if(current_cycle >= 20 && current_cycle % 20 == 0)
var/list/screens = list(M.hud_used.plane_masters["[FLOOR_PLANE]"], M.hud_used.plane_masters["[GAME_PLANE]"])
var/rotation = min(round(current_cycle / 20), 89) // By this point the player is probably puking and quitting anyway
for(var/whole_screen in screens)
animate(whole_screen, transform = matrix(rotation, MATRIX_ROTATE), time = 5, easing = QUAD_EASING, loop = -1)
animate(transform = matrix(-rotation, MATRIX_ROTATE), time = 5, easing = QUAD_EASING)
return ..()
/datum/reagent/rotatium/on_mob_delete(mob/living/M)
if(M && M.hud_used)
var/list/screens = list(M.hud_used.plane_masters["[FLOOR_PLANE]"], M.hud_used.plane_masters["[GAME_PLANE]"])
for(var/whole_screen in screens)
animate(whole_screen, transform = matrix(), time = 5, easing = QUAD_EASING)
..()
//////////////////////////////
// Synth-Drugs //
//////////////////////////////
+1 -1
View File
@@ -680,7 +680,7 @@
dir = 0 // dir will contain dominant direction for junction pipes
var/health = 10 // health points 0-10
armor = list("melee" = 25, "bullet" = 10, "laser" = 10, "energy" = 100, "bomb" = 0, "bio" = 100, "rad" = 100)
layer = 2.3 // slightly lower than wires and other pipes
layer = DISPOSAL_PIPE_LAYER // slightly lower than wires and other pipes
var/base_icon_state // initial icon state on map
// new pipe, set the icon_state as on map
+1
View File
@@ -144,6 +144,7 @@
#include "code\_onclick\hud\movable_screen_objects.dm"
#include "code\_onclick\hud\other_mobs.dm"
#include "code\_onclick\hud\picture_in_picture.dm"
#include "code\_onclick\hud\plane_master.dm"
#include "code\_onclick\hud\radial.dm"
#include "code\_onclick\hud\robot.dm"
#include "code\_onclick\hud\screen_objects.dm"