Merge pull request #14447 from LetterN/fixes-2
Fixes laptop and tweaks stacks
This commit is contained in:
@@ -202,8 +202,9 @@
|
||||
filled = 1
|
||||
release_pressure = ONE_ATMOSPHERE*2
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/Initialize(mapload, datum/gas_mixture/existing_mixture)
|
||||
. = ..()
|
||||
/obj/machinery/portable_atmospherics/canister/New(loc, datum/gas_mixture/existing_mixture)
|
||||
..()
|
||||
|
||||
if(existing_mixture)
|
||||
air_contents.copy_from(existing_mixture)
|
||||
else
|
||||
@@ -221,10 +222,8 @@
|
||||
air_contents.set_temperature(starter_temp)
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/air/create_gas()
|
||||
var/oh_two = /datum/gas/oxygen
|
||||
var/dihydrogen = /datum/gas/nitrogen //how to piss of chemists
|
||||
air_contents.set_moles(oh_two, (O2STANDARD * maximum_pressure * filled) * air_contents.return_volume() / (R_IDEAL_GAS_EQUATION * air_contents.return_temperature()))
|
||||
air_contents.set_moles(dihydrogen, (N2STANDARD * maximum_pressure * filled) * air_contents.return_volume() / (R_IDEAL_GAS_EQUATION * air_contents.return_temperature()))
|
||||
air_contents.set_moles(/datum/gas/oxygen, (O2STANDARD * maximum_pressure * filled) * air_contents.return_volume() / (R_IDEAL_GAS_EQUATION * air_contents.return_temperature()))
|
||||
air_contents.set_moles(/datum/gas/nitrogen, (N2STANDARD * maximum_pressure * filled) * air_contents.return_volume() / (R_IDEAL_GAS_EQUATION * air_contents.return_temperature()))
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/update_icon_state()
|
||||
if(stat & BROKEN)
|
||||
|
||||
@@ -130,26 +130,28 @@
|
||||
|
||||
/obj/structure/closet/supplypod/update_overlays()
|
||||
. = ..()
|
||||
if (style == STYLE_INVISIBLE)
|
||||
if(style == STYLE_INVISIBLE)
|
||||
return
|
||||
if (rubble)
|
||||
|
||||
if(rubble)
|
||||
. += rubble.getForeground(src)
|
||||
if (style == STYLE_SEETHROUGH)
|
||||
for (var/atom/A in contents)
|
||||
|
||||
if(style == STYLE_SEETHROUGH)
|
||||
for(var/atom/A in contents)
|
||||
var/mutable_appearance/itemIcon = new(A)
|
||||
itemIcon.transform = matrix().Translate(-1 * SUPPLYPOD_X_OFFSET, 0)
|
||||
. += itemIcon
|
||||
for (var/t in turfs_in_cargo)//T is just a turf's type
|
||||
for(var/t in turfs_in_cargo)//T is just a turf's type
|
||||
var/turf/turf_type = t
|
||||
var/mutable_appearance/itemIcon = mutable_appearance(initial(turf_type.icon), initial(turf_type.icon_state))
|
||||
itemIcon.transform = matrix().Translate(-1 * SUPPLYPOD_X_OFFSET, 0)
|
||||
. += itemIcon
|
||||
return
|
||||
|
||||
if (opened) //We're opened means all we have to worry about is masking a decal if we have one
|
||||
if (!decal) //We don't have a decal to mask
|
||||
if(opened) //We're opened means all we have to worry about is masking a decal if we have one
|
||||
if(!decal) //We don't have a decal to mask
|
||||
return
|
||||
if (!door) //We have a decal but no door, so let's just add the decal
|
||||
if(!door) //We have a decal but no door, so let's just add the decal
|
||||
. += decal
|
||||
return
|
||||
var/icon/masked_decal = new(icon, decal) //The decal we want to apply
|
||||
@@ -159,23 +161,25 @@
|
||||
door_masker.Blend("#000000", ICON_SUBTRACT)
|
||||
masked_decal.Blend(door_masker, ICON_ADD)
|
||||
. += masked_decal
|
||||
else //If we're closed
|
||||
if (!door) //We have no door, lets see if we have a decal. If not, theres nothing we need to do
|
||||
if (decal)
|
||||
. += decal
|
||||
return
|
||||
else if (GLOB.podstyles[style][POD_SHAPE] != POD_SHAPE_NORML) //If we're not a normal pod shape (aka, if we don't have fins), just add the door without masking
|
||||
. += door
|
||||
else
|
||||
var/icon/masked_door = new(icon, door) //The door we want to apply
|
||||
var/icon/fin_masker = new(icon, "mask_[fin_mask]") //The fin shape we want to 'cut out' of the door
|
||||
fin_masker.MapColors(0,0,0,1, 0,0,0,1, 0,0,0,1, 1,1,1,0, 0,0,0,1)
|
||||
fin_masker.SwapColor("#ffffffff", null)
|
||||
fin_masker.Blend("#000000", ICON_SUBTRACT)
|
||||
masked_door.Blend(fin_masker, ICON_ADD)
|
||||
. += masked_door
|
||||
if (decal)
|
||||
return
|
||||
|
||||
//If we're closed
|
||||
if(!door) //We have no door, lets see if we have a decal. If not, theres nothing we need to do
|
||||
if(decal)
|
||||
. += decal
|
||||
return
|
||||
else if (GLOB.podstyles[style][POD_SHAPE] != POD_SHAPE_NORML) //If we're not a normal pod shape (aka, if we don't have fins), just add the door without masking
|
||||
. += door
|
||||
else
|
||||
var/icon/masked_door = new(icon, door) //The door we want to apply
|
||||
var/icon/fin_masker = new(icon, "mask_[fin_mask]") //The fin shape we want to 'cut out' of the door
|
||||
fin_masker.MapColors(0,0,0,1, 0,0,0,1, 0,0,0,1, 1,1,1,0, 0,0,0,1)
|
||||
fin_masker.SwapColor("#ffffffff", null)
|
||||
fin_masker.Blend("#000000", ICON_SUBTRACT)
|
||||
masked_door.Blend(fin_masker, ICON_ADD)
|
||||
. += masked_door
|
||||
if(decal)
|
||||
. += decal
|
||||
|
||||
/obj/structure/closet/supplypod/tool_interact(obj/item/W, mob/user)
|
||||
if(bluespace) //We dont want to worry about interacting with bluespace pods, as they are due to delete themselves soon anyways.
|
||||
@@ -192,7 +196,7 @@
|
||||
/obj/structure/closet/supplypod/toggle(mob/living/user)
|
||||
return
|
||||
|
||||
/obj/structure/closet/supplypod/open(mob/living/user, force = TRUE)
|
||||
/obj/structure/closet/supplypod/open(mob/living/user, force = FALSE)
|
||||
return
|
||||
|
||||
/obj/structure/closet/supplypod/proc/handleReturnAfterDeparting(atom/movable/holder = src)
|
||||
@@ -550,9 +554,6 @@
|
||||
var/obj/effect/pod_landingzone_effect/helper
|
||||
var/list/smoke_effects = new /list(13)
|
||||
|
||||
/obj/effect/ex_act()
|
||||
return
|
||||
|
||||
/obj/effect/pod_landingzone/Initialize(mapload, podParam, single_order = null, clientman)
|
||||
. = ..()
|
||||
if (ispath(podParam)) //We can pass either a path for a pod (as expressconsoles do), or a reference to an instantiated pod (as the centcom_podlauncher does)
|
||||
@@ -647,4 +648,12 @@
|
||||
desc = "This disk provides a firmware update to the Express Supply Console, granting the use of Nanotrasen's Bluespace Drop Pods to the supply department."
|
||||
icon = 'icons/obj/module.dmi'
|
||||
icon_state = "cargodisk"
|
||||
// inhand_icon_state = "card-id"
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
|
||||
// let's not.
|
||||
/obj/structure/closet/supplypod/handle_lock_addition()
|
||||
return
|
||||
|
||||
/obj/structure/closet/supplypod/handle_lock_removal()
|
||||
return
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
|
||||
/obj/item/modular_computer/laptop/examine(mob/user)
|
||||
. = ..()
|
||||
. += "<span class='notice'>Drag it in your hand to pick it up.</span>"
|
||||
if(screen_on)
|
||||
. += "<span class='notice'>Alt-click to close it.</span>"
|
||||
|
||||
@@ -76,6 +77,9 @@
|
||||
M.put_in_hand(src, H.held_index)
|
||||
|
||||
/obj/item/modular_computer/laptop/on_attack_hand(mob/user)
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
if(screen_on && isturf(loc))
|
||||
return attack_self(user)
|
||||
|
||||
|
||||
@@ -20,7 +20,8 @@
|
||||
"Head of Security",
|
||||
"Chief Engineer",
|
||||
"Research Director",
|
||||
"Chief Medical Officer")
|
||||
"Chief Medical Officer",
|
||||
"Quartermaster")
|
||||
|
||||
//The scaling factor of max total positions in relation to the total amount of people on board the station in %
|
||||
var/max_relative_positions = 30 //30%: Seems reasonable, limit of 6 @ 20 players
|
||||
@@ -43,7 +44,7 @@
|
||||
|
||||
/datum/computer_file/program/job_management/proc/can_close_job(datum/job/job)
|
||||
if(!(job?.title in blacklisted))
|
||||
if(job.total_positions > length(GLOB.player_list) * (max_relative_positions / 100))
|
||||
if(job.total_positions > job.current_positions)
|
||||
var/delta = (world.time / 10) - GLOB.time_last_changed_position
|
||||
if((change_position_cooldown < delta) || (opened_positions[job.title] > 0))
|
||||
return TRUE
|
||||
@@ -67,7 +68,7 @@
|
||||
if(!j || !can_open_job(j))
|
||||
return
|
||||
if(opened_positions[edit_job_target] >= 0)
|
||||
GLOB.time_last_changed_position = world.time / 10
|
||||
GLOB.time_last_changed_position = world.time / 10 // global cd
|
||||
j.total_positions++
|
||||
opened_positions[edit_job_target]++
|
||||
playsound(computer, 'sound/machines/terminal_prompt_confirm.ogg', 50, FALSE)
|
||||
|
||||
Reference in New Issue
Block a user