18 ms·
Been using unity since 4.0 and it's problem is it wants you to treat the engine as the operating system and enforces that with walled-gardens and a deluge of ba
by l3uwin 4y ago
Been using unity since 4.0 and it's problem is it wants you to treat the engine as the operating system and enforces that with walled-gardens and a deluge of bad programming and systems-design advice that leads to some of the most unscalable spaghetti imaginable.
- BoorishBears 4y agoI used Unity for years, starting in the 2.x days when their moving off Mac was big news. I agree with Unity having a lot of issues, but disagree with this being one of them: Unity doesn't really encourage anything that ECS doesn't encourage. ECS is a very ergonomic abstraction for games: that's the only reason it's even put up with over data oriented models like DOTS which are much more performant To me the spaghetti code thing is in part because games are just a really hard architecture problem if you're not used to it. It's like trying to build the design, frontend and backend of a CRUD app while also feeling out the business plan as you go along. Before you know it, you have the bones of a few wrong turns sticking out of the foundation, there's huge amounts of coupling between everything, and you essentially can't change any side of the puzzle without breaking a ton of stuff. Realistically I think Unity is often picked up by people who could make spaghetti code in any engine. And for the same reason I still contend that the asset store should never have allowed primarily code assets. You need a certain level of engineering rigor to not end up with a brittle buggy mess to slog through by the time something as open ended as a game. The asset store is full of just awful code written by people who don't know better, picked up by people who don't know better, resulting in a gnashing of teeth for everyone involved.
- rhn_mk1 4y agoWhat is DOTS? Quick research tells me that an ECS is part of it, not an alternative.
- l3uwin 4y agodata oriented tech stack, uses the burst compiler and jobs system for massively-parallel workloads (maybe it's changed though since I was last using it)
- l3uwin 4y ago> The asset store is full of just awful code written by people who don't know better, picked up by people who don't know better, resulting in a gnashing of teeth for everyone involved. honestly you nailed it lol
- klodolph 4y ago> ECS is a very ergonomic abstraction for games: that's the only reason it's even put up with over data oriented models like DOTS which are much more performant I'm a bit unsure what you're saying here. By my reckoning, building objects in Unity out of MonoBehaviour components is simply not ECS, and as far as I can tell, Unity ECS and DOTS go hand-in-hand. I haven't used DOTS, though. I have used ECS but not with Unity. The reason Unity isn't ECS is because it's missing the "S" in ECS. Unity has entities and components, but you're left on your own if you want to create a system. Agreed that there's a ton of bad code out there, in video tutorials and on the asset store. I avoid using code assets or copy/pasting code, but I'm mostly running into the next issue you mentioned--that it's a hard architecture problem to begin with.
- BoorishBears 4y agoUnity muddied the waters by naming a component in DOTS "ECS", but I'm referring to the pattern, not that package, and the fact that you need to include Systems to have ECS is debatable: https://en.wikipedia.org/wiki/Entity_component_system#Is_%22system%22_first_class https://en.wikipedia.org/wiki/Entity_component_system#Is_%22...? Even if you want to reduce it to "Entity-Component" the point is that the architecture they provide via Monobehaviors is ergonomic It creates a very workable mental model for assembling complex game entities without relying on inheritance, and it provides reasonable tools to orchestrate them without introducing hard dependencies