{"id":15987723,"url":"https://github.com/jak2k/nexaraquest","last_synced_at":"2025-08-16T05:37:13.656Z","repository":{"id":215692491,"uuid":"736784634","full_name":"Jak2k/nexaraquest","owner":"Jak2k","description":"An interactive, modern fantasy story \u0026 a game engine","archived":false,"fork":false,"pushed_at":"2024-04-05T15:10:47.000Z","size":120,"stargazers_count":0,"open_issues_count":4,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-04T22:13:47.424Z","etag":null,"topics":["fantasy","game-engine","interactive-fiction","interactive-story","rust","superpowers","terminal-game","text-game","text-game-engine"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Jak2k.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2023-12-28T21:43:53.000Z","updated_at":"2024-01-12T19:45:40.000Z","dependencies_parsed_at":"2024-01-08T09:24:03.912Z","dependency_job_id":"ca67eb36-874b-44de-a325-a0cc9bbfa989","html_url":"https://github.com/Jak2k/nexaraquest","commit_stats":null,"previous_names":["jak2k/nexaraquest"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/Jak2k/nexaraquest","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jak2k%2Fnexaraquest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jak2k%2Fnexaraquest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jak2k%2Fnexaraquest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jak2k%2Fnexaraquest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Jak2k","download_url":"https://codeload.github.com/Jak2k/nexaraquest/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jak2k%2Fnexaraquest/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270672527,"owners_count":24625984,"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-08-16T02:00:11.002Z","response_time":91,"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":["fantasy","game-engine","interactive-fiction","interactive-story","rust","superpowers","terminal-game","text-game","text-game-engine"],"created_at":"2024-10-08T03:41:32.319Z","updated_at":"2025-08-16T05:37:13.635Z","avatar_url":"https://github.com/Jak2k.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nexara Quest \u0026 Nexara Text Engine\n\nAn older version of the game / game engine demo:\n[![asciicast](https://asciinema.org/a/j97MRngAlp1TuQPJ34y9gDwl1.svg)](https://asciinema.org/a/j97MRngAlp1TuQPJ34y9gDwl1)\n\n## What is Nexara Quest?\n\nNexara Quest will be a game about a teenager who lives in the city Nexara. He/her/they discovers their superpowers and has to use them to defend against people who want to use their powers for evil.\n\nThe game will be text based and will be written in Rust. A user has to use the terminal to play the game. (It's not that hard, I promise.)\n\n[Download from releases](https://github.com/Jak2k/nexaraquest/releases/).\n\n## What is Nexara Text Engine?\n\nNexara Text Engine is a game engine for text based games. You basicly create 2 enums or structs and stick it into two macros:\n\n- `scenify!` - This macro creates a scene from your data structures and a function that calculates what scene can be gone to next.\n- `run_scene!` - This macro runs the start scene and allows the user to navigate.\n\n```rust\nuse nexara_text_engine::prelude::*; // Import all the necessary stuff\n\nenum MyScenes { // Create an enum for your scenes. Could also be a struct.\n    Bedroom,\n    Kitchen,\n    School,\n}\n\nstruct MyContext { // Create a struct for your context. Could also be an enum.\n    morning: bool,\n    heard_news: bool,\n}\n\nscenify!(\n    MyScenes,\n    MyContext,\n    MyScenes::Bedroom, // The starting scene\n    |this: \u0026MyScenes, context: \u0026mut MyContext| {\n        match this { // This gives the current scene data from the active scene and context.\n            MyScenes::Bedroom =\u003e Scene {\n                location: \"Bedroom\".to_string(),\n                text: match context.morning { // We can do more logic here...\n                    true =\u003e {\n                        context.morning = false; // ...and change the context.\n                        \"Your alarm is ringing. You are tired, but you have to go to school.\"\n                            .to_string()\n                    }\n                    false =\u003e \"You went into your bedroom.\".to_string(),\n                },\n                options: vec![Option {\n                    title: \"Go to the kitchen\".to_string(), // This is the text that is shown to the user.\n                    target: MyScenes::Kitchen, // This is the next scene.\n                }],\n            },\n            MyScenes::Kitchen =\u003e Scene {\n                location: \"Kitchen\".to_string(),\n                text: match context.heard_news {\n                    true =\u003e \"You are in the kitchen.\".to_string(),\n                    false =\u003e {\n                        context.heard_news = true;\n                        \"You went into the kitchen. The radio is on and you hear the news.\"\n                            .to_string()\n                    }\n                },\n                options: vec![\n                    Option {\n                        title: \"Go to the bedroom\".to_string(),\n                        target: MyScenes::Bedroom,\n                    },\n                    Option {\n                        title: \"Go to school\".to_string(),\n                        target: MyScenes::School,\n                    },\n                ],\n            },\n            MyScenes::School =\u003e Scene {\n                location: \"School\".to_string(),\n                text: \"You are at school.\".to_string(), // This doesn't need to be logic. A simple string is fine.\n                options: vec![Option {\n                    title: \"Go home\".to_string(),\n                    target: MyScenes::Kitchen,\n                }],\n            },\n            // We haven't forgotten a scene. Rust would have complained if we did.\n        }\n    }\n);\n\nfn main() {\n    run_scene!( // Just sugar for running the start scene.\n        MyScenes,\n        MyContext {\n            morning: true,\n            heard_news: false\n        }\n    );\n}\n```\n\nCheck out the code in `nexara_text_engine/src`. It's not that much.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjak2k%2Fnexaraquest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjak2k%2Fnexaraquest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjak2k%2Fnexaraquest/lists"}