mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 11:37:40 +01:00
Prevent constructed AI laws from randomly becoming null. (#25913)
Co-authored-by: FunnyMan3595 (Charlie Nolan) <funnyman@google.com>
This commit is contained in:
co-authored by
FunnyMan3595
parent
1fae459c26
commit
3bc5f8ebbe
@@ -178,6 +178,8 @@
|
||||
SSticker.mode.remove_revolutionary(brain.brainmob.mind, 1)
|
||||
|
||||
var/mob/living/silicon/ai/A = new /mob/living/silicon/ai(loc, laws, brain)
|
||||
// Stop holding onto the laws so we don't qdel them and make the AI randomly lose its laws when GC gives up and hard deletes them.
|
||||
laws = null
|
||||
if(A) //if there's no brain, the mob is deleted and a structure/AIcore is created
|
||||
A.rename_self("AI", 1)
|
||||
SSblackbox.record_feedback("amount", "ais_created", 1)
|
||||
|
||||
Reference in New Issue
Block a user