ParadiseSS13 / Paradise

Paradise Station's GitHub main repository.
https://www.paradisestation.org/forum
GNU Affero General Public License v3.0
405 stars 1.2k forks source link

Runtime in getpois. Ghost orbit menu #14841

Closed farie82 closed 3 years ago

farie82 commented 3 years ago

Issue Description:

Runtime in unsorted.dm,1986: getpois returned something under a non-string name - 
   proc name: stack trace (/datum/proc/stack_trace)
   usr: NAME (CKEY) (/mob/dead/observer)
   usr.loc: The floor (41,145,1) (/turf/simulated/shuttle/floor)
   src: /datum/orbit_menu (/datum/orbit_menu)
   call stack:
   /datum/orbit_menu (/datum/orbit_menu): stack trace("getpois returned something und...")
   /datum/orbit_menu (/datum/orbit_menu): tgui static data(NAME (/mob/dead/observer))
   /datum/tgui (/datum/tgui): open()
   /datum/orbit_menu (/datum/orbit_menu): tgui interact(NAME (/mob/dead/observer), "main", /datum/tgui (/datum/tgui), 0, null, /datum/tgui_state/observer_sta... (/datum/tgui_state/observer_state))
   NAME (/mob/dead/observer): Orbit()
   Orbit (/obj/screen/ghost/orbit): Click(null, "mapwindow.map", "icon-x=17;icon-y=19;left=1;scr...")

What did you expect to happen: It not to runtime

What happened instead: It runtimes. Unsure what the effects are functionally

Why is this bad/What are the consequences: Runtimes are bad

Steps to reproduce the problem:

When did the problem start happening: TGUI version of the orbit menu. Runtime observed around 14:00 7/11/2020

moxian commented 3 years ago

Steps to reproduce:

The issue is that roundstart "Robot" borgs have a brainmob with empty name. Stacktrace of that is roughly: https://github.com/ParadiseSS13/Paradise/blob/56752b0e78eace31c753612c26e6567b2397bc82/code/modules/mob/living/carbon/brain/robotic_brain.dm#L91-L95 https://github.com/ParadiseSS13/Paradise/blob/56752b0e78eace31c753612c26e6567b2397bc82/code/modules/mob/transform_procs.dm#L93-L98

Note that mmi is freshly-created with a freshly-created brain with a freshly-created nameless dna https://github.com/ParadiseSS13/Paradise/blob/56752b0e78eace31c753612c26e6567b2397bc82/code/modules/mob/living/carbon/brain/robotic_brain.dm#L200-L208

Ideally this should be solved by refactoring the whole mmi conscious system. Like, right now all robots seem to have two mmis in them (one from robot /new , another - freshly inserted in the Robotize proc). Less invasive approach would be to just remove the /obj/item/mmi/robotic_brain/transfer_identity override and let just the base /obj/item/mmi/transfer_identity handle it, but i'm not sure if that would break something. Scary code!

Kyep commented 3 years ago

Fixed in https://github.com/ParadiseSS13/Paradise/pull/15011

Kyep commented 3 years ago

Not actually fully fixed. See my comment on https://github.com/ParadiseSS13/Paradise/pull/14991