Skip to content

1.1.0

Compare
Choose a tag to compare
@genaray genaray released this 20 Dec 14:32
· 330 commits to master since this release
2c40bd3

Features & Changes

  • PURE_ECS preprocessor variable for utilizing pure ecs paradigma
  • Tag Components ( Empty components ) will not influence the amount of possible entities in a certain chunk
  • Entity.Null will not anymore create a new null entity each time its acessed
  • ComponentType is now required for several operations to provide additional component data and to prevent lookups
  • World.Id is now a int and not limited to 255 anymore
  • Structural changes, adds and removals are now way "smarter" and more efficient
  • Made several World, Archetype and Chunk methods internal for a better workflow and less headache
  • World will internally track entities and some meta data for faster lookup speed and less dictionarys
  • Major refactoring of internal structures Archetype and Chunk are now slimmer and act as pure containers without mapping entities and wasting space.
  • Several other little tweaks

Pure ECS

Theres a PURE_ECS preprocessor variable now which sets an entity to exactly one integer and disables all existing entity extension methods. This way the ECS can be accessed by a "pure ecs" mindset, thus more entities fit into one chunk and less unnecessary ballast is dragged around. This may only work with forks since the nugget package version will not have that flag enabled.

Increased lookup speed

Entities are now tracked in one single dictionary inside the world, this one stores archetype and chunk index data to provide instand acess. Compared to previous versions only one single lookup is now required instead of multiple ones, therefore the lookup speed increased by a lot.

Previous version:

Method Amount Mean Error StdDev Allocated
WorldEntityQuery 10000 513.765 us 297.3252 us 16.2974 us -
WorldEntityQuery 100000 5,032.846 us 2,116.4383 us 116.0091 us -
WorldEntityQuery 1000000 50,894.500 us 1,944.0534 us 106.5601 us -

Current version :

Method Amount Mean Error StdDev CacheMisses/Op Allocated
WorldEntityQuery 10000 147.660 us 13.2838 us 0.7281 us 746 -
WorldEntityQuery 100000 1,726.959 us 3,058.5935 us 167.6518 us 11,761 -
WorldEntityQuery 1000000 20,419.798 us 4,491.2760 us 246.1820 us 90,624 -

Contributors

@andreakarasho thanks for pointing out issues with commandbuffers and the entity tweaks ! :)