sschmid / Entitas

Entitas is a super fast Entity Component System (ECS) Framework specifically made for C# and Unity
MIT License
7.03k stars 1.11k forks source link

Unity 2020/2021 Crash while selecting entity game object (Windows) #990

Closed zendorx closed 1 year ago

zendorx commented 2 years ago

https://user-images.githubusercontent.com/909905/145678347-e79df163-5174-4734-b648-9dc042074f10.mp4

zendorx commented 2 years ago

same for 2021 unity

zendorx commented 2 years ago

found the reason. It because component contains int2 property. And workaround here?

sschmid commented 2 years ago

Hi, a custom TypeDrawer for that type might help, example https://github.com/sschmid/Entitas-CSharp/blob/master/Addons/Entitas.VisualDebugging.Unity.Editor/Entitas.VisualDebugging.Unity.Editor/Entity/TypeDrawer/Vector2TypeDrawer.cs

Save them in an Editor folder.

Maybe sth goes wrong close to here https://github.com/sschmid/Entitas-CSharp/blob/master/Addons/Entitas.VisualDebugging.Unity.Editor/Entitas.VisualDebugging.Unity.Editor/Entity/Entity/EntityDrawer.cs#L301-L328

sschmid commented 1 year ago

@zendorx I hope that helped. Feel free to reopen if you still have issues