diff --git a/code/modules/mob/living/simple_animal/slime/ai.dm b/code/modules/mob/living/simple_animal/slime/ai.dm index b35ebb6e03..3a8718c997 100644 --- a/code/modules/mob/living/simple_animal/slime/ai.dm +++ b/code/modules/mob/living/simple_animal/slime/ai.dm @@ -5,9 +5,46 @@ return ..() +/mob/living/simple_animal/slime/Found(mob/living/L) + if(isliving(L)) + if(SA_attackable(L)) + if(L.faction == faction && !attack_same) + if(ishuman(L)) + var/mob/living/carbon/human/H = L + if(istype(H.species, /datum/species/monkey)) // istype() is so they'll eat the alien monkeys too. + return H // Monkeys are always food. + else + return + + if(L in friends) + return + + if(istype(L, /mob/living/simple_animal/slime)) + var/mob/living/simple_animal/slime/buddy = L + if(buddy.slime_color == src.slime_color || discipline || unity || buddy.unity) + return // Don't hurt same colored slimes. + else + return buddy //do hurt others + + if(ishuman(L)) + var/mob/living/carbon/human/H = L + if(istype(H.species, /datum/species/monkey)) // istype() is so they'll eat the alien monkeys too. + return H // Monkeys are always food. + + if(issilicon(L) || isbot(L)) + if(discipline && !rabid) + return // We're a good slime. For now at least. + return + return + /mob/living/simple_animal/slime/special_target_check(mob/living/L) - if(L.faction == faction && !attack_same) - return FALSE + if(L.faction == faction && !attack_same && !istype(L, /mob/living/simple_animal/slime)) + if(ishuman(L)) + var/mob/living/carbon/human/H = L + if(istype(H.species, /datum/species/monkey)) // istype() is so they'll eat the alien monkeys too. + return TRUE // Monkeys are always food. + else + return FALSE if(L in friends) return FALSE diff --git a/code/modules/mob/living/simple_animal/slime/life.dm b/code/modules/mob/living/simple_animal/slime/life.dm index 21e7c62820..691b880574 100644 --- a/code/modules/mob/living/simple_animal/slime/life.dm +++ b/code/modules/mob/living/simple_animal/slime/life.dm @@ -112,6 +112,11 @@ if(!speaker.client) return + //Are all slimes being referred to? + var/mass_order = 0 + if(findtext(message, "slimes")) + mass_order = 1 + // Say hello back. if(findtext(message, "hello") || findtext(message, "hi") || findtext(message, "greetings")) delayed_say(pick("Hello...", "Hi..."), speaker) @@ -165,13 +170,14 @@ var/list/valid_names = splittext(L.name, " ") // Should output list("John", "Doe") as an example. for(var/line in valid_names) // Check each part of someone's name. if(findtext(message, lowertext(line))) // If part of someone's name is in the command, the slime targets them if allowed to. - if(special_target_check(L)) - delayed_say("Okay... I attack \the [L]...", speaker) - LoseFollow() - set_target(L) - return - else - delayed_say("No... I won't attack \the [L].", speaker) - return - // If we're here, it couldn't find anyone with that name. - delayed_say("No... I don't know who to attack...", speaker) + if(!(mass_order && line == "slime")) //don't think random other slimes are target + if(special_target_check(L)) + delayed_say("Okay... I attack \the [L]...", speaker) + LoseFollow() + set_target(L, 1) + return + else + delayed_say("No... I won't attack \the [L].", speaker) + return + // If we're here, it couldn't find anyone with that name. + delayed_say("No... I don't know who to attack...", speaker) diff --git a/code/modules/mob/living/simple_animal/slime/slime.dm b/code/modules/mob/living/simple_animal/slime/slime.dm index 93b1f0e9c6..219074dc6c 100644 --- a/code/modules/mob/living/simple_animal/slime/slime.dm +++ b/code/modules/mob/living/simple_animal/slime/slime.dm @@ -356,10 +356,13 @@ baby.mutation_chance = mutation_chance baby.power_charge = round(power_charge / 4) baby.resentment = max(resentment - 1, 0) - baby.discipline = max(discipline - 1, 0) - baby.obedience = max(obedience - 1, 0) - baby.unity = unity + if(!istype(baby, /mob/living/simple_animal/slime/light_pink)) + baby.discipline = max(discipline - 1, 0) + baby.obedience = max(obedience - 1, 0) + if(!istype(baby, /mob/living/simple_animal/slime/rainbow)) + baby.unity = unity baby.faction = faction + baby.attack_same = attack_same baby.friends = friends.Copy() if(rabid) baby.enrage() diff --git a/code/modules/mob/living/simple_animal/slime/subtypes.dm b/code/modules/mob/living/simple_animal/slime/subtypes.dm index 486c04866f..d30bdf0d7d 100644 --- a/code/modules/mob/living/simple_animal/slime/subtypes.dm +++ b/code/modules/mob/living/simple_animal/slime/subtypes.dm @@ -120,7 +120,7 @@ /mob/living/simple_animal/slime/dark_purple desc = "This slime produces ever-coveted phoron. Risky to handle but very much worth it." - color = "#CC23FF" + color = "#660088" slime_color = "dark purple" coretype = /obj/item/slime_extract/dark_purple reagent_injected = "phoron"