nova64 0.2.4 → 0.2.6
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 +25 -8
- package/bin/nova64.js +165 -0
- package/dist/assets/console-CY_kygm3.js +14 -0
- package/dist/assets/console-CY_kygm3.js.map +1 -0
- package/dist/assets/main-l0sNRNKZ.js.map +1 -0
- package/dist/assets/sky/studio/nx.png +0 -0
- package/dist/assets/sky/studio/ny.png +0 -0
- package/dist/assets/sky/studio/nz.png +0 -0
- package/dist/assets/sky/studio/px.png +0 -0
- package/dist/assets/sky/studio/py.png +0 -0
- package/dist/assets/sky/studio/pz.png +0 -0
- package/dist/assets/vanilla-Dcuy32gi.js +2 -0
- package/dist/assets/vanilla-Dcuy32gi.js.map +1 -0
- package/dist/console.html +899 -0
- package/dist/docs/BENCHMARK.md +77 -0
- package/dist/docs/CHEATSHEET.md +255 -0
- package/dist/docs/EFFECTS_API_GUIDE.md +577 -0
- package/dist/docs/EFFECTS_QUICK_REFERENCE.md +331 -0
- package/dist/docs/FONT_CHARACTER_REFERENCE.md +219 -0
- package/dist/docs/FREE_GLB_ASSETS.md +330 -0
- package/dist/docs/FULLSCREEN_BUTTON_FEATURE.md +296 -0
- package/dist/docs/GAMEPAD_SUPPORT.md +348 -0
- package/dist/docs/GAME_IMPROVEMENTS.md +278 -0
- package/dist/docs/GAME_QUALITY_STATUS.md +300 -0
- package/dist/docs/MIGRATION_GUIDE.md +553 -0
- package/dist/docs/NOVA64_3D_API.md +356 -0
- package/dist/docs/NOVA64_API_REFERENCE.md +1406 -0
- package/dist/docs/NOVA64_UI_API.md +503 -0
- package/dist/docs/UI_SYSTEM_SUMMARY.md +445 -0
- package/dist/docs/VOXEL_ENGINE_GUIDE.md +662 -0
- package/dist/docs/VOXEL_QUICK_REFERENCE.md +386 -0
- package/dist/docs/api-3d.html +750 -0
- package/dist/docs/api-effects.html +385 -0
- package/dist/docs/api-improvements.md +121 -0
- package/dist/docs/api-skybox.html +407 -0
- package/dist/docs/api-sprites.html +321 -0
- package/dist/docs/api-voxel.html +337 -0
- package/dist/docs/api.html +543 -0
- package/dist/docs/assets.html +306 -0
- package/dist/docs/audio.html +340 -0
- package/dist/docs/blogs.html +286 -0
- package/dist/docs/collision.html +316 -0
- package/dist/docs/console.html +247 -0
- package/dist/docs/editor.html +297 -0
- package/dist/docs/font.html +247 -0
- package/dist/docs/framebuffer.html +247 -0
- package/dist/docs/fullscreen-button.html +297 -0
- package/dist/docs/gpu-systems.html +247 -0
- package/dist/docs/index.html +580 -0
- package/dist/docs/input.html +491 -0
- package/dist/docs/physics.html +311 -0
- package/dist/docs/screens.html +311 -0
- package/dist/docs/storage.html +311 -0
- package/dist/docs/textinput.html +332 -0
- package/dist/docs/ui.html +488 -0
- package/dist/examples/3d-advanced/code.js +695 -0
- package/dist/examples/adventure-comic-3d/code.js +342 -0
- package/dist/examples/audio-lab/code.js +150 -0
- package/dist/examples/boids-flocking/code.js +270 -0
- package/dist/examples/crystal-cathedral-3d/code.js +706 -0
- package/dist/examples/cyberpunk-city-3d/code.js +1383 -0
- package/dist/examples/demoscene/README.md +192 -0
- package/dist/examples/demoscene/code.js +1081 -0
- package/dist/examples/demoscene/meta.json +21 -0
- package/dist/examples/dungeon-crawler-3d/code.js +1117 -0
- package/dist/examples/f-zero-nova-3d/code.js +865 -0
- package/dist/examples/f-zero-nova-3d/code_old.js +1555 -0
- package/dist/examples/fps-demo-3d/code.js +744 -0
- package/dist/examples/game-of-life-3d/code.js +338 -0
- package/dist/examples/generative-art/code.js +632 -0
- package/dist/examples/hello-3d/code.js +325 -0
- package/dist/examples/hello-skybox/code.js +183 -0
- package/dist/examples/hello-world/code.js +19 -0
- package/dist/examples/input-showcase/code.js +109 -0
- package/dist/examples/instancing-demo/code.js +315 -0
- package/dist/examples/minecraft-demo/code.js +387 -0
- package/dist/examples/model-viewer-3d/code.js +114 -0
- package/dist/examples/mystical-realm-3d/code.js +1203 -0
- package/dist/examples/nature-explorer-3d/code.js +1318 -0
- package/dist/examples/particles-demo/code.js +522 -0
- package/dist/examples/pbr-showcase/code.js +140 -0
- package/dist/examples/physics-demo-3d/code.js +948 -0
- package/dist/examples/screen-demo/code.js +267 -0
- package/dist/examples/shooter-demo-3d/code.js +1286 -0
- package/dist/examples/space-combat-3d/IMPLEMENTATION_SUMMARY.md +109 -0
- package/dist/examples/space-combat-3d/README.md +135 -0
- package/dist/examples/space-combat-3d/code.js +1332 -0
- package/dist/examples/space-harrier-3d/code.js +923 -0
- package/dist/examples/star-fox-nova-3d/code.js +1116 -0
- package/dist/examples/star-fox-nova-3d/code_backup.js +410 -0
- package/dist/examples/star-fox-nova-3d/code_broken.js +1821 -0
- package/dist/examples/storage-quest/code.js +209 -0
- package/dist/examples/strider-demo-3d/IMPROVEMENT_OPTIONS.md +285 -0
- package/dist/examples/strider-demo-3d/cache-test.html +132 -0
- package/dist/examples/strider-demo-3d/code-fixed.js +582 -0
- package/dist/examples/strider-demo-3d/code-old.js +1537 -0
- package/dist/examples/strider-demo-3d/code.js +1462 -0
- package/dist/examples/strider-demo-3d/code.js.bak2 +1169 -0
- package/dist/examples/strider-demo-3d/fix-game.sh +53 -0
- package/dist/examples/super-plumber-64/README.md +128 -0
- package/dist/examples/super-plumber-64/code.js +1185 -0
- package/dist/examples/super-plumber-64/index.html +88 -0
- package/dist/examples/test-2d-overlay/code.js +32 -0
- package/dist/examples/test-font/code.js +51 -0
- package/dist/examples/test-minimal/code.js +21 -0
- package/dist/examples/ui-demo/code.js +306 -0
- package/dist/examples/wing-commander-space/README.md +180 -0
- package/dist/examples/wing-commander-space/code.js +1285 -0
- package/dist/examples/wizardry-3d/CHANGELOG.md +366 -0
- package/dist/examples/wizardry-3d/code.js +3928 -0
- package/dist/index.html +666 -0
- package/dist/os9-shell/assets/index-DIHfrTaW.css +1 -0
- package/dist/os9-shell/assets/index-KchE_ngx.js +483 -0
- package/dist/os9-shell/assets/index-KchE_ngx.js.map +1 -0
- package/dist/os9-shell/index.html +23 -0
- package/dist/os9-shell/nova-icon.svg +12 -0
- package/index.html +6 -1
- package/package.json +37 -32
- package/public/assets/sky/studio/nx.png +0 -0
- package/public/assets/sky/studio/ny.png +0 -0
- package/public/assets/sky/studio/nz.png +0 -0
- package/public/assets/sky/studio/px.png +0 -0
- package/public/assets/sky/studio/py.png +0 -0
- package/public/assets/sky/studio/pz.png +0 -0
- package/public/os9-shell/assets/index-KchE_ngx.js +483 -0
- package/public/os9-shell/assets/index-KchE_ngx.js.map +1 -0
- package/public/os9-shell/index.html +10 -1
- package/runtime/api-2d.js +301 -21
- package/runtime/api-3d/pbr.js +45 -1
- package/runtime/api-3d.js +1 -0
- package/runtime/api-effects.js +90 -3
- package/runtime/api-gameutils.js +476 -0
- package/runtime/api-generative.js +610 -0
- package/runtime/api-skybox.js +54 -0
- package/runtime/api-voxel.js +139 -28
- package/runtime/gpu-threejs.js +13 -9
- package/runtime/ui.js +2 -2
- package/src/main.js +24 -1
- package/public/os9-shell/assets/index-B1Uvacma.js +0 -32825
- package/public/os9-shell/assets/index-B1Uvacma.js.map +0 -1
|
@@ -0,0 +1,330 @@
|
|
|
1
|
+
# Free GLB Assets for Nova64
|
|
2
|
+
|
|
3
|
+
This document lists **MIT, CC0, and Creative Commons** licensed GLB/glTF models that can be freely used in Nova64 projects.
|
|
4
|
+
|
|
5
|
+
## 🎯 Official glTF Sample Models (Khronos Group)
|
|
6
|
+
|
|
7
|
+
**Repository**: https://github.com/KhronosGroup/glTF-Sample-Models
|
|
8
|
+
|
|
9
|
+
**License**: Various (CC0, CC-BY 4.0, MIT equivalent)
|
|
10
|
+
|
|
11
|
+
### Recommended Models for Games:
|
|
12
|
+
|
|
13
|
+
#### Characters & Creatures
|
|
14
|
+
|
|
15
|
+
- **Fox** - CC0 & CC-BY 4.0 - Animated low-poly fox
|
|
16
|
+
- `2.0/Fox/glTF-Binary/Fox.glb`
|
|
17
|
+
- Perfect for platformers, includes walk/run animations
|
|
18
|
+
- **Cesium Man** - CC-BY 4.0 - Animated character
|
|
19
|
+
- `2.0/CesiumMan/glTF-Binary/CesiumMan.glb`
|
|
20
|
+
- Good for testing character animations
|
|
21
|
+
- **Rigged Simple** - CC-BY 4.0 - Basic rigged character
|
|
22
|
+
- `2.0/RiggedSimple/glTF-Binary/RiggedSimple.glb`
|
|
23
|
+
- Great for learning skinning/animation
|
|
24
|
+
|
|
25
|
+
#### Vehicles
|
|
26
|
+
|
|
27
|
+
- **Cesium Milk Truck** - CC-BY 4.0
|
|
28
|
+
- `2.0/CesiumMilkTruck/glTF-Binary/CesiumMilkTruck.glb`
|
|
29
|
+
- Retro style truck with texture
|
|
30
|
+
|
|
31
|
+
#### Objects & Props
|
|
32
|
+
|
|
33
|
+
- **Avocado** - CC-BY 4.0
|
|
34
|
+
- `2.0/Avocado/glTF-Binary/Avocado.glb`
|
|
35
|
+
- Food prop with PBR textures
|
|
36
|
+
- **Water Bottle** - CC0 (Public Domain)
|
|
37
|
+
- `2.0/WaterBottle/glTF-Binary/WaterBottle.glb`
|
|
38
|
+
- Photorealistic bottle
|
|
39
|
+
- **Flight Helmet** - CC0 (Public Domain)
|
|
40
|
+
- `2.0/FlightHelmet/glTF-Binary/FlightHelmet.glb`
|
|
41
|
+
- High quality prop
|
|
42
|
+
|
|
43
|
+
- **Duck** - Public Domain
|
|
44
|
+
- `2.0/Duck/glTF-Binary/Duck.glb`
|
|
45
|
+
- Classic COLLADA duck model
|
|
46
|
+
|
|
47
|
+
#### Environment
|
|
48
|
+
|
|
49
|
+
- **Sponza** - CC-BY 4.0
|
|
50
|
+
- `2.0/Sponza/glTF-Binary/Sponza.glb`
|
|
51
|
+
- Building interior for testing lighting
|
|
52
|
+
|
|
53
|
+
- **A Beautiful Game** - CC-BY 4.0
|
|
54
|
+
- `2.0/ABeautifulGame/glTF-Binary/ABeautifulGame.glb`
|
|
55
|
+
- Chess set with PBR materials
|
|
56
|
+
|
|
57
|
+
#### Basic Shapes (CC-BY 4.0 / CC0)
|
|
58
|
+
|
|
59
|
+
- **Box** - `2.0/Box/glTF-Binary/Box.glb`
|
|
60
|
+
- **Box Textured** - `2.0/BoxTextured/glTF-Binary/BoxTextured.glb`
|
|
61
|
+
- **Cube** - `2.0/Cube/glTF-Binary/Cube.glb`
|
|
62
|
+
- **Suzanne** (Blender Monkey) - `2.0/Suzanne/glTF-Binary/Suzanne.glb`
|
|
63
|
+
|
|
64
|
+
### How to Download:
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
# Clone the entire repository
|
|
68
|
+
git clone https://github.com/KhronosGroup/glTF-Sample-Models.git
|
|
69
|
+
|
|
70
|
+
# Or download individual models via raw GitHub URLs:
|
|
71
|
+
# https://raw.githubusercontent.com/KhronosGroup/glTF-Sample-Models/master/2.0/Fox/glTF-Binary/Fox.glb
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
---
|
|
75
|
+
|
|
76
|
+
## 🎨 Kenney Assets (CC0 - Public Domain)
|
|
77
|
+
|
|
78
|
+
**Website**: https://kenney.nl/assets
|
|
79
|
+
|
|
80
|
+
**License**: CC0 1.0 Universal (Public Domain)
|
|
81
|
+
|
|
82
|
+
Kenney offers **hundreds of themed game assets**, all free with CC0 license:
|
|
83
|
+
|
|
84
|
+
### Asset Packs (with glTF/GLB support):
|
|
85
|
+
|
|
86
|
+
- **Pirate Kit** (30+ models) - Ships, cannons, treasure
|
|
87
|
+
- **Racing Kit** - Cars, tracks, obstacles
|
|
88
|
+
- **Space Kit** - Spaceships, asteroids, planets
|
|
89
|
+
- **Castle Kit** - Medieval buildings, props
|
|
90
|
+
- **Nature Kit** - Trees, rocks, plants
|
|
91
|
+
- **City Kit** - Buildings, vehicles, street furniture
|
|
92
|
+
- **Platformer Kit** - Platforms, enemies, collectibles
|
|
93
|
+
- **Furniture Pack** - Interior props
|
|
94
|
+
- **Food Pack** - Various food items
|
|
95
|
+
|
|
96
|
+
**Download**: Browse https://kenney.nl/assets?q=3d and filter by 3D models
|
|
97
|
+
|
|
98
|
+
---
|
|
99
|
+
|
|
100
|
+
## 🌟 Poly Haven (CC0)
|
|
101
|
+
|
|
102
|
+
**Website**: https://polyhaven.com/models
|
|
103
|
+
|
|
104
|
+
**License**: CC0 (Public Domain)
|
|
105
|
+
|
|
106
|
+
High-quality photorealistic 3D models, all CC0:
|
|
107
|
+
|
|
108
|
+
### Categories:
|
|
109
|
+
|
|
110
|
+
- **Furniture** - Chairs, tables, lamps
|
|
111
|
+
- **Plants** - Trees, bushes, flowers
|
|
112
|
+
- **Rocks & Nature** - Photoscanned rocks, terrain
|
|
113
|
+
- **Props** - Various objects
|
|
114
|
+
- **Food** - Realistic food items
|
|
115
|
+
|
|
116
|
+
**Format**: Models available in multiple formats including glTF/GLB
|
|
117
|
+
|
|
118
|
+
---
|
|
119
|
+
|
|
120
|
+
## 🎮 Quaternius (CC0)
|
|
121
|
+
|
|
122
|
+
**Website**: https://quaternius.com/
|
|
123
|
+
|
|
124
|
+
**License**: CC0 (Public Domain)
|
|
125
|
+
|
|
126
|
+
**Massive collection** of low-poly game-ready assets:
|
|
127
|
+
|
|
128
|
+
### Popular Packs:
|
|
129
|
+
|
|
130
|
+
- **Ultimate Animated Animals** - 100+ animated creatures
|
|
131
|
+
- **Ultimate Platformer Pack** - Platforms, enemies, collectibles
|
|
132
|
+
- **Ultimate Space Pack** - Spaceships, aliens, stations
|
|
133
|
+
- **Ultimate Fantasy Pack** - Dragons, knights, castles
|
|
134
|
+
- **Ultimate Stylized Nature** - Trees, rocks, plants
|
|
135
|
+
- **Ultimate Retro Pack** - Low-poly retro style assets
|
|
136
|
+
|
|
137
|
+
**Download**: Available on https://quaternius.com/ and https://opengameart.org/
|
|
138
|
+
|
|
139
|
+
---
|
|
140
|
+
|
|
141
|
+
## 🎪 Poly Pizza (CC0)
|
|
142
|
+
|
|
143
|
+
**Website**: https://poly.pizza/
|
|
144
|
+
|
|
145
|
+
**License**: CC0 (Public Domain)
|
|
146
|
+
|
|
147
|
+
Archive of Google Poly models (before it shut down):
|
|
148
|
+
|
|
149
|
+
- Thousands of low-poly models
|
|
150
|
+
- Perfect for retro/stylized games
|
|
151
|
+
- Easy search and download
|
|
152
|
+
- All CC0 license
|
|
153
|
+
|
|
154
|
+
---
|
|
155
|
+
|
|
156
|
+
## 📦 Sketchfab
|
|
157
|
+
|
|
158
|
+
**Website**: https://sketchfab.com/
|
|
159
|
+
|
|
160
|
+
**License**: Various (filter by Creative Commons)
|
|
161
|
+
|
|
162
|
+
### How to Find Free Models:
|
|
163
|
+
|
|
164
|
+
1. Go to https://sketchfab.com/
|
|
165
|
+
2. Search for models
|
|
166
|
+
3. Filter by:
|
|
167
|
+
- "Downloadable" ✓
|
|
168
|
+
- License: "Creative Commons" (CC-BY, CC0)
|
|
169
|
+
4. Download in glTF/GLB format
|
|
170
|
+
|
|
171
|
+
**Note**: Always check individual licenses - many are CC-BY 4.0 (requires attribution)
|
|
172
|
+
|
|
173
|
+
---
|
|
174
|
+
|
|
175
|
+
## 🎨 OpenGameArt.org
|
|
176
|
+
|
|
177
|
+
**Website**: https://opengameart.org/
|
|
178
|
+
|
|
179
|
+
**License**: Various (CC0, CC-BY, GPL, OGA-BY)
|
|
180
|
+
|
|
181
|
+
Community-contributed game assets:
|
|
182
|
+
|
|
183
|
+
### Search Tips:
|
|
184
|
+
|
|
185
|
+
- Filter by "3D Art"
|
|
186
|
+
- Check "glTF" or "GLB" in search
|
|
187
|
+
- Verify license before use
|
|
188
|
+
- Many CC0 and CC-BY assets available
|
|
189
|
+
|
|
190
|
+
---
|
|
191
|
+
|
|
192
|
+
## 🏛️ Smithsonian Open Access
|
|
193
|
+
|
|
194
|
+
**Website**: https://3d.si.edu/
|
|
195
|
+
|
|
196
|
+
**License**: CC0 (Public Domain)
|
|
197
|
+
|
|
198
|
+
Historical artifacts and specimens:
|
|
199
|
+
|
|
200
|
+
- Museum quality 3D scans
|
|
201
|
+
- Perfect for educational content
|
|
202
|
+
- Dinosaurs, artifacts, sculptures
|
|
203
|
+
- All free to use (CC0)
|
|
204
|
+
|
|
205
|
+
---
|
|
206
|
+
|
|
207
|
+
## 📋 Quick Reference: License Comparison
|
|
208
|
+
|
|
209
|
+
| License | Commercial Use | Attribution Required | Modifications OK |
|
|
210
|
+
| ------------- | -------------- | -------------------- | ---------------- |
|
|
211
|
+
| **CC0** | ✅ Yes | ❌ No | ✅ Yes |
|
|
212
|
+
| **CC-BY 4.0** | ✅ Yes | ✅ **Yes** | ✅ Yes |
|
|
213
|
+
| **MIT** | ✅ Yes | ✅ **Yes** (in code) | ✅ Yes |
|
|
214
|
+
|
|
215
|
+
---
|
|
216
|
+
|
|
217
|
+
## 🔧 How to Use GLB Files in Nova64
|
|
218
|
+
|
|
219
|
+
1. **Download** GLB files to your project:
|
|
220
|
+
|
|
221
|
+
```bash
|
|
222
|
+
mkdir -p /path/to/nova64/models
|
|
223
|
+
cd /path/to/nova64/models
|
|
224
|
+
# Download your GLB files here
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
2. **Load in Nova64 code**:
|
|
228
|
+
|
|
229
|
+
```javascript
|
|
230
|
+
export async function init() {
|
|
231
|
+
// Load GLB model
|
|
232
|
+
const fox = await loadModel('/models/Fox.glb', [0, 0, 0], 1.0);
|
|
233
|
+
|
|
234
|
+
// Or with options
|
|
235
|
+
const player = await loadModel(
|
|
236
|
+
'/models/character.glb',
|
|
237
|
+
[0, 2, 0], // position
|
|
238
|
+
2.0 // scale
|
|
239
|
+
);
|
|
240
|
+
}
|
|
241
|
+
```
|
|
242
|
+
|
|
243
|
+
3. **Animate GLB models** (if they have animations):
|
|
244
|
+
```javascript
|
|
245
|
+
export function update(dt) {
|
|
246
|
+
// Play animation
|
|
247
|
+
playAnimation(modelMesh, 'Walk', dt);
|
|
248
|
+
}
|
|
249
|
+
```
|
|
250
|
+
|
|
251
|
+
---
|
|
252
|
+
|
|
253
|
+
## 📥 Recommended Downloads for Nova64
|
|
254
|
+
|
|
255
|
+
### For Platformers:
|
|
256
|
+
|
|
257
|
+
- Fox (animated character) - CC-BY 4.0
|
|
258
|
+
- Kenney Platformer Kit - CC0
|
|
259
|
+
- Quaternius Ultimate Platformer Pack - CC0
|
|
260
|
+
|
|
261
|
+
### For Racing Games:
|
|
262
|
+
|
|
263
|
+
- Kenney Racing Kit - CC0
|
|
264
|
+
- Kenney Car Kit - CC0
|
|
265
|
+
|
|
266
|
+
### For Space Games:
|
|
267
|
+
|
|
268
|
+
- Kenney Space Kit - CC0
|
|
269
|
+
- Quaternius Ultimate Space Pack - CC0
|
|
270
|
+
|
|
271
|
+
### For RPG/Adventure:
|
|
272
|
+
|
|
273
|
+
- Quaternius Ultimate Fantasy Pack - CC0
|
|
274
|
+
- Kenney Castle Kit - CC0
|
|
275
|
+
|
|
276
|
+
---
|
|
277
|
+
|
|
278
|
+
## 🎯 Direct Download Links
|
|
279
|
+
|
|
280
|
+
Create a models directory and download these starter models:
|
|
281
|
+
|
|
282
|
+
```bash
|
|
283
|
+
# Create models directory
|
|
284
|
+
mkdir -p models
|
|
285
|
+
|
|
286
|
+
# Download from Khronos glTF samples (use raw.githubusercontent.com)
|
|
287
|
+
# Example URLs:
|
|
288
|
+
# https://raw.githubusercontent.com/KhronosGroup/glTF-Sample-Models/master/2.0/Fox/glTF-Binary/Fox.glb
|
|
289
|
+
# https://raw.githubusercontent.com/KhronosGroup/glTF-Sample-Models/master/2.0/Duck/glTF-Binary/Duck.glb
|
|
290
|
+
# https://raw.githubusercontent.com/KhronosGroup/glTF-Sample-Models/master/2.0/CesiumMan/glTF-Binary/CesiumMan.glb
|
|
291
|
+
```
|
|
292
|
+
|
|
293
|
+
---
|
|
294
|
+
|
|
295
|
+
## ⚖️ License Compliance
|
|
296
|
+
|
|
297
|
+
### When using CC-BY 4.0 models:
|
|
298
|
+
|
|
299
|
+
Add attribution to your game credits or README:
|
|
300
|
+
|
|
301
|
+
```markdown
|
|
302
|
+
## Credits
|
|
303
|
+
|
|
304
|
+
3D Models:
|
|
305
|
+
|
|
306
|
+
- Fox by PixelMannen (CC0) and @tomkranis (CC-BY 4.0)
|
|
307
|
+
https://sketchfab.com/models/371dea88d7e04a76af5763f2a36866bc
|
|
308
|
+
- [Model Name] by [Author] (CC-BY 4.0)
|
|
309
|
+
[Source URL]
|
|
310
|
+
```
|
|
311
|
+
|
|
312
|
+
### When using CC0 models:
|
|
313
|
+
|
|
314
|
+
No attribution required, but it's nice to credit creators!
|
|
315
|
+
|
|
316
|
+
---
|
|
317
|
+
|
|
318
|
+
## 🚀 Next Steps
|
|
319
|
+
|
|
320
|
+
1. Choose a model pack based on your game genre
|
|
321
|
+
2. Download GLB files to your `models/` directory
|
|
322
|
+
3. Load them in your Nova64 game using `loadModel()`
|
|
323
|
+
4. Add proper attribution for CC-BY licensed models
|
|
324
|
+
5. Have fun making games! 🎮
|
|
325
|
+
|
|
326
|
+
---
|
|
327
|
+
|
|
328
|
+
**Last Updated**: October 2025
|
|
329
|
+
|
|
330
|
+
**Note**: Always verify licenses before use. This list focuses on models that are free for commercial use.
|
|
@@ -0,0 +1,296 @@
|
|
|
1
|
+
# Nova64 Fullscreen Button Feature
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
A universal fullscreen button that appears in the lower-right corner of the canvas for **every** Nova64 demo. This allows users to quickly toggle fullscreen mode with a single click.
|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
✅ **Universal**: Appears for all demos automatically
|
|
10
|
+
✅ **Stylish UI**: Neon cyan button with hover effects matching Nova64 theme
|
|
11
|
+
✅ **Smooth Transitions**: Animated hover and fullscreen transitions
|
|
12
|
+
✅ **Keyboard Support**: ESC key exits fullscreen mode
|
|
13
|
+
✅ **Cross-browser**: Works in Chrome, Firefox, Safari, Edge
|
|
14
|
+
✅ **Icon Changes**: Shows expand icon (⛶) normally, compress icon (⛉) in fullscreen
|
|
15
|
+
✅ **Transparent Background**: Blurred backdrop for modern glass effect
|
|
16
|
+
|
|
17
|
+
## Usage
|
|
18
|
+
|
|
19
|
+
### For Users:
|
|
20
|
+
|
|
21
|
+
1. **Enter Fullscreen**:
|
|
22
|
+
- Click the button in the lower-right corner
|
|
23
|
+
- Or use F11 (browser default)
|
|
24
|
+
|
|
25
|
+
2. **Exit Fullscreen**:
|
|
26
|
+
- Click the button again
|
|
27
|
+
- Or press **ESC** key
|
|
28
|
+
- Or press F11 again
|
|
29
|
+
|
|
30
|
+
### For Developers:
|
|
31
|
+
|
|
32
|
+
The fullscreen button is **automatically created** when the Nova64 runtime initializes. No setup needed in individual demos!
|
|
33
|
+
|
|
34
|
+
```javascript
|
|
35
|
+
// In main.js - already configured!
|
|
36
|
+
import { createFullscreenButton } from '../runtime/fullscreen-button.js';
|
|
37
|
+
|
|
38
|
+
const canvas = document.getElementById('screen');
|
|
39
|
+
globalThis.fullscreenButton = createFullscreenButton(canvas);
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Implementation Details
|
|
43
|
+
|
|
44
|
+
### File: `runtime/fullscreen-button.js`
|
|
45
|
+
|
|
46
|
+
The fullscreen button:
|
|
47
|
+
|
|
48
|
+
- Creates a floating button element
|
|
49
|
+
- Positions it at `bottom: 20px`, `right: 20px`
|
|
50
|
+
- Uses fixed positioning (visible in all demos)
|
|
51
|
+
- Adds event listeners for:
|
|
52
|
+
- Click to toggle fullscreen
|
|
53
|
+
- ESC key to exit
|
|
54
|
+
- Fullscreen change detection (handles F11, ESC, etc.)
|
|
55
|
+
|
|
56
|
+
### Styling
|
|
57
|
+
|
|
58
|
+
```css
|
|
59
|
+
Position: Fixed (lower-right corner)
|
|
60
|
+
Size: 48px × 48px
|
|
61
|
+
Border: 2px solid cyan (#00ffff)
|
|
62
|
+
Background: Semi-transparent dark with blur effect
|
|
63
|
+
Shadow: Neon cyan glow
|
|
64
|
+
Z-index: 9999 (always on top)
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
### Browser Compatibility
|
|
68
|
+
|
|
69
|
+
Uses standard Fullscreen API with fallbacks:
|
|
70
|
+
|
|
71
|
+
- `requestFullscreen()` - Standard
|
|
72
|
+
- `webkitRequestFullscreen()` - Safari
|
|
73
|
+
- `mozRequestFullScreen()` - Firefox
|
|
74
|
+
- `msRequestFullscreen()` - IE11
|
|
75
|
+
|
|
76
|
+
## Technical Architecture
|
|
77
|
+
|
|
78
|
+
### Class: FullscreenButton
|
|
79
|
+
|
|
80
|
+
```javascript
|
|
81
|
+
class FullscreenButton {
|
|
82
|
+
constructor(canvas)
|
|
83
|
+
createButton() // Creates DOM element with styles
|
|
84
|
+
attachListeners() // Sets up click and keyboard handlers
|
|
85
|
+
toggleFullscreen() // Toggles between fullscreen/normal
|
|
86
|
+
enterFullscreen() // Enters fullscreen mode
|
|
87
|
+
exitFullscreen() // Exits fullscreen mode
|
|
88
|
+
handleFullscreenChange() // Syncs state with browser
|
|
89
|
+
updateButton() // Updates icon based on state
|
|
90
|
+
destroy() // Cleanup (if needed)
|
|
91
|
+
}
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
### State Management
|
|
95
|
+
|
|
96
|
+
```javascript
|
|
97
|
+
this.isFullscreen = false; // Tracks current state
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
State is automatically synchronized when:
|
|
101
|
+
|
|
102
|
+
- User clicks button
|
|
103
|
+
- User presses ESC
|
|
104
|
+
- User presses F11
|
|
105
|
+
- Browser exits fullscreen for any reason
|
|
106
|
+
|
|
107
|
+
## Customization
|
|
108
|
+
|
|
109
|
+
If you need to customize the button appearance, edit `runtime/fullscreen-button.js`:
|
|
110
|
+
|
|
111
|
+
```javascript
|
|
112
|
+
// Change position
|
|
113
|
+
bottom: '20px', // Distance from bottom
|
|
114
|
+
right: '20px', // Distance from right
|
|
115
|
+
|
|
116
|
+
// Change size
|
|
117
|
+
width: '48px',
|
|
118
|
+
height: '48px',
|
|
119
|
+
|
|
120
|
+
// Change colors
|
|
121
|
+
border: '2px solid #00ffff', // Cyan border
|
|
122
|
+
color: '#00ffff', // Cyan icon
|
|
123
|
+
|
|
124
|
+
// Change background
|
|
125
|
+
background: 'rgba(21, 24, 34, 0.9)', // Dark semi-transparent
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
## ESC Key Behavior
|
|
129
|
+
|
|
130
|
+
The ESC key is handled at two levels:
|
|
131
|
+
|
|
132
|
+
1. **Browser Level**: Native fullscreen ESC handling
|
|
133
|
+
2. **Button Level**: Custom ESC listener that calls `exitFullscreen()`
|
|
134
|
+
|
|
135
|
+
Both work together to ensure ESC always exits fullscreen mode.
|
|
136
|
+
|
|
137
|
+
## Examples
|
|
138
|
+
|
|
139
|
+
### Button in Different States
|
|
140
|
+
|
|
141
|
+
**Normal Mode**:
|
|
142
|
+
|
|
143
|
+
```
|
|
144
|
+
┌──────────────────┐
|
|
145
|
+
│ ⛶ │ ← Expand icon
|
|
146
|
+
└──────────────────┘
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
**Fullscreen Mode**:
|
|
150
|
+
|
|
151
|
+
```
|
|
152
|
+
┌──────────────────┐
|
|
153
|
+
│ ⛉ │ ← Compress icon
|
|
154
|
+
└──────────────────┘
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
### Hover Effect
|
|
158
|
+
|
|
159
|
+
- Scale: 1.0 → 1.1
|
|
160
|
+
- Background: Darker → Cyan tint
|
|
161
|
+
- Shadow: Subtle → Bright glow
|
|
162
|
+
|
|
163
|
+
## Testing
|
|
164
|
+
|
|
165
|
+
### Test Checklist
|
|
166
|
+
|
|
167
|
+
- ☐ Button appears in lower-right corner
|
|
168
|
+
- ☐ Button has cyan neon glow effect
|
|
169
|
+
- ☐ Hover effect works (scale + glow increase)
|
|
170
|
+
- ☐ Click enters fullscreen
|
|
171
|
+
- ☐ Icon changes to compress icon in fullscreen
|
|
172
|
+
- ☐ ESC exits fullscreen
|
|
173
|
+
- ☐ Click exits fullscreen (when already fullscreen)
|
|
174
|
+
- ☐ F11 syncs with button state
|
|
175
|
+
- ☐ Button works across all demos
|
|
176
|
+
- ☐ Button stays on top of game content
|
|
177
|
+
|
|
178
|
+
### Browser Testing
|
|
179
|
+
|
|
180
|
+
Test in:
|
|
181
|
+
|
|
182
|
+
- ✅ Chrome/Edge
|
|
183
|
+
- ✅ Firefox
|
|
184
|
+
- ✅ Safari
|
|
185
|
+
- ✅ Mobile browsers (if applicable)
|
|
186
|
+
|
|
187
|
+
## Canvas Behavior in Fullscreen
|
|
188
|
+
|
|
189
|
+
When entering fullscreen:
|
|
190
|
+
|
|
191
|
+
- Canvas expands to fill entire screen
|
|
192
|
+
- Maintains aspect ratio (letterboxing/pillarboxing)
|
|
193
|
+
- Image rendering stays pixelated for retro look
|
|
194
|
+
- All controls remain functional
|
|
195
|
+
|
|
196
|
+
## Performance
|
|
197
|
+
|
|
198
|
+
- **Minimal overhead**: Single DOM element
|
|
199
|
+
- **No rendering impact**: Pure CSS/HTML
|
|
200
|
+
- **Event efficient**: Uses native fullscreen API
|
|
201
|
+
- **Memory**: ~1KB footprint
|
|
202
|
+
|
|
203
|
+
## Accessibility
|
|
204
|
+
|
|
205
|
+
- **Keyboard**: ESC key support
|
|
206
|
+
- **Visual**: Clear icon indication
|
|
207
|
+
- **Tooltip**: Hover shows "Toggle Fullscreen (ESC to exit)"
|
|
208
|
+
- **Color contrast**: Cyan on dark meets WCAG standards
|
|
209
|
+
|
|
210
|
+
## Troubleshooting
|
|
211
|
+
|
|
212
|
+
### Button doesn't appear
|
|
213
|
+
|
|
214
|
+
- Check browser console for errors
|
|
215
|
+
- Verify `fullscreen-button.js` is loaded
|
|
216
|
+
- Check z-index conflicts with other UI
|
|
217
|
+
|
|
218
|
+
### Fullscreen doesn't work
|
|
219
|
+
|
|
220
|
+
- Check browser permissions (some block fullscreen)
|
|
221
|
+
- Verify canvas element exists
|
|
222
|
+
- Try F11 as alternative
|
|
223
|
+
|
|
224
|
+
### ESC doesn't exit fullscreen
|
|
225
|
+
|
|
226
|
+
- Check for conflicting ESC handlers in demos
|
|
227
|
+
- Verify fullscreen API is supported
|
|
228
|
+
|
|
229
|
+
### Button blocked by game UI
|
|
230
|
+
|
|
231
|
+
- Adjust z-index (default: 9999)
|
|
232
|
+
- Move position if needed
|
|
233
|
+
- Check demo's custom UI elements
|
|
234
|
+
|
|
235
|
+
## Future Enhancements
|
|
236
|
+
|
|
237
|
+
Potential additions:
|
|
238
|
+
|
|
239
|
+
- [ ] Customizable position (corners)
|
|
240
|
+
- [ ] Hide button in fullscreen (auto-show on mouse move)
|
|
241
|
+
- [ ] Keyboard shortcut display
|
|
242
|
+
- [ ] Animation on enter/exit fullscreen
|
|
243
|
+
- [ ] Mobile-specific handling
|
|
244
|
+
- [ ] VR mode toggle
|
|
245
|
+
|
|
246
|
+
## Integration with Demos
|
|
247
|
+
|
|
248
|
+
No changes needed in individual demos! The button is globally available.
|
|
249
|
+
|
|
250
|
+
### If a demo needs to disable it:
|
|
251
|
+
|
|
252
|
+
```javascript
|
|
253
|
+
// In your demo's init()
|
|
254
|
+
if (globalThis.fullscreenButton) {
|
|
255
|
+
globalThis.fullscreenButton.destroy();
|
|
256
|
+
}
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
### If a demo needs custom fullscreen handling:
|
|
260
|
+
|
|
261
|
+
```javascript
|
|
262
|
+
// Access the button instance
|
|
263
|
+
const fsBtn = globalThis.fullscreenButton;
|
|
264
|
+
|
|
265
|
+
// Check state
|
|
266
|
+
if (fsBtn.isFullscreen) {
|
|
267
|
+
console.log('Currently in fullscreen');
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
// Programmatically toggle
|
|
271
|
+
fsBtn.toggleFullscreen();
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
## Files Modified
|
|
275
|
+
|
|
276
|
+
1. **Created**: `runtime/fullscreen-button.js`
|
|
277
|
+
- New fullscreen button class
|
|
278
|
+
- 150+ lines of code
|
|
279
|
+
|
|
280
|
+
2. **Modified**: `src/main.js`
|
|
281
|
+
- Added import statement
|
|
282
|
+
- Created button instance
|
|
283
|
+
- 2 lines added
|
|
284
|
+
|
|
285
|
+
## Summary
|
|
286
|
+
|
|
287
|
+
✅ **Universal fullscreen button** added to all Nova64 demos
|
|
288
|
+
✅ **ESC key support** for easy exit
|
|
289
|
+
✅ **Modern UI** with neon effects matching Nova64 theme
|
|
290
|
+
✅ **Zero configuration** needed in individual demos
|
|
291
|
+
✅ **Cross-browser compatible** with fallbacks
|
|
292
|
+
✅ **Performance optimized** with minimal overhead
|
|
293
|
+
|
|
294
|
+
**Status**: ✅ Production Ready
|
|
295
|
+
**Last Updated**: October 26, 2025
|
|
296
|
+
**Version**: 1.0
|