mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Adds in a var that allows species to ignore the slowdown effects of items
This commit is contained in:
@@ -25,21 +25,6 @@
|
||||
var/hungry = (500 - nutrition)/5 // So overeat would be 100 and default level would be 80
|
||||
if (hungry >= 70) tally += hungry/50
|
||||
|
||||
// Loop through some slots, and add up their slowdowns. Shoes are handled below, unfortunately.
|
||||
// Includes slots which can provide armor, the back slot, and suit storage.
|
||||
for(var/obj/item/I in list(wear_suit, w_uniform, back, gloves, head, s_store) )
|
||||
tally += I.slowdown
|
||||
|
||||
// Hands are also included, to make the 'take off your armor instantly and carry it with you to go faster' trick no longer viable.
|
||||
// This is done seperately to disallow negative numbers.
|
||||
for(var/obj/item/I in list(r_hand, l_hand) )
|
||||
tally += max(I.slowdown, 0)
|
||||
|
||||
// Dragging heavy objects will also slow you down, similar to above.
|
||||
if(pulling && istype(pulling, /obj/item))
|
||||
var/obj/item/pulled = pulling
|
||||
tally += max(pulled.slowdown, 0)
|
||||
|
||||
if(istype(buckled, /obj/structure/bed/chair/wheelchair))
|
||||
for(var/organ_name in list(BP_L_HAND, BP_R_HAND, BP_L_ARM, BP_R_ARM))
|
||||
var/obj/item/organ/external/E = get_organ(organ_name)
|
||||
@@ -76,6 +61,24 @@
|
||||
if(mRun in mutations)
|
||||
tally = 0
|
||||
|
||||
if(species.slowdown_fixed)
|
||||
return (tally+config.human_delay)
|
||||
|
||||
// Loop through some slots, and add up their slowdowns. Shoes are handled below, unfortunately.
|
||||
// Includes slots which can provide armor, the back slot, and suit storage.
|
||||
for(var/obj/item/I in list(wear_suit, w_uniform, back, gloves, head, s_store) )
|
||||
tally += I.slowdown
|
||||
|
||||
// Hands are also included, to make the 'take off your armor instantly and carry it with you to go faster' trick no longer viable.
|
||||
// This is done seperately to disallow negative numbers.
|
||||
for(var/obj/item/I in list(r_hand, l_hand) )
|
||||
tally += max(I.slowdown, 0)
|
||||
|
||||
// Dragging heavy objects will also slow you down, similar to above.
|
||||
if(pulling && istype(pulling, /obj/item))
|
||||
var/obj/item/pulled = pulling
|
||||
tally += max(pulled.slowdown, 0)
|
||||
|
||||
return (tally+config.human_delay)
|
||||
|
||||
/mob/living/carbon/human/Process_Spacemove(var/check_drift = 0)
|
||||
|
||||
@@ -121,6 +121,7 @@
|
||||
var/appearance_flags = 0 // Appearance/display related features.
|
||||
var/spawn_flags = 0 // Flags that specify who can spawn as this species
|
||||
var/slowdown = 0 // Passive movement speed malus (or boost, if negative)
|
||||
var/slowdown_fixed = 0 // If this is on, they're not affected by object related slowdown (positive or negative)
|
||||
var/primitive_form // Lesser form, if any (ie. monkey for humans)
|
||||
var/greater_form // Greater form, if any, ie. human for monkeys.
|
||||
var/holder_type
|
||||
|
||||
Reference in New Issue
Block a user