{"id":23978567,"url":"https://github.com/simmsb/simple-ecs","last_synced_at":"2025-06-14T17:04:04.624Z","repository":{"id":94007410,"uuid":"187434138","full_name":"simmsb/simple-ecs","owner":"simmsb","description":"A simple Entity Component System written in C","archived":false,"fork":false,"pushed_at":"2019-06-01T06:11:25.000Z","size":24,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-22T00:03:18.231Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/simmsb.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-19T04:33:31.000Z","updated_at":"2021-08-11T23:06:02.000Z","dependencies_parsed_at":"2023-04-26T09:31:48.019Z","dependency_job_id":null,"html_url":"https://github.com/simmsb/simple-ecs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/simmsb/simple-ecs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simmsb%2Fsimple-ecs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simmsb%2Fsimple-ecs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simmsb%2Fsimple-ecs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simmsb%2Fsimple-ecs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/simmsb","download_url":"https://codeload.github.com/simmsb/simple-ecs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/simmsb%2Fsimple-ecs/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259851696,"owners_count":22921628,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-01-07T08:18:49.878Z","updated_at":"2025-06-14T17:04:04.602Z","avatar_url":"https://github.com/simmsb.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":" # Simple ECS\n\n This is a simple ECS framework for C\n\n# Example\n\n```c\n#include \u003cstdio.h\u003e\n#include \u003cstdlib.h\u003e\n\n#include \"entity.h\"\n#include \"component.h\"\n#include \"system.h\"\n\nstruct position_storage {\n  int32_t x, y;\n};\n\nDEFINE_COMPONENT(position, struct position_storage);\nREGISTER_COMPONENT(position, struct position_storage);\n\nstruct velocity_storage {\n  int32_t dx, dy;\n};\n\nDEFINE_COMPONENT(velocity, struct velocity_storage);\nREGISTER_COMPONENT(velocity, struct velocity_storage);\n\nREGISTER_SYSTEM(update_velocity_values, {\n  FOR_JOIN_COMPONENT_2(position, velocity, d, {\n    d.position-\u003ex += d.velocity-\u003edx;\n    d.position-\u003ey += d.velocity-\u003edy;\n  });\n});\n\nint main() {\n  uint32_t test_entity = new_entity_id();\n\n  position.add_value(test_entity, (struct position_storage){.x = 0, .y = 0});\n  velocity.add_value(test_entity, (struct velocity_storage){.dx = 1, .dy = 2});\n\n  while (true) {\n    run_systems();\n  }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsimmsb%2Fsimple-ecs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsimmsb%2Fsimple-ecs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsimmsb%2Fsimple-ecs/lists"}