Mike is the best unity tutor imo. He knows what to say and he's very systematic in his explanations. He knows what he's talking, he knows what he's doing, and he can makes things easy to understand. I'll say he's on par with Sebastian. They have the healthy balance of knowledge and articulation.
I don't really understand and frankly not yet interested in DOTS... But this guys explaining knows how to keep an audience. I don't get bored and keep watching till the end. Great job.. man
@@jacobmakob1 that's a very good point. in theend it's just gonna come down to how verbose your're allowed to be w/ visual counterparts. node editing is fun,but rarley efficient. i'd love to see that change.
Awesome and all. You just left out the most important part of the whole process. How to convert a classic prefab into a ECS prefab. A link to your project would have been helpfull also.
They just keep changing the API and coding style of ECS, I don't think the current version will be a stable version. 99.99%ECS Tutorial 1 year ago are outdated :(
Yeah Unity has a propensity to release stuff early. It's both good and bad: I like that I can play with the technology but I'm too afraid to put it in a long term project as it will keep changing and upgrading the project gets harder and harder. I also wish more stuff would go out of beta. HWRP and LWRP are still beta. That tiny project thing is still beta. Auto LOD is still beta, etc.
@@Weaver_Games You have to approach the previews with caution, of course, but I like the fact that the preview releases allow the developer community to have more input into the final design. Isolate the experimental features through careful functional partitioning so only a small part of the project needs to change to adapt to API updates. Scalpel, not shotgun.
While the performance of these new features is awesome I have a serious gripe with it: From my point the machine should adapt to my thinking and not the other way around. Stick with me for a turn to make my point: In the 70’s to mid 80’s we programmed Assembly, Pascal, Basic, Cobol… all procedural languages or (APL etc for functional programming) leading to too much time being used to code and debug. So to get more reliable code faster there was a move in the 80’s towards more powerful syntax constructs so we turned from procedural to 4th Generation languages like SQL, Natural, SAS etc. The point was to just tell the machine what I want and let it figure out the optimal way to do it… That worked very well speeding up database programming by factors of 20 or more. Then came the GUI and along with it the daunting task of managing many objects on screen. In the beginning most code for this was extremely buggy as it was too much for plot programmers to handle using procedural languages. The solution was to get a more abstract view in ways of object oriented programming. This helped the programmer with a more natural view of things and letting the machine do the handling of object communication in the background. Unity followed the approach by having objects and components. With the DOTS approach we are being thrown back to assembly level thinking. All this talk about “simple” and “straight forward” is not so as I am forced to understand all kinds of inner workings and contexts that I feel I should no be bothered with. It is not “simple” just because I don’t have to type much (which I don’t :-/ ) There is no obvious and intuitive red thread to all that syntax gibberish Unity has come up with to formulate these things. So here is Mike Geig showing me a truly generic way of turning towards something. In fact it is so generic and general that it covers everything (much more than I intended). And as a workaround I have to install yet another unintuitive measure - a dummy - to regain control. What a great concept… Why don’t you hide this stuff behind a component that I can just use instead of forcing EVERYONE to do that same coding over and over again. I feel the engine and compiler should this kind of optimisation behind the scenes… with as minimal control input from me as possible. Unity is breaking the OO paradigm to make me think for the engine instead of the other way around. (If I want that I might as well go back to assembly again…or C or any other procedural language…) This coupled with the insufficient documentation that I have seen from Unity in the past does not forebode well for fast, stable development. The learning curve is getting all the more flat… :-(
@@TheAndrejP Oh... whoops. You're right! Here I go getting my timelines mixed up. Sorry about that. What I meant to say was "New DOTS capable physics was NOT released at GDC. It WILL BE awesome, check it out, EVENTUALLY!"
I know you are joking, but you could really ditch it sometimes now. ECS combined with the incremental garbace collector- which works great by now - really lets you do a lot of things before instantiation and garbage collection becomes a problem. And before I try to pool prefabs that have to detach parts of itself while beeing active - and other messy stuff - I might just not do it if performance isnt an issue and Im not developing for mobile.
I have like a technical gap I guess with this stuff and I've been watching tutorials of this for a while, is DOTS and ECS the same? I see the two of them getting used interchangeably sometimes, also, once you set up this system for spawning bullets for example, do you still need "object pooling" (does it even make sense to call it object pooling when they are entities?) also if any of you guys know of a good place to really get started with this I'd really appreciate it. As always thanks to the unity team and the community for the awesome work cheers!
I'm nine minutes into the video and I'm a bit surprised that he left the call for the position inside an in-bedded for-loop. That's a value that gets calculated on every single call, so calling it multiple times in a single frame is frowned upon when writing performance code. I get that this is a demo for DOTs, and I'm impressed that this slower method was running so many times inside the initialization code, but having this inside the for-loop will create a limit for the DOTs initialization as he scales up the array size. That being said, his player object is at the top of the scene hierarchy so it shouldn't be too much of an issue in this case, but if you switch the spawn point into the position of a child object, then it could turn into an issue that's easy to avoid.
So basically DOTS is isolating the parts of an entity that can be multithreaded while leaving components on the main thread? That's nice, would it be possible to use path-finding planes and alter physics from the job components or that would still run on the main thread?
The recent (ish) videos from Unity on ECS & JOB system programming are quite out of date, are there any plans to keep them and DOTS videos and tutorials updated or at the very least delete videos that are teching something that is no longer relevant?
@@WelshGuitarDude Yup. Later in this video he explains this brand new video actually uses older API syntax than from an older video too.. As well as the ones I already mentioned. What a mess.
It's all WIP. Documentation will become complete when all the ECS stuff is officially released. If you want to work with it you have to go into the forums and ask around after going over the samples Unity has on github.
Their ECS implementation is great, but threading is other subject. I really hate the idea of spawning jobs from main thread and then having to sync them. Async programming is so much more beautiful concept, especially for games, where most of stuff happens in loops.
Over time, I would expect there to be fewer explicit loops (especially polling or update loops) and more event-driven code, even if the loops still exist within the engine. The Linux kernel developers learned (partly through Linux being ported to IBM mainframes) that loops and close links to hardware interrupts and timers are performance killers when you massively scale up. (Do a web search for "Linux" and "jiffie" for some background reading.)
Yes, though the impact of generating entities is minimal. So while it would be more efficient, it will be significantly less so as it is already very optimized.
I dont have "Jobs" at the top in unity and cant write [BurstCompile]. Kinda confused. Using version 2019.1.0f2. Any ideas? Edit: As always you find your answer 5 minutes after asking for help, even when you searched for quite some time before. You need to install it in the unity package manager, since it's as of now only a preview and not installed by default. This goes for Burst, Entities, Mathematics, ..
There is a separate entity viewer window that will show you a list of various entities in the game and their data. As DOTS becomes more standard, I assume there will be more GUI devoted to it.
Not as of today, but if you check the Megacity project, you can see an implementation that goes from GameObjects to Entities so you can see, modify, etc. GO's in the Hierarchy, and then using them as Entities at runtime.
Is the source for this available? I know there's a ton of samples, but this one would actually be simple to follow to see the stuff that's not touched during the presentation...
anyone know if the enemy tag component was put on the enemy prefab? i'm assuming that enemy tag script component he showed at the end was added to the enemy prefab, also do all jobs just automatically work without having to attach it to a gameobject? or is it because he put the [BurstCompile] attribute in there?
That's one thing. But there are many other scenarios for DOTS. For example, running a mobile game at 30 fps on non-DOTS, battery lasting 1 hour. On DOTS, battery lasting 4. Just theoretical examples, but you can get the point :)
This is a criticism more about the title than the actual video, but: You say "Converting your game to DOTS" so I was hoping to see a real world, mundane example and seeing if there are any benefits there. Instead I learnt that DOTS is really useful in a totally implausible scenario, if I'm also following the worst practices ever. Thanks, I guess?
I believe that the thing is in memory manage. Sure, its possible to do same by taking all objects like FindByComponent and update them, but ECS doing it in some "sorted" way, already having all components sorted in memory and ready to use instead search any and make a list
im trying to figure out which packages and library i need to be able to use the Entity type in my code , as it is my packages are up to date and we never see the first lines of his code in the script where he creates Entity type variables
You need the Entities package from the package manager. The entity generation stuff was done in the video. Entity entity = EntityManager.Instantiate(...);
@@MikeGeigTV Entity entity = EntityManager.Instantiate(...); throws "cannot convert from 'unity.entities.prefab' to 'unity.entities.entity' ? what am I missing?
The point of this presentation wasn't to be a tutorial, it was a demo, and introduction to some concepts, they have limited times in these conferences and can't spend too long writing up the demos they're going to showcase.
Documentation still ass, experimental packages still hidden, updating old packages requires a manual partial rewrite. Support absolute Unity tier garbage as expected.