Commit Graph

6 Commits (main)

Author SHA1 Message Date
En Yi bbe3a22cc5 Replace ringbuffer with sc_queue
It is more flexible and uses less heap.
2024-08-24 15:30:32 +08:00
En Yi bf655daf8d Add mempool macros to simplify definition 2024-08-19 20:29:49 +08:00
En Yi 056b50c431 Separate out component memory pools definition
Changelog:
- Refactor the EC header files to put struct in more sensible locations:
    - Sprite and Particle Emitter + Configs are now assets, as they
      should be
    - Components type are now unsigned int, thus it is not sensitive to
      any component enums
    - Components enums are now pure index store. There are two sets of
      components: Basic for engine use, Extended for game-specific ones
- Component memory pools are now defined on outside of engine. Majority
  of the components will be game-specific, so it should be on the game
  to define the components and the mempools for all of them.
2024-08-19 18:26:08 +08:00
En Yi d2af974b29 Experiment with extern component mempool
Internal Changelog:
- Split assets from engine so that rres_packer do not need to implement
  mempools
- The idea is that mempool is incomplete and requires implementation of
  the mempool in scenes.
    - Components are usually game-specific, so this is the first step to
      decouple it from the engine.
2024-08-19 17:33:05 +08:00
En Yi 3961366ac4 Add function to get number of free entities 2024-04-22 22:52:59 +08:00
En Yi b9b0c11524 Separate out engine from scenes
This creates stronger separation the engine stuff from game
implementations.

way overdue tbh
2023-10-13 21:26:42 +08:00