From 30a3f4ca8dbfe3d15efb8b5d80db5a8a528bdc59 Mon Sep 17 00:00:00 2001 From: Nick Koirala Date: Wed, 5 Nov 2025 22:24:18 +1300 Subject: [PATCH] feat: added README.md --- README.md | 127 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..b0d319a --- /dev/null +++ b/README.md @@ -0,0 +1,127 @@ +# Simian + +**Simian** is a Raylib + AngelScript test project on Windows. +It demonstrates how to integrate **Raylib** for graphics and **AngelScript** for scripting, including the `scriptstdstring` add-on. + +--- + +## Requirements + +- Windows 10/11 (tested) +- [Visual Studio 2022](https://visualstudio.microsoft.com/) with **Desktop development with C++** workload +- [CMake 3.25+](https://cmake.org/download/) +- Git +- Optional: VSCode for editing + +--- + +## Getting Started + +### 1. Clone the repository with submodules + +```bash +git clone --recurse-submodules +cd Simian +```` + +If you forgot `--recurse-submodules`, run: + +```bash +git submodule update --init --recursive +``` + +This will pull **Raylib** and **AngelScript** into `external/`. + +--- + +### 2. Build with CMake + +```bash +# Create build folder +mkdir build +cd build + +# Generate Visual Studio solution (64-bit) +cmake -G "Visual Studio 17 2022" -A x64 .. + +# Build Release version +cmake --build . --config Release +``` + +After building, the executable will be at: + +``` +build\Release\simian.exe +``` + +--- + +### 3. Run the project + +```bash +build\Release\simian.exe +``` + +You should see a **Raylib window** open and the console will output: + +``` +[Script] Hello from AngelScript! +``` + +--- + +## Project Structure + +``` +Simian/ +├─ external/ +│ ├─ raylib/ # Git submodule +│ └─ angelscript/ # Git submodule (includes scriptstdstring add-on) +├─ scripts/ # Optional: .as scripts to be loaded at runtime +├─ main.cpp # Entry point (Raylib + AngelScript) +├─ CMakeLists.txt # Build configuration +└─ README.md +``` + +--- + +## Notes + +* **AngelScript `string` support** is enabled via `scriptstdstring` add-on. +* **Hot-reloading scripts** can be implemented by loading `.as` files from the `scripts/` folder. +* Update submodules with: + +```bash +cd external/raylib +git pull origin master +cd ../angelscript +git pull origin master +cd ../.. +git add external/raylib external/angelscript +git commit -m "Update submodules" +``` + +--- + +## CMake Targets + +* `simian` — main executable +* `raylib` — static library submodule +* `angelscript` — static library submodule +* `scriptstdstring` — static library add-on for AngelScript + +--- + +## Tips + +* Always use **VS2022 Developer Command Prompt** or VSCode terminal configured for MSVC. +* Pin submodules to specific commits for reproducible builds. +* To clean build: delete the `build/` folder and regenerate with CMake. + +--- + +## License + +* Raylib: [Zlib License](https://github.com/raysan5/raylib#license) +* AngelScript: [MIT License](https://github.com/angelcode/angelscript/blob/master/license.txt) +* Simian: Not open source (Yet)