ChainSafe / web3.unity

🕹 Unity SDK for building games that interact with blockchains.
GNU Lesser General Public License v3.0
923 stars 236 forks source link

Update web3.unity GameObjects to Entities #454

Closed KBryan closed 10 months ago

KBryan commented 1 year ago

With the latest release of Unity3d 2022. ECS is now out of preview mode and is at full release. This changes the way game developers work in Unity and will become the de facto standard moving forward. It would be a good idea to get ahead of the curve and update our tools to support this.

boorich commented 1 year ago

@oleksandrchainsafe @kantagara What is your opinion on ECS? Worth it or just another hype?

From an on-chain gaming perspective, it is the de-facto standard already. The significant frameworks MUD and Dojo extensively use it.

kantagara commented 10 months ago

It's not a hype. But ECS doesn't make much sense in regards to our own SDK, since it would require us

  1. To either rework our entire SDK and make it ECS Only
  2. To have two versions of our Unity package -> One for ECS and one for regular GO. We might add some sort of an ECS support later, but it's really hard to tell when will that happen.
kantagara commented 10 months ago

@boorich MUD and DOJO are frameworks (actually, DOJO Is an engine) that haven't even been built in Unity and are then of course not using the Unitys ECS stack which OP is mentioning. And ECS is kind of like MVC or MVVM -> It's a design pattern, nothing much. The new Unity ECS package that got released is a good thing to have in back of our head to be supported, but as I've stated above, it'd require a lot of rework and a lot of support + it's not still that much in use in games (like, it's not a standard, but it might become in like 3 years).

boorich commented 10 months ago

I agree. This massive change introduces a lot of cognitive overhead for developers and an enormous development and maintenance overhead for us. What we might do instead at a later point in time would be to prototype a specific client for some on-chain world and see if we can make use of Unity's in-build ECS capabilities. If we don't find a worthy problem to tackle with ECS, then it's probably too early to work on it.