Merge pull request #3389 from Verkister/mobvors

Fixes resting and vore icon issues with mobs and silicons
This commit is contained in:
Spades
2018-04-10 14:44:36 -04:00
committed by GitHub
10 changed files with 30 additions and 23 deletions

View File

@@ -1088,10 +1088,10 @@ default behaviour is:
/mob/living/proc/is_sentient() /mob/living/proc/is_sentient()
return TRUE return TRUE
/* //VOREStation Edit. We have a better system in place.
/mob/living/update_transform() /mob/living/update_transform()
// First, get the correct size. // First, get the correct size.
var/desired_scale = icon_scale var/desired_scale = size_multiplier //VOREStation edit
for(var/datum/modifier/M in modifiers) for(var/datum/modifier/M in modifiers)
if(!isnull(M.icon_scale_percent)) if(!isnull(M.icon_scale_percent))
desired_scale *= M.icon_scale_percent desired_scale *= M.icon_scale_percent
@@ -1101,8 +1101,8 @@ default behaviour is:
M.Scale(desired_scale) M.Scale(desired_scale)
M.Translate(0, 16*(desired_scale-1)) M.Translate(0, 16*(desired_scale-1))
src.transform = M src.transform = M
animate(src, transform = M, time = 10) //animate(src, transform = M, time = 10) //VOREStation edit
*/ //VOREStation Edit
// This handles setting the client's color variable, which makes everything look a specific color. // This handles setting the client's color variable, which makes everything look a specific color.
// This proc is here so it can be called without needing to check if the client exists, or if the client relogs. // This proc is here so it can be called without needing to check if the client exists, or if the client relogs.

View File

@@ -314,6 +314,12 @@
else else
ma.icon_state = initial(icon_state) ma.icon_state = initial(icon_state)
//VOREStation edit start
var/vore_icon_state = update_vore_icon()
if(vore_icon_state)
ma.icon_state = vore_icon_state
//VOREStation edit end
if(has_hands) if(has_hands)
if(r_hand_sprite) if(r_hand_sprite)
ma.overlays += r_hand_sprite ma.overlays += r_hand_sprite

View File

@@ -44,21 +44,21 @@
var/obj/belly/B = belly var/obj/belly/B = belly
for(var/mob/living/M in B) for(var/mob/living/M in B)
new_fullness += M.size_multiplier new_fullness += M.size_multiplier
new_fullness = round(new_fullness, 1) // Because intervals of 0.25 are going to make sprite artists cry. new_fullness = round(new_fullness, 1) // Because intervals of 0.25 are going to make sprite artists cry.
vore_fullness = min(vore_capacity, new_fullness) vore_fullness = min(vore_capacity, new_fullness)
/mob/living/simple_animal/update_icon() /mob/living/simple_animal/proc/update_vore_icon()
. = ..() // Call sideways "parent" to decide state if(!vore_active)
if(vore_active) return 0
update_fullness() update_fullness()
if(!vore_fullness) if(!vore_fullness)
return return 0
else if(icon_state == icon_living && (vore_icons & SA_ICON_LIVING)) else if((stat == CONSCIOUS) && (!icon_rest || !resting || !incapacitated(INCAPACITATION_DISABLED)) && (vore_icons & SA_ICON_LIVING))
icon_state = "[icon_state]-[vore_fullness]" return "[icon_living]-[vore_fullness]"
else if(icon_state == icon_dead && (vore_icons & SA_ICON_DEAD)) else if(stat >= DEAD && (vore_icons & SA_ICON_DEAD))
icon_state = "[icon_state]-[vore_fullness]" return "[icon_dead]-[vore_fullness]"
else if(icon_state == icon_rest && (vore_icons & SA_ICON_REST)) else if(((stat == UNCONSCIOUS) || resting || incapacitated(INCAPACITATION_DISABLED) ) && icon_rest && (vore_icons & SA_ICON_REST))
icon_state = "[icon_state]-[vore_fullness]" return "[icon_rest]-[vore_fullness]"
/mob/living/simple_animal/proc/will_eat(var/mob/living/M) /mob/living/simple_animal/proc/will_eat(var/mob/living/M)
if(client) //You do this yourself, dick! if(client) //You do this yourself, dick!

View File

@@ -51,7 +51,7 @@
vore_active = TRUE vore_active = TRUE
vore_capacity = 1 vore_capacity = 1
vore_pounce_chance = 30 vore_pounce_chance = 30
vore_icons = SA_ICON_LIVING vore_icons = SA_ICON_LIVING | SA_ICON_REST
vore_stomach_name = "fuel processor" vore_stomach_name = "fuel processor"
vore_stomach_flavor = "You have ended up in the fuel processor of this corrupted machine. This place was definitely not designed with safety and comfort in mind. The heated and cramped surroundings oozing potent fluids all over your form, eager to do nothing less than breaking you apart to fuel its rampage for the next few days... hours... minutes? Oh dear..." vore_stomach_flavor = "You have ended up in the fuel processor of this corrupted machine. This place was definitely not designed with safety and comfort in mind. The heated and cramped surroundings oozing potent fluids all over your form, eager to do nothing less than breaking you apart to fuel its rampage for the next few days... hours... minutes? Oh dear..."

View File

@@ -56,7 +56,7 @@
vore_active = 1 vore_active = 1
vore_capacity = 1 vore_capacity = 1
vore_pounce_chance = 20 vore_pounce_chance = 20
vore_icons = SA_ICON_LIVING vore_icons = SA_ICON_LIVING | SA_ICON_REST
/mob/living/simple_animal/otie/feral //gets the pet2tame feature. starts out hostile tho so get gamblin' /mob/living/simple_animal/otie/feral //gets the pet2tame feature. starts out hostile tho so get gamblin'
name = "mutated feral otie" name = "mutated feral otie"

View File

@@ -32,4 +32,4 @@
vore_active = 1 vore_active = 1
vore_capacity = 2 vore_capacity = 2
vore_pounce_chance = 10 vore_pounce_chance = 10
vore_icons = SA_ICON_LIVING vore_icons = SA_ICON_LIVING | SA_ICON_REST

View File

@@ -65,7 +65,7 @@
icon_state = "queen_s" icon_state = "queen_s"
icon_living = "queen_s" icon_living = "queen_s"
icon_dead = "queen_dead" icon_dead = "queen_dead"
vore_icons = SA_ICON_LIVING vore_icons = SA_ICON_LIVING | SA_ICON_REST
old_x = -16 old_x = -16
old_y = 0 old_y = 0
default_pixel_x = -16 default_pixel_x = -16
@@ -77,6 +77,7 @@
/mob/living/simple_animal/hostile/alien/sentinel/praetorian /mob/living/simple_animal/hostile/alien/sentinel/praetorian
icon = 'icons/mob/vore64x64.dmi' icon = 'icons/mob/vore64x64.dmi'
vore_icons = SA_ICON_LIVING | SA_ICON_REST
/mob/living/simple_animal/hostile/alien/queen/empress/mother /mob/living/simple_animal/hostile/alien/queen/empress/mother
vore_icons = 0 // NO VORE SPRITES vore_icons = 0 // NO VORE SPRITES

Binary file not shown.

Before

Width:  |  Height:  |  Size: 183 KiB

After

Width:  |  Height:  |  Size: 183 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 126 KiB

After

Width:  |  Height:  |  Size: 127 KiB