mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-22 04:24:20 +01:00
Fix alarms triggering on non-contact levels, spectral blade ghost fix, assigning outfits runtime fix
This commit is contained in:
@@ -72,7 +72,7 @@
|
||||
var/mob/dead/observer/current_spirits = list()
|
||||
|
||||
for(var/mob/dead/observer/O in GLOB.player_list)
|
||||
if(is_type_in_list(O.following, contents))
|
||||
if((O.following in contents))
|
||||
ghost_counter++
|
||||
O.invisibility = 0
|
||||
current_spirits |= O
|
||||
|
||||
@@ -99,7 +99,7 @@
|
||||
var/indestructible = 0 // If set, prevents aliens from destroying it
|
||||
var/keep_preset_name = 0
|
||||
|
||||
var/report_power_alarm = 1
|
||||
var/report_power_alarm = TRUE
|
||||
|
||||
var/shock_proof = 0 //if set to 1, this APC will not arc bolts of electricity if it's overloaded.
|
||||
|
||||
@@ -117,11 +117,11 @@
|
||||
operating = 0
|
||||
|
||||
/obj/machinery/power/apc/noalarm
|
||||
report_power_alarm = 0
|
||||
report_power_alarm = FALSE
|
||||
|
||||
/obj/machinery/power/apc/syndicate //general syndicate access
|
||||
req_access = list(access_syndicate)
|
||||
report_power_alarm = 0
|
||||
report_power_alarm = FALSE
|
||||
|
||||
/obj/item/apc_electronics
|
||||
name = "power control module"
|
||||
@@ -1171,14 +1171,14 @@
|
||||
lighting = autoset(lighting, 1)
|
||||
environ = autoset(environ, 1)
|
||||
autoflag = 3
|
||||
if(report_power_alarm)
|
||||
if(report_power_alarm && is_station_contact(z))
|
||||
SSalarms.power_alarm.clearAlarm(loc, src)
|
||||
else if(cell.charge < 1250 && cell.charge > 750 && longtermpower < 0) // <30%, turn off equipment
|
||||
if(autoflag != 2)
|
||||
equipment = autoset(equipment, 2)
|
||||
lighting = autoset(lighting, 1)
|
||||
environ = autoset(environ, 1)
|
||||
if(report_power_alarm)
|
||||
if(report_power_alarm && is_station_contact(z))
|
||||
SSalarms.power_alarm.triggerAlarm(loc, src)
|
||||
autoflag = 2
|
||||
else if(cell.charge < 750 && cell.charge > 10) // <15%, turn off lighting & equipment
|
||||
@@ -1186,7 +1186,7 @@
|
||||
equipment = autoset(equipment, 2)
|
||||
lighting = autoset(lighting, 2)
|
||||
environ = autoset(environ, 1)
|
||||
if(report_power_alarm)
|
||||
if(report_power_alarm && is_station_contact(z))
|
||||
SSalarms.power_alarm.triggerAlarm(loc, src)
|
||||
autoflag = 1
|
||||
else if(cell.charge <= 0) // zero charge, turn all off
|
||||
@@ -1194,7 +1194,7 @@
|
||||
equipment = autoset(equipment, 0)
|
||||
lighting = autoset(lighting, 0)
|
||||
environ = autoset(environ, 0)
|
||||
if(report_power_alarm)
|
||||
if(report_power_alarm && is_station_contact(z))
|
||||
SSalarms.power_alarm.triggerAlarm(loc, src)
|
||||
autoflag = 0
|
||||
|
||||
@@ -1250,7 +1250,7 @@
|
||||
equipment = autoset(equipment, 0)
|
||||
lighting = autoset(lighting, 0)
|
||||
environ = autoset(environ, 0)
|
||||
if(report_power_alarm)
|
||||
if(report_power_alarm && is_station_contact(z))
|
||||
SSalarms.power_alarm.triggerAlarm(loc, src)
|
||||
autoflag = 0
|
||||
|
||||
|
||||
@@ -82,11 +82,10 @@
|
||||
var/heal_burn = 0
|
||||
var/heal_oxy = 0
|
||||
|
||||
|
||||
/obj/item/organ/internal/heart/cursed/attack(mob/living/carbon/human/H, mob/living/carbon/human/user, obj/target)
|
||||
if(H == user && istype(H))
|
||||
if(NO_BLOOD in H.dna.species.species_traits)
|
||||
to_chat(H, "<span class = 'userdanger'>\The [src] is not compatible with your form!</span>")
|
||||
to_chat(H, "<span class='userdanger'>[src] is not compatible with your form!</span>")
|
||||
return
|
||||
playsound(user,'sound/effects/singlebeat.ogg', 40, 1)
|
||||
user.drop_item()
|
||||
@@ -111,17 +110,16 @@
|
||||
if(owner)
|
||||
to_chat(owner, "<span class='userdanger'>Your heart has been replaced with a cursed one, you have to pump this one manually otherwise you'll die!</span>")
|
||||
|
||||
|
||||
/datum/action/item_action/organ_action/cursed_heart
|
||||
name = "pump your blood"
|
||||
|
||||
//You are now brea- pumping blood manually
|
||||
/datum/action/item_action/organ_action/cursed_heart/Trigger()
|
||||
. = ..()
|
||||
if(. && istype(target,/obj/item/organ/internal/heart/cursed))
|
||||
if(. && istype(target, /obj/item/organ/internal/heart/cursed))
|
||||
var/obj/item/organ/internal/heart/cursed/cursed_heart = target
|
||||
|
||||
if(world.time < (cursed_heart.last_pump + (cursed_heart.pump_delay-10))) //no spam
|
||||
if(world.time < (cursed_heart.last_pump + (cursed_heart.pump_delay - 10))) //no spam
|
||||
to_chat(owner, "<span class='userdanger'>Too soon!</span>")
|
||||
return
|
||||
|
||||
@@ -132,7 +130,7 @@
|
||||
var/mob/living/carbon/human/H = owner
|
||||
if(istype(H))
|
||||
if(!(NO_BLOOD in H.dna.species.species_traits))
|
||||
H.blood_volume = min(H.blood_volume + cursed_heart.blood_loss*0.5, BLOOD_VOLUME_NORMAL)
|
||||
H.blood_volume = min(H.blood_volume + cursed_heart.blood_loss * 0.5, BLOOD_VOLUME_NORMAL)
|
||||
if(owner.client)
|
||||
owner.client.color = ""
|
||||
|
||||
|
||||
Reference in New Issue
Block a user