README rewrite, example scaffolding tooling, quickstart example#12
Merged
Conversation
Adds a features pitch, a runnable quick-start snippet, and a table describing each example. Moves the original-fork credit into a new Acknowledgements section and adds RokuCommunity and Marcelo Lv Cabral. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
README: - Pitches the engine as both a full game framework and a standalone 2D/3D drawing library - Adds a runnable quick-start code sample (Game/MainRoom/Player) - Adds an examples table, callouts for the BrightScript Simulator (brs-desktop) and the new scaffolding script - Moves the original-fork credit into an Acknowledgements section and adds RokuCommunity and Marcelo Lv Cabral Scaffolding (npm run create-example -- <name> ["Title"]): - scripts/exampleTemplate is now a real template (manifest, bsconfig, package.json, .vscode configs, minimal main.bs/MainRoom.bs) - scripts/create_example.sh copies the template, fills in the title, generates icon/splash images, and registers the new example in the root .vscode/tasks.json example picker - Icon/splash generation (scripts/generate_example_images.js) uses pureimage, a pure-JS canvas implementation, instead of ImageMagick - no native/system dependency required. Bundles WorkSans-Bold.ttf (OFL-licensed) for the text. examples/quickstart: the exact Game/MainRoom/Player code from the README's quick-start sample, as a real runnable app. Verified it validates, lints, and builds/packages cleanly. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The scripts/examples_*.sh and create_example.sh shell scripts only worked via a POSIX shell (Git Bash/WSL on Windows) since they used cp -R, sed, uname, and find -delete. Rewritten as plain Node so `npm run prepare-examples`/`build-examples`/`validate-examples`/ `clean-all`/`create-example` work identically on Windows, macOS, and Linux. - scripts/examples.js replaces the seven examples_*.sh one-liners with a single task-dispatch script (install/build/validate/clean/ audit/ropm-install), still iterating examples/*/ and continuing past a failing example, matching the old behavior. - scripts/create-example.js replaces create_example.sh, using fs.cpSync/fs.rmSync instead of cp/find/sed. - generate-example-images.js and add-example-to-vscode-tasks.js (renamed from the underscore versions) now export their logic as functions so create-example.js calls them in-process instead of spawning child node processes, while still supporting standalone CLI use. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
npm run create-example -- <name> ["Title"]generates a newexamples/<name>fromscripts/exampleTemplate(manifest, bsconfig, a minimalMainRoom), auto-generates placeholder icon/splash images (pure-JS viapureimage, no ImageMagick needed), and registers the example in the root.vscode/tasks.jsonpicker.examples/quickstart: the exactGame/MainRoom/Playercode from the README's quick-start sample, as a real runnable app. Validated, linted, and built/packaged clean.scripts/examples_*.shandcreate_example.shshell scripts as plain Node (scripts/examples.js,scripts/create-example.js, etc.), soprepare-examples/build-examples/validate-examples/clean-all/create-exampleall work on Windows without Git Bash/WSL.Screenshots (Asteroids, 3D, Pong/Snake) to follow - README has placeholders ready under
assets/screenshots/.Test plan
npm run validate/npm run lintpassexamples/quickstartbuilds, validates, lints, and packages cleanlycreate-example.jsscaffolds a working example end-to-end (tested with throwaway names, cleaned up)examples.js validateruns across all example dirs, behavior matches old shell scripts (same pre-existing failures inhybrid/terrain, unrelated to this PR)validatecheck passes in CI