o
odin.langpkg.dev
packages / app / gdoc

gdoc

35d998dapp

Game Dev O'Clock - Odin utilities for game development.

MIT Β· updated 4 months ago
gdoc-logo

GDOC is a modular library for game development in Odin, focused on performance, clarity, and reusability.

βš™οΈ Built by Leandro Libanio.
πŸ–ΌοΈ Logo by Kevin FranΓ§a.


✨ Features

πŸ”Έ Sparse Set implementation (manual and auto ID allocation)
πŸ”Έ Minimalist ECS (Entity Component System) built on sparse sets
πŸ”Έ Timer utility for measuring elapsed time and triggering events


πŸ¦‰ Philosophy

  • Designed for performance, simplicity, and modularity
  • No OOP – built to work with Odin's idioms
  • Clean API with high-level ergonomics

⚑ Getting Started

Add as a submodule:

git submodule add https://github.com/LeandroLibanio28H/gdoc.git

πŸ“¦ Modules

Containers

sparse_set

A blazing-fast sparse set implementation with two modes:

  • Sparse_Set_Auto – IDs are automatically generated. Use like a performant list.
  • Sparse_Set_Manual – IDs are user-defined. Great for syncing between multiple sets.

Architecture

ecs

A minimal ECS built on top of sparse_set, focused on:

  • Automatic entity creation via Sparse_Set_Auto
  • Per-component sparse sets
  • Dynamic queries over registered components

Utilities

timer

A general purpose timer utility for measuring elapsed time and triggering events.


πŸ“ Directory Structure

gdoc/
β”œβ”€β”€ container/
β”‚   └── sparse_set/
β”‚       └── sparse_set.odin
β”‚       └── sparse_set_private.odin #for private procedures
β”‚       └── sparse_set_test.odin # unit tests
β”œβ”€β”€ ecs/
β”‚   └── ecs.odin
β”‚   └── ecs_private.odin #for private procedures
β”‚   └── ecs_test.odin # unit tests
β”œβ”€β”€ utils/
β”‚   └── timer/
β”‚       └── timer.odin
β”‚       └── timer_private.odin #for private procedures
β”‚       └── timer_test.odin # unit tests
└── README.md

βœ… Requirements

  • Odin (Latest Version)
  • No external dependencies

πŸ“¬ Feedback & Contributions

GDOC is modular and opinionated β€” if you're using it in your projects or want to contribute:

  • Open an issue or PR
  • Share your thoughts!