mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-24 21:48:39 +01:00
Adds a knockedout trait, begins refactoring mobility 2.0 (#51348)
* ko * change request
This commit is contained in:
@@ -68,10 +68,10 @@
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
ADD_TRAIT(owner, TRAIT_INCAPACITATED, TRAIT_STATUS_EFFECT(id))
|
||||
ADD_TRAIT(owner, TRAIT_KNOCKEDOUT, TRAIT_STATUS_EFFECT(id))
|
||||
|
||||
/datum/status_effect/incapacitating/unconscious/on_remove()
|
||||
REMOVE_TRAIT(owner, TRAIT_INCAPACITATED, TRAIT_STATUS_EFFECT(id))
|
||||
REMOVE_TRAIT(owner, TRAIT_KNOCKEDOUT, TRAIT_STATUS_EFFECT(id))
|
||||
return ..()
|
||||
|
||||
/datum/status_effect/incapacitating/unconscious/tick()
|
||||
@@ -99,6 +99,16 @@
|
||||
human_owner = null
|
||||
return ..()
|
||||
|
||||
/datum/status_effect/incapacitating/sleeping/on_apply()
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
ADD_TRAIT(owner, TRAIT_KNOCKEDOUT, TRAIT_STATUS_EFFECT(id))
|
||||
|
||||
/datum/status_effect/incapacitating/sleeping/on_remove()
|
||||
REMOVE_TRAIT(owner, TRAIT_KNOCKEDOUT, TRAIT_STATUS_EFFECT(id))
|
||||
return ..()
|
||||
|
||||
/datum/status_effect/incapacitating/sleeping/tick()
|
||||
if(owner.maxHealth)
|
||||
var/health_ratio = owner.health / owner.maxHealth
|
||||
|
||||
Reference in New Issue
Block a user