mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 12:41:09 +01:00
[MIRROR] Fix royal alien pixel offset, change getter to variable (#1641)
* Fix royal alien pixel offset, change getter to variable (#54706) Fixed a bug where royal aliens would have their base pixel offset applied twice, making them off-center (https://i.imgur.com/BtspaM0.png) Changed the mob/living procs get_standard_pixel_x_offset() and get_standard_pixel_y_offset() to variables (body_position_pixel_x_offset and body_position_pixel_y_offset), to match the contribution guidelines. Also corrected a few random things that weren't using base pixels but should have been. * Fix royal alien pixel offset, change getter to variable * Update pixel_shift.dm Co-authored-by: Yenwodyah <yenwodyah@gmail.com> Co-authored-by: Azarak <azarak10@gmail.com>
This commit is contained in:
co-authored by
Yenwodyah
Azarak
parent
2ff5f9b259
commit
8db24d79e6
@@ -65,14 +65,14 @@
|
||||
"<span class='hear'>You hear squelching...</span>")
|
||||
|
||||
/obj/structure/bed/nest/post_buckle_mob(mob/living/M)
|
||||
M.pixel_y = 0
|
||||
M.pixel_x = initial(M.pixel_x) + 2
|
||||
M.pixel_y = M.base_pixel_y
|
||||
M.pixel_x = M.base_pixel_x + 2
|
||||
M.layer = BELOW_MOB_LAYER
|
||||
add_overlay(nest_overlay)
|
||||
|
||||
/obj/structure/bed/nest/post_unbuckle_mob(mob/living/M)
|
||||
M.pixel_x = M.base_pixel_x + M.get_standard_pixel_x_offset(M.body_position == LYING_DOWN)
|
||||
M.pixel_y = M.base_pixel_y + M.get_standard_pixel_y_offset(M.body_position == LYING_DOWN)
|
||||
M.pixel_x = M.base_pixel_x + M.body_position_pixel_x_offset
|
||||
M.pixel_y = M.base_pixel_y + M.body_position_pixel_y_offset
|
||||
M.layer = initial(M.layer)
|
||||
cut_overlay(nest_overlay)
|
||||
|
||||
|
||||
@@ -90,7 +90,8 @@
|
||||
/obj/structure/bed/roller/post_buckle_mob(mob/living/M)
|
||||
density = TRUE
|
||||
icon_state = "up"
|
||||
M.pixel_y = initial(M.pixel_y)
|
||||
//Push them up from the normal lying position
|
||||
M.pixel_y = M.base_pixel_y
|
||||
|
||||
/obj/structure/bed/roller/Moved()
|
||||
. = ..()
|
||||
@@ -101,8 +102,8 @@
|
||||
/obj/structure/bed/roller/post_unbuckle_mob(mob/living/M)
|
||||
density = FALSE
|
||||
icon_state = "down"
|
||||
M.pixel_x = M.base_pixel_x + M.get_standard_pixel_x_offset(M.body_position == LYING_DOWN)
|
||||
M.pixel_y = M.base_pixel_y + M.get_standard_pixel_y_offset(M.body_position == LYING_DOWN)
|
||||
//Set them back down to the normal lying position
|
||||
M.pixel_y = M.base_pixel_y + M.body_position_pixel_y_offset
|
||||
|
||||
|
||||
/obj/item/roller
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
var/matrix/m180 = matrix(L.transform)
|
||||
m180.Turn(180)
|
||||
animate(L, transform = m180, time = 3)
|
||||
L.pixel_y = L.get_standard_pixel_y_offset(TRUE)
|
||||
L.pixel_y = L.base_pixel_y + PIXEL_Y_OFFSET_LYING
|
||||
else if (has_buckled_mobs())
|
||||
for(var/mob/living/L in buckled_mobs)
|
||||
user_unbuckle_mob(L, user)
|
||||
@@ -124,7 +124,7 @@
|
||||
var/matrix/m180 = matrix(M.transform)
|
||||
m180.Turn(180)
|
||||
animate(M, transform = m180, time = 3)
|
||||
M.pixel_y = M.base_pixel_y + M.get_standard_pixel_y_offset(TRUE)
|
||||
M.pixel_y = M.base_pixel_y + PIXEL_Y_OFFSET_LYING
|
||||
M.adjustBruteLoss(30)
|
||||
src.visible_message(text("<span class='danger'>[M] falls free of [src]!</span>"))
|
||||
unbuckle_mob(M,force=1)
|
||||
|
||||
Reference in New Issue
Block a user