[MIRROR] Fixed runtime from unowned cooldown actions (carp rift) [MDB IGNORE] (#26085)

* Fixed runtime from unowned cooldown actions (carp rift) (#80895)

## About The Pull Request

This might not be the most correct fix but it *makes sense*.

Some actions can not have an owner if it is unowned, so this check would
runtime.

![image](https://github.com/tgstation/tgstation/assets/51863163/b4787b7f-f481-4601-bdb1-ad001e0fea2a)

I assume carp rift is unowned in some places?

* Fixed runtime from unowned cooldown actions (carp rift)

---------

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
This commit is contained in:
SkyratBot
2024-01-12 03:17:10 +01:00
committed by GitHub
co-authored by MrMelbert
parent 7b8484e69a
commit 7b9ccd564b
+1 -1
View File
@@ -177,7 +177,7 @@
/// Starts a cooldown time for other abilities that share a cooldown with this. Has some niche usage with more complicated attack ai!
/// Will use default cooldown time if an override is not specified
/datum/action/cooldown/proc/StartCooldownOthers(override_cooldown_time)
if(!length(owner.actions))
if(!length(owner?.actions))
return // Possible if they have an action they don't control
for(var/datum/action/cooldown/shared_ability in owner.actions - src)
if(!(shared_cooldown & shared_ability.shared_cooldown))