{"id":31013949,"url":"https://github.com/m1dsolo/survivor","last_synced_at":"2025-11-03T18:27:48.828Z","repository":{"id":250428916,"uuid":"834435143","full_name":"m1dsolo/survivor","owner":"m1dsolo","description":"A Simple Game Based on ECS and SDL3, Written in C++23","archived":false,"fork":false,"pushed_at":"2025-09-13T02:25:13.000Z","size":2938,"stargazers_count":9,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-10-01T10:36:09.371Z","etag":null,"topics":["cpp","ecs","game","sdl3"],"latest_commit_sha":null,"homepage":"","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/m1dsolo.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-07-27T09:01:37.000Z","updated_at":"2025-09-13T02:25:17.000Z","dependencies_parsed_at":null,"dependency_job_id":"55a12663-4edc-4d7d-8e6b-925c7037f967","html_url":"https://github.com/m1dsolo/survivor","commit_stats":null,"previous_names":["m1dsolo/game"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/m1dsolo/survivor","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m1dsolo%2Fsurvivor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m1dsolo%2Fsurvivor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m1dsolo%2Fsurvivor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m1dsolo%2Fsurvivor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/m1dsolo","download_url":"https://codeload.github.com/m1dsolo/survivor/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/m1dsolo%2Fsurvivor/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279002053,"owners_count":26083286,"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","status":"online","status_checked_at":"2025-10-09T02:00:07.460Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["cpp","ecs","game","sdl3"],"created_at":"2025-09-13T06:51:48.855Z","updated_at":"2025-10-09T21:38:25.379Z","avatar_url":"https://github.com/m1dsolo.png","language":"C++","readme":"## Project Migration Notice\n\nThis repository has been **archived** and will no longer receive updates or maintenance.\n\nAll ongoing development has been migrated to [this project](https://github.com/m1dsolo/game), which features significant architectural improvements:\n\n- **Core Logic Encapsulation**:\n`ECS` framework, `SDL3` interactions,\nand other fundamental functionalities are abstracted into an independent `core` module,\nforming a game engine-like foundation.\n\n- **Multi-game Support**:\nThe `core` module enables rapid development of games across different genres.\nIt is planned to build various types of games based on it,\nincluding `survivor`, `RPG`, `MOBA`, `RTS` games, and more..\n\n- **Visualization editor**:\nA `visualization editor` similar to War3's editor is in the roadmap,\ndesigned to assist with programming and facilitate game content creation.\n\nStay tuned to the new repository for the latest developments!\n\n---\n\n\u003cdiv align=\"center\"\u003e\n\n\u003ch1\u003eA Simple Rougelike Game\u003c/h1\u003e\n\n\u003cp\u003e(I haven't thought of a name for this game yet.)\u003c/p\u003e\n\n[![license](https://img.shields.io/badge/License-MIT%202.0-blue.svg)](https://github.com/Lightning-AI/lightning/blob/master/LICENSE)\n\n\u003c/div\u003e\n\n## Language\n\n- [English](README.md)\n- [简体中文](README_zh_CN.md)\n\n## Table of Contents\n\n- [Introduction](#introduction)\n- [Features](#features)\n- [Install](#install)\n- [Usage](#usage)\n- [License](#license)\n\n## Introduction\n\nDemo:\n\n[demo](https://github.com/user-attachments/assets/bb18c641-a574-485e-b261-53d6e00e250e)\n\nThis is a simple rougelike game developed based on [SDL3](https://github.com/libsdl-org/SDL) and my [ECS](https://github.com/m1dsolo/wheel/blob/main/include/wheel/ecs.hpp) framework.\n\nThis game is a 2D top-down rougelike survivor roguelike.\nThe objective is to survive through endless waves of enemies.\nBefore each wave starts, you need to upgrade the enemies.\nThen you have half a minute to survive the relentless attacks of the enemies.\nDuring this time, you can upgrade yourself, collect resources, and establish powerful defensive structures.\n\nSince the game is based on highly scalable `ECS` framework,\nand the main game information can be configured through `JSON`,\nyou can easily add more monsters, items, and modify the AI, etc.\n\n## Features\n\nThe project used the following technologies:\n\n- `ECS`(Entity-Component-System) architecture, providing highly reusable modules and efficient execution speed\n- `QuadTree` to accelerate collision detection\n- `SceneGraph` to manage the logical relationship between objects and the rendering order\n- `BehaviorTree` to manage the AI Logic of enemies and defense towers\n- `Lazy Theta*` pathfinding algorithm, providing smoother movement compared to `A*`\n- `JSON` is used to configure game settings, monster information, item information, upgrade rewards, monster upgrade information, behavior tree, etc.\n\n- `ECS` rely on my [ECS library](https://github.com/m1dsolo/ecs).\n- `QuadTree` and other modules primarily rely on my [wheel library](https://github.com/m1dsolo/wheel).\nRefer to the library's documentation for more details.\n\n## Install\n\nThis project is written in `C++23` and built using `CMake`.\nIt has only been tested on my own computer (Arch Linux).\nIf you use another operating systems, you may need to modify `CMakeLists.txt` to meet your requirements.\n\n1. clone project\n\n```bash\ngit clone --depth=1 https://github.com/m1dsolo/game.git\ncd game\ngit submodule update --init --depth=1\n```\n\n2. build\n\n```bash\ncmake -B build -DCMAKE_BUILD_TYPE=Release\ncmake --build build -j4\n```\n\n3. run\n\n```bash\n./build/game\n```\n\n## Usage\n\nThe game controls are as follows:\n- Movement\n    - `WASD` to move the character\n- Combat\n    - `LeftMouse` to shoot if you have a gun selected\n    - `R` to reload the gun if you have one selected\n    - `Space` to use consumables if you have one selected\n    - `F` to flash\n    - `G` to drop selected item\n- Hotbar\n    - `1`, `2`, `3`, etc. to select items\n    - `QE` to cycle through items\n    - hold `LeftMouse` to swap items\n- Menu\n    - `ESC` to show the exit menu\n        - `1` to quit\n        - `2` to resume\n    - `I` to switch inventory menu\n        - same as hotbar controls\n\n## License\n\n[MIT](LICENSE) © m1dsolo\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm1dsolo%2Fsurvivor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fm1dsolo%2Fsurvivor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fm1dsolo%2Fsurvivor/lists"}