Repository navigation
Pite v0.5.0
Project-local Python plugins (
Plugin System v1), workspace trust & safe mode, an interactive visual.ptatlaseditor, instanced 2D sprite batching withz_index&modulate, content-hashedassets.pite.toml, standalonepite-stubson PyPI, and a unified CLI/JSON output layer.
Breaking Changes & Migration Guide ⚠️
1. Atlas Sidecars Switched from .atlas.json to .ptatlas
Sprite-sheet atlas sidecars now use strict TOML (format_version = 1) with the .ptatlas extension.
- Migration: Run
pite check --reimport-assetsin your project root to automatically convert legacy.atlas.jsonfiles to.ptatlas, rewrite references in.ptscn,.ptmap, and.py, and remove legacy files.
2. pite-export Library API (Progress Sink)
I/O-facing functions in pite_export (export_project, ensure_archive, verify, stage, download_and_extract_player, ensure_player_binary) now take &mut dyn pite_export::Progress instead of printing raw eprintln! lines.
- Migration: Pass an implementation of
pite_export::Progress, or pass&mut ()for silent execution:// Before pite_export::export_project(&opts)?; // After pite_export::export_project(&opts, &mut ())?;
3. Unified CLI --json Envelope & stderr Human Output
All pite commands now share one --json envelope ({ schema_version, command, ok, data?, error? }, starting at schema_version: 1; previously pite check --json emitted schema_version: 3). Human progress, cards, and tables now write to stderr so stdout carries only JSON payloads and requested data.
Highlights 🔥
Plugin System (v1)
Extend both the runtime and editor with project-local Python plugins under res://plugins/<id>/:
- Manifests & CLI Management: Configure
[plugins]inpite.tomland manage plugins withpite plugin new|add|enable|disable|remove|list(local paths, git URLs with--rev, and.ziparchives; added disabled by default). - Dynamic
SchemaRegistry: Replaced static engine node tables inpite-corewith a dynamicSchemaRegistrysupporting plugin-contributed node types ([[nodes]]), typed properties ([[nodes.props]]), signals ([[nodes.signals]]), and custom[props]. - Runtime
PluginHost&Canvas2D_draw: Access plugins viapite.plugin("<id>")andpite.autoload("<Name>"), hookon_scene_loadedand post-node_process/_physics_process, auto-bind plugin node classes with livePluginPropDescriptors, and draw custom 2D geometry in_draw(self, canvas: pite.Canvas2D)(draw_rect,draw_line,draw_text,draw_sprite). - Editor Bridge & Tooling: Trust-gated
EditorPluginHostinpite-editor(EditorUI/EditorContext, bottom panel tabs alongsideConsole, Inspector sections,Pluginsmenu, viewport overlay/pointer hooks, and PyrightextraPaths), plus validation inpite checkand runtime-only staging inpite export.
Workspace Trust & Safe Mode
Opening an untrusted workspace in pite edit enters Safe Mode: the scene tree, inspector, code editor, and viewport render normally without importing or executing Python scripts or .py hot reloads.
- Trust Gate: Top Safe Mode banner (
Trust Workspace) and Play (F5/Ctrl+R) confirmation modal (Trust & Play/Stay in Safe Mode). - External Trust Store: Trusted paths are stored outside repositories in
<config_dir>/pite/trusted_workspaces.toml;pite newautomatically trusts newly created projects.
Visual Atlas Creator & Inspector Editor
Author and edit .ptatlas sprite sheets directly inside the Inspector (Edit Atlas…, Create Atlas (.ptatlas)… on PNGs, or double-clicking a .ptatlas file in Assets):
- Interactive Canvas: Zoom/pan, drag-to-create/move/resize frame boxes, frame filtering and renaming.
- Grid Slicer: Slice by tile size or column/row counts with offset, spacing, and transparent-tile skipping.
- Animation Sequences: Frame-range selection, FPS and loop controls, live playback preview, and automatic viewport texture/atlas invalidation on save.
2D Rendering Layering, Tinting, and Instanced Batching
z_index&modulate: Addedz_indexdraw ordering onNode2D(inherited by 2D, UI, and physics nodes) andmodulateRGBA tinting onSprite2DandAnimatedSprite2D.- Instanced GPU Pipeline: Upgraded
Renderer2D/WgpuRendererto instanced quad rendering with persistent GPU buffers, 64-bit depth sort keys, texture slot handles, and texture-grouped batching withinz_indexlayers. - TileMap2D Chunk Baking: Added baked 16×16 static chunks and pre-resolved atlas UV rects for
TileMap2D.
Asset Manifest Completion (assets.pite.toml) & pite-stubs
- Content-Hashed Asset Tracking: Removed legacy opaque UIDs in favor of
assets.pite.toml(committed to git), automatically reconciled bypite new/pite editand checked bypite check. - Standalone Type Stubs (
pite-stubs): Added the locksteppite-stubsPyPI distribution generated fromNODE_SCHEMASforimport piteautocompletion in external editors.
Unified CLI Output Layer & Structured JSON
- Every
pitecommand shares one output context, accepts--color <auto|always|never>,--json,-v/--verbose, and-q/--quietbefore or after subcommands, and renders consistentError:/Warning:/Success:cards, aligned tables, and full-width summary bars.
Changes Overview 📜
• Plugin System v1: plugin.toml manifests, pite plugin CLI, SchemaRegistry, PluginHost, Canvas2D._draw, EditorPluginHost, pite check validation, and pite export runtime-only staging.
• Workspace Trust & Safe Mode: Safe Mode in pite edit, external trusted_workspaces.toml, Play confirmation modal, and auto-trust on pite new.
• Visual Atlas Creator: Interactive .ptatlas frame editor, grid slicer, and animation previewer in pite-editor.
• .ptatlas Migration: Strict TOML atlas sidecars (format_version = 1) with automatic migration via pite check --reimport-assets.
• 2D Rendering Upgrade: Node2D.z_index, Sprite2D/AnimatedSprite2D modulate, instanced quad batching in WgpuRenderer, and 16×16 baked TileMap2D chunks.
• assets.pite.toml: Content-hashed project asset tracking replacing legacy UIDs.
• pite-stubs: Lockstep PyPI stub package generated from NODE_SCHEMAS.
• Unified CLI & JSON: Shared output layer, stderr human output / stdout JSON, typed Finding values in pite check, and pite_export::Progress sink.
• Security & Workflow: Sandboxed res:// path resolution, bounded recursive scene-cache/instance expansion, pre-commit hooks, and workspace Clippy enforcement in CI.
Download ⬇️
• pite-v0.5.0-linux.tar.gz / pite-v0.5.0-windows.zip / pite-v0.5.0-macos.tar.gz: engine + player binaries (any machine exports for all supported platforms), verified by SHA256SUMS.
• pite-player-v0.5.0-<platform>: standalone player binaries for lightweight deployments and export toolchains.
• Crates & Stubs: cargo install pite / pip install pite-stubs
• Install scripts: install.sh (Linux/macOS) / install.ps1 (Windows) from the repo root.
Full Changelog: v0.4.0...v0.5.0