diff --git a/code/__DEFINES/traits.dm b/code/__DEFINES/traits.dm index d1fc0ec6791..0bbbf1a1b9a 100644 --- a/code/__DEFINES/traits.dm +++ b/code/__DEFINES/traits.dm @@ -234,6 +234,8 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai #define TRAIT_PERMANENTLY_ONFIRE "permanently_onfire" //overrides the update_fire proc to always add fire (for lava) #define TRAIT_SIGN_LANG "sign_language" //Galactic Common Sign Language #define TRAIT_NANITE_MONITORING "nanite_monitoring" //The mob's nanites are sending a monitoring signal visible on diag HUD +/// Prevents mob from riding mobs when buckled onto something +#define TRAIT_CANT_RIDE "cant_ride" // You can stare into the abyss, but it does not stare back. // You're immune to the hallucination effect of the supermatter, either diff --git a/code/datums/elements/ridable.dm b/code/datums/elements/ridable.dm index c68418bb040..68d01da6bf8 100644 --- a/code/datums/elements/ridable.dm +++ b/code/datums/elements/ridable.dm @@ -39,6 +39,9 @@ /datum/element/ridable/proc/check_mounting(atom/movable/target_movable, mob/living/potential_rider, force = FALSE, ride_check_flags = NONE) SIGNAL_HANDLER + if(HAS_TRAIT(potential_rider, TRAIT_CANT_RIDE)) + return + var/arms_needed = 0 if(ride_check_flags & RIDER_NEEDS_ARMS) arms_needed = 2 diff --git a/code/modules/mob/living/simple_animal/slime/slime.dm b/code/modules/mob/living/simple_animal/slime/slime.dm index bf4bca663f9..cdffb7158f3 100644 --- a/code/modules/mob/living/simple_animal/slime/slime.dm +++ b/code/modules/mob/living/simple_animal/slime/slime.dm @@ -86,6 +86,7 @@ /mob/living/simple_animal/slime/Initialize(mapload, new_colour="grey", new_is_adult=FALSE) var/datum/action/innate/slime/feed/F = new F.Grant(src) + ADD_TRAIT(src, TRAIT_CANT_RIDE, INNATE_TRAIT) is_adult = new_is_adult