mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
[MIRROR] some fixes (#9265)
Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com> Co-authored-by: CHOMPStation2 <chompsation2@gmail.com>
This commit is contained in:
@@ -365,6 +365,7 @@ GLOBAL_LIST_BOILERPLATE(allCasters, /obj/machinery/newscaster)
|
||||
if(!viewing_channel.censored)
|
||||
for(var/datum/feed_message/M in viewing_channel.messages)
|
||||
var/list/msgdata = list(
|
||||
"title" = M.title,
|
||||
"body" = M.body,
|
||||
"img" = null,
|
||||
"type" = M.message_type,
|
||||
|
||||
@@ -654,8 +654,10 @@ var/list/global/slot_flags_enumeration = list(
|
||||
return
|
||||
|
||||
//if we haven't made our blood_overlay already
|
||||
if( !blood_overlay )
|
||||
if(!blood_overlay)
|
||||
generate_blood_overlay()
|
||||
else
|
||||
overlays.Remove(blood_overlay)
|
||||
|
||||
//Make the blood_overlay have the proper color then apply it.
|
||||
blood_overlay.color = blood_color
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
var/fake_oxy = max(rand(1,40), M.getOxyLoss(), (300 - (M.getToxLoss() + M.getFireLoss() + M.getBruteLoss())))
|
||||
var/OX = M.getOxyLoss() > 50 ? span_bold("[M.getOxyLoss()]") : M.getOxyLoss()
|
||||
var/TX = M.getToxLoss() > 50 ? span_bold("[M.getToxLoss()]") : M.getToxLoss()
|
||||
var/BU = M.getFireLoss() > 50 ? span_bold("M.getFireLoss()]") : M.getFireLoss()
|
||||
var/BU = M.getFireLoss() > 50 ? span_bold("[M.getFireLoss()]") : M.getFireLoss()
|
||||
var/BR = M.getBruteLoss() > 50 ? span_bold("[M.getBruteLoss()]") : M.getBruteLoss()
|
||||
var/analyzed_results = ""
|
||||
if(M.status_flags & FAKEDEATH)
|
||||
|
||||
@@ -559,9 +559,22 @@
|
||||
return
|
||||
busy = 0
|
||||
|
||||
user.clean_blood()
|
||||
if(ishuman(user))
|
||||
user:update_inv_gloves()
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.gunshot_residue = null
|
||||
if(H.gloves)
|
||||
H.gloves.clean_blood()
|
||||
H.update_inv_gloves()
|
||||
H.gloves.germ_level = 0
|
||||
else
|
||||
if(H.r_hand)
|
||||
H.r_hand.clean_blood()
|
||||
if(H.l_hand)
|
||||
H.l_hand.clean_blood()
|
||||
H.bloody_hands = 0
|
||||
H.germ_level = 0
|
||||
else
|
||||
user.clean_blood()
|
||||
for(var/mob/V in viewers(src, null))
|
||||
V.show_message(span_notice("[user] washes their hands using \the [src]."))
|
||||
|
||||
|
||||
@@ -212,16 +212,16 @@
|
||||
var/slot_num
|
||||
if(slot_start == 0)
|
||||
slot_num = 1
|
||||
slot_start = 2
|
||||
else
|
||||
slot_num = slot_start + 1
|
||||
|
||||
while(slot_start != slot_num) //If we wrap around without finding any free slots, just give up.
|
||||
if(slot_num > 3)
|
||||
return
|
||||
// Attempt to rotate through the slots until we're past slot 3, or find the next usable slot. Allows skipping empty slots, while still having an empty slot at end of rotation.
|
||||
while(slot_num <= 3)
|
||||
if(module_active(slot_num))
|
||||
select_module(slot_num)
|
||||
return
|
||||
slot_num++
|
||||
if(slot_num > 3) slot_num = 1 //Wrap around.
|
||||
|
||||
return
|
||||
|
||||
|
||||
@@ -84,7 +84,8 @@ export const NewscasterViewSelected = (props: { setScreen: Function }) => {
|
||||
{(!!viewing_channel.messages.length &&
|
||||
viewing_channel.messages.map((message) => (
|
||||
<Section key={message.ref}>
|
||||
- {decodeHtmlEntities(message.body)}
|
||||
{message.title && decodeHtmlEntities(message.title) + ' - '}
|
||||
{decodeHtmlEntities(message.body)}
|
||||
{!!message.img && (
|
||||
<Box>
|
||||
<Image src={'data:image/png;base64,' + message.img} />
|
||||
|
||||
@@ -31,6 +31,7 @@ export type Data = {
|
||||
author: string;
|
||||
censored: BooleanLike;
|
||||
messages: {
|
||||
title: string | null;
|
||||
body: string;
|
||||
img: string | null;
|
||||
type: string;
|
||||
|
||||
Reference in New Issue
Block a user