Skip to content
Snippets Groups Projects
Commit 8ab33d4f authored by Alex Ksandra's avatar Alex Ksandra
Browse files

Fixed objects losing identification on changing their ego list.

parent 3a0d6da5
No related branches found
No related tags found
No related merge requests found
......@@ -506,6 +506,7 @@ end
-- WARNING the thing may be in need of re-identifying after this
local function reapplyEgos(self, e)
if not e.__original then return e end
local id = e.isIdentified and e:isIdentified()
local brandNew = e.__original -- it will be cloned upon first ego application
if e.ego_list and #e.ego_list > 0 then
for _, ego_args in ipairs(e.ego_list) do
......@@ -513,6 +514,7 @@ local function reapplyEgos(self, e)
end
end
e:replaceWith(brandNew)
if e.identify then e:identify(id) end
end
-- Remove an ego
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment