Merge pull request #15943 from SandPoot/silicon-stuff

Update some silicon stuff
This commit is contained in:
Lin
2023-01-18 17:52:06 -07:00
committed by GitHub
8 changed files with 30 additions and 57 deletions
@@ -9,9 +9,6 @@
adjustBruteLoss(damage_amount, forced = forced)
if(BURN)
adjustFireLoss(damage_amount, forced = forced)
if(OXY)
if(damage < 0 || forced) //we shouldn't be taking oxygen damage through this proc, but we'll let it heal.
adjustOxyLoss(damage_amount, forced = forced)
return 1
@@ -30,7 +27,7 @@
/mob/living/silicon/setCloneLoss(amount, updating_health = TRUE, forced = FALSE)
return FALSE
/mob/living/silicon/adjustStaminaLoss(amount, updating_health = 1, forced = FALSE)//immune to stamina damage.
/mob/living/silicon/adjustStaminaLoss(amount, updating_health = 1, forced = FALSE) //immune to stamina damage.
return FALSE
/mob/living/silicon/setStaminaLoss(amount, updating_health = 1)
@@ -41,3 +38,15 @@
/mob/living/silicon/setOrganLoss(slot, amount)
return FALSE
/mob/living/silicon/adjustOxyLoss(amount, updating_health = TRUE, forced = FALSE) //immune to oxygen damage
if(istype(src, /mob/living/silicon/ai)) //ais are snowflakes and use oxyloss for being in AI cards and having no battery
return ..()
return FALSE
/mob/living/silicon/setOxyLoss(amount, updating_health = TRUE, forced = FALSE)
if(istype(src, /mob/living/silicon/ai)) //ditto
return ..()
return FALSE
@@ -85,15 +85,6 @@
/mob/living/silicon/pai/adjustFireLoss(amount, updating_health = TRUE, forced = FALSE, only_robotic = FALSE, only_organic = TRUE)
return take_holo_damage(amount)
/mob/living/silicon/pai/adjustToxLoss(amount, updating_health = TRUE, forced = FALSE, toxins_type = TOX_DEFAULT)
return FALSE
/mob/living/silicon/pai/adjustOxyLoss(amount, updating_health = TRUE, forced = FALSE)
return FALSE
/mob/living/silicon/pai/adjustCloneLoss(amount, updating_health = TRUE, forced = FALSE)
return FALSE
/mob/living/silicon/pai/adjustStaminaLoss(amount, updating_health, forced = FALSE)
if(forced)
take_holo_damage(amount)
@@ -108,27 +99,3 @@
/mob/living/silicon/pai/getFireLoss()
return emittermaxhealth - emitterhealth
/mob/living/silicon/pai/getToxLoss(toxins_type = TOX_OMNI)
return FALSE
/mob/living/silicon/pai/getOxyLoss()
return FALSE
/mob/living/silicon/pai/getCloneLoss()
return FALSE
/mob/living/silicon/pai/getStaminaLoss()
return FALSE
/mob/living/silicon/pai/setCloneLoss()
return FALSE
/mob/living/silicon/pai/setStaminaLoss()
return FALSE
/mob/living/silicon/pai/setToxLoss(toxins_type = TOX_OMNI)
return FALSE
/mob/living/silicon/pai/setOxyLoss()
return FALSE
@@ -1,7 +1,6 @@
/mob/living/silicon/robot/BiologicalLife(delta_time, times_fired)
if(!(. = ..()))
return
adjustOxyLoss(-10) //we're a robot!
handle_robot_hud_updates()
handle_robot_cell()
@@ -17,12 +17,16 @@
icon_state = "[module.cyborg_base_icon]-wreck"
if(module.cyborg_pixel_offset)
pixel_x = module.cyborg_pixel_offset
var/matrix/M = transform
M.c = module.cyborg_pixel_offset
transform = M
//End of citadel changes
if(module.cyborg_base_icon == "robot")
icon = 'icons/mob/robots.dmi'
pixel_x = initial(pixel_x)
var/matrix/M = transform
M.c = 0 // Cyborg's initial x offset is very likely to be 0
transform = M
if(stat != DEAD && !(IsUnconscious() || IsStun() || IsParalyzed() || low_power_mode)) //Not dead, not stunned.
if(!eye_lights)
eye_lights = new()
@@ -45,14 +45,6 @@
adjustBruteLoss(damage)
if(BURN)
adjustFireLoss(damage)
if(TOX)
adjustToxLoss(damage)
if(OXY)
adjustOxyLoss(damage)
if(CLONE)
adjustCloneLoss(damage)
if(STAMINA)
adjustStaminaLoss(damage)
/mob/living/silicon/attack_paw(mob/living/user)
return attack_hand(user)
@@ -75,9 +75,8 @@
restoring = FALSE
return
ai_slot.locked = TRUE
A.adjustOxyLoss(-5, FALSE)
A.adjustFireLoss(-5, FALSE)
A.adjustToxLoss(-5, FALSE)
A.adjustOxyLoss(-5, FALSE, FALSE)
A.adjustFireLoss(-5, FALSE, FALSE)
A.adjustBruteLoss(-5, FALSE)
// Please don't forget to update health, otherwise the below if statements will probably always fail.