mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2025-12-16 13:12:22 +00:00
Merge pull request #9242 from Spookerton/spkrtn/fix/misc-overlays
fix some misc hits on direct overlays access
This commit is contained in:
@@ -191,7 +191,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/obj/structure/atmospheric_retention_field/update_icon()
|
/obj/structure/atmospheric_retention_field/update_icon()
|
||||||
cut_overlays() //overlays.Cut()
|
cut_overlays()
|
||||||
var/list/dirs = list()
|
var/list/dirs = list()
|
||||||
for(var/obj/structure/atmospheric_retention_field/F in orange(src,1))
|
for(var/obj/structure/atmospheric_retention_field/F in orange(src,1))
|
||||||
dirs += get_dir(src, F)
|
dirs += get_dir(src, F)
|
||||||
|
|||||||
@@ -883,7 +883,7 @@ modules/mob/living/carbon/human/life.dm if you die, you will be zoomed out.
|
|||||||
if(addblends && standing && source_icon)
|
if(addblends && standing && source_icon)
|
||||||
var/image/I = image(source_icon, addblends)
|
var/image/I = image(source_icon, addblends)
|
||||||
I.blend_mode = BLEND_ADD
|
I.blend_mode = BLEND_ADD
|
||||||
standing.overlays += I
|
standing.add_overlay(I)
|
||||||
return standing
|
return standing
|
||||||
|
|
||||||
//STUB
|
//STUB
|
||||||
|
|||||||
@@ -471,14 +471,11 @@
|
|||||||
randpixel_xy()
|
randpixel_xy()
|
||||||
|
|
||||||
/obj/item/reagent_containers/food/condiment/carton/update_icon()
|
/obj/item/reagent_containers/food/condiment/carton/update_icon()
|
||||||
overlays.Cut()
|
cut_overlays()
|
||||||
|
|
||||||
if(reagents.total_volume)
|
if(reagents.total_volume)
|
||||||
var/image/filling = image('icons/obj/food.dmi', src, "[icon_state]10")
|
var/image/filling = image('icons/obj/food.dmi', src, "[icon_state]10")
|
||||||
|
|
||||||
filling.icon_state = "[icon_state]-[clamp(round(100 * reagents.total_volume / volume, 25), 0, 100)]"
|
filling.icon_state = "[icon_state]-[clamp(round(100 * reagents.total_volume / volume, 25), 0, 100)]"
|
||||||
|
add_overlay(filling)
|
||||||
overlays += filling
|
|
||||||
|
|
||||||
/obj/item/reagent_containers/food/condiment/carton/flour/rustic
|
/obj/item/reagent_containers/food/condiment/carton/flour/rustic
|
||||||
name = "flour sack"
|
name = "flour sack"
|
||||||
|
|||||||
@@ -166,21 +166,24 @@
|
|||||||
holder.trans_to(I, weights[I] / total)
|
holder.trans_to(I, weights[I] / total)
|
||||||
|
|
||||||
/obj/item/reagent_containers/cooking_container/update_icon()
|
/obj/item/reagent_containers/cooking_container/update_icon()
|
||||||
overlays.Cut()
|
cut_overlays()
|
||||||
|
|
||||||
if(food_items)
|
if(food_items)
|
||||||
var/image/filling = image('icons/obj/cooking_machines.dmi', src, "[icon_state]10")
|
var/image/filling = image('icons/obj/cooking_machines.dmi', src, "[icon_state]10")
|
||||||
|
|
||||||
var/percent = round((food_items / max_space) * 100)
|
var/percent = round((food_items / max_space) * 100)
|
||||||
switch(percent)
|
switch(percent)
|
||||||
if(0 to 2) filling.icon_state = "[icon_state]"
|
if(0 to 2)
|
||||||
if(3 to 24) filling.icon_state = "[icon_state]1"
|
filling.icon_state = "[icon_state]"
|
||||||
if(25 to 49) filling.icon_state = "[icon_state]2"
|
if(3 to 24)
|
||||||
if(50 to 74) filling.icon_state = "[icon_state]3"
|
filling.icon_state = "[icon_state]1"
|
||||||
if(75 to 79) filling.icon_state = "[icon_state]4"
|
if(25 to 49)
|
||||||
if(80 to INFINITY) filling.icon_state = "[icon_state]5"
|
filling.icon_state = "[icon_state]2"
|
||||||
|
if(50 to 74)
|
||||||
overlays += filling
|
filling.icon_state = "[icon_state]3"
|
||||||
|
if(75 to 79)
|
||||||
|
filling.icon_state = "[icon_state]4"
|
||||||
|
if(80 to INFINITY)
|
||||||
|
filling.icon_state = "[icon_state]5"
|
||||||
|
add_overlay(filling)
|
||||||
|
|
||||||
/obj/item/reagent_containers/cooking_container/oven
|
/obj/item/reagent_containers/cooking_container/oven
|
||||||
name = "oven dish"
|
name = "oven dish"
|
||||||
|
|||||||
@@ -225,8 +225,7 @@
|
|||||||
|
|
||||||
/obj/item/honey_frame/update_icon()
|
/obj/item/honey_frame/update_icon()
|
||||||
..()
|
..()
|
||||||
|
cut_overlays()
|
||||||
overlays.Cut()
|
|
||||||
if(honey > 0)
|
if(honey > 0)
|
||||||
add_overlay("honeycomb")
|
add_overlay("honeycomb")
|
||||||
|
|
||||||
|
|||||||
@@ -41,7 +41,7 @@
|
|||||||
// appearance = ma
|
// appearance = ma
|
||||||
|
|
||||||
|
|
||||||
// If your simple mob's update_icon() call calls overlays.Cut(), this needs to be called after this, or manually apply modifier_overly to overlays.
|
// Call this if your simple mob cuts overlays.
|
||||||
/mob/living/simple_mob/update_modifier_visuals()
|
/mob/living/simple_mob/update_modifier_visuals()
|
||||||
var/image/effects = null
|
var/image/effects = null
|
||||||
if(modifier_overlay)
|
if(modifier_overlay)
|
||||||
|
|||||||
@@ -89,12 +89,10 @@
|
|||||||
if(is_infesting)
|
if(is_infesting)
|
||||||
icon = infested.icon
|
icon = infested.icon
|
||||||
copy_overlays(infested)
|
copy_overlays(infested)
|
||||||
// overlays = infested.overlays
|
|
||||||
var/mutable_appearance/blob_head_overlay = mutable_appearance('icons/mob/blob.dmi', "blob_head")
|
var/mutable_appearance/blob_head_overlay = mutable_appearance('icons/mob/blob.dmi', "blob_head")
|
||||||
if(overmind)
|
if(overmind)
|
||||||
blob_head_overlay.color = overmind.blob_type.complementary_color
|
blob_head_overlay.color = overmind.blob_type.complementary_color
|
||||||
color = initial(color)//looks better.
|
color = initial(color)//looks better.
|
||||||
// overlays += blob_head_overlay
|
|
||||||
add_overlay(blob_head_overlay, TRUE)
|
add_overlay(blob_head_overlay, TRUE)
|
||||||
|
|
||||||
/mob/living/simple_mob/blob/spore/handle_special()
|
/mob/living/simple_mob/blob/spore/handle_special()
|
||||||
|
|||||||
@@ -144,15 +144,3 @@
|
|||||||
//Constructs levitate, can fall from a shuttle with no harm, and are piloted by either damned spirits or some otherworldly entity. Let 'em float in space.
|
//Constructs levitate, can fall from a shuttle with no harm, and are piloted by either damned spirits or some otherworldly entity. Let 'em float in space.
|
||||||
/mob/living/simple_mob/construct/Process_Spacemove(var/check_drift = 0)
|
/mob/living/simple_mob/construct/Process_Spacemove(var/check_drift = 0)
|
||||||
return TRUE
|
return TRUE
|
||||||
|
|
||||||
/*
|
|
||||||
// Glowing Procs
|
|
||||||
/mob/living/simple_mob/construct/proc/add_glow()
|
|
||||||
var/image/eye_glow = image(icon,"glow-[icon_state]")
|
|
||||||
eye_glow.plane = PLANE_LIGHTING_ABOVE
|
|
||||||
overlays += eye_glow
|
|
||||||
set_light(2, -2, l_color = "#FFFFFF")
|
|
||||||
|
|
||||||
/mob/living/simple_mob/construct/proc/remove_glow()
|
|
||||||
overlays.Cut()
|
|
||||||
*/
|
|
||||||
|
|||||||
Reference in New Issue
Block a user