mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 19:47:22 +01:00
Refactors screen objects to /atom/movable (#24068)
* introduce helper + remove unused proc * we love compatibility * Update code/_onclick/hud/action_button.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/action_button.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/alert.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/blob_overmind.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/blob_overmind.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/blob_overmind.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/modules/martial_arts/martial.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/modules/mining/lavaland/loot/tendril_loot.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/modules/mob/living/carbon/human/species/shadow.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/modules/mob/living/carbon/human/species/shadow.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/modules/mob/living/living_update_status.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/screen_objects.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/screen_objects.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/_onclick/hud/screen_objects.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/game/objects/items/weapons/storage/internal.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/game/machinery/computer/camera_advanced.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/game/machinery/computer/camera_advanced.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/game/objects/items/weapons/storage/internal.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * Update code/game/mecha/mecha.dm Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> * deconflict --------- Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com>
This commit is contained in:
@@ -164,7 +164,7 @@
|
||||
if(lum_count > 0.2)
|
||||
if(!thrown_alert)
|
||||
thrown_alert = TRUE
|
||||
throw_alert("light", /obj/screen/alert/lightexposure)
|
||||
throw_alert("light", /atom/movable/screen/alert/lightexposure)
|
||||
alpha = 255
|
||||
speed = initial(speed)
|
||||
else
|
||||
|
||||
@@ -12,8 +12,8 @@
|
||||
var/toggle = FALSE
|
||||
var/stealthcooldown = 0
|
||||
var/default_stealth_cooldown = 10 SECONDS
|
||||
var/obj/screen/alert/canstealthalert
|
||||
var/obj/screen/alert/instealthalert
|
||||
var/atom/movable/screen/alert/canstealthalert
|
||||
var/atom/movable/screen/alert/instealthalert
|
||||
|
||||
/mob/living/simple_animal/hostile/guardian/assassin/Initialize(mapload, mob/living/host)
|
||||
. = ..()
|
||||
@@ -88,12 +88,12 @@
|
||||
if(stealthcooldown <= world.time)
|
||||
if(toggle)
|
||||
if(!instealthalert)
|
||||
instealthalert = throw_alert("instealth", /obj/screen/alert/instealth)
|
||||
instealthalert = throw_alert("instealth", /atom/movable/screen/alert/instealth)
|
||||
clear_alert("canstealth")
|
||||
canstealthalert = null
|
||||
else
|
||||
if(!canstealthalert)
|
||||
canstealthalert = throw_alert("canstealth", /obj/screen/alert/canstealth)
|
||||
canstealthalert = throw_alert("canstealth", /atom/movable/screen/alert/canstealth)
|
||||
clear_alert("instealth")
|
||||
instealthalert = null
|
||||
else
|
||||
|
||||
@@ -11,13 +11,13 @@
|
||||
tech_fluff_string = "Boot sequence complete. Charge modules loaded. Holoparasite swarm online."
|
||||
bio_fluff_string = "Your scarab swarm finishes mutating and stirs to life, ready to deal damage."
|
||||
var/charging = FALSE
|
||||
var/obj/screen/alert/chargealert
|
||||
var/atom/movable/screen/alert/chargealert
|
||||
|
||||
/mob/living/simple_animal/hostile/guardian/charger/Life()
|
||||
. = ..()
|
||||
if(ranged_cooldown <= world.time)
|
||||
if(!chargealert)
|
||||
chargealert = throw_alert("charge", /obj/screen/alert/cancharge)
|
||||
chargealert = throw_alert("charge", /atom/movable/screen/alert/cancharge)
|
||||
else
|
||||
clear_alert("charge")
|
||||
chargealert = null
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
id = "morph_ambush"
|
||||
duration = -1
|
||||
tick_interval = MORPH_AMBUSH_PERFECTION_TIME
|
||||
alert_type = /obj/screen/alert/status_effect/morph_ambush
|
||||
alert_type = /atom/movable/screen/alert/status_effect/morph_ambush
|
||||
|
||||
/datum/status_effect/morph_ambush/tick()
|
||||
STOP_PROCESSING(SSfastprocess, src)
|
||||
@@ -49,7 +49,7 @@
|
||||
linked_alert.name = "Perfect Ambush!"
|
||||
linked_alert.desc = "You have prepared an ambush! Your disguise is flawless!"
|
||||
|
||||
/obj/screen/alert/status_effect/morph_ambush
|
||||
/atom/movable/screen/alert/status_effect/morph_ambush
|
||||
name = "Ambush!"
|
||||
desc = "You have prepared an ambush!"
|
||||
icon_state = "morph_ambush"
|
||||
|
||||
@@ -502,7 +502,7 @@
|
||||
// 2 * initial_rate - upgrade_level
|
||||
rate += initial(health_loss_rate)
|
||||
adjustHealth(rate)
|
||||
throw_alert(ALERT_CATEGORY_NOPOWER, /obj/screen/alert/pulse_nopower)
|
||||
throw_alert(ALERT_CATEGORY_NOPOWER, /atom/movable/screen/alert/pulse_nopower)
|
||||
|
||||
if(regen_lock > 0)
|
||||
if(--regen_lock == 0)
|
||||
@@ -704,7 +704,7 @@
|
||||
return
|
||||
visible_message("<span class='danger'>[src] [pick("fizzles", "wails", "flails")] in anguish!</span>")
|
||||
playsound(get_turf(src), pick(hurt_sounds), 30, TRUE)
|
||||
throw_alert(ALERT_CATEGORY_NOREGEN, /obj/screen/alert/pulse_noregen)
|
||||
throw_alert(ALERT_CATEGORY_NOREGEN, /atom/movable/screen/alert/pulse_noregen)
|
||||
switch(severity)
|
||||
if(EMP_LIGHT)
|
||||
adjustHealth(round(max(initial(health) / 4, round(maxHealth / 8))))
|
||||
@@ -843,12 +843,12 @@
|
||||
cell_location.update_icon() //update power meters and such
|
||||
cell_to_charge.update_icon()
|
||||
|
||||
/obj/screen/alert/pulse_nopower
|
||||
/atom/movable/screen/alert/pulse_nopower
|
||||
name = "No Power"
|
||||
desc = "You are not connected to a cable or machine and are losing health!"
|
||||
icon_state = "pd_nopower"
|
||||
|
||||
/obj/screen/alert/pulse_noregen
|
||||
/atom/movable/screen/alert/pulse_noregen
|
||||
name = "Regeneration Stalled"
|
||||
desc = "You've been EMP'd and cannot regenerate health!"
|
||||
icon_state = "pd_noregen"
|
||||
|
||||
@@ -144,7 +144,7 @@
|
||||
SEND_SOUND(player_client, sound('sound/misc/notice2.ogg'))
|
||||
window_flash(player_client)
|
||||
|
||||
var/obj/screen/alert/notify_soulstone/A = player_mob.throw_alert("\ref[src]_soulstone_thingy", /obj/screen/alert/notify_soulstone)
|
||||
var/atom/movable/screen/alert/notify_soulstone/A = player_mob.throw_alert("\ref[src]_soulstone_thingy", /atom/movable/screen/alert/notify_soulstone)
|
||||
if(player_client.prefs && player_client.prefs.UI_style)
|
||||
A.icon = ui_style2icon(player_client.prefs.UI_style)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user