mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-13 03:33:21 +00:00
Reverted some layer adjustments I did that seem to have broken things, bugfixes for operating tables, choking people, and CPR, giving. Also added sterile mask box sprite, and tossed the singularity crap into a spawn(0) to try and reduce lag.
This commit is contained in:
@@ -5,7 +5,6 @@
|
|||||||
icon_state = "wardrobe_sealed"
|
icon_state = "wardrobe_sealed"
|
||||||
item_state = "wardrobe"
|
item_state = "wardrobe"
|
||||||
w_class = 4
|
w_class = 4
|
||||||
layer = 2.9
|
|
||||||
var
|
var
|
||||||
descriptor = "various clothing"
|
descriptor = "various clothing"
|
||||||
seal_torn = 0
|
seal_torn = 0
|
||||||
|
|||||||
@@ -13,7 +13,6 @@
|
|||||||
var/health = 100 //Might be a bit much, dono can always change later //Nerfed -Pete
|
var/health = 100 //Might be a bit much, dono can always change later //Nerfed -Pete
|
||||||
var/lastbang //
|
var/lastbang //
|
||||||
var/lasttry = 0
|
var/lasttry = 0
|
||||||
layer = 2.8
|
|
||||||
|
|
||||||
/obj/structure/closet/detective
|
/obj/structure/closet/detective
|
||||||
name = "Detective's Closet"
|
name = "Detective's Closet"
|
||||||
|
|||||||
@@ -277,7 +277,7 @@
|
|||||||
/obj/item/weapon/storage/stma_kit
|
/obj/item/weapon/storage/stma_kit
|
||||||
name = "Sterile Masks"
|
name = "Sterile Masks"
|
||||||
desc = "This box contains masks of +2 constitution." //I made it better. --SkyMarshal
|
desc = "This box contains masks of +2 constitution." //I made it better. --SkyMarshal
|
||||||
icon_state = "latex"
|
icon_state = "mask"
|
||||||
item_state = "syringe_kit"
|
item_state = "syringe_kit"
|
||||||
|
|
||||||
/obj/item/weapon/storage/trackimp_kit
|
/obj/item/weapon/storage/trackimp_kit
|
||||||
|
|||||||
@@ -17,7 +17,7 @@
|
|||||||
|
|
||||||
New()
|
New()
|
||||||
..()
|
..()
|
||||||
if(id)
|
if(!isnull(id))
|
||||||
for(var/obj/machinery/computer/operating/O in world)
|
for(var/obj/machinery/computer/operating/O in world)
|
||||||
if(src.id == O.id)
|
if(src.id == O.id)
|
||||||
src.computer = O
|
src.computer = O
|
||||||
@@ -94,11 +94,13 @@
|
|||||||
if(locate(/mob/living/carbon, src.loc))
|
if(locate(/mob/living/carbon, src.loc))
|
||||||
var/mob/M = locate(/mob/living/carbon, src.loc)
|
var/mob/M = locate(/mob/living/carbon, src.loc)
|
||||||
if(M.resting)
|
if(M.resting)
|
||||||
src.victim = M
|
victim = M
|
||||||
if(updatesicon)
|
if(updatesicon)
|
||||||
icon_state = "table2-active"
|
icon_state = "table2-active"
|
||||||
return 1
|
return 1
|
||||||
src.victim = null
|
if(victim)
|
||||||
|
victim.update_clothing()
|
||||||
|
victim = null
|
||||||
if(updatesicon)
|
if(updatesicon)
|
||||||
icon_state = "table2-idle"
|
icon_state = "table2-idle"
|
||||||
processing_objects.Remove(src)
|
processing_objects.Remove(src)
|
||||||
@@ -124,6 +126,7 @@
|
|||||||
if(updatesicon)
|
if(updatesicon)
|
||||||
icon_state = "table2-active"
|
icon_state = "table2-active"
|
||||||
src.victim = M
|
src.victim = M
|
||||||
|
M.update_clothing()
|
||||||
processing_objects.Add(src)
|
processing_objects.Add(src)
|
||||||
del(W)
|
del(W)
|
||||||
return
|
return
|
||||||
@@ -133,7 +136,7 @@
|
|||||||
return
|
return
|
||||||
|
|
||||||
/obj/machinery/optable/portable
|
/obj/machinery/optable/portable
|
||||||
name = "mobile operating Table"
|
name = "mobile operating table"
|
||||||
desc = "Used for advanced medical procedures. Seems to be movable, neat."
|
desc = "Used for advanced medical procedures. Seems to be movable, neat."
|
||||||
icon = 'rollerbed.dmi'
|
icon = 'rollerbed.dmi'
|
||||||
icon_state = "up"
|
icon_state = "up"
|
||||||
|
|||||||
@@ -20,12 +20,6 @@ mob/living/carbon/verb/give()
|
|||||||
I = usr.r_hand
|
I = usr.r_hand
|
||||||
if(!I)
|
if(!I)
|
||||||
return
|
return
|
||||||
var/obj/item/weapon/T = new(usr.loc)
|
|
||||||
if(!src.loc.Enter(T))
|
|
||||||
usr << "Can't reach him"
|
|
||||||
del(T)
|
|
||||||
return
|
|
||||||
del(T)
|
|
||||||
if(src.r_hand == null)
|
if(src.r_hand == null)
|
||||||
switch(alert(src,"[usr.name] wants to give you \a [I.name]?",,"Yes","No"))
|
switch(alert(src,"[usr.name] wants to give you \a [I.name]?",,"Yes","No"))
|
||||||
if("Yes")
|
if("Yes")
|
||||||
@@ -42,11 +36,13 @@ mob/living/carbon/verb/give()
|
|||||||
usr.drop_item(I)
|
usr.drop_item(I)
|
||||||
src.l_hand = I
|
src.l_hand = I
|
||||||
else
|
else
|
||||||
|
src << "Your hands are full."
|
||||||
usr << "Their hands are full."
|
usr << "Their hands are full."
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
usr.drop_item(I)
|
usr.drop_item(I)
|
||||||
src.r_hand = I
|
src.r_hand = I
|
||||||
|
usr.client.screen -= I
|
||||||
I.loc = src
|
I.loc = src
|
||||||
I.layer = 20
|
I.layer = 20
|
||||||
I.add_fingerprint(src)
|
I.add_fingerprint(src)
|
||||||
@@ -71,11 +67,13 @@ mob/living/carbon/verb/give()
|
|||||||
usr.drop_item(I)
|
usr.drop_item(I)
|
||||||
src.r_hand = I
|
src.r_hand = I
|
||||||
else
|
else
|
||||||
|
src << "Your hands are full."
|
||||||
usr << "Their hands are full."
|
usr << "Their hands are full."
|
||||||
return
|
return
|
||||||
else
|
else
|
||||||
usr.drop_item(I)
|
usr.drop_item(I)
|
||||||
src.l_hand = I
|
src.l_hand = I
|
||||||
|
usr.client.screen -= I
|
||||||
I.loc = src
|
I.loc = src
|
||||||
I.layer = 20
|
I.layer = 20
|
||||||
I.add_fingerprint(src)
|
I.add_fingerprint(src)
|
||||||
|
|||||||
@@ -1584,7 +1584,7 @@
|
|||||||
return
|
return
|
||||||
message = text("\red <B>[] is trying to empty []'s pockets!!</B>", source, target)
|
message = text("\red <B>[] is trying to empty []'s pockets!!</B>", source, target)
|
||||||
if("CPR")
|
if("CPR")
|
||||||
if (target.cpr_time >= world.time + 3)
|
if (target.cpr_time + 3 >= world.time)
|
||||||
//SN src = null
|
//SN src = null
|
||||||
del(src)
|
del(src)
|
||||||
return
|
return
|
||||||
@@ -2045,14 +2045,15 @@ It can still be worn/put on as normal.
|
|||||||
target.handcuffed = item
|
target.handcuffed = item
|
||||||
item.loc = target
|
item.loc = target
|
||||||
if("CPR")
|
if("CPR")
|
||||||
if (target.cpr_time >= world.time + 30)
|
if (target.cpr_time + 30 >= world.time)
|
||||||
//SN src = null
|
//SN src = null
|
||||||
del(src)
|
del(src)
|
||||||
return
|
return
|
||||||
if ((target.health >= -99.0 && target.health < config.health_threshold_dead))
|
if ((target.health >= -99.0 && target.stat == 1))
|
||||||
target.cpr_time = world.time
|
target.cpr_time = world.time
|
||||||
var/suff = min(target.getOxyLoss(), 7)
|
var/suff = min(target.getOxyLoss(), 7)
|
||||||
target.oxyloss -= suff
|
target.oxyloss -= suff
|
||||||
|
target.losebreath = 0
|
||||||
target.updatehealth()
|
target.updatehealth()
|
||||||
for(var/mob/O in viewers(source, null))
|
for(var/mob/O in viewers(source, null))
|
||||||
O.show_message(text("\red [] performs CPR on []!", source, target), 1)
|
O.show_message(text("\red [] performs CPR on []!", source, target), 1)
|
||||||
|
|||||||
@@ -118,6 +118,7 @@
|
|||||||
proc
|
proc
|
||||||
handle_health_updates()
|
handle_health_updates()
|
||||||
// if the mob has enough health, she should slowly heal
|
// if the mob has enough health, she should slowly heal
|
||||||
|
if(stat != 2)
|
||||||
if(health >= 0)
|
if(health >= 0)
|
||||||
var/pr = 10
|
var/pr = 10
|
||||||
if(stat == 1) // sleeping means faster healing
|
if(stat == 1) // sleeping means faster healing
|
||||||
@@ -126,7 +127,7 @@
|
|||||||
heal_organ_damage(1,1)
|
heal_organ_damage(1,1)
|
||||||
adjustToxLoss(-1)
|
adjustToxLoss(-1)
|
||||||
else if(health < 0)
|
else if(health < 0)
|
||||||
var/pr = 80
|
var/pr = 50
|
||||||
if(prob(pr))
|
if(prob(pr))
|
||||||
adjustToxLoss(1)
|
adjustToxLoss(1)
|
||||||
|
|
||||||
@@ -275,23 +276,23 @@
|
|||||||
var/datum/air_group/breath
|
var/datum/air_group/breath
|
||||||
// HACK NEED CHANGING LATER
|
// HACK NEED CHANGING LATER
|
||||||
if(health < config.health_threshold_dead)
|
if(health < config.health_threshold_dead)
|
||||||
|
losebreath++
|
||||||
isbreathing = 0
|
isbreathing = 0
|
||||||
spawn emote("stopbreath")
|
spawn emote("stopbreath")
|
||||||
|
|
||||||
if(holdbreath)
|
if(holdbreath)
|
||||||
isbreathing = 0
|
isbreathing = 0
|
||||||
|
|
||||||
if(isbreathing)
|
|
||||||
// are we running out of air in our lungs?
|
|
||||||
if(losebreath > 0)
|
if(losebreath > 0)
|
||||||
// inaprovaline prevents the need to breathe for a while
|
// inaprovaline prevents the need to breathe for a while
|
||||||
if(reagents.has_reagent("inaprovaline"))
|
if(reagents.has_reagent("inaprovaline"))
|
||||||
losebreath = 0
|
losebreath = 0
|
||||||
else
|
else
|
||||||
|
losebreath--
|
||||||
// we're running out of air, gasp for it!
|
// we're running out of air, gasp for it!
|
||||||
if (prob(25)) //High chance of gasping for air
|
if (prob(25)) //High chance of gasping for air
|
||||||
spawn emote("gasp")
|
spawn emote("gasp")
|
||||||
else if(health >= 0)
|
isbreathing = 0
|
||||||
|
else if(health >= 0 && !isbreathing)
|
||||||
if(holdbreath)
|
if(holdbreath)
|
||||||
// we're simply holding our breath, see if we can hold it longer
|
// we're simply holding our breath, see if we can hold it longer
|
||||||
if(health < 30)
|
if(health < 30)
|
||||||
@@ -457,6 +458,7 @@
|
|||||||
else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning
|
else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning
|
||||||
if(prob(20))
|
if(prob(20))
|
||||||
spawn(0) emote(pick("giggle", "laugh"))
|
spawn(0) emote(pick("giggle", "laugh"))
|
||||||
|
SA.moles = 0 //Hack to stop the damned surgeon from giggling.
|
||||||
|
|
||||||
|
|
||||||
if(breath.temperature > (T0C+66) && !(mutations & COLD_RESISTANCE)) // Hot air hurts :(
|
if(breath.temperature > (T0C+66) && !(mutations & COLD_RESISTANCE)) // Hot air hurts :(
|
||||||
|
|||||||
@@ -85,6 +85,7 @@ var/global/list/uneatable = list(
|
|||||||
|
|
||||||
|
|
||||||
process()
|
process()
|
||||||
|
spawn(0)
|
||||||
eat()
|
eat()
|
||||||
dissipate()
|
dissipate()
|
||||||
check_energy()
|
check_energy()
|
||||||
@@ -442,6 +443,7 @@ var/global/list/uneatable = list(
|
|||||||
consume_range = 3 //How many tiles out do we eat
|
consume_range = 3 //How many tiles out do we eat
|
||||||
|
|
||||||
process()
|
process()
|
||||||
|
spawn(0)
|
||||||
eat()
|
eat()
|
||||||
if(!target || prob(5))
|
if(!target || prob(5))
|
||||||
pickcultist()
|
pickcultist()
|
||||||
|
|||||||
@@ -7,7 +7,6 @@
|
|||||||
name = "conveyor belt"
|
name = "conveyor belt"
|
||||||
desc = "A conveyor belt."
|
desc = "A conveyor belt."
|
||||||
anchored = 1
|
anchored = 1
|
||||||
layer = 2.7
|
|
||||||
var/operating = 0 // 1 if running forward, -1 if backwards, 0 if off
|
var/operating = 0 // 1 if running forward, -1 if backwards, 0 if off
|
||||||
var/operable = 1 // true if can operate (no broken segments in this belt run)
|
var/operable = 1 // true if can operate (no broken segments in this belt run)
|
||||||
var/forwards // this is the default (forward) direction, set by the map dir, can be 0
|
var/forwards // this is the default (forward) direction, set by the map dir, can be 0
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 42 KiB After Width: | Height: | Size: 43 KiB |
Reference in New Issue
Block a user