mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-19 02:54:41 +01:00
clothing that gives speed now works properly as well
This commit is contained in:
@@ -218,6 +218,7 @@
|
||||
////////////////
|
||||
// MOVE SPEED //
|
||||
////////////////
|
||||
#define ADD_SLOWDOWN(__value) if(!ignoreslow || __value < 0) . += __value
|
||||
|
||||
/datum/species/proc/movement_delay(mob/living/carbon/human/H)
|
||||
. = 0 //We start at 0.
|
||||
@@ -230,27 +231,23 @@
|
||||
if((H.status_flags & IGNORESLOWDOWN) || (RUN in H.mutations))
|
||||
ignoreslow = TRUE
|
||||
|
||||
if(ignoreslow)
|
||||
if(speed_mod < 0) // Apply the speed_mod if it's negative. Meaning it's a speedup
|
||||
. += speed_mod
|
||||
return .
|
||||
|
||||
var/flight = H.flying //Check for flight and flying items
|
||||
|
||||
if(speed_mod)
|
||||
. += speed_mod
|
||||
ADD_SLOWDOWN(speed_mod)
|
||||
|
||||
if(H.wear_suit)
|
||||
. += H.wear_suit.slowdown
|
||||
if(!H.buckled)
|
||||
if(H.shoes)
|
||||
. += H.shoes.slowdown
|
||||
ADD_SLOWDOWN(H.wear_suit.slowdown)
|
||||
if(!H.buckled && H.shoes)
|
||||
ADD_SLOWDOWN(H.shoes.slowdown)
|
||||
if(H.back)
|
||||
. += H.back.slowdown
|
||||
ADD_SLOWDOWN(H.back.slowdown)
|
||||
if(H.l_hand && (H.l_hand.flags & HANDSLOW))
|
||||
. += H.l_hand.slowdown
|
||||
ADD_SLOWDOWN(H.l_hand.slowdown)
|
||||
if(H.r_hand && (H.r_hand.flags & HANDSLOW))
|
||||
. += H.r_hand.slowdown
|
||||
ADD_SLOWDOWN(H.r_hand.slowdown)
|
||||
|
||||
if(ignoreslow)
|
||||
return . // Only malusses after here
|
||||
|
||||
var/health_deficiency = max(H.maxHealth - H.health, H.staminaloss)
|
||||
var/hungry = (500 - H.nutrition)/5 // So overeat would be 100 and default level would be 80
|
||||
@@ -274,6 +271,8 @@
|
||||
|
||||
return .
|
||||
|
||||
#undef ADD_SLOWDOWN
|
||||
|
||||
/datum/species/proc/on_species_gain(mob/living/carbon/human/H) //Handles anything not already covered by basic species assignment.
|
||||
for(var/slot_id in no_equip)
|
||||
var/obj/item/thing = H.get_item_by_slot(slot_id)
|
||||
|
||||
Reference in New Issue
Block a user