Describe the bug:
I am calling method Clone on an entity, which is NPC, it has a template and itself is a part of another template. For some reason when trying to do that, Crayta always shows “Server missing” message and after a bit editor is reconnected, but preview never works.
How do you cause this bug?
I was unable to make minimal reproducing example. However, this is very reliably reproduces on a copy of game, which I have created for this purpose. The game is called “Four Towers crashing”.
I am going to keep that backup untouched so that you can reproduce this.
In that game it is enough to run preview to get the problem.
To fix the problem, you could try to open script “TowerSpawn” and comment line 43 where clone is called.
Another way is to open template “SandTower”, go to script folder “hunters/archers” and replace in the property “entities” (which is a list), first entity from “archer1” to “archer2”. The difference between “archer1” and “archer2” is that in second one I have broken link to its template. For unknown reason that action fixed the problem as well. You could try copy-paste “archer1” once more and try with that copy, then try to break link to the template on that copy, it would have the same effect (crash when template link is present, no problem otherwise).
Screenshots / video of bug:
Which platform: PC
Which input: keyboard + mouse
Your Crayta username: strowk
Game seen in (including “Hub” or “Editor for XYZ”): Editor of “Four Towers crashing”
How regularly do you see this? (E.g. 2/3 times - please try 3 times if possible): always
Time + date seen: 30.05.2022
Version number (found in Help tab in Settings): 0.f3.5.122296