From e24229089b984c64d4bf3ca3b3d86086d07f4afe Mon Sep 17 00:00:00 2001 From: Redmoogle Date: Tue, 30 Aug 2022 17:12:22 -0400 Subject: [PATCH 1/4] Update regalrat.dm --- code/modules/mob/living/simple_animal/hostile/regalrat.dm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/modules/mob/living/simple_animal/hostile/regalrat.dm b/code/modules/mob/living/simple_animal/hostile/regalrat.dm index a716f142d1b0..cafd71b659c2 100644 --- a/code/modules/mob/living/simple_animal/hostile/regalrat.dm +++ b/code/modules/mob/living/simple_animal/hostile/regalrat.dm @@ -103,8 +103,8 @@ . = ..() if(!.) return - var/turf/T = get_turf(owner) - if(!T) + var/turf/T = owner.loc + if(!istype(T)) return var/loot = rand(1,100) switch(loot) From 09adc7d0701517085543db79ce7a614e9fbcf7e5 Mon Sep 17 00:00:00 2001 From: Redmoogle Date: Tue, 30 Aug 2022 17:32:26 -0400 Subject: [PATCH 2/4] rest of fixes --- code/controllers/subsystem/minor_mapping.dm | 2 +- .../living/simple_animal/friendly/mouse.dm | 20 +++++++++---------- .../living/simple_animal/hostile/regalrat.dm | 12 +++++------ config/game_options.txt | 3 +++ 4 files changed, 19 insertions(+), 18 deletions(-) diff --git a/code/controllers/subsystem/minor_mapping.dm b/code/controllers/subsystem/minor_mapping.dm index 2c50afeb811f..d9e137bf2299 100644 --- a/code/controllers/subsystem/minor_mapping.dm +++ b/code/controllers/subsystem/minor_mapping.dm @@ -1,4 +1,4 @@ -#define REGAL_RAT_CHANCE 0 +#define REGAL_RAT_CHANCE 2 #define PLAGUE_RAT_CHANCE 0 SUBSYSTEM_DEF(minor_mapping) name = "Minor Mapping" diff --git a/code/modules/mob/living/simple_animal/friendly/mouse.dm b/code/modules/mob/living/simple_animal/friendly/mouse.dm index f396f9672bd4..78fd1669310d 100644 --- a/code/modules/mob/living/simple_animal/friendly/mouse.dm +++ b/code/modules/mob/living/simple_animal/friendly/mouse.dm @@ -97,9 +97,9 @@ GLOBAL_VAR_INIT(mouse_killed, 0) if(!stat) var/mob/M = AM to_chat(M, span_notice("[icon2html(src, M)] Squeak!")) - //if(istype(AM, /obj/item/reagent_containers/food/snacks/royalcheese)) - // evolve() - // qdel(AM) + if(istype(AM, /obj/item/reagent_containers/food/snacks/royalcheese)) + evolve() + qdel(AM) ..() /mob/living/simple_animal/mouse/handle_automated_action() @@ -121,10 +121,10 @@ GLOBAL_VAR_INIT(mouse_killed, 0) be_fruitful() qdel(cheese) return - //for(var/obj/item/reagent_containers/food/snacks/royalcheese/bigcheese in range(1, src)) - // qdel(bigcheese) - // evolve() - // return + for(var/obj/item/reagent_containers/food/snacks/royalcheese/bigcheese in range(1, src)) + qdel(bigcheese) + evolve() + return /** @@ -267,9 +267,9 @@ GLOBAL_VAR_INIT(mouse_killed, 0) var/list/cheeses = list(/obj/item/reagent_containers/food/snacks/cheesewedge, /obj/item/reagent_containers/food/snacks/cheesewheel, /obj/item/reagent_containers/food/snacks/store/cheesewheel, /obj/item/reagent_containers/food/snacks/customizable/cheesewheel, /obj/item/reagent_containers/food/snacks/cheesiehonkers) //all cheeses - royal - //if(istype(F, /obj/item/reagent_containers/food/snacks/royalcheese)) - // evolve() - // return + if(istype(F, /obj/item/reagent_containers/food/snacks/royalcheese)) + evolve() + return if(istype(F, /obj/item/grown/bananapeel/bluespace)) var/obj/item/grown/bananapeel/bluespace/B var/teleport_radius = max(round(B.seed.potency / 10), 1) diff --git a/code/modules/mob/living/simple_animal/hostile/regalrat.dm b/code/modules/mob/living/simple_animal/hostile/regalrat.dm index cafd71b659c2..f233fd60eed7 100644 --- a/code/modules/mob/living/simple_animal/hostile/regalrat.dm +++ b/code/modules/mob/living/simple_animal/hostile/regalrat.dm @@ -47,7 +47,6 @@ var/title = pick("King","Lord","Prince","Emperor","Supreme","Overlord","Master","Shogun","Bojar","Tsar","Hetman") name = "[kingdom] [title]" language_holder += new /datum/language_holder/mouse(src) - qdel(src) /mob/living/simple_animal/hostile/regalrat/handle_automated_action() if(prob(20)) @@ -77,7 +76,7 @@ . += "This is your king. Long live his majesty!" else . += "This is a false king! Strike him down!" - else if(istype(user,/mob/living/simple_animal/hostile/regalrat)) + else if(istype(user,/mob/living/simple_animal/hostile/regalrat) && (user != src)) . += "Who is this foolish false king? This will not stand!" /mob/living/simple_animal/hostile/regalrat/handle_environment(datum/gas_mixture/environment) @@ -188,14 +187,14 @@ name = "Rat King's Domain" desc = "Corrupts this area to be more suitable for your rat army." check_flags = AB_CHECK_CONSCIOUS - cooldown_time = 6 SECONDS + cooldown_time = 10 SECONDS icon_icon = 'icons/mob/actions/actions_spells.dmi' background_icon_state = "bg_clock" button_icon_state = "smoke" /datum/action/cooldown/domain/proc/domain() - var/turf/T = get_turf(owner) - if(!T) + var/turf/T = owner.loc + if(!istype(T)) return T.atmos_spawn_air("miasma=4;TEMP=[T20C]") switch (rand(1,10)) @@ -210,7 +209,6 @@ StartCooldown() /datum/action/cooldown/domain/Trigger() - StartCooldown(10 SECONDS) domain() StartCooldown() @@ -230,7 +228,7 @@ target.reagents.add_reagent(/datum/reagent/rat_spit, rand(1,3), no_react = TRUE) to_chat(src, span_notice("You finish licking [target].")) else if(istype(target, /obj/item/reagent_containers/food/snacks/cheesewedge)) - to_chat(src, span_green("You eat [src], restoring some health.")) + to_chat(src, span_green("You eat [target], restoring some health.")) heal_bodypart_damage(30) qdel(target) diff --git a/config/game_options.txt b/config/game_options.txt index c241ad8e0086..40d7e84c8d4b 100644 --- a/config/game_options.txt +++ b/config/game_options.txt @@ -664,6 +664,9 @@ DISABLE_HUMAN_MOOD ## A cap on how many monkeys may be created via monkey cubes #MONKEYCAP 64 +## Cap on how many regal rat minions there can be +RATCAP 64 + ## Enable the capitalist agenda on your server. ECONOMY From 7d58a89f983761df13f8d2f5ec23426b0e359116 Mon Sep 17 00:00:00 2001 From: Redmoogle Date: Tue, 30 Aug 2022 17:36:34 -0400 Subject: [PATCH 3/4] Misc --- code/modules/mob/living/simple_animal/hostile/regalrat.dm | 8 ++------ config/game_options.txt | 2 +- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/code/modules/mob/living/simple_animal/hostile/regalrat.dm b/code/modules/mob/living/simple_animal/hostile/regalrat.dm index f233fd60eed7..c94ecf164e8f 100644 --- a/code/modules/mob/living/simple_animal/hostile/regalrat.dm +++ b/code/modules/mob/living/simple_animal/hostile/regalrat.dm @@ -192,10 +192,10 @@ background_icon_state = "bg_clock" button_icon_state = "smoke" -/datum/action/cooldown/domain/proc/domain() +/datum/action/cooldown/domain/Trigger() var/turf/T = owner.loc if(!istype(T)) - return + return FALSE T.atmos_spawn_air("miasma=4;TEMP=[T20C]") switch (rand(1,10)) if (8) @@ -208,10 +208,6 @@ new /obj/effect/decal/cleanable/dirt(T) StartCooldown() -/datum/action/cooldown/domain/Trigger() - domain() - StartCooldown() - #define REGALRAT_INTERACTION "regalrat" /mob/living/simple_animal/hostile/regalrat/AttackingTarget() if (DOING_INTERACTION(src, REGALRAT_INTERACTION)) diff --git a/config/game_options.txt b/config/game_options.txt index 40d7e84c8d4b..050db497b542 100644 --- a/config/game_options.txt +++ b/config/game_options.txt @@ -665,7 +665,7 @@ DISABLE_HUMAN_MOOD #MONKEYCAP 64 ## Cap on how many regal rat minions there can be -RATCAP 64 +#RATCAP 64 ## Enable the capitalist agenda on your server. ECONOMY From 08d9b1164c26f6bd29ab7f4eda1003ee95955b22 Mon Sep 17 00:00:00 2001 From: Redmoogle Date: Tue, 30 Aug 2022 17:43:38 -0400 Subject: [PATCH 4/4] add text --- code/modules/mob/living/simple_animal/hostile/regalrat.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/modules/mob/living/simple_animal/hostile/regalrat.dm b/code/modules/mob/living/simple_animal/hostile/regalrat.dm index c94ecf164e8f..b1c868cffe29 100644 --- a/code/modules/mob/living/simple_animal/hostile/regalrat.dm +++ b/code/modules/mob/living/simple_animal/hostile/regalrat.dm @@ -104,6 +104,7 @@ return var/turf/T = owner.loc if(!istype(T)) + to_chat(owner, "There is no cheese in here!") return var/loot = rand(1,100) switch(loot) @@ -195,6 +196,7 @@ /datum/action/cooldown/domain/Trigger() var/turf/T = owner.loc if(!istype(T)) + to_chat(owner, "Building our domain here is for cowards!") return FALSE T.atmos_spawn_air("miasma=4;TEMP=[T20C]") switch (rand(1,10))