Skip to content

Commit

Permalink
Merge pull request #3 from tgstation/master
Browse files Browse the repository at this point in the history
3
  • Loading branch information
GuillaumePrata committed Aug 18, 2020
2 parents eb222f8 + db11e76 commit ce6714e
Show file tree
Hide file tree
Showing 26 changed files with 74 additions and 54 deletions.
8 changes: 3 additions & 5 deletions _maps/map_files/generic/CentCom.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -161,9 +161,9 @@
/area/holodeck/rec_center/bunker)
"az" = (
/obj/structure/table/wood,
/obj/item/storage/box/matches{
pixel_x = -4;
pixel_y = 8
/obj/item/lighter{
pixel_x = 3;
pixel_y = 3
},
/turf/open/floor/holofloor{
dir = 9;
Expand Down Expand Up @@ -305,13 +305,11 @@
/area/holodeck/rec_center/lounge)
"aU" = (
/turf/open/floor/holofloor{
dir = 9;
icon_state = "stairs-l"
},
/area/holodeck/rec_center/lounge)
"aV" = (
/turf/open/floor/holofloor{
dir = 9;
icon_state = "stairs-r"
},
/area/holodeck/rec_center/lounge)
Expand Down
2 changes: 2 additions & 0 deletions code/__DEFINES/interaction_flags.dm
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,5 @@
/// This flag determines if a machine set_machine's the user when the user uses it, making updateUsrDialog make the user re-call interact() on it.
/// THIS FLAG IS ON ALL MACHINES BY DEFAULT, NEEDS TO BE RE-EVALUATED LATER!!
#define INTERACT_MACHINE_SET_MACHINE (1<<6)
/// the user must have vision to interact (blind people need not apply)
#define INTERACT_MACHINE_REQUIRES_SIGHT (1<<7)
3 changes: 2 additions & 1 deletion code/_globalvars/bitfields.dm
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ GLOBAL_LIST_INIT(bitfields, list(
"INTERACT_MACHINE_ALLOW_SILICON" = INTERACT_MACHINE_ALLOW_SILICON,
"INTERACT_MACHINE_OPEN_SILICON" = INTERACT_MACHINE_OPEN_SILICON,
"INTERACT_MACHINE_REQUIRES_SILICON" = INTERACT_MACHINE_REQUIRES_SILICON,
"INTERACT_MACHINE_SET_MACHINE" = INTERACT_MACHINE_SET_MACHINE
"INTERACT_MACHINE_SET_MACHINE" = INTERACT_MACHINE_SET_MACHINE,
"INTERACT_MACHINE_REQUIRES_SIGHT" = INTERACT_MACHINE_REQUIRES_SIGHT
),
"interaction_flags_item" = list(
"INTERACT_ITEM_ATTACK_HAND_PICKUP" = INTERACT_ITEM_ATTACK_HAND_PICKUP,
Expand Down
5 changes: 5 additions & 0 deletions code/game/machinery/_machinery.dm
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,11 @@ Class Procs:
if(interaction_flags_machine & INTERACT_MACHINE_REQUIRES_SILICON) // First make sure the machine doesn't require silicon interaction
return FALSE

if(interaction_flags_machine & INTERACT_MACHINE_REQUIRES_SIGHT)
if(user.is_blind())
to_chat(user, "<span class='warning'>This machine requires sight to use.</span>")
return FALSE

if(!Adjacent(user)) // Next make sure we are next to the machine unless we have telekinesis
var/mob/living/carbon/H = L
if(!(istype(H) && H.has_dna() && H.dna.check_mutation(TK)))
Expand Down
2 changes: 2 additions & 0 deletions code/game/machinery/computer/camera.dm
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@
var/list/cam_plane_masters
var/obj/screen/background/cam_background

interaction_flags_machine = INTERACT_MACHINE_ALLOW_SILICON | INTERACT_MACHINE_SET_MACHINE | INTERACT_MACHINE_REQUIRES_SIGHT

/obj/machinery/computer/security/Initialize()
. = ..()
// Map name has to start and end with an A-Z character,
Expand Down
11 changes: 5 additions & 6 deletions code/game/machinery/computer/camera_advanced.dm
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
///Should we supress any view changes?
var/should_supress_view_changes = TRUE

interaction_flags_machine = INTERACT_MACHINE_ALLOW_SILICON | INTERACT_MACHINE_SET_MACHINE | INTERACT_MACHINE_REQUIRES_SIGHT

/obj/machinery/computer/camera_advanced/Initialize()
. = ..()
for(var/i in networks)
Expand Down Expand Up @@ -81,7 +83,7 @@
playsound(src, 'sound/machines/terminal_off.ogg', 25, FALSE)

/obj/machinery/computer/camera_advanced/check_eye(mob/user)
if( (machine_stat & (NOPOWER|BROKEN)) || (!Adjacent(user) && !user.has_unlimited_silicon_privilege) || user.is_blind() || user.incapacitated() )
if(!can_use(user) || (issilicon(user) && !user.has_unlimited_silicon_privilege))
user.unset_machine()

/obj/machinery/computer/camera_advanced/Destroy()
Expand All @@ -97,7 +99,7 @@
remove_eye_control(M)

/obj/machinery/computer/camera_advanced/proc/can_use(mob/living/user)
return TRUE
return can_interact(user)

/obj/machinery/computer/camera_advanced/abductor/can_use(mob/user)
if(!isabductor(user))
Expand All @@ -108,15 +110,12 @@
. = ..()
if(.)
return
if(!is_operational()) //you cant use broken machine you chumbis
if(!can_use(user))
return
if(current_user)
to_chat(user, "<span class='warning'>The console is already in use!</span>")
return
var/mob/living/L = user

if(!can_use(user))
return
if(!eyeobj)
CreateEye()

Expand Down
5 changes: 2 additions & 3 deletions code/game/turfs/change_turf.dm
Original file line number Diff line number Diff line change
Expand Up @@ -136,12 +136,11 @@ GLOBAL_LIST_INIT(blacklisted_automated_baseturfs, typecacheof(list(
return W

/turf/open/ChangeTurf(path, list/new_baseturfs, flags) //Resist the temptation to make this default to keeping air.
SSair.remove_from_active(src) //Turfs are fucking weird with refs, let's be safe yeah?
if ((flags & CHANGETURF_INHERIT_AIR) && ispath(path, /turf/open))
SSair.remove_from_active(src)
var/datum/gas_mixture/stashed_air = new()
stashed_air.copy_from(air)
air = null
. = ..()
. = ..() //If path == type this will return us, don't bank on making a new type
if (!.) // changeturf failed or didn't do anything
QDEL_NULL(stashed_air)
return
Expand Down
2 changes: 1 addition & 1 deletion code/modules/holodeck/area_copy.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
GLOBAL_LIST_INIT(duplicate_forbidden_vars,list(
"tag", "datum_components", "area", "type", "loc", "locs", "vars", "parent", "parent_type", "verbs", "ckey", "key",
"power_supply", "contents", "reagents", "stat", "x", "y", "z", "group", "atmos_adjacent_turfs", "comp_lookup",
"client_mobs_in_contents", "bodyparts", "internal_organs", "hand_bodyparts", "overlays", "overlays_standing", "hud_list",
"client_mobs_in_contents", "bodyparts", "internal_organs", "hand_bodyparts", "overlays_standing", "hud_list",
"actions", "AIStatus", "appearance", "managed_overlays", "managed_vis_overlays", "computer_id", "lastKnownIP", "implants",
"tgui_shared_states"
))
Expand Down
4 changes: 3 additions & 1 deletion code/modules/mob/dead/observer/observer_say.dm
Original file line number Diff line number Diff line change
Expand Up @@ -48,5 +48,7 @@
create_chat_message(speaker, message_language, raw_message, spans)
// Recompose the message, because it's scrambled by default
message = compose_message(speaker, message_language, raw_message, radio_freq, spans, message_mods)
to_chat(src, "[link] [message]")
to_chat(src,
html = "[link] [message]",
avoid_highlighting = speaker == src)

3 changes: 0 additions & 3 deletions code/modules/mob/living/carbon/human/human.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1225,9 +1225,6 @@
/mob/living/carbon/human/species/android
race = /datum/species/android

/mob/living/carbon/human/species/corporate
race = /datum/species/corporate

/mob/living/carbon/human/species/dullahan
race = /datum/species/dullahan

Expand Down
20 changes: 0 additions & 20 deletions code/modules/mob/living/carbon/human/species_types/corporate.dm

This file was deleted.

2 changes: 1 addition & 1 deletion code/modules/mob/living/living_say.dm
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ GLOBAL_LIST_INIT(department_radio_keys, list(
// Recompose message for AI hrefs, language incomprehension.
message = compose_message(speaker, message_language, raw_message, radio_freq, spans, message_mods)

show_message(message, MSG_AUDIBLE, deaf_message, deaf_type)
show_message(message, MSG_AUDIBLE, deaf_message, deaf_type, avoid_highlighting = speaker == src)
return message

/mob/living/send_speech(message, message_range = 6, obj/source = src, bubble_type = bubble_icon, list/spans, datum/language/message_language=null, list/message_mods = list())
Expand Down
4 changes: 2 additions & 2 deletions code/modules/mob/mob.dm
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@
/**
* Show a message to this mob (visual or audible)
*/
/mob/proc/show_message(msg, type, alt_msg, alt_type)//Message, type of message (1 or 2), alternative message, alt message type (1 or 2)
/mob/proc/show_message(msg, type, alt_msg, alt_type, avoid_highlighting = FALSE)//Message, type of message (1 or 2), alternative message, alt message type (1 or 2)
if(!client)
return

Expand All @@ -160,7 +160,7 @@
if(type & MSG_AUDIBLE) //audio
to_chat(src, "<I>... You can almost hear something ...</I>")
return
to_chat(src, msg)
to_chat(src, msg, avoid_highlighting = avoid_highlighting)

/**
* Generate a visible message from this atom
Expand Down
4 changes: 4 additions & 0 deletions code/modules/tgchat/to_chat.dm
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
/proc/to_chat_immediate(target, html,
type = null,
text = null,
avoid_highlighting = FALSE,
// FIXME: These flags are now pointless and have no effect
handle_whitespace = TRUE,
trailing_newline = TRUE,
Expand All @@ -23,6 +24,7 @@
if(type) message["type"] = type
if(text) message["text"] = text
if(html) message["html"] = html
if(avoid_highlighting) message["avoidHighlighting"] = avoid_highlighting
var/message_blob = TGUI_CREATE_MESSAGE("chat/message", message)
var/message_html = message_to_html(message)
if(islist(target))
Expand Down Expand Up @@ -52,6 +54,7 @@
/proc/to_chat(target, html,
type = null,
text = null,
avoid_highlighting = FALSE,
// FIXME: These flags are now pointless and have no effect
handle_whitespace = TRUE,
trailing_newline = TRUE,
Expand All @@ -68,4 +71,5 @@
if(type) message["type"] = type
if(text) message["text"] = text
if(html) message["html"] = html
if(avoid_highlighting) message["avoidHighlighting"] = avoid_highlighting
SSchat.queue(target, message)
14 changes: 14 additions & 0 deletions html/changelog.html
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,20 @@
-->
<div class="commit sansserif">
<h2 class="date">18 August 2020</h2>
<h3 class="author">LemonInTheDark updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">The ash drake fight is winnable again, and the game will no longer die when he goes into the lava arena attack.</li>
</ul>
<h3 class="author">Paxilmaniac updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">missing areas and directional windows on pubby's chapel</li>
</ul>
<h3 class="author">nightred updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">fixed ore silo deconstruction steps</li>
</ul>

<h2 class="date">17 August 2020</h2>
<h3 class="author">ATHATH updated:</h3>
<ul class="changes bgimages16">
Expand Down
8 changes: 8 additions & 0 deletions html/changelogs/.all_changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41945,3 +41945,11 @@ DO NOT EDIT THIS FILE BY HAND! AUTOMATICALLY GENERATED BY ss13_genchangelog.py.
- code_imp: 'tgchat: Chat schema bumped to version 5. All chat-related settings
were reset to avoid breakage.'
- bugfix: 'tgchat: Fixed adminsay to no longer show up as [object Object].'
2020-08-18:
LemonInTheDark:
- bugfix: The ash drake fight is winnable again, and the game will no longer die
when he goes into the lava arena attack.
Paxilmaniac:
- bugfix: missing areas and directional windows on pubby's chapel
nightred:
- bugfix: fixed ore silo deconstruction steps
4 changes: 0 additions & 4 deletions html/changelogs/AutoChangeLog-pr-52863.yml

This file was deleted.

6 changes: 6 additions & 0 deletions html/changelogs/AutoChangeLog-pr-52895.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
author: "Melbert"
delete-after: True
changes:
- tweak: "Blinded people can no longer use camera consoles"
- bugfix: "Blinded people can no longer activate all types of advanced camera consoles, including navigation consoles (They were already not intended to be able to use them)"
- code_imp: "adds a machine interaction flag for machines that require the user not be blind to use"
4 changes: 0 additions & 4 deletions html/changelogs/AutoChangeLog-pr-52923.yml

This file was deleted.

4 changes: 4 additions & 0 deletions html/changelogs/AutoChangeLog-pr-52924.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
author: "uomo91"
delete-after: True
changes:
- bugfix: "Nanotrasen software division has fixed an issue with station holodecks creating invisible tables and floor decals."
4 changes: 4 additions & 0 deletions html/changelogs/AutoChangeLog-pr-52991.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
author: "Jared-Fogle"
delete-after: True
changes:
- tweak: "Messages sent by yourself no longer highlight."
4 changes: 4 additions & 0 deletions html/changelogs/AutoChangeLog-pr-53018.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
author: "tralezab"
delete-after: True
changes:
- rscdel: "Goodbye corporate species. I can't even pretend like you were good at all."
Binary file modified icons/mob/human_parts.dmi
Binary file not shown.
1 change: 0 additions & 1 deletion tgstation.dme
Original file line number Diff line number Diff line change
Expand Up @@ -2304,7 +2304,6 @@
#include "code\modules\mob\living\carbon\human\suicides.dm"
#include "code\modules\mob\living\carbon\human\species_types\abductors.dm"
#include "code\modules\mob\living\carbon\human\species_types\android.dm"
#include "code\modules\mob\living\carbon\human\species_types\corporate.dm"
#include "code\modules\mob\living\carbon\human\species_types\dullahan.dm"
#include "code\modules\mob\living\carbon\human\species_types\ethereal.dm"
#include "code\modules\mob\living\carbon\human\species_types\felinid.dm"
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui-panel/chat/renderer.js
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ class ChatRenderer {
logger.error('Error: message is missing text payload', message);
}
// Highlight text
if (this.highlightRegex) {
if (!message.avoidHighlighting && this.highlightRegex) {
const highlighted = highlightNode(node,
this.highlightRegex,
text => (
Expand Down
2 changes: 1 addition & 1 deletion tgui/packages/tgui/public/tgui-panel.bundle.js

Large diffs are not rendered by default.

0 comments on commit ce6714e

Please sign in to comment.