move this..
This commit is contained in:
@@ -91,20 +91,13 @@
|
||||
..()
|
||||
update_resting_icon(resting)
|
||||
|
||||
/mob/living/silicon/pai/proc/update_icon()
|
||||
if((chassis == "custom") && !custom_holoform_icon)
|
||||
chassis = pick(possible_chassis - "custom")
|
||||
if(chassis != "custom")
|
||||
icon_state = "[chassis]_[resting]"
|
||||
else
|
||||
icon = custom_holoform_icon
|
||||
icon_state = ""
|
||||
update_transform()
|
||||
|
||||
/mob/living/silicon/pai/proc/update_resting_icon(rest)
|
||||
if(chassis == "custom")
|
||||
lying_prev = lying
|
||||
if(resting)
|
||||
lying = pick(90, 270)
|
||||
else
|
||||
lying = 0
|
||||
else
|
||||
lying = 0
|
||||
update_icon()
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
/mob/living/silicon/pai/proc/update_icon()
|
||||
if((chassis == "custom") && !custom_holoform_icon)
|
||||
chassis = pick(possible_chassis - "custom")
|
||||
if(chassis != "custom")
|
||||
icon_state = "[chassis]_[resting]"
|
||||
else
|
||||
icon = custom_holoform_icon
|
||||
icon_state = ""
|
||||
update_transform()
|
||||
|
||||
//Might be a copypaste from /mob/living/carbon/update_transform(), is it time to pull the combined code to /living yet? didn't want edge cases.
|
||||
/mob/living/silicon/pai/update_transform()
|
||||
var/matrix/ntransform = matrix(transform)
|
||||
var/final_pixel_y = pixel_y
|
||||
var/final_dir = dir
|
||||
if(lying != lying_prev)
|
||||
ntransform.TurnTo(lying_prev, lying)
|
||||
if(!lying) //standing
|
||||
final_pixel_y = get_standard_pixel_y_offset()
|
||||
else
|
||||
if(!lying_prev)
|
||||
pixel_y = get_standard_pixel_y_offset()
|
||||
final_pixel_y = get_standard_pixel_y_offset(lying)
|
||||
if(dir & (EAST|WEST))
|
||||
final_dir = pick(NORTH, SOUTH)
|
||||
animate(src, transform = ntransform, time = 2, pixel_y = final_pixel_y, dir = final_dir, easing = EASE_IN | EASE_OUT)
|
||||
Reference in New Issue
Block a user