Search Unity

What types of ECS Examples would you like to see?

Discussion in 'Entity Component System' started by JohnHudeski, Mar 25, 2018.

  1. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    Perhaps you need to get out of the dark cave you're lurking in, a little more often. Your presumptions are bizarre
     
  2. Well, I'm just trying to make good deeeds here. Which presumptions of mine are bizarre and why exactly?
     
  3. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    All of them. Not going to begin wondering why. Not a psychologist, nor a psychiatrist.
     
  4. sngdan

    sngdan

    Joined:
    Feb 7, 2014
    Posts:
    1,154
  5. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    No. Sorry. Wasn't clear enough. Not the pixel collision stuff. I'm interested in this:
     
  6. Gigantic off-topic, but:

    I found these very informative if we're talking about Unity performance optimizations:
    https://unity3d.com/learn/tutorials...ng-performance-problems-using-profiler-window
    https://unity3d.com/learn/tutorials/topics/performance-optimization/optimizing-scripts-unity-games
    https://unity3d.com/learn/tutorials...ion/optimizing-garbage-collection-unity-games
    https://unity3d.com/learn/tutorials...ion/optimizing-graphics-rendering-unity-games
    https://blogs.unity3d.com/2016/07/26/il2cpp-optimizations-devirtualization/


    (this is extraordinary good)


    Also https://jacksondunstan.com/ is a must if you optimize Unity stuff.

    But optimization is a very complex subject, it's hard to really teach, because of the different problems case by case and different 'best solutions' for those problems.
     
    Deeeds likes this.
  7. Deeeds

    Deeeds

    Joined:
    Mar 15, 2018
    Posts:
    739
    @LurkingNinjaDev I found Jackson Dunston a week ago. BLEW MY MIND!!! Still recovering.

    I was more specifically asking about the Mono world examples.


    The Unity videos I've seen. The guy in the candy apple red jacket, I've watched a couple of his videos. Very good!
     
  8. DerDicke

    DerDicke

    Joined:
    Jun 30, 2015
    Posts:
    292
    Couple a state machine or a coroutine with ECS. Something that handles state. Prove the code is better structured and has same flexibility as what we have right now.
    Make a video about it, just like this guy:
     
    hippocoder likes this.
  9. Rowlan

    Rowlan

    Joined:
    Aug 4, 2016
    Posts:
    4,267
    I really would like to see the boids demo with the fish using proper animations. The trick with the wiggle shader on the fish is neat, but not really much of use for other objects than fish ;)

    I just tried the boids demo with different skins and models, but when the birds don't flap, it looks too static :)



    Also, if someone could tell how to combine the ECS demo with the Instanced Animations demo, it'd be awesome.
     
  10. Tzan

    Tzan

    Joined:
    Apr 5, 2009
    Posts:
    736
    I do the same thing.
    When I started with Unity it just seemed like the right thing to do.
     
    dt665m likes this.
  11. sngdan

    sngdan

    Joined:
    Feb 7, 2014
    Posts:
    1,154
    I learned to use the profiler and only worry about performance / optimization when I need to, not that I like this approach much. I learned programming, where the main concern was performance and memory Mgmt. Most of the time other things matter nowadays, that’s why it is fun for me to fool around with frame time challenges like the pixel collision...
     
  12. avvie

    avvie

    Joined:
    Jan 26, 2014
    Posts:
    74
    The bottomline is that if you cant or dont want to experiment with an early system, just dont. Last time i checked this is the experimental part of the forums.
    I have seen descriptions of simple examples and i am pretty sure most that play around with the stuff have already done these simple ideas. Their support and enthusiasm for ecs stems from seeing the resutls or the small manageable code or the simplicity of ecs that slowly creeps on you as you learn this non OOP coding style.
     
  13. Brendonm17

    Brendonm17

    Joined:
    Dec 9, 2013
    Posts:
    43
    I would like to see an infinite procedurally generated grass system with ECS. i can't seem to find much info on this subject, so i will try and implement it myself in the upcoming weeks. Anyone have a rough idea where to start? i was planning on using a noise function to generate positions for the grass entities, and have them be created when a procedural mesh (terrain chunk) is generated during runtime. Im trying to come up with a fast way to generate grass for my procedural terrain, and i think ECS is the key
     
  14. zulfajuniadi

    zulfajuniadi

    Joined:
    Nov 18, 2017
    Posts:
    117
    Most performant way that I found so far is baking the animations into textures. You can see my post here where i drew 100,000 units at 60 fps
     
    Rowlan likes this.
  15. Razmot

    Razmot

    Joined:
    Apr 27, 2013
    Posts:
    346
    I'd like to see ecs example implementations of Octrees and Quadtrees.

    A minecraft terrain and a procedural planet would be very cool ways to illustrate that :p

    I'm trying to do the planet thing myself but I'm a total noob at multithread code, but that's exactly why the ECS is so good:
    Seasoned OO programmers who are total noobs at multiplayer architectures can actually do something that works 100%, instead of working at 80% and exploding / missing chunks / working only on your specific pc / full of race conditions :)
     
    Djayp and Deeeds like this.
  16. jamesnw

    jamesnw

    Joined:
    Mar 23, 2013
    Posts:
    51
    +1 for Octrees as well. It would be great to somehow share a large read-only tree so I can use jobs in parallel instead of having to check each object's surrounding objects one by one. As it is I am using a custom threaded system to share a single octree which is updated via the main thread (with syncing). It works well, but if there was a way to do this in a struct system that could be copied from the main thread and shared as read-only across parallel jobs it would be great.
     
  17. Antypodish

    Antypodish

    Joined:
    Apr 29, 2014
    Posts:
    10,769
    I tried and I failed. But it was just my first weak experience with ECS. I will attempt at some point again, to convert OOP octree to ECS. As I need them too.
     
    jamesnw likes this.
  18. Zymes

    Zymes

    Joined:
    Feb 8, 2017
    Posts:
    118
    Crafting system, interactions between entities, inventory system.
     
    FROS7 likes this.