scad-gltf 0.2.1 β 0.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -5
- package/godot/README.md +0 -3
- package/package.json +1 -1
- package/godot/examples/LICENSE +0 -21
- package/godot/examples/README.md +0 -91
- package/godot/examples/fruit_fusion_3d.js +0 -1774
- package/godot/examples/horde_survivor_3d.js +0 -2753
- package/godot/examples/kids_digit_writing.js +0 -2532
- package/godot/examples/naval_battle_3d.js +0 -1691
- package/godot/examples/package.json +0 -5
- package/godot/export_presets.cfg +0 -25
package/README.md
CHANGED
|
@@ -22,7 +22,7 @@ The C++ source code for this custom OpenSCAD version is included directly in thi
|
|
|
22
22
|
- **CLI Converter:** Bundled `scad-convert` CLI utility for single file and batch compiling `.scad` files with smart dependency hashing.
|
|
23
23
|
- **MCP Server for AI Agents:** Bundled `scad-mcp` server enables MCP clients to iteratively design, compile, and **visually inspect** 3D models via multi-angle headless rendering and animation frame evaluation.
|
|
24
24
|
- **AI Studio Extension:** Chrome extension to natively preview, prompt, take chat snapshots, open in Scadify, and locally save AI-generated 3D models directly inside Google AI Studio.
|
|
25
|
-
- **Godot 4, Rust Bevy & Web Integration:** Native Godot 4 importer addon
|
|
25
|
+
- **Godot 4, Rust Bevy & Web Integration:** Native Godot 4 importer addon and Rust Bevy compile-time `build.rs` integration.
|
|
26
26
|
- **Automated AI Generation:** Pass an OpenAI-compatible base URL (and optional API key) to the `scad-godot`, `scad-bevy`, or `scad-web` CLI to automatically spawn a local MCP server, query the LLM via standard endpoints, allow it to visually iterate, and output a ready-to-run project generator script.
|
|
27
27
|
|
|
28
28
|
---
|
|
@@ -287,11 +287,7 @@ This repository includes an official **Godot 4.x Importer Addon** located in the
|
|
|
287
287
|
|
|
288
288
|
The addon allows you to drag-and-drop `.scad` files directly into your Godot project. It uses this WASM compiler under the hood to transform scripts into 3D scenes automatically.
|
|
289
289
|
|
|
290
|
-
**πΉοΈ Play Web Demos (No Installation Required):**
|
|
291
|
-
Try prebuilt AI-generated Godot games directly in your browser: [https://iliagrigorevdev.github.io/scad-godot/](https://iliagrigorevdev.github.io/scad-godot/)
|
|
292
|
-
|
|
293
290
|
- **Features:** Supports PBR Materials and Hierarchical Node Animations inside the Godot Editor.
|
|
294
|
-
- **Examples:** Check out AI-generated game templates in the [`godot/examples`](./godot/examples) directory.
|
|
295
291
|
- **License:** The Godot Addon is licensed under **MIT**.
|
|
296
292
|
- **Setup:** Simply copy the `addons/scad_importer` folder to your project and enable it in Project Settings.
|
|
297
293
|
|
package/godot/README.md
CHANGED
|
@@ -4,9 +4,6 @@ This folder contains the official Godot 4.x Editor plugin for natively importing
|
|
|
4
4
|
|
|
5
5
|
By leveraging the `scad-gltf` compiler under the hood, this addon allows you to drag and drop procedural CAD files directly into your Godot project. It automatically compiles them into binary glTF (`.glb`) meshes, supporting advanced features like **PBR materials**, **hierarchical node animations**, and **texture baking**βall natively within the Godot editor.
|
|
6
6
|
|
|
7
|
-
**πΉοΈ Play Online in Your Browser (No Installation Required):**
|
|
8
|
-
π **[https://iliagrigorevdev.github.io/scad-godot/](https://iliagrigorevdev.github.io/scad-godot/)**
|
|
9
|
-
|
|
10
7
|
## β¨ Features
|
|
11
8
|
|
|
12
9
|
- **Seamless Integration**: Drag and drop `.scad` files directly into the Godot FileSystem dock.
|
package/package.json
CHANGED
package/godot/examples/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2026 Ilia Grigorev
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
package/godot/examples/README.md
DELETED
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
# AI-Generated Godot Examples
|
|
2
|
-
|
|
3
|
-
This folder contains a collection of **all-in-one Node.js scripts**, each representing a complete, playable 3D Godot 4 game generated entirely by AI using the `scad-godot` CLI tool.
|
|
4
|
-
|
|
5
|
-
Instead of committing messy project folders, each example is bundled into a single, self-extracting JavaScript file. These scripts contain the generated OpenSCAD (`.scad`) 3D assets, Godot scripts (`.gd`), Godot scenes (`.tscn`), and the required `scad_importer` addon needed to parse the SCAD files directly in the engine.
|
|
6
|
-
|
|
7
|
-
**πΉοΈ Play Online in Your Browser (No Installation Required):**
|
|
8
|
-
π **[https://iliagrigorevdev.github.io/scad-godot/](https://iliagrigorevdev.github.io/scad-godot/)**
|
|
9
|
-
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
## π How to Play the Examples
|
|
13
|
-
|
|
14
|
-
To test out an example, you need to extract it and open it in Godot 4. The Godot importer relies on the `scad-gltf` tools to compile the 3D OpenSCAD scripts into binary meshes.
|
|
15
|
-
|
|
16
|
-
Depending on your operating system and environment, there are two ways to handle this.
|
|
17
|
-
|
|
18
|
-
### Prerequisites
|
|
19
|
-
|
|
20
|
-
- **Node.js** installed on your system.
|
|
21
|
-
- **Godot 4.x** installed on your system.
|
|
22
|
-
|
|
23
|
-
### Step 1: Extract the Project
|
|
24
|
-
|
|
25
|
-
Open your terminal in this folder and execute the desired example script using Node.js:
|
|
26
|
-
|
|
27
|
-
```bash
|
|
28
|
-
node my_example_game.js
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
_The script will automatically create a new folder (e.g., `./my-example-game`) containing the full Godot project directory structure, saving all the assets and addon files to disk._
|
|
32
|
-
|
|
33
|
-
---
|
|
34
|
-
|
|
35
|
-
### Step 2: Compile Models & Open Godot
|
|
36
|
-
|
|
37
|
-
Choose the method that best fits your environment:
|
|
38
|
-
|
|
39
|
-
#### Option A: Standard Desktop (Global Install)
|
|
40
|
-
|
|
41
|
-
If you are on a standard Windows, macOS, or Linux desktop, the easiest way is to have the CLI globally installed. The Godot plugin will automatically find and use the `scad-convert` command.
|
|
42
|
-
|
|
43
|
-
1. Install the tool globally:
|
|
44
|
-
```bash
|
|
45
|
-
npm install -g scad-gltf
|
|
46
|
-
```
|
|
47
|
-
2. Launch **Godot 4**.
|
|
48
|
-
3. Click **Import** in the Project Manager, browse to the generated folder, and select the `project.godot` file.
|
|
49
|
-
4. Click **Import & Edit**. The addon will automatically compile the `.scad` files in the background.
|
|
50
|
-
|
|
51
|
-
#### Option B: Termux / Android / Restricted Environments (Backend Server)
|
|
52
|
-
|
|
53
|
-
In some environments (like running Godot directly on an Android device via Termux), the Godot engine cannot easily execute globally installed NPM CLI binaries. To solve this, you can run `scad-serve` as a local backend server. The Godot importer will automatically detect it and use its REST API to convert the 3D models.
|
|
54
|
-
|
|
55
|
-
1. Open your terminal and navigate into the newly extracted project folder:
|
|
56
|
-
```bash
|
|
57
|
-
cd my-example-game
|
|
58
|
-
```
|
|
59
|
-
2. Start the local server:
|
|
60
|
-
```bash
|
|
61
|
-
npx -p scad-gltf scad-serve
|
|
62
|
-
```
|
|
63
|
-
_(This starts a local backend server on port 3000)._
|
|
64
|
-
3. Leave the server running in the background.
|
|
65
|
-
4. Launch **Godot 4**, import the project, and open it. The `scad_importer` addon will ping your local `scad-serve` backend to compile the `.scad` files over HTTP.
|
|
66
|
-
|
|
67
|
-
---
|
|
68
|
-
|
|
69
|
-
### Step 3: Play the Game
|
|
70
|
-
|
|
71
|
-
Once the Godot Editor opens and finishes importing the 3D scenes:
|
|
72
|
-
|
|
73
|
-
- Press **F5** (or click the Play button in the top right) to run the game!
|
|
74
|
-
|
|
75
|
-
---
|
|
76
|
-
|
|
77
|
-
## π οΈ How were these generated?
|
|
78
|
-
|
|
79
|
-
These files were created using this repository's built-in AI prompt pipeline. By running the `scad-godot` CLI command, the system instructs an LLM (like Claude, Gemini, or ChatGPT) to generate procedural OpenSCAD geometry, gameplay logic, and scene configurations, outputting them as a single JS extractor script.
|
|
80
|
-
|
|
81
|
-
If you want to generate your own games, run:
|
|
82
|
-
|
|
83
|
-
```bash
|
|
84
|
-
scad-godot "A simple 3D platformer where you control a rolling ball collecting coins"
|
|
85
|
-
```
|
|
86
|
-
|
|
87
|
-
_(See the main repository documentation for full details on generating your own AI projects)._
|
|
88
|
-
|
|
89
|
-
## π License
|
|
90
|
-
|
|
91
|
-
These examples and their generated Godot project assets are licensed under the [MIT License](LICENSE).
|