From d611d0c68d73732392b97fbada70b47cc17bf3cb Mon Sep 17 00:00:00 2001 From: VerySoft Date: Thu, 23 Jun 2022 21:55:43 -0400 Subject: [PATCH] XIII tweaks! Couple little issues I missed! --- code/modules/mob/living/silicon/pai/pai.dm | 55 ++++++++++-------- code/modules/mob/living/silicon/pai/pai_vr.dm | 19 ++++-- icons/mob/pai_vr32x64.dmi | Bin 0 -> 602 bytes icons/mob/pai_vr64x32.dmi | Bin 0 -> 507 bytes pai_vr64x32.dmi | Bin 0 -> 186 bytes 5 files changed, 45 insertions(+), 29 deletions(-) create mode 100644 icons/mob/pai_vr32x64.dmi create mode 100644 icons/mob/pai_vr64x32.dmi create mode 100644 pai_vr64x32.dmi diff --git a/code/modules/mob/living/silicon/pai/pai.dm b/code/modules/mob/living/silicon/pai/pai.dm index af8277e9870..2ac08ea4f4f 100644 --- a/code/modules/mob/living/silicon/pai/pai.dm +++ b/code/modules/mob/living/silicon/pai/pai.dm @@ -251,7 +251,7 @@ if(world.time <= last_special) to_chat(src, "You can't unfold yet.") return - + last_special = world.time + 100 if(istype(card.loc, /obj/machinery)) // VOREStation edit, this statement allows pAIs stuck in a machine to eject themselves. @@ -353,7 +353,7 @@ return else if(chassis == "13") resting = !resting - update_transform() + //update_transform() I want this to make you ROTATE like normal HUMANS do! But! There's lots of problems and I don't know how to fix them! else resting = !resting icon_state = resting ? "[chassis]_rest" : "[chassis]" @@ -362,37 +362,42 @@ canmove = !resting +/* /mob/living/silicon/pai/update_transform() - . = ..() - if(chassis != "13") - return - to_chat(src, "I'm gonna try to rotate the icon!") + var/desired_scale_x = size_multiplier * icon_scale_x var/desired_scale_y = size_multiplier * icon_scale_y - appearance_flags |= PIXEL_SCALE + // Now for the regular stuff. var/matrix/M = matrix() - var/anim_time = 3 + M.Scale(desired_scale_x, desired_scale_y) + M.Translate(0, (vis_height/2)*(desired_scale_y-1)) - if(resting) - var/randn = rand(1, 2) - if(randn <= 1) // randomly choose a rotation - M.Turn(-90) - else + if(chassis != "13") + appearance_flags |= PIXEL_SCALE + + var/anim_time = 3 + + if(resting) M.Turn(90) - M.Scale(desired_scale_y, desired_scale_x)//VOREStation Edit - if(holo_icon_dimension == 64)//VOREStation Edit - M.Translate(13,-22) + M.Scale(desired_scale_y, desired_scale_x) + if(holo_icon_dimension_X == 64 && holo_icon_dimension_Y == 64) + M.Translate(13,-22) + else if(holo_icon_dimension_X == 32 && holo_icon_dimension_Y == 64) + M.Translate(1,-22) + else if(holo_icon_dimension_X == 64 && holo_icon_dimension_Y == 32) + M.Translate(13,-6) + else + M.Translate(1,-6) + layer = MOB_LAYER -0.01 // Fix for a byond bug where turf entry order no longer matters else - M.Translate(1,-6) - layer = MOB_LAYER -0.01 // Fix for a byond bug where turf entry order no longer matters - else - M.Scale(desired_scale_x, desired_scale_y)//VOREStation Edit - M.Translate(0, (vis_height/2)*(desired_scale_y-1)) //VOREStation edit - layer = MOB_LAYER // Fix for a byond bug where turf entry order no longer matters - animate(src, transform = M, time = anim_time) - - + M.Scale(desired_scale_x, desired_scale_y) + M.Translate(0, (vis_height/2)*(desired_scale_y-1)) + layer = MOB_LAYER // Fix for a byond bug where turf entry order no longer matters + animate(src, transform = M, time = anim_time) + src.transform = M + handle_status_indicators() +*/ //Overriding this will stop a number of headaches down the track. /mob/living/silicon/pai/attackby(obj/item/weapon/W as obj, mob/user as mob) if(W.force) diff --git a/code/modules/mob/living/silicon/pai/pai_vr.dm b/code/modules/mob/living/silicon/pai/pai_vr.dm index 7930778e7e2..9da5e849685 100644 --- a/code/modules/mob/living/silicon/pai/pai_vr.dm +++ b/code/modules/mob/living/silicon/pai/pai_vr.dm @@ -8,7 +8,8 @@ var/eye_color = "#00ff0d" var/icon/holo_icon var/icon/holo_icon_north - var/holo_icon_dimension = 32 + var/holo_icon_dimension_X = 32 + var/holo_icon_dimension_Y = 32 var/global/list/wide_chassis = list( "rat", "panther", @@ -88,6 +89,7 @@ /mob/living/silicon/pai/update_icon() //Some functions cause this to occur, such as resting ..() if(chassis == "13") + icon = holo_icon add_eyes() return @@ -120,6 +122,7 @@ /mob/living/silicon/pai/update_icons() //And other functions cause this to occur, such as digesting someone. ..() if(chassis == "13") + icon = holo_icon add_eyes() return update_fullness_pai() @@ -211,12 +214,20 @@ remove_eyes() if(chassis == "13") if(holo_icon.Width() > 32) - eye_layer = image('icons/mob/pai_vr64x64.dmi', "type13-eyes") + holo_icon_dimension_X = 64 pixel_x = -16 default_pixel_x = -16 - holo_icon_dimension = 64 - else + if(holo_icon.Height() > 32) + holo_icon_dimension_Y = 64 + if(holo_icon_dimension_X == 32 && holo_icon_dimension_Y == 32) eye_layer = image('icons/mob/pai_vr.dmi', "type13-eyes") + else if(holo_icon_dimension_X == 32 && holo_icon_dimension_Y == 64) + eye_layer = image('icons/mob/pai_vr32x64.dmi', "type13-eyes") + else if(holo_icon_dimension_X == 64 && holo_icon_dimension_Y == 32) + eye_layer = image('icons/mob/pai_vr64x32.dmi', "type13-eyes") + else if(holo_icon_dimension_X == 64 && holo_icon_dimension_Y == 64) + eye_layer = image('icons/mob/pai_vr64x64.dmi', "type13-eyes") + else else if(chassis in allows_eye_color) eye_layer = image(icon, "[icon_state]-eyes") else return diff --git a/icons/mob/pai_vr32x64.dmi b/icons/mob/pai_vr32x64.dmi new file mode 100644 index 0000000000000000000000000000000000000000..02c15d3de82c33c029146c16fd8725c76a7bdccf GIT binary patch literal 602 zcmeAS@N?(olHy`uVBq!ia0vp^4nW+%!3HFEH|A#nsq(6jh!U67;^d;tf|AVqJO+k} zIjjc_`I-%QST9)G9Th*bmdhn4Zq))U<~xj>&PF1uZY+BAZBO`P+nPr$25weMGwjL? z{(N?QH(%U4p+tA5N~JfO+k4MkGseZ6UaR|lpWwYkY5S8!2^B@zGxsk_FbPSX!E{LC zCEL3a85v7{xep8sjPpEQ978JRyuIU?cgTQ&!SPoAPW#nABL8fTt6HHYkZ`F_sZ4*T z%D1$}A5MR^<=%cdwemXCET#-bU&bvB%NU{@f*EudXf}vl5OLtn;99_H!g_%?=`ekn zYzuon?tEU^UzB;roBzK1 z^ZnKb=6tTn{$P0Q`JB&xIu5-0Gd*m<)SvRdIPXaPS)cdsRLt%*4(-vb>uOJ}zQ6A< z>y6oAjO00wG|wgUJ05xcx%%wS5{8ZK2j&&q$vV7I-0*zPUW=8$5Q*6PVf{DGh=-EX spE7)Zqy9nOW_P+Hzav41RsLj%XLigCHz@b-0wxv)Pgg&ebxsLQ0N?NL1ONa4 literal 0 HcmV?d00001 diff --git a/icons/mob/pai_vr64x32.dmi b/icons/mob/pai_vr64x32.dmi new file mode 100644 index 0000000000000000000000000000000000000000..468e5cd216ef92d6dd6aac992cb7d1d72dbda3a7 GIT binary patch literal 507 zcmeAS@N?(olHy`uVBq!ia0vp^4M6O`!3HERU8}DLQsq@45hX6E#mPmP1tppJc?=8{ zb65`=@--XquwJmVJ1Tx=EtgA9+^Pjy%y$?$osC3R-B|SK+n(^pwl$Ah4BV`iX4sV( z{Q2zqZoas8!k2k5llG`GFV6PNHDg@7>9xA=_X*xxl(s)vlu%KWJ#+t}1e1{D8BB*H zUb4O0DkHdS>tM9e- zaz}Z~_{_MxYhCw_b1#JhrZFCnWSGNv;3(6IRaJIc%0dSoJI9;5v$`<7co#SA=_X69 z2T%Spbfz-U%99 zKJ$?wteukTAW;zSx}OhpU1#ZF(){zps4iwm*9erU!Q1s>uQ}lb3S-OsKG_! z2aj~l`)HnIDC+6mVPPC(eA(EmLB?2EFO@aiUVH-^!zU^JqWUEv?||m=db&7