From f1e840fd1caddd0c413f63c76b2be17455700440 Mon Sep 17 00:00:00 2001 From: Incoming Date: Wed, 27 Apr 2016 10:37:20 -0400 Subject: [PATCH 1/2] Shuffles a line that could have potentially been delayed from running by rapid catting. The delay of reading said line might have allowed "deploy_the_cats" to fire more than once. --- code/modules/mob/living/simple_animal/friendly/cat.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/mob/living/simple_animal/friendly/cat.dm b/code/modules/mob/living/simple_animal/friendly/cat.dm index 6e9cef8a147..06f6c04fbbf 100644 --- a/code/modules/mob/living/simple_animal/friendly/cat.dm +++ b/code/modules/mob/living/simple_animal/friendly/cat.dm @@ -125,11 +125,11 @@ memory_saved = 1 /mob/living/simple_animal/pet/cat/Runtime/proc/Deploy_The_Cats() + cats_deployed = 1 for(var/cat_type in family) if(family[cat_type] > 0) for(var/i in 1 to min(family[cat_type],100)) //Limits to about 500 cats, you wouldn't think this would be needed (BUT IT IS) new cat_type(loc) - cats_deployed = 1 /mob/living/simple_animal/pet/cat/Proc name = "Proc" From f612c83c87c597ffee2820f7bbf0f72be08b58ce Mon Sep 17 00:00:00 2001 From: Incoming5643 Date: Wed, 27 Apr 2016 14:23:38 -0400 Subject: [PATCH 2/2] negates nullcats --- code/modules/mob/living/simple_animal/friendly/cat.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/mob/living/simple_animal/friendly/cat.dm b/code/modules/mob/living/simple_animal/friendly/cat.dm index 06f6c04fbbf..82b7cfae730 100644 --- a/code/modules/mob/living/simple_animal/friendly/cat.dm +++ b/code/modules/mob/living/simple_animal/friendly/cat.dm @@ -115,7 +115,7 @@ var/savefile/S = new /savefile("data/npc_saves/Runtime.sav") family = list() for(var/mob/living/simple_animal/pet/cat/C in mob_list) - if(istype(C,type) || C.stat || !C.butcher_results) //That last one is a work around for hologram cats + if(istype(C,type) || C.stat || !C.z || !C.butcher_results) //That last one is a work around for hologram cats continue if(C.type in family) family[C.type] += 1