flame-engine/flame
61.7
Adequate · 22 September 2026
93.5k
lines of production code
Dart
primary language
5
measurements over time
What this system is
This system is the Flame game engine, a framework for building cross-platform 2D and 3D games using Flutter and Dart. It provides a component-based architecture for managing game logic, rendering, and input, supported by extensive documentation and interactive examples. The engine features a modular design with dedicated packages for physics, audio, and 3D graphics, enabling developers to create everything from simple prototypes to complex, performant games.
How it got here
2017–2021 — Flame 1.38.0 engine rewrite and documentation
53 changes.
This period centered on the release of Flame 1.38.0, which introduced a comprehensive rewrite of the core engine architecture, including a new component system, effects engine, and rendering pipeline. The work involved removing legacy APIs, adding extensive new features for input, geometry, and widgets, and establishing a robust test suite to ensure stability. Simultaneously, the project overhauled its documentation infrastructure with Sphinx and populated it with interactive Dashbook examples to guide users through the new API.
2022 — Core engine architecture and subsystem expansion
68 changes.
This period focused on a major overhaul of the Flame engine's core systems, introducing a new collision detection framework with raycasting, a comprehensive camera subsystem, and a structured text rendering pipeline. Significant infrastructure improvements included a new asset caching layer, experimental layout components, and the initial release of bridge packages for Spine, Lottie, Jenny, and background isolates. The work was supported by extensive documentation updates, interactive examples, and comprehensive test coverage for these new features.
2023–2024 — 3D engine and ecosystem expansion
55 changes.
This period focused on the introduction of the flame\_3d package, establishing a complete 3D rendering infrastructure with cameras, materials, and skeletal animation support. The work also expanded the broader ecosystem through new packages for debugging, state management, and asset handling, alongside significant updates to the text rendering architecture and physics examples.
2025–2026 — 3D engine and input system expansion
23 changes.
This period focused on significantly expanding the Flame 3D engine with GLB/GLTF model parsing, skeletal animation support, and an abstracted WebGPU backend. Concurrently, the core engine introduced a comprehensive post-processing shader API, a rewritten event dispatcher with new input mixins, and several new packages for behaviors, gamepad input, and sprite atlases.
Features
Abstracted 3D graphics backend to support WebGPU on the web
The 3D rendering engine now uses an abstracted GPU backend interface, allowing it to run on different platforms. On Flutter mobile/desktop, it uses the \flutter\_gpu\ library, while on the web, it introduces experimental support via a new WebGPU backend that leverages the browser's native \navigator.gpu\ API. This change requires developers to call \await GpuBackend.initialize()\ at the start of their application to set up the appropriate backend for the current platform.
_packages/flame\3d/lib/src/graphics/backend · high confidence
Add 3D example scenarios for lighting, culling, and model rendering
The flame\_3d example app now includes dedicated scenario files to demonstrate key 3D capabilities. Users can explore a boxes scenario featuring point lights and floating meshes, a colors scenario showcasing various primitive shapes with solid materials, a culling scenario demonstrating AABB frustum culling with grouped objects, and a models scenario that parses and renders a skeletal animation from a GLB file.
_packages/flame\3d/example/lib/scenarios · high confidence
Add 3D lighting support with point and ambient lights
The flame\_3d package now includes a new lighting system allowing developers to add illumination to 3D scenes. This change introduces a \Light\ resource class that positions a \LightSource\ in the scene, along with specific source implementations: \PointLight\ for omnidirectional emission and \AmbientLight\ for uniform scene illumination. These classes provide basic properties like color and intensity to modify how other 3D objects are rendered.
_packages/flame\3d/lib/src/resources/light · high confidence
Add 3D texture resource types
The flame\_3d package now includes base classes for managing GPU textures, introducing \Texture\ as the core resource type, along with \ColorTexture\ for solid-color textures and \ImageTexture\ for loading images. This provides the foundational infrastructure for 3D rendering capabilities within the library.
_packages/flame\3d/lib/src/resources/texture · high confidence
Add Ember Quest platformer tutorial
The platformer tutorial now includes a complete, runnable example application. The entry point uses the new \GameWidget.managed\ API to initialize the \EmberQuestGame\, which features a camera anchored to the top-left, collision detection, keyboard handling, and a HUD overlay. The game logic demonstrates segment-based level loading using switch expressions and manages game state such as health and collected stars.
doc/tutorials/platformer/app/lib · high confidence
Add Flame Lottie animation example story
The examples app now includes a new story demonstrating how to integrate and play Lottie animations using the Flame game engine. This addition provides a concrete usage example for the flame\_lottie bridge, showing users how to load a Lottie asset, configure it to loop continuously, and render it within a Flame game widget.
_examples/lib/stories/bridge\_libraries/flame\lottie · high confidence
Add Flame Spine bridge examples
New example stories demonstrating the Flame Spine bridge integration have been added to the examples gallery. These include a basic animation example that loads and switches between Spine animation states via tap, and a shared data example that pre-loads atlas and skeleton assets to efficiently render 100 Spine components simultaneously.
_examples/lib/stories/bridge\_libraries/flame\spine · high confidence
Add Flame-Jenny integration examples
New example stories have been added to the Flame-Jenny bridge library demonstrating how to integrate the Jenny dialogue system with Flame. The collection includes a simple example for basic Yarn script parsing, an advanced example showcasing custom commands and variable management, and a command lifecycle example illustrating the use of onCommand and onCommandFinish hooks.
_examples/lib/stories/bridge\_libraries/flame\jenny · high confidence
Add FlameIsolate example demonstrating background computation
The FlameIsolate example story now includes a demo that showcases running heavy computations (prime number checking) in a background isolate to prevent UI stutter. Users can tap the square to toggle between synchronous and isolate-based computation, utilizing the \DiscardNewBackPressureStrategy\ to handle queue backpressure.
_examples/lib/stories/bridge\_libraries/flame\isolate · high confidence
Add GLTF model parsing and skeletal animation support
The flame\_3d package now includes a complete GLTF parser that reads GLTF and GLB files, resolving buffers, meshes, materials, and textures, and converts them into Flame 3D models. This change introduces support for skeletal animations by parsing animation channels, samplers, and interpolation modes (linear, step, cubic spline) to drive node transformations, enabling animated 3D models to be rendered and played within the engine.
_packages/flame\3d/lib/src/parser/gltf · high confidence
Add Jenny dialogue examples to Yarn assets
Added three new Yarn dialogue scripts (simple.yarn, advanced.yarn, command\_lifecycle.yarn) featuring the character Jenny. These examples demonstrate basic greetings, a gambling game with variable state and conditional logic, and a custom command lifecycle hook, providing users with reference implementations for Yarn integration in Flame.
examples/assets/yarn · high confidence
Add Padracing game example for DartPad
Introduces the Padracing example, a racing game built with Flame and Forge2D designed to run in DartPad without external assets. The implementation includes a physics-based car controller with tire friction and turning mechanics, a split-screen camera system for two-player local multiplayer, and lap-tracking logic via sensor-based lap lines. The entry also provides a build script to merge the game source into a single file for DartPad compatibility.
examples/games/padracing · high confidence
Add Rogue Shooter game components
The examples/games/rogue\_shooter/lib/components directory now contains the core gameplay components for the Rogue Shooter example, including BulletComponent, EnemyComponent, EnemyCreator, ExplosionComponent, PlayerComponent, StarBackgroundCreator, and StarComponent. These files implement the game's entity logic, collision handling, and visual effects.
_examples/games/rogue\shooter/lib/components · high confidence
Add Rogue Shooter performance test game example
The examples/games/rogue\_shooter/lib directory now contains the source files for a new space shooter game example designed to test collision detection and rendering performance. The game utilizes the HasPerformanceTracker mixin to display update and render times, and implements the HasAutoBatchedChildren mixin on batch groups to optimize draw calls. Users can toggle sprite batching on and off by pressing the 'B' key to compare performance metrics directly within the game UI.
_examples/games/rogue\shooter/lib · high confidence
Add SVG component example and story
The examples library now includes a new SVG demonstration located in \examples/lib/stories/svg\. This addition introduces \svg\_component.dart\, a playable Flame game that renders SVG graphics (a player, background, and balloons) and handles user interactions like tapping to move the player and double-tapping to spawn balloons. The \svg.dart\ file registers this game as a story in the Dashbook documentation, allowing users to view and interact with the SVG rendering capabilities directly.
examples/lib/stories/svg · high confidence
Add basic audio example using Flame Audio
The examples library now includes a new basic audio demonstration located in the bridge\_libraries/audio stories. This example showcases core Flame Audio capabilities, including playing sound effects via the static FlameAudio class, managing efficient audio playback with an AudioPool, and handling background music using the Bgm utility.
_examples/lib/stories/bridge\libraries/audio · high confidence
Add built-in 3D primitive meshes and automatic normal calculation
The flame\_3d package now includes ready-to-use geometric primitives—ConeMesh, CuboidMesh, CylinderMesh, PlaneMesh, and SphereMesh—allowing developers to quickly instantiate common 3D shapes without manual vertex definition. Additionally, the underlying Surface resource now automatically calculates vertex normals when they are not explicitly provided, ensuring correct lighting and shading for meshes that rely on default normal data.
_packages/flame\3d/lib/src/resources/mesh · high confidence
Add example demonstrating world swapping via RouterComponent
The router example story now includes a demo showing how to use \WorldRoute\ to navigate between different game worlds, allowing users to see how the router handles world transitions and state management in a multi-world setup.
examples/lib/stories/router · high confidence
Add experimental 2D geometric shape primitives
The geometry package now includes a new set of experimental 2D shape classes—Circle, Polygon, Rectangle, and RoundedRectangle—that implement a common Shape interface. These primitives provide standard geometric capabilities such as point containment checks, axis-aligned bounding box (AABB) calculations, affine transformation projection, and random point generation, enabling more robust collision detection and spatial queries in Flame games.
packages/flame/lib/src/experimental/geometry · high confidence
Add parallax examples with animation and filter quality support
The parallax examples now demonstrate how to use animated layers (via \ParallaxAnimationData\) and control image filtering (via \filterQuality\ arguments) in parallax components. The examples also show how to create non-fullscreen parallax components and use parallax outside the Flame Component System.
examples/lib/stories/parallax · high confidence
Add shared utility functions for the Flame Jenny example
A new \commons.dart\ file has been added to the Flame Jenny example location, providing a \baseLink\ helper to construct GitHub URLs for the example code and a \fontSize\ constant. This change supports the example's documentation and UI consistency by centralizing these shared resources.
_examples/lib/stories/bridge\_libraries/flame\jenny/commons · high confidence
Add skeletal animation and unlit material support to 3D shaders
The 3D rendering pipeline now supports skeletal animation and unlit materials. New shader files introduce \spatial\_material\ (with PBR lighting and skinning support via \skinning.glsl\) and \unlit\_material\ (basic texture/color rendering), both utilizing a new \\#include\ mechanism for shared code like skinning matrices. This enables animated meshes and simpler, performance-optimized rendering for non-lighted objects.
_packages/flame\3d/shaders · high confidence
Add skeletal animation support for 3D models
The \flame\_3d\ package now supports skeletal animations for 3D models. This change introduces new classes (\AnimationState\, \ModelAnimation\, \ModelNode\, \ModelJoint\) to handle animation data, keyframe interpolation, and joint transformations. \ModelComponent\ now tracks animation state, allowing users to play, stop, and manage animations by name or index, and correctly applies skeletal transforms during rendering.
_packages/flame\3d/lib/src/model · high confidence
Add timer usage examples to the utils stories
New example stories have been added to the utils section, demonstrating how to use the \Timer\ class and the \TimerComponent\ within a Flame game. The \Timer\ example shows a manual countdown and interval timer driven by tap events, while the \TimerComponent\ example illustrates using the component mixin with tap and double-tap callbacks to spawn and remove timed visual elements.
examples/lib/stories/utils · high confidence
Add web deployment configuration for Flame examples
The examples/web directory now includes the necessary files to support web deployment, including a CNAME file pointing to examples.flame-engine.org, an index.html entry point with a configurable base href, and a manifest.json for PWA support. This enables the examples to be properly hosted and accessed via a web browser.
examples/web · high confidence
Add widget catalog examples for Sprite, NineTileBox, and CustomPainter
The examples directory now includes a new 'Widgets' catalog in the Dashbook storybook, providing interactive demos for Flame's Flutter widget integration. This addition introduces examples for rendering sprites via \SpriteWidget\ (including partial image sections and fixed sizing), creating interactive \SpriteButton\ components, tiling backgrounds with \NineTileBoxWidget\ (including an animation variant), and drawing custom graphics using \CustomPainterComponent\ with overlay support. These stories allow users to explore widget properties like anchors, paint effects, and sizing directly in the documentation interface.
examples/lib/stories/widgets · high confidence
Added AlignComponent layout example
The examples now include a new layout story demonstrating the AlignComponent. This example shows how to arrange child elements (circles) in a diamond pattern that remains intact when the window size changes, and it is accessible via the Layout stories section in the examples app.
examples/lib/stories/layout · high confidence
Added animated Tiled map example
A new example story demonstrating how to load and display animated Tiled maps has been added to the examples library. The \flame\_tiled\_animation\_example.dart\ file implements a \FlameGame\ that loads a dungeon map asset, and \tiled.dart\ registers this as a new 'Flame Tiled Animation' story in the Dashbook documentation, allowing users to see the animated tile support in action.
examples/lib/stories/tiled · high confidence
Added animated dungeon tileset example
The examples/assets/tiles area now includes a new dungeon tileset (0x72\_DungeonTilesetII\_v1.4) and a corresponding map (dungeon.tmx) that demonstrates animated tiles. The tileset defines several tiles with frame-based animations (e.g., looping water or fire effects) using Tiled version 1.9.2 format, and the map references this tileset to showcase these animations in a 10x10 orthogonal grid with ground, walls, and stuff layers.
examples/assets/tiles · high confidence
Added initial Space Shooter tutorial step
The Space Shooter tutorial now includes the first step, providing a basic Flutter application that renders a white rectangular player component centered on the screen. This entry point establishes the foundational game structure using Flame, serving as the starting point for users to begin learning the tutorial series.
_doc/tutorials/space\_shooter/app/lib/step1, doc/tutorials/space\shooter/app/web · high confidence
Added platformer tutorial assets and level data
The platformer tutorial now includes the necessary web entry point (\index.html\) to run the Flutter application in a browser, along with a new \segment\_manager.dart\ file that defines the grid-based level layout for five distinct segments, specifying the positions of ground blocks, platforms, stars, and water enemies.
doc/tutorials/platformer/app/lib/managers, doc/tutorials/platformer/app/web · high confidence
Bring back collision detection examples
The collision detection examples have been restored to the examples library. This adds a suite of interactive demos including bouncing balls, circle interactions, animated collidables, multiple shapes, multiple worlds, quadtree-based detection, and various raycasting/raytracing scenarios (light, max distance, inside/outside shapes). These examples demonstrate how to use the collision detection API, including broadphase optimizations like QuadTree, raycasting for obstacle avoidance and lighting, and handling collisions across discrete worlds.
_examples/lib/stories/collision\detection · high confidence
Centralized game storybook registration
The examples now provide a single entry point (games.dart) that registers sample games—Crystal Ball, Padracing, Rogue Shooter, and T-Rex—into the Dashbook storybook. This centralizes how these games are presented in the documentation, ensuring consistent linking to their source code and displaying their descriptions.
examples/lib/stories/games · high confidence
Flame 3D example now supports interactive console commands and scenario setup
The flame\_3d example application has been restructured to include an interactive console (via flame\_console) that allows users to manage the 3D scene directly. New commands include 'setup' to load specific game scenarios, 'destroy' to remove objects like crates, lights, or meshes, and 'reset' to restore the camera and player positions. The example game now utilizes GameWidget.managed and integrates these custom commands into the console overlay, providing a more flexible environment for testing and debugging 3D features.
_packages/flame\3d/example/lib · high confidence
Initial Flame DevTools integration for game inspection
Developers can now inspect and debug Flame games directly within Flutter DevTools. This change introduces a service and a set of connectors that expose the game's component tree, individual component snapshots, and specific attributes (such as position, scale, and angle for PositionComponents) to the DevTools UI. It also enables runtime control over the game loop, allowing users to pause, resume, and step through the game execution, as well as toggle debug modes and navigate game overlays directly from the extension.
packages/flame/lib/src/devtools · high confidence
Initial Sphinx-based documentation build system
The documentation site has been migrated to a Sphinx-based build system, introducing a new configuration in doc/\_sphinx. This change adds support for Markdown via MyST, Mermaid diagrams, and custom Dart/Flutter extensions (dart\_domain, flutter\_app, package). It also includes a custom 'flames' HTML theme, copy buttons for code snippets, and build scripts (Makefile, make.bat) to facilitate local development and building on both Unix and Windows environments.
_doc/\sphinx · high confidence
Initial release of Flame Console for game debugging
The flame\_console package is introduced, providing a terminal-style overlay for Flame games that allows developers to debug and interact with running games. The package includes a FlameConsoleView widget that can be added as an overlay, supporting built-in commands such as listing components (ls), removing components (rm), toggling debug mode (debug), and pausing or resuming the game loop (pause/resume). It also supports custom commands and is built on the terminui library.
_packages/flame\console · high confidence
Initial release of flame\_bloc integration for Flame games
This release introduces the \flame\_bloc\ package, providing a bridge to use \flutter\_bloc\ within Flame games. It adds \FlameBlocProvider\ and \FlameMultiBlocProvider\ components to inject BLoCs into the game tree, alongside \FlameBlocListener\ and the \FlameBlocListenable\ mixin to allow game components to react to state changes. An example space-shooter game is included to demonstrate these patterns.
_packages/flame\bloc · high confidence
Initial release of flame\_isolate for background computation
This change introduces the flame\_isolate package, providing FlameGame components with the ability to offload heavy calculations to background isolates. It includes the FlameIsolate and FlameTailoredIsolate mixins, which expose isolateCompute and isolateComputeStream methods for running work on long-lived threads, along with an example application demonstrating pathfinding in a worker isolate.
_packages/flame\isolate · high confidence
Initial release of flame\_jenny dialogue integration
This entry introduces the flame\_jenny package, which integrates the Jenny dialogue framework (a Dart port of YarnSpinner) into the Flame engine. The diff establishes the package structure with a new CHANGELOG, README, and core library files. Key capabilities include a DialogueRunner for executing dialogue nodes, a DialogueView mixin for presenting lines and choices, and support for user-defined commands and functions via CommandStorage and FunctionStorage. The release also includes built-in commands like \<\<set\>\>, \<\<declare\>\>, \<\<local\>\>, \<\<visit\>\>, and \<\<character\>\>, as well as built-in functions like if(). Fixes ensure whole numbers are stringified without decimals and whitespace before commands in dialogue options is removed.
_packages/flame\jenny · high confidence
Initial release of flame\_markdown for rich text rendering
The new flame\_markdown package allows Flame games to render rich text by converting markdown strings into Flame's TextNode hierarchy. It supports standard inline formatting (bold, italics, code), strike-through text, and a custom attribute syntax (e.g., \\[text\]{.class}\) that enables applying named styles to specific spans of text. The parser defaults to not encoding HTML, and the package includes an example demonstrating these features.
_packages/flame\markdown · high confidence
Initial release of flame\_rive for Rive animations in Flame games
The new flame\_rive package integrates Rive animations into Flame games, providing a RiveComponent that renders Rive artboards with configurable fit, alignment, and clipping, alongside a loadArtboard helper to load specific or default artboards from Rive files. An example project demonstrates loading a Rive file, binding a state machine's view model, and handling user interactions to update animation inputs, while tests verify artboard loading and component integration.
_packages/flame\rive · high confidence
Initial release of flame\_riverpod for integrating Riverpod state management with Flame games
This entry introduces the flame\_riverpod package, providing \RiverpodAwareGameWidget\, \RiverpodGameMixin\, and \RiverpodComponentMixin\ to allow Flame components to access and react to Riverpod providers. The implementation bridges the gap between Flutter's widget lifecycle and Flame's component lifecycle by registering build callbacks and provider subscriptions when components mount and cleaning them up when they remove, ensuring state updates trigger game widget rebuilds without causing framework errors.
_packages/flame\riverpod · high confidence
Initial release of flame\_spine package for Spine 4.3 support
The flame\_spine package is introduced as a bridge to integrate Esoteric Spine skeletal animations into Flame games, starting with support for Spine 4.3 (available from version 0.3.0). This release includes the core SpineComponent implementation, an example application demonstrating usage, and necessary licensing documentation. Users should note that this initial version targets Spine 4.3; for projects using Spine 4.2, version 0.2.2 remains the compatible release.
_packages/flame\spine · high confidence
Initial release of flame\_test testing utilities
The flame\_test package is introduced, providing a suite of helpers and utilities for testing Flame games. This includes the FlameTester and GameTester classes for managing game lifecycle and widget testing, along with specific matchers like closeToVector, closeToAabb, and closeToMatrix4 for precise assertions. The package also offers mock event generators for gestures and input, a DebugTextRenderer for stable golden tests, and utilities for handling random seeds in randomized tests.
_packages/flame\test · high confidence
Initial release of the flame\_sprite\_fusion package
The new \flame\_sprite\_fusion\ package allows developers to parse and render tilemaps exported from Sprite Fusion directly within the Flame engine. It introduces the \SpriteFusionTilemapComponent\, which loads JSON map definitions and sprite sheets to render tile layers efficiently using sprite batching. The package provides data classes like \SpriteFusionTilemapData\ and \SpriteFusionTileData\ to access map structure, including methods to retrieve layers by name and check tile attributes, enabling seamless integration with the Flame Component System.
(repo-wide) · high confidence
Introduce 3D camera system with first-person and third-person modes
The \flame\_3d\ package now includes a dedicated 3D camera infrastructure, adding \CameraComponent3D\ as the base class for 3D viewing, along with \FirstPersonCamera\ and \ThirdPersonCamera\ implementations that support following targets and smooth damping. \World3D\ has been introduced as the root component for 3D scenes, handling light registration and rendering via a \GraphicsDevice\ pass, enabling users to observe 3D worlds with configurable projection types (perspective or orthographic) and camera controls.
_packages/flame\3d/lib/src/camera · high confidence
Introduce 3D component hierarchy with nested transforms and frustum culling
The \flame\_3d\ package now provides a foundational 3D component system (\Component3D\, \Object3D\, \MeshComponent\, \LightComponent\, \Line3D\) that supports nested hierarchies. Users can group 3D objects, and their positions, rotations, and scales will correctly accumulate via world-space transformation matrices. The system also includes automatic axis-aligned bounding box (AABB) calculation for efficient frustum culling, ensuring that only visible 3D geometry is rendered.
_packages/flame\3d/lib/src/components · high confidence
Introduce 3D game infrastructure with notifying transforms and unmodifiable vectors
The \flame\_3d\ package now includes core 3D game engine components in the \lib/src/game\ directory. This adds \FlameGame3D\, a specialized game class that initializes a 3D world and camera, and \Game3D\, a mixin that integrates the \GraphicsDevice\ into the standard render loop. To support reactive 3D logic, the update introduces \Transform3D\ for managing position, rotation, and scale with cached matrix updates, along with \NotifyingVector3\ and \NotifyingQuaternion\ classes that emit change notifications when their values are modified. Additionally, \UnmodifiableVector3\ is provided to prevent accidental mutation of vector data.
_packages/flame\3d/lib/src/game · high confidence
Introduce 3D support in Flame
The flame\_3d package now provides a complete set of exports for 3D game development, including camera components (first-person, third-person, and world 3D), 3D-specific game and transform classes, and a full graphics backend with GPU handling and render contexts. Users can now load and render 3D models with skeletal animations, manage lights and materials, and utilize extended vector and quaternion math utilities exposed via core and extension libraries.
_packages/flame\3d/lib · high confidence
Introduce Flame DevTools extension for game inspection and control
A new DevTools extension is available for Flame games, adding a dedicated tab in Flutter DevTools that provides a visual component tree, game loop controls (pause, play, step), and the ability to inspect and modify position component attributes (x, y, width, height, angle, scale) in real time. The extension also supports overlay navigation and displays component snapshots, allowing developers to debug and tune their games directly from the browser.
_packages/flame\devtools · high confidence
Introduce Flame Studio for in-editor game debugging
The new flame\_studio package provides a development-time overlay for Flame games, enabling developers to inspect the component hierarchy and control game execution directly within the Flutter environment. By wrapping a game with runFlameStudio, users gain access to a UI scaffold featuring a resizable left panel that displays a live, expandable tree of game components, and a toolbar offering Start, Pause, and Next Frame controls to step through game logic frame-by-frame.
_packages/flame\studio · high confidence
Introduce Post-Processing API for Shader Effects
Adds a new post-processing system allowing developers to apply visual effects, such as bloom or blur via FragmentShaders, to the entire screen or specific component groups. This includes the abstract PostProcess base class for defining effects, PostProcessComponent for applying effects to a subtree, and PostProcessGroup/PostProcessSequentialGroup for chaining or parallelizing multiple effects. The API also provides PostProcessingContextFinder so child components can detect if they are being rendered within a post-process context.
_packages/flame/lib/src/post\process · high confidence
Introduce base Material class with UnlitMaterial and SpatialMaterial implementations
The flame\_3d package now provides a structured material system for 3D rendering. A new abstract \Material\ base class manages shader resources and face culling modes. This is accompanied by two concrete implementations: \SpatialMaterial\, which supports physically-based rendering (PBR) with albedo color/texture, metallic, roughness, and dynamic lighting (ambient and point lights), and \UnlitMaterial\, which renders textures without lighting calculations, making it suitable for UI panels, HUDs, or emissive surfaces. Both materials support skeletal animation via joint matrices.
_packages/flame\3d/lib/src/resources/material · high confidence
Introduce behavior tree AI system for Flame components
This change adds the \flame\_behavior\_tree\ package, providing a bridge between the \behavior\_tree\ library and the Flame engine. It introduces the \HasBehaviorTree\ mixin, which allows Flame components to execute behavior trees for AI logic. The system supports composite nodes (Sequence, Selector), decorators (Inverter, Limiter), and leaf tasks (Task, AsyncTask, Condition). A key feature is Blackboard support, enabling nodes to share state via a centralized data store accessible through the component, as demonstrated in the included example agent.
_packages/flame\_behavior\tree · high confidence
Introduce core text rendering primitives and sprite font support
This change adds the foundational classes for the new text rendering pipeline in the \flame/lib/src/text/common\ directory. It introduces \SpriteFont\ to handle custom fonts stored in image assets, \Glyph\ to define individual character metrics and source image locations, and \LineMetrics\ to track text line measurements. Additionally, utility functions for margin collapsing and background element generation are provided to support the structured text system.
packages/flame/lib/src/text/common · high confidence
Introduce flame\_kenney\_xml package for Kenney.nl XML sprite sheets
The new \flame\_kenney\_xml\ package allows developers to load and use XML-formatted sprite sheets (specifically the ShoeBox format used by Kenney.nl) in Flame games. It provides an \XmlSpriteSheet\ class that parses the XML structure to map sprite names to their coordinates within an image, enabling easy retrieval of individual sprites via \getSprite\ or \getRandomSprite\. The package includes a \load\ method that supports optional image and assets caches, as well as a \package\ argument for resolving assets from other packages, and comes with an example demonstrating how to add random sprites to the screen on tap.
_packages/flame\_kenney\xml · high confidence
Introduce flame\_network\_assets package for loading network images
The new \flame\_network\_assets\ package allows Flame games to load and cache images from network URLs. It provides a \FlameNetworkImages\ class that handles fetching assets via HTTP, decoding them into Flame-compatible \Image\ objects, and caching them in both memory and local storage (with local storage disabled on web). The package includes a two-layer caching system, configurable memory and storage caching flags, and supports custom HTTP clients and directory providers. An example app demonstrates loading a network sprite and using it in a game component.
_packages/flame\_network\assets · high confidence
Introduce flame\_noise package with NoiseEffectController
The new flame\_noise package provides a NoiseEffectController that oscillates around a noise curve to create shake effects in Flame games. This controller allows developers to apply noise-based motion to effects like MoveEffect.by, with the magnitude and direction controlled by the effect's offset and a configurable tapering curve that fades the effect out over time. The package bridges the fast\_noise library into Flame, offering a simple API for generating natural-looking random motion.
_packages/flame\noise · high confidence
Introduce flame\_typled package for Typled sprite atlas support
The new flame\_typled package allows Flame games to load Typled sprite atlases as Sprites. It provides a TypledSpriteAtlas class that parses Typled atlas definitions and associated images, applying edge-repeated padding by default to eliminate ghost lines caused by floating-point texture sampling errors. Users can load atlases via TypledSpriteAtlas.load() and retrieve individual sprites by ID, with an option to disable padding if needed.
_packages/flame\typled · high confidence
Introduce the flame\_behaviors package for entity-component separation
The new flame\_behaviors package allows developers to apply separation of concerns to game logic by attaching modular behaviors to entities. It provides a Behavior base class and specialized implementations for collision (PropagatingCollisionBehavior, ScreenCollisionBehavior), input events (TappableBehavior, DraggableBehavior, HoverableBehavior), and entity management (EntityMixin, PositionedEntity). The package includes a complete example demonstrating how to compose entities like circles and rectangles with distinct behaviors for movement, rotation, and screen-edge collision.
_packages/flame\behaviors · high confidence
Introduce the new CameraComponent system with Viewport, Viewfinder, and World abstractions
The camera subsystem has been replaced by a new \CameraComponent\ architecture that separates the viewing window (\Viewport\), the world observation controls (\Viewfinder\), and the game world root (\World\). Users can now observe the game world through a dedicated camera component that supports fixed resolutions (\CameraComponent.withFixedResolution\), static backdrops, and post-processing effects. The system provides coordinate transformation utilities (\globalToLocal\, \localToGlobal\) on both the viewport and viewfinder, exposes the currently visible world area via \visibleWorldRect\, and allows for multiple simultaneous cameras observing the same world or nested worlds.
packages/flame/lib/src/camera · high confidence
Introduction of core 2D rendering and device control primitives
This change introduces the foundational classes for the Flame 2D engine, establishing the core rendering and utility infrastructure. It adds the Anchor class for defining relative positioning on components, the Device class for managing screen orientation and full-screen modes, and the central Flame singleton for accessing shared caches and device controls. Rendering capabilities are provided through the Sprite class for drawing image regions, the SpriteBatch class for optimized multi-sprite rendering with atlas support, and the NineTileBox class for scalable UI elements. Animation support is introduced via SpriteAnimation, SpriteAnimationFrameData, and the SpriteAnimationTicker, which handles frame ticking, pausing, and completion events. Additional utilities include the Parallax class for scrolling backgrounds, the Palette class for color management, and the ImageComposition class for compositing images.
packages/flame/lib/src · high confidence
Klondike Step 5 tutorial introduces interactive card and pile components
The Klondike tutorial's Step 5 now includes a complete set of interactive game components, including \Card\, \FlatButton\, \FoundationPile\, \StockPile\, \TableauPile\, and \WastePile\. These components implement the core gameplay logic for Klondike Solitaire, such as card dragging, tapping, flipping, and pile management (e.g., fanning out cards in the waste and tableau piles). The \Card\ component handles rendering of card faces and backs, while the pile components manage card movement and validation rules. This update provides a fully functional, interactive card game experience within the tutorial context.
doc/tutorials/klondike/app/lib/step5/components · high confidence
Klondike tutorial app adds multi-step navigation and web entry point
The Klondike tutorial application now supports navigating between different tutorial steps (step2 through step5) via URL query parameters, allowing users to jump directly to specific parts of the guide. A new main.dart entry point parses the URL to dispatch to the corresponding step's main function, while a new index.html file provides the web entry point with service worker registration for offline support.
doc/tutorials/klondike/app/lib · high confidence
Klondike tutorial step 2 adds game layout and component scaffolding
The Klondike tutorial now includes a second step that demonstrates the initial game structure. This update adds the main entry point and the core game class, which loads the card sprite assets and positions the foundational game elements: the stock, waste, four foundation piles, and seven tableau piles. It also introduces the corresponding component classes (Foundation, Pile, Stock, Waste) to serve as the structural basis for the card game logic.
doc/tutorials/klondike/app/lib/step2 · high confidence
Klondike tutorial step 3 adds card rendering and game component stubs
The Klondike tutorial's step 3 now includes a fully implemented Card component that renders playing card faces and backs using Flame sprites, and introduces stub PositionComponent classes for the game's core areas: Foundation, Pile, Stock, and Waste.
doc/tutorials/klondike/app/lib/step3/components · high confidence
Klondike tutorial step 3 adds game setup and card data models
The Klondike tutorial's third step now includes the core game initialization and card definition files. The new \klondike\_game.dart\ sets up the game world by positioning the stock, waste, foundation, and tableau piles, configures the camera view, and deals a randomized initial hand of cards. Supporting data models in \rank.dart\ and \suit.dart\ define the card ranks and suits with their corresponding sprite coordinates, while \main.dart\ provides the entry point to run the game widget.
doc/tutorials/klondike/app/lib/step3 · high confidence
Klondike tutorial step 4 adds card and pile components
The tutorial now includes the core game components for step 4, introducing the \Card\ class with drag support and rendering logic, along with the four pile types: \FoundationPile\, \StockPile\, \TableauPile\, and \WastePile\. These components implement the game's layout rules, such as card fanning in the tableau and waste piles, stock pile drawing mechanics, and foundation pile acceptance criteria.
doc/tutorials/klondike/app/lib/step4/components · high confidence
Klondike tutorial step 4 adds game logic and UI components
The Klondike tutorial's fourth step now includes the core game implementation, introducing the \KlondikeGame\ class that initializes the board layout (stock, waste, foundation, and tableau piles) and deals the cards. This update adds supporting data models for card ranks and suits, a \Pile\ interface for managing card movements, and the entry point to run the game widget, providing a complete playable example for this stage of the tutorial.
doc/tutorials/klondike/app/lib/step4 · high confidence
New 3D example components for player, environment, and HUD
The flame\_3d example now includes dedicated Dart components for a playable 3D scene: a Player component with keyboard/mouse movement and jumping, a Crate that scales dynamically, a RoomBounds component defining the floor and walls, a RotatingLight that orbits the scene, a RenderedPointLight for visualizing light sources, and a SimpleHud that displays camera controls, FPS, and camera state. These files provide the concrete UI and gameplay logic for the 3D demo.
_packages/flame\3d/example/lib/components · high confidence
New AlignComponent for relative child positioning
A new \AlignComponent\ layout component has been added to the Flame library, allowing users to position a single child component within the parent's bounding box using relative alignment (similar to Flutter's Align widget). Users can specify the alignment anchor, and optionally control the parent's size via \widthFactor\ and \heightFactor\ relative to the child's dimensions. The component supports keeping the child's original anchor independent of the alignment via the \keepChildAnchor\ flag, enabling more complex placement scenarios.
packages/flame/lib/src/layout · high confidence
New CI scripts for dictionary validation, documentation setup, and customer testing
Added new shell and Dart scripts to the repository's CI tooling: \cspell-verify.sh\ and \cspell-run.sh\ for validating and fixing alphabetical order and unused words in dictionary files; \doc-setup.sh\ to check for Python 3.8+ and install Sphinx and dartdoc\_json dependencies; and \customer\_testing.dart\ to run Flame package analysis and tests against Flutter framework changes, excluding \flame\_3d\ and \flame\_forge2d\ due to environment constraints and pinning random seeds for deterministic results.
scripts · high confidence
New Camera & Viewport example stories
Added a new set of interactive examples in the documentation to demonstrate the Flame camera and viewport system. These stories cover core capabilities including camera following (with world bounds and horizontal-only modes), zooming via scroll and scale gestures, fixed-resolution viewports, static components (HUDs and backdrops) that remain fixed while the world moves, and a detailed breakdown of the three coordinate systems (global, widget, and game) for event handling.
_examples/lib/stories/camera\_and\viewport · high confidence
New Crystal Ball example showcasing the Flame shader pipeline
Added a new Crystal Ball game example that demonstrates the Flame post-process and fragment shader API. The example features a jumping ball in a swampy world with visual effects including water reflections, fog, fireflies, and a dynamic ball glow, all implemented using custom GLSL shaders and the PostProcessComponent system.
_examples/games/crystal\ball · high confidence
New Flame widget library for rendering Sprites, Animations, and UI components
This change introduces a new set of Flutter widgets in the \packages/flame/lib/src/widgets\ directory, enabling the rendering of Flame game assets directly within Flutter UIs. The library includes \SpriteWidget\ for displaying static images with support for rotation, anchoring, and custom paint, as well as \SpriteAnimationWidget\ for playing sprite animations with an \onComplete\ callback and optional ticker. \SpriteButton\ provides a pressable UI button backed by sprite assets, including support for disabled states and cached asset loading. Additionally, \NineTileBoxWidget\ allows for scalable UI elements using nine-slice scaling, and \ComponentsNotifierBuilder\ facilitates rebuilding Flutter widgets in response to changes in Flame game components. A shared \BaseFutureBuilder\ handles the asynchronous loading of assets with loading and error states.
packages/flame/lib/src/widgets · high confidence
New Flame-Jenny dialogue UI components for the example app
The example application now includes a set of reusable UI components to render dialogues using the Jenny library: \DialogueButton\ and \MenuButton\ for interactive elements, \DialogueTextBox\ for text display, \ButtonRow\ to manage button layouts, \DialogueBoxComponent\ to compose the dialogue box, and \DialogueControllerComponent\ (along with \CommandLifecycleDialogueDialogueController\) to bridge Jenny's dialogue lifecycle with Flame's component system. These changes provide a concrete, working implementation of how to integrate Jenny's dialogue features into a Flame game within the examples directory.
_examples/lib/stories/bridge\_libraries/flame\jenny/components · high confidence
New Forge2D example utilities for physics visualization and interaction
The Forge2D example suite now includes a shared set of utility components to enhance the visual fidelity and interactivity of physics demos. A new \GlowingBody\ mixin provides a consistent translucent fill with a bright outline for all physics bodies, while \ExampleColors\ defines a shared palette. New helper classes include \Ball\ and \WhiteBall\ for circular bodies with contact-based color swapping, \Box\ and \DraggableBox\ for rectangular bodies that can be dragged via a visible \MouseJoint\, and \Wall\ for boundary segments. Additionally, \JointRenderer\, \MouseJointRenderer\, and \PrismaticJointRenderer\ components make internal physics constraints visible to the user, and \Forge2DExampleGame\ sets up the standard dark background and rendering scale for these stories.
_examples/lib/stories/bridge\_libraries/flame\forge2d/utils · high confidence
New Forge2D joint interaction examples
Added interactive story examples for seven Forge2D joint types: Distance, Filter, Motor, Mouse, Prismatic, Revolute, and Weld joints. These demos illustrate how to create and manipulate these physics constraints, such as connecting bodies with springs, preventing collisions between specific bodies, driving rotational motion, dragging objects with a mouse, constraining linear movement with limits, and building structures like bridges.
_examples/lib/stories/bridge\_libraries/flame\forge2d/joints · high confidence
New Sphinx extensions for Dart documentation, Flutter app embedding, and Yarn syntax highlighting
The documentation build system now includes three new Sphinx extensions located in doc/\_sphinx/extensions. The dart\_domain extension adds a {dartdoc} directive and CSS styling to automatically generate and display API documentation for Dart symbols. The flutter\_app extension introduces a {flutter-app} directive that allows embedding interactive Flutter web apps directly into documentation pages via iframes, popups, or infoboxes, including support for viewing source code listings. Additionally, the yarn\_lexer extension provides Pygments syntax highlighting for Yarn/Jenny dialogue scripts, complete with specific CSS for code blocks.
_doc/\sphinx/extensions · high confidence
New animation examples and storybook integration
The examples/lib/stories/animations directory now includes four new demonstration files: basic\_animation\_example.dart (showing dynamic sprite animation creation), animation\_group\_example.dart (demonstrating state-based animation switching with SpriteAnimationGroupComponent), aseprite\_example.dart (loading animations from Aseprite JSON data), and benchmark\_example.dart (testing performance with many concurrent animations). These examples are registered in animations.dart for display in the Dashbook storybook interface, providing users with concrete usage patterns for Flame's animation components.
examples/lib/stories/animations · high confidence
New caching infrastructure for assets, images, and values
The cache package now provides dedicated classes for managing different types of cached data. AssetsCache allows loading and caching text, binary, and JSON assets with optional package support and synchronous access via fromCache. Images supports loading images from files, base64 data, or generators, with methods to clear, check keys, and wait for pending loads. MemoryCache offers a simple size-based eviction cache. ValueCache enables caching computed values based on a list of dependency values. MatrixPool provides a pool for Float64List buffers to optimize canvas and path transformations.
packages/flame/lib/src/cache · high confidence
New camera behavior components for position bounding and viewport-aware constraints
This change introduces three new camera behavior components to the Flame engine. \BoundedPositionBehavior\ ensures a target component's position remains within a specified geometric shape, snapping back to the nearest boundary point if it strays outside. \FollowBehavior\ allows an owner component to smoothly pursue a target component with configurable maximum speed and optional horizontal or vertical axis constraints. \ViewportAwareBoundsBehavior\ dynamically adjusts the camera's bounding area based on the viewport's size and position, ensuring the entire viewport stays within the defined world bounds for Rectangle, RoundedRectangle, and Circle shapes.
packages/flame/lib/src/camera/behaviors · high confidence
New camera viewport implementations for flexible game rendering
The camera system now includes several new viewport types to control how the game world is displayed on screen. Users can use FixedResolutionViewport to maintain a specific logical resolution with letterboxing, FixedAspectRatioViewport to fill the screen while preserving a set aspect ratio, FixedSizeViewport for a static rectangular area, CircularViewport for a circular or elliptical clipping region, and MaxViewport to use the entire canvas without clipping. These components allow for more precise control over the visible game area and coordinate mapping.
packages/flame/lib/src/camera/viewports · high confidence
New component examples and storybook entries
The component stories section now includes interactive examples for several new capabilities: ClipComponent for clipping children to circular, rectangular, or polygonal shapes; ComponentPool for efficient object reuse; ComponentNotifier for synchronizing game state with Flutter widgets (both via a built-in builder and the provider package); IconComponent for rendering Flutter IconData; HasVisibility for toggling component visibility without removal; ComponentKey for locating components by name; SpawnComponent for spawning entities within geometric areas; and HasTimeScale for controlling game speed. The entry also adds examples for the lookAt and angleTo rotation methods, the skip functionality in TextBoxComponent, and demonstrates composability, debug mode with FpsTextComponent, and priority-based z-ordering.
examples/lib/stories/components · high confidence
New component input event callback mixins
The \packages/flame/lib/src/events/callbacks\ directory now provides a comprehensive set of new mixins for handling user input, replacing older patterns. Components can now mix in \TapCallbacks\ for primary taps, \DoubleTapCallbacks\ for double-taps, \SecondaryTapCallbacks\ and \TertiaryTapCallbacks\ for right/middle mouse clicks, \DragCallbacks\ (with support for multi-pointer drags via \allowsMultiPointerDrag\), \ScaleCallbacks\ for pinch/zoom gestures, \ScrollCallbacks\ for mouse wheels, \HoverCallbacks\ for mouse hover states, and \LongPressCallbacks\. Each mixin handles its own dispatcher registration and lifecycle, simplifying the implementation of interactive behaviors in Flame components.
packages/flame/lib/src/events/callbacks · high confidence
New component mixins for rendering, visibility, and state management
This update introduces a suite of new mixins to the component system. \HasVisibility\ allows components to be toggled on and off without removal from the tree, while \IgnoreEvents\ enables entire subtrees to opt out of input handling. Rendering capabilities are expanded with \Snapshot\ for caching static component trees, \HasAutoBatchedChildren\ for optimized sprite batching, and \HasDecorator\ for applying visual effects. State and lifecycle management are enhanced via \HasTimeScale\ for pausing/resuming updates, \HasAncestor\ for type-safe ancestor access, and \Notifier\ for listener-based change propagation. Additional utilities include \HasGameRef\ and \HasWorldRef\ for accessing game/world instances, \GestureHitboxes\ for custom hit detection, \ComponentViewportMargin\ for responsive positioning, and \CoordinateTransform\ for defining coordinate space conversions.
packages/flame/lib/src/components/mixins · high confidence
New component utilities and specialized renderers
This update introduces several new component types to the Flame engine. Developers can now use ClipComponent to mask content with circles, rectangles, or polygons, and CustomPainterComponent to integrate Flutter's CustomPainter into the game loop. Performance monitoring is supported via FpsComponent and FpsTextComponent. For UI and asset rendering, IconComponent allows rendering Flutter icons with paint effects, while RasterSpriteComponent provides automatic rasterization and disposal of sprite images. NineTileBoxComponent enables scalable UI boxes, and ScrollTextBoxComponent adds drag-to-scroll functionality to text boxes. Additionally, SpawnComponent now supports multiFactory for spawning multiple items at once, and ComponentPool offers object pooling to reduce garbage collection overhead.
packages/flame/lib/src/components · high confidence
New cross-platform shader build tooling with WebGPU support
The flame\_3d package now includes a new \build\_shaders\ script that compiles GLSL shader sources into optimized assets. This tool supports cross-platform builds (macOS, Linux, Windows) by locating the Impeller compiler from the Flutter SDK and allows shaders to include files from other Dart packages. Additionally, it offers experimental WebGPU support via the \--with-web-gpu\ flag, which uses the \naga\ compiler to convert GLSL to WGSL bundles.
_packages/flame\3d/bin · high confidence
New effect controllers and restructured effect controller API
The effect controller system has been restructured with a new base class and several new controller types to provide more granular control over animations. New controllers include CallbackController for inserting callbacks at specific progress points, CombinedEffectController for bundling multiple effects with optional alternating forward/backward playback, DelayedEffectController for adding start delays, and PauseEffectController for freezing progress. Additional controllers support specific motion patterns: SineEffectController for harmonic motion, ZigzagEffectController for oscillating around a middle ground, and SpeedEffectController for driving effects at a predefined speed based on measurable distance. The base EffectController factory has been expanded to support complex sequences involving start delays, repeat counts, infinite looping, alternate playback, and callbacks at max/min progress points. The HasSingleChildEffectController mixin ensures proper delegation of setToStart/setToEnd to child controllers.
packages/flame/lib/src/effects/controllers · high confidence
New effects for anchor, hue, and rotation around a center point
The effects library now includes AnchorByEffect and AnchorToEffect to animate a component's anchor position, HueByEffect and HueToEffect to adjust a component's hue, and RotateAroundEffect to rotate a component around a specified pivot point.
packages/flame/lib/src/effects · high confidence
New event message types for comprehensive gesture support
The event system in \packages/flame/lib/src/events/messages\ now includes a complete set of message classes for handling advanced input gestures. This adds support for secondary (right-click) and tertiary (middle-click) taps, double-tap sequences, mouse movement, and scaling (pinch/zoom/rotate) gestures. Additionally, drag events now utilize a new \DisplacementEvent\ base class to provide accurate start/end positions and deltas across device, canvas, and local coordinate spaces, ensuring correct coordinate transformations during drag operations.
packages/flame/lib/src/events/messages · high confidence
New examples for the updated effects system
The examples directory now includes demonstrations for the new effects engine, covering ColorEffect, CombinedEffect, DualEffectRemoval, EffectControllers, FunctionEffect, GlowEffect, HueEffect, MoveEffect, OpacityEffect, RemoveEffect, RotateAroundEffect, RotateEffect, ScaleEffect, SequenceEffect, and SizeEffect. These examples illustrate the new API, including the use of \opacityTo\ in ColorEffect and the ability to bundle or sequence multiple effects.
examples/lib/stories/effects · high confidence
New experimental layout and shape examples
The experimental stories section now includes interactive demos for the new layout components (ColumnComponent, LinearLayoutComponent, ExpandedComponent, PaddingComponent) and raw geometric shapes. Users can explore layout behaviors such as direction, alignment, gaps, padding, and child inflation through configurable examples, and visualize how raw Shape objects (Circle, Rectangle, Polygon, etc.) handle point containment and rendering.
examples/lib/stories/experimental · high confidence
New experimental layout components for UI composition
The Flame engine introduces a new suite of experimental layout components to simplify UI construction. This includes \LayoutComponent\ as the base for layout logic, \LinearLayoutComponent\ (with concrete \RowComponent\ and \ColumnComponent\ subclasses) for arranging children along a single axis with support for gaps, alignment, and shrink-wrapping, and \ExpandedComponent\ to allow children to fill available space. Additionally, \PaddingComponent\ provides inset spacing for single children, and \RaycastResult\ supports raycasting operations. These components are marked as experimental and may undergo breaking changes.
packages/flame/lib/src/experimental · high confidence
New extension methods for 3D math and utility types
This change introduces a new set of extension methods and utility classes in the \flame\_3d\ package to improve the ergonomics of 3D development. It adds frustum culling support via \Aabb3Extension\ for efficient scene graph traversal, and provides convenient matrix setup methods (\setAsViewMatrix\, \setAsPerspective\, \setAsOrthographic\) on \Matrix4\. Quaternion operations are enhanced with \slerp\ and \lerp\ extensions, including a robust implementation that prevents NaN results during interpolation. Additionally, immutable tuple types (\ImmutableVector2\, \ImmutableVector3\, \ImmutableVector4\) are introduced with conversion helpers and storage accessors, and a \ColorExtension\ allows easy conversion of colors to float arrays for shader usage.
_packages/flame\3d/lib/src/extensions · high confidence
New extension methods for core types in the Flame extensions package
The \packages/flame/lib/src/extensions\ directory now provides a comprehensive suite of extension methods for common Dart and Flame types, simplifying geometry, rendering, and utility operations. Key additions include \Vector2Extension\ for vector math (e.g., \lerp\, \rotate\, \clampLength\, \moveToTarget\), \CanvasExtension\ for debugging and rendering helpers (e.g., \renderPoint\, \renderLine\, \renderRotated\), and \ColorExtension\/\PaintExtension\ for color manipulation (e.g., \darken\, \brighten\, hex parsing, random generation). Other extensions cover \Rect\ (e.g., \displace\, \randomPoint\, \transform\), \Image\ (e.g., \resize\, \darken\, \brighten\), \Matrix4\ (e.g., \transform2\, \translate2\), \Path\ (e.g., \resizeTo\, \walkContours\), \Offset\/\Size\ (conversions to \Vector2\/\Rect\), \Aabb2\ (e.g., \toRect\), \FragmentShader\ (convenient uniform setters), \Double\ (e.g., \toNormalizedAngle\), \List\ (e.g., \random\), and \Random\ (e.g., \nextBoolean\, \nextColor\). These extensions allow developers to use more fluent, type-safe APIs for common 2D game development tasks directly on standard library and Flame types.
packages/flame/lib/src/extensions · high confidence
New flame\_gamepads package for gamepad input
The flame\_gamepads package has been added to provide a bridge between the underlying gamepads library and Flame, allowing developers to easily integrate gamepad support into their games. The core feature is the GamepadCallbacks mixin, which can be added to any Flame Component to receive normalized gamepad events (such as stick movements and button presses) via the onGamepadEvent callback. An example application is included to demonstrate how to use the mixin to control a player character with a gamepad's left stick.
_packages/flame\gamepads · high confidence
New flame\_steering\_behaviors package for autonomous entity movement
The new \flame\_steering\_behaviors\ package brings Craig Reynolds' steering algorithms to the Flame Behaviors system, allowing developers to create entities with natural, autonomous movement. By adding the \Steerable\ mixin to an entity, you gain access to a suite of behaviors including Wander (for random exploration), Separation (to avoid crowding), Pursue (to chase moving targets), and Flee (to escape threats). The package includes a complete example demonstrating these behaviors in action with 100 entities, along with comprehensive unit and golden tests for all core algorithms.
_packages/flame\_steering\behaviors · high confidence
New game mixins for performance tracking, keyboard handling, and singleton management
The Flame game engine introduces three new mixins to enhance game functionality and structure. The \HasPerformanceTracker\ mixin allows developers to monitor the time spent on update and render cycles via \updateTime\ and \renderTime\ properties. The \HasKeyboardHandlerComponents\ mixin provides a structured way to handle keyboard events by propagating them to components implementing \KeyboardHandler\, replacing the need for the older \KeyboardEvents\ mixin on the game class itself. Additionally, the \SingleGameInstance\ mixin enables the declaration of a game as a singleton, optimizing component lifecycle resolution (such as \onLoad\) when only one game instance exists in the application.
packages/flame/lib/src/game/mixins · high confidence
New geometry primitives and raycasting capabilities
The geometry package now includes new shape components (CircleComponent, RectangleComponent, PolygonComponent) and utility classes (Line, LineSegment, Ray2) to support advanced spatial queries. Users can now perform raycasting and raytracing using the Ray2 class and polygon ray intersection logic, enabling features like line-of-sight checks and projectile trajectories. The new components also support solid hitboxes for full-enclosure collision detection and provide helper methods on LineSegment for translation and inflation.
packages/flame/lib/src/geometry · high confidence
New hardware keyboard support and configurable long-tap delay
The events system now includes a HardwareKeyboardDetector component that allows games to listen directly to hardware keyboard events (key down, repeat, and up) without relying on Flutter's Focus widget, providing properties to track currently pressed keys and modifier states. Additionally, the long-tap detection threshold is now configurable via the TapConfig.longTapDelay static property, allowing developers to adjust the delay (defaulting to 0.3 seconds) to better suit their game's interaction needs or accessibility requirements.
packages/flame/lib/src/events · high confidence
New image manipulation examples for brightness, darkness, and resizing
Added interactive storybook examples demonstrating the new Image extension methods for resizing, brightening, and darkening images. The \image.dart\ storybook entry now includes dedicated sections for \resize\, \brightness\, and \darkness\, allowing users to interactively adjust parameters like target dimensions, brightness levels, and darkness values to see the effects on a sample image.
examples/lib/stories/image · high confidence
New input components: AdvancedButton, Joystick, and KeyboardListener
The input component library has been expanded with several new classes. AdvancedButtonComponent provides a flexible button with distinct skins for states like up, down, hover, and disabled, along with onPressed, onReleased, and onCancelled callbacks. SpriteButtonComponent bundles two sprites to visually indicate press states. ToggleButtonComponent extends AdvancedButton to support selected/unselected states with corresponding skins. JoystickComponent handles drag interactions to report direction and intensity, while KeyboardListenerComponent provides a component-based way to handle key events via the new KeyEvent API.
packages/flame/lib/src/components/input · high confidence
New input gesture examples and advanced button component
The input examples directory now includes demonstrations for the new callback-based input system, covering double-tap, drag, hover, long-press, scroll, and hardware keyboard events. A new Advanced Button example showcases a customizable button component with distinct visual states (default, hover, pressed, disabled, selected). Additionally, a Dynamic Scale & Drag example illustrates how to mix interaction types like dragging and scaling on the same component, and a Gesture Hitboxes example shows how to use specific hitboxes for precise gesture detection on various shapes.
examples/lib/stories/input · high confidence
New interactive documentation examples for Flame effects, decorators, and routing
The \doc/flame/examples\ directory now includes a comprehensive suite of interactive examples demonstrating core Flame capabilities. These new files provide live, runnable demonstrations for visual effects (such as \ColorEffect\, \GlowEffect\, \HueEffect\, and various \Move\, \Scale\, \Rotate\, and \Opacity\ effects), rendering decorators (including \Blur\, \Grayscale\, \Tint\, \Hue\, \Shadow3D\, and \Rotate3D\), and interaction patterns (like \DragCallbacks\, \TapCallbacks\, and \HoverCallbacks\). The collection also features examples for collision detection, ray casting/tracing, post-processing, and the \RouterComponent\ for managing game worlds and routes, all tied together by a central \main.dart\ index page.
doc/flame/examples · high confidence
New modular library entry points and data-oriented particle system
The Flame library now exposes a set of dedicated entry-point files (such as \cache.dart\, \camera.dart\, \collisions.dart\, \components.dart\, \effects.dart\, \events.dart\, \experimental.dart\, \game.dart\, \geometry.dart\, \input.dart\, \layout.dart\, \particles.dart\, and \post\_process.dart\) to simplify imports. Additionally, a new data-oriented particle system has been added, featuring a \ParticleEmitterComponent\ that uses a \ParticleBuffer\ for high-performance simulation and supports declarative presets via \ParticleEmitter\, \ParticleCurve\, and \ColorRamp\.
packages/flame/lib · high confidence
New overlay UI components for the platformer tutorial
The platformer tutorial now includes dedicated overlay files for the main menu, game-over screen, heads-up display (HUD), and health hearts. These components provide the visual interface for starting the game, displaying score and health, and handling the game-over state with a 'Play Again' button.
doc/tutorials/platformer/app/lib/overlays · high confidence
New platformer tutorial with Ember player and Water Enemy actors
The platformer tutorial now includes the \EmberPlayer\ and \WaterEnemy\ actor components. The \EmberPlayer\ handles keyboard input for movement and jumping, applies gravity, manages collision resolution with ground and platform blocks, and handles interactions with stars and enemies. The \WaterEnemy\ moves back and forth across the screen and can damage the player upon collision.
doc/tutorials/platformer/app/lib/actors · high confidence
New rendering examples for decorators, particles, and text components
Added a suite of new interactive examples in the rendering stories section: \HueDecorator\ and \DecoratorVsEffect\ to demonstrate color shifting and group-level transparency blending; an interactive particle system playground allowing users to paint with various emitter presets (fire, smoke, explosions, etc.) and adjust zoom; updated text rendering demos showcasing \TextElementComponent\ with rich document styles, \TextBoxComponent\ with dynamic max-width reflow, and scrollable text boxes; plus examples for flipping sprites, isometric tile maps, layered shadow effects, and customizable nine-patch boxes.
examples/lib/stories/rendering · high confidence
New route types for overlays, worlds, and value-returning navigation
The router now supports three new route types: OverlayRoute lets you display Flutter widgets on top of the game canvas as navigable routes; WorldRoute allows swapping the game world (and optionally the camera) when navigating, enabling seamless transitions between different game scenes; and ValueRoute enables navigation that returns a value when popped, useful for dialogs or forms that need to pass data back to the previous screen.
packages/flame/lib/src/components/router · high confidence
New shared example utilities for paths, shapes, and game references
The examples library now includes a new commons module providing reusable components and helpers for demonstration purposes. This includes a PathComponent that renders arbitrary paths with optional, filtered polygon hitboxes, and a RoundedRectComponent for drawing shapes with semicircular ends. It also introduces an Ember animation component that utilizes the HasGameRef mixin for asset loading, and a PathsCreationMixin to assist games in generating random path-based test entities. Additionally, a utility function is provided to generate GitHub links for source files.
examples/lib/commons · high confidence
New sprite rendering examples and documentation
Added a suite of new example stories in the sprites section, demonstrating how to load and render sprites from base64 strings and asset folders, create animations from sprite sheets, and use SpriteBatch for efficient rendering. The examples also cover the new SpriteBatch bleed option to prevent edge artifacts and the SpriteGroupComponent for state-based sprite switching, such as creating interactive buttons.
examples/lib/stories/sprites · high confidence
New structured text styling system with document-level control
The text rendering pipeline now uses a new tree-based styling architecture (FlameTextStyle) that allows users to define comprehensive visual rules for rich text documents. This includes DocumentStyle for top-level page settings (width, height, padding, background), BlockStyle for structural elements like paragraphs and headers (margin, padding, alignment), and InlineTextStyle for character-level details (font, color, decoration, background/foreground). The system supports cascading styles, merging, and overflow handling (clip, ellipsis, expand, paginate), enabling more precise and CSS-like control over text layout and appearance.
packages/flame/lib/src/text/styles · high confidence
New system examples for overlays, pause/resume, resizing, and step engine
Added new example stories in the system category demonstrating key engine features: the overlays system now supports a \priority\ parameter to control display order (as shown in the overlays example); the pause/resume example illustrates using both \pauseEngine\/\resumeEngine\ and the \isPaused\ property; a new resize example shows how to react to game size changes via \onGameResize\; and a step engine example demonstrates frame-by-frame game advancement using \stepEngine\. These examples are registered in the system stories index.
examples/lib/stories/system · high confidence
New visual decorator system for game components
The rendering layer now includes a composable \Decorator\ system that allows you to apply visual effects to components without modifying their core logic. This location introduces the \Decorator\ base class and several concrete implementations: \PaintDecorator\ for blurring, tinting, and grayscale effects; \Shadow3DDecorator\ for realistic isometric shadows; \Rotate3DDecorator\ for 3D-style rotation; \HueDecorator\ for hue shifting; and \Transform2DDecorator\ for standard 2D transforms. These decorators can be chained together to create complex visual styles, and the system also includes a \MutableRSTransform\ for efficient batch manipulation of transform data.
packages/flame/lib/src/rendering · high confidence
Platform-specific page URL resolution for web examples
The platform example library now includes a provider abstraction that resolves the current page context differently per platform. A new abstract PageProvider interface defines a getPage method, with a stub implementation returning null for non-web platforms and a web-specific implementation that extracts the URL search parameters from the browser window location. This allows the example to dynamically determine which page to display based on web query strings while maintaining a consistent interface across platforms.
examples/lib/platform · high confidence
Platformer tutorial adds ground, platform, and star object components
The platformer tutorial example now includes three new game object components: GroundBlock, PlatformBlock, and Star. These components handle rendering, movement, and collision detection (using passive hitboxes) for the tutorial's level elements, providing a concrete implementation of game entities within the EmberQuest example app.
doc/tutorials/platformer/app/lib/objects · high confidence
Project initialization and repository structure setup
The repository has been initialized with essential project infrastructure files, including a comprehensive CONTRIBUTING guide, a Code of Conduct, an MIT License, and a detailed README. Configuration for development workflows has been added, such as a .gitignore for Flutter/Dart artifacts, markdown linting rules (.markdownlint.yaml), and Read the Docs configuration (.readthedocs.yaml). The CHANGELOG has been restructured to follow Conventional Commits standards, and the .gitignore has been expanded to cover platform-specific build folders and IDE settings.
(repo-wide) · high confidence
QuadTree-based collision detection for static-heavy scenes
Flame now includes a QuadTree broadphase implementation for collision detection, available via the \HasQuadTreeCollisionDetection\ mixin. This allows games with many static collidable entities (such as platforms, walls, or trees) to use a spatial partitioning algorithm instead of the default broadphase, potentially improving performance in dense static environments. Users can initialize it by adding the mixin to their \FlameGame\ and calling \initializeCollisionDetection\ with map dimensions and optional tuning parameters like \maxObjects\ and \maxLevels\.
packages/flame/lib/src/collisions/broadphase/quadtree · high confidence
Space Shooter tutorial adds Step 6 with bullet spawning and drag controls
The Space Shooter tutorial now includes a new Step 6 that demonstrates how to implement bullet spawning and player movement via drag events. This step introduces a \SpawnComponent\ to handle periodic bullet creation from the player, utilizes the \HasGameRef\ mixin to access game-level resources, and implements \DragCallbacks\ to allow users to move the player and control shooting by dragging on the screen.
_doc/tutorials/space\shooter/app/lib/step6 · high confidence
Space Shooter tutorial step 3 adds parallax scrolling and drag controls
The Space Shooter tutorial now includes a new step 3 example that demonstrates adding a parallax background effect and controlling the player ship via drag gestures. This example shows how to load and display a multi-layered parallax background using \loadParallaxComponent\ and how to implement \DragCallbacks\ to update the player's position based on drag events.
_doc/tutorials/space\shooter/app/lib/step3 · high confidence
Space Shooter tutorial step 4 adds player movement and bullet spawning
The Space Shooter tutorial now includes a new step 4 that demonstrates core gameplay mechanics. Users can now see how to implement player movement via drag events and how to use a SpawnComponent to automatically generate bullets at a set interval when the player starts dragging. This step introduces the integration of the Flame game engine's event system and component lifecycle for a basic interactive game loop.
_doc/tutorials/space\shooter/app/lib/step4 · high confidence
Space Shooter tutorial step 5 adds enemy spawning and drag-based player control
The Space Shooter tutorial now includes a fifth step that demonstrates how to spawn enemies using a SpawnComponent and control the player ship via drag gestures. The game logic now initializes a background parallax effect, adds a SpawnComponent to the game world to periodically create Enemy instances, and implements DragCallbacks on the main game class to move the player and toggle bullet firing. The Player component uses its own SpawnComponent to manage bullet creation, while Bullet and Enemy components handle their own vertical movement and removal from the scene when they go off-screen.
_doc/tutorials/space\shooter/app/lib/step5 · high confidence
Support for parsing GLB, GLTF, and OBJ 3D model files
The flame\_3d package now includes parsers for GLB, GLTF, and OBJ 3D model formats, enabling users to load and render these assets in their games. This change introduces a unified \ModelParser\ interface that automatically selects the appropriate parser based on the file extension (.gltf, .glb, or .obj). The GLB and GLTF parsers handle binary and JSON-based glTF 2.0 structures respectively, while the OBJ parser supports basic mesh geometry, vertex normals, UV coordinates, and simple material definitions via MTL files.
_packages/flame\3d/lib/src/parser · high confidence
flame\_audio package initialization with AudioPlayers integration
The flame\_audio package is introduced to provide audio capabilities for Flame games by integrating with the audioplayers library. This release establishes the core API surface, including the FlameAudio utility class for playing sounds and background music, the Bgm class for managing looping background tracks with lifecycle awareness, and support for AudioPools. It also includes an example application demonstrating these features and sets the minimum Flutter version to 3.41.0.
_packages/flame\audio · high confidence
flame\_lint package initial release with comprehensive lint rules
The flame\_lint package is now available as a standalone dependency, providing a strict set of lint rules for Flame, Flutter, and Dart projects. It includes the standard lints/core.yaml rules, enforces trailing comma preservation for Dart 3.8+, and integrates Dart Code Metrics (DCM) rules such as avoid-cascade-after-if-null and avoid-throw-in-catch-block. Users can adopt these standards by adding flame\_lint to their dev\_dependencies and including package:flame\_lint/analysis\_options.yaml in their analysis\_options.yaml.
_packages/flame\lint · high confidence
flame\_texturepacker package initialization and core API
The \flame\_texturepacker\ package is introduced, providing the ability to import sprite sheets generated by Gdx Texture Packer and Code & Web Texture Packer into Flame games. The package exposes \TexturePackerAtlas\ for loading and querying sprites, supports loading from both Flutter assets and device storage, and includes an \atlasFromAssets\ extension on \Game\ for convenient integration. It also features sprite whitelisting to optimize memory usage, support for rotated sprites, and the ability to generate animations from sprite sequences.
_packages/flame\texturepacker · high confidence
Removals
Removal of legacy core engine and utility classes
The legacy \lib\ entry point and its foundational classes have been removed from the library. Specifically, \audio.dart\ (the \Audio\ class), \component.dart\ (the \Component\ and \SpriteComponent\ classes), \flame.dart\ (the static \Flame\ facade), \game.dart\ (the \Game\ abstract class and its internal rendering loop), \images.dart\ (the \Images\ loader), and \util.dart\ (the \Util\ class) are no longer part of the public API. Users relying on these specific classes for basic game loops, sprite rendering, or asset loading will need to migrate to the new architecture.
lib · high confidence
Behavioural changes
1 commit (0 fixes) modifying examples/assets/audio
A change to existing behaviour in examples/assets/audio — 1 commit, 3 files.
examples/assets/audio · medium confidence · unverified
4 commits (0 fixes) modifying doc/flame/examples/assets
A change to existing behaviour in doc/flame/examples/assets — 4 commits, 3 files.
doc/flame/examples/assets · medium confidence · unverified
Core component lifecycle and tree management overhaul
The component system has been re-architected to improve performance and reliability. The component tree is now managed by a dedicated ComponentTreeRoot that processes lifecycle events (add, remove, move, rebalance) via a RecycledQueue, allowing safe modification during iteration and preventing concurrent mutation errors. The children container has been replaced with a flat, sorted ComponentList for faster update traversals, and a CustomTraversal mixin allows components to define their own subtree update logic. Additionally, components now support public keys for identification, a Render Context API for rendering, and a new 'removed' future for tracking lifecycle completion.
packages/flame/lib/src/components/core · high confidence
Documentation site receives a new dark theme and UI enhancements
The documentation site has been updated with a new visual identity, introducing a dark color scheme and improved typography via the new \flames.css\ theme. This update also integrates Font Awesome 5.15.4 for consistent iconography, adds a styled copy button for code snippets (\copy-button.css\), and includes a custom JavaScript module (\doctools.js\) to enhance search word highlighting and navigation behavior.
_doc/\sphinx/theme · high confidence
Documentation version selector and home page navigation improvements
The documentation site now includes a version selector in the top navigation bar, allowing users to switch between different documentation versions (e.g., 'latest', 'main', or specific releases) via a dropdown menu. A warning is displayed for non-standard versions. Additionally, the home page now automatically expands the first section in the table of contents upon loading to improve initial visibility.
_doc/\sphinx/scripts · high confidence
Extract obstacle logic into dedicated Trex game package
The T-Rex game example has been moved to its own package, and the obstacle management logic is now contained within the \examples/games/trex/lib/obstacle\ directory. This change introduces \Obstacle\, \ObstacleManager\, and \ObstacleType\ components, which handle the spawning, positioning, and collision hitboxes for cactus obstacles. The new implementation uses \HasGameRef\ to access game state and random extensions for gap calculation, replacing the previous monolithic structure with a modular, reusable component system.
examples/games/trex/lib/obstacle · high confidence
Flame 1.38.0 release with gesture resilience and collision fixes
This update introduces Flame version 1.38.0, featuring a refactor to make the \GestureDetectorBuilder\ and callback registration more resilient. It includes several fixes: a workaround for \TextBoxComponent\ entering an endless loop, ensuring \HasWorldReference.onRemove()\ calls \super.onRemove()\, and improved raycasting and collision prospect checking for better accuracy. New features include a \displace\ extension for \Rect\, \OpacityEffect\ support for text components, brighten/darken helpers on palettes, a \bleed\ option for \SpriteBatch\ to prevent seam artifacts, regular polygon constructors, and tertiary tap, long press, and scroll callbacks on the new event system. Breaking changes include the addition of \HoverCallbacks.onHoverCancel\ and an update to the scale event with a custom recognizer.
packages/flame · high confidence
Flame Forge2D examples updated for Box2D v3 and CameraComponent
The flame\_forge2d examples have been migrated to use the Box2D v3-based forge2d library and updated to work with Flame's new CameraComponent. This migration introduces several behavioral changes: drag events now use DisplacementEvent for correct delta coordinate transformations, and drag cancellation no longer delegates to drag end by default. The examples also demonstrate new capabilities such as camera following for BodyComponents, composition of BodyComponents with standard Flame components, and the integration of real Flutter widgets with physics bodies.
_examples/lib/stories/bridge\_libraries/flame\forge2d · high confidence
Flame example app migrated to modern API
The example application in packages/flame/example/lib has been updated to use the current Flame API surface. It now utilizes the GameWidget wrapper with a FlameGame instance, employs the TapCallbacks mixin for handling touch interactions, and uses the BasicPalette for color management, reflecting the library's current best practices for game initialization and event handling.
packages/flame/example/lib · high confidence
GameWidget now supports configurable hit testing behavior and dynamic overlay management
The GameWidget now exposes a \behavior\ property (defaulting to \HitTestBehavior.opaque\) that allows developers to control how pointer events are handled, supporting \deferToChild\ and \translucent\ modes for more flexible UI layering. Additionally, the widget now supports adding and removing multiple overlays at once via the \overlayBuilderMap\ and \initialActiveOverlays\ properties, and includes a new \managed\ constructor for easier game instance lifecycle management within other widgets.
_packages/flame/lib/src/game/game\widget · high confidence
Introduce RenderContext to decouple rendering logic from GPU device
The graphics layer has been refactored to introduce a \RenderContext\ abstraction, separating high-level rendering state (such as camera matrices, lighting, and deferred draw sorting) from the low-level \GraphicsDevice\ which now focuses purely on GPU command recording. This change provides a cleaner API for 3D rendering pipelines, allowing components to interact with a unified context for setting up scenes and materials without directly managing backend-specific device operations.
_packages/flame\3d/lib/src/graphics · high confidence
Introduce layer rendering pipeline with pre/post processors
The layers package now exposes a new rendering architecture where \Layer\ classes can define \preProcessors\ and \postProcessors\ to modify the canvas before and after drawing the layer's picture. This enables effects like shadows (via \ShadowProcessor\) to be applied declaratively. The change introduces \PreRenderedLayer\ for static content and \DynamicLayer\ for content that re-renders every frame, fundamentally changing how layers are composed and rendered.
packages/flame/lib/src/layers · high confidence
Introduce new shader resource API with automatic uniform binding
The flame\_3d package now provides a new, simplified shader system via the Shader, VertexShader, and FragmentShader classes. Users can load shaders from assets and set uniform values (such as vectors, matrices, colors, and textures) using intuitive string keys that support struct members and array indexing (e.g., 'Lights.positions\[0\]'). The API automatically handles GPU buffer allocation and binding, removing the need for manual uniform class management and reducing allocation overhead.
_packages/flame\3d/lib/src/resources/shader · high confidence
Introduce on-demand resource creation and reorganize 3D resource exports
The \flame\_3d\ library now uses an on-demand resource creation pattern, allowing resources to be instantiated only when accessed via a \createResource\ method, which facilitates testing and reduces unnecessary initialization. Additionally, the public API surface has been reorganized into dedicated export files for lights, materials (including UnlitMaterial), meshes (such as ConeMesh), shaders, and textures, providing a cleaner and more modular entry point for these 3D components.
_packages/flame\3d/lib/src/resources · high confidence
Introduce structured text element hierarchy for rich text rendering
The text rendering system has been restructured to support a tree-based layout model, introducing a new hierarchy of elements in the \packages/flame/lib/src/text/elements\ directory. \TextElement\ serves as the base abstract class for concrete rendering blocks, while \InlineTextElement\ extends it to handle single-line metrics and positioning. New concrete types include \BlockElement\ for rectangular layouts, \GroupElement\ for grouping multiple block children, and \GroupTextElement\ for composing inline text lines. The system now supports specific rendering backends via \TextPainterTextElement\ (wrapping Flutter's TextPainter) and \SpriteFontTextElement\ (using raw atlases), alongside geometric primitives like \RectElement\ and \RRectElement\. This change enables complex, nested text structures and style propagation through the node tree, moving away from flat rendering logic.
packages/flame/lib/src/text/elements · high confidence
Klondike Tutorial Step 5: Redesigned card interaction and deal animation
The Klondike tutorial's fifth step has been updated to improve the user experience of card manipulation and game initialization. The implementation now distinguishes between drag and tap inputs using a configurable tolerance, allowing for more intuitive card movement. Additionally, the card dealing process has been corrected to ensure proper animation sequencing, where cards fly from the stock to the tableau piles in the correct visual order, and the top card of each tableau pile flips with a slight staggered delay.
doc/tutorials/klondike/app/lib/step5 · high confidence
Migrate to Forge2D 0.15 (Box2D v3) and adapt to Flutter 3.47
The flame\_forge2d bridge has been upgraded to Forge2D 0.15, which replaces the pure Dart Box2D 2.x port with bindings for Box2D v3. This is a breaking change that updates the underlying physics API, requiring users to follow the migration guide to adapt their code to the new Forge2D interface. Additionally, the package has been adapted to be compatible with Flutter 3.47.
_packages/flame\forge2d · high confidence
New collision detection system with callbacks and raycasting
The collision detection system has been restructured to use a broadphase algorithm for improved performance and now exposes granular lifecycle callbacks (\onCollisionStart\, \onCollision\, \onCollisionEnd\) via the \CollisionCallbacks\ mixin on \Component\. This change introduces a new \HasCollisionDetection\ mixin for games to enable the system, which tracks \ShapeHitbox\ instances and runs detection every tick. Additionally, the system now supports raycasting and raytracing with options to filter hitboxes or ignore specific ones, and allows collision events to be passed up to ancestor components via the \CollisionPassthrough\ mixin.
packages/flame/lib/src/collisions · high confidence
New collision hitbox API with raycasting and solid support
The collision system introduces a new set of hitbox classes (CircleHitbox, RectangleHitbox, PolygonHitbox, CompositeHitbox, and ScreenHitbox) that replace the previous implementation. This update adds support for solid hitboxes, which allow intersections even when one shape is fully enclosed by another, and introduces raycasting capabilities for precise intersection detection. PolygonHitbox now supports regular polygons and Path-based shapes, while ScreenHitbox automatically tracks the camera viewport to detect collisions with screen edges. The API also exposes the hitbox parent component and allows configuring whether collisions propagate to the parent.
packages/flame/lib/src/collisions/hitboxes · high confidence
New game engine architecture with FlameGame, Transform2D, and lifecycle management
The game engine core has been restructured to introduce a new recommended base class, FlameGame, which automatically manages a CameraComponent and World, and waits for the entire initial component tree to load before starting. The low-level Game mixin now exposes buildContext during onLoad and onMount, and integrates with a new GameLoop that drives the update/render cycle. A new Transform2D class handles 2D transformations with caching and change notifications, backed by a NotifyingVector2. The engine also adds lifecycle awareness, pausing the game loop when the app is backgrounded and resuming on mount, and introduces an OverlayManager for managing UI overlays with priority sorting.
packages/flame/lib/src/game · high confidence
New structured text rendering pipeline with node-based styling
The text rendering system has been replaced with a new structured pipeline that uses a tree of text nodes (such as BlockNode, InlineTextNode, HeaderNode, and ParagraphNode) to manage layout and styling. This change introduces support for hierarchical style propagation, allowing styles to inherit and merge through the node tree, and enables specific formatting features like bold, italic, strikethrough, inline code, and custom style attributes. Users will now experience more consistent text layout with proper margin collapsing and text alignment, as the new nodes handle the conversion of document structures into renderable elements.
packages/flame/lib/src/text/nodes · high confidence
New text rendering architecture with TextRenderer interface and factory
The text rendering system has been restructured around a new abstract TextRenderer interface, which defines how text strings are converted into renderable InlineTextElements. This change introduces two concrete implementations: TextPaint, which leverages Flutter's TextPainter for standard text styling and supports conversion to InlineTextStyle, and SpriteFontRenderer, which renders text using sprite fonts with configurable scale and letter spacing. A TextRendererFactory has been added to manage default renderer creation via a registry, allowing users to easily instantiate renderers or register custom ones. This provides a more flexible and extensible foundation for text rendering in Flame applications.
packages/flame/lib/src/text/renderers · high confidence
Optimized collision prospect handling with object pooling and reliable hashing
The broadphase collision detection system now reuses \CollisionProspect\ objects via a \ProspectPool\ to reduce per-frame memory allocations, improving performance. Additionally, the \CollisionProspect\ equality and hash code implementation has been corrected to use proper hash combining, ensuring reliable behavior in hash-based collections and fixing previously flaky tests.
packages/flame/lib/src/collisions/broadphase · high confidence
Optimized sweep broadphase with insertion sort and object pooling
The sweep broadphase implementation now uses insertion sort instead of a general-purpose sort, leveraging the fact that hitboxes move incrementally between ticks to achieve near-linear performance. Additionally, collision prospects are now pooled to reduce garbage collection pressure by reusing objects rather than creating new ones on every query.
packages/flame/lib/src/collisions/broadphase/sweep · high confidence
Refactored background rendering into dedicated component classes
The background logic for the T-Rex game example has been restructured into specific, reusable components: \Cloud\, \CloudManager\, and \Horizon\. Previously, these elements were likely embedded within larger game files; they are now isolated in \lib/background/\. The \Horizon\ component now acts as a container that manages the scrolling ground layers, instantiates the \CloudManager\ for sky elements, and integrates with the \ObstacleManager\. This change improves code organization and separation of concerns within the game's visual layer.
examples/games/trex/lib/background · high confidence
Rewritten event dispatchers with new dispatcher infrastructure
The event dispatching system in \packages/flame/lib/src/events/dispatchers\ has been completely rewritten. A new base \Dispatcher\ class now manages the lifecycle and registration of gesture handlers on the \FlameGame\ instance. Specific dispatchers for double-tap, long-press, mouse movement, multi-drag/scale, multi-tap, non-primary taps, and scroll have been implemented to replace the previous shared interfaces. This change introduces a more robust mechanism for delivering pointer events to components mixing in the corresponding \\*Callbacks\ mixins, including support for multi-pointer drag handling via \allowsMultiPointerDrag\ and improved tracking of pointer states across the component tree.
packages/flame/lib/src/events/dispatchers · high confidence
Space Shooter tutorial app now routes to specific steps via URL
The Space Shooter tutorial application now supports navigating to individual tutorial steps directly through URL parameters. By appending a query string such as \?step1\ through \?step6\ to the page URL, users can instantly load the corresponding step's implementation. If an invalid or missing step is provided, the app displays a clear error message instructing the user on the correct usage, improving the ease of following the tutorial sequence.
_doc/tutorials/space\shooter/app/lib · high confidence
Space Shooter tutorial step 2 updated to use new event system
The Space Shooter tutorial's step 2 example has been updated to demonstrate the new drag event system. The game class now mixes in \DragCallbacks\ and handles input via \onDragUpdate\ using \DragUpdateEvent\, replacing previous drag handling mechanisms. Additionally, the \Player\ component uses \HasGameRef\ to access the game instance for loading assets.
_doc/tutorials/space\shooter/app/lib/step2 · high confidence
T-Rex game example restructured into a standalone package
The T-Rex game example has been moved into its own dedicated package (\trex\_game\) and reorganized under \examples/games/trex/lib\. This change introduces a modular structure with separate files for the main game logic (\trex\_game.dart\), player behavior (\player.dart\), and the game-over state (\game\_over.dart\), replacing the previous single-file implementation. The entry point now uses \GameWidget\ to host the \TRexGame\ instance, and the game logic has been updated to use the modern \KeyEvent\ API for keyboard input instead of the deprecated \RawKeyEvent\.
examples/games/trex/lib · high confidence
Unified examples entry point with Dashbook catalog and direct route support
The examples/lib/main.dart file has been replaced with a new entry point that serves as the central hub for all Flame examples. It now integrates the Dashbook UI library to present a browsable catalog of stories covering core features (such as components, effects, input, and rendering) and bridge packages (including Forge2D, Jenny, Lottie, and Spine). Additionally, it supports direct navigation to specific physics joint examples (e.g., DistanceJoint, MotorJoint) via URL routes, falling back to the Dashbook catalog when no specific route is provided.
examples/lib · high confidence
Updated 3D rendering shaders with skeletal animation and unlit material support
The flame\_3d package now includes compiled WGSL shader bundles for spatial and unlit materials that support skeletal animation via joint matrices and weights in the vertex shader. The spatial material shader has been updated to correctly calculate ambient lighting without duplicating the base color multiplication, and uses a float for the number of lights uniform to prevent crashes on GLES. The new unlit material shader provides a simpler rendering path for objects that do not require lighting calculations.
_packages/flame\3d/assets · high confidence
Updated Spine example assets to version 4.3
The Spine animation assets in the examples directory have been updated to support Spine 4.3 (specifically 4.3.39-beta). This change introduces new skeleton data files (spineboy-pro.json) and updated texture atlases (spineboy.atlas) that reflect the structural and formatting changes in the newer Spine runtime version, ensuring compatibility with the latest Spine animation features.
examples/assets/spine · high confidence
flame\_svg v2.0.0: Breaking removal of integralSize and Flutter 3.47 adaptation
The flame\_svg package has been updated to version 2.0.0, introducing a breaking change where the \integralSize\ property on the \Svg\ class has been removed, enforcing an 'always true' behavior for integral sizing. Additionally, the package has been adapted to be compatible with Flutter 3.47.
_packages/flame\svg · high confidence
Test coverage
Added comprehensive test coverage for Flame game engine core components; Added comprehensive test coverage for core Flame components; Added comprehensive test suite for collision detection system; Added test coverage for CameraComponent, Viewfinder, and World; Added test coverage for camera viewport components; Added test coverage for core Flame rendering and animation components; Added test coverage for new and existing Flame effects; Added test resources and utilities for unit testing; Added test to verify shader bundle consistency; Added tests for 3D math extensions and Transform3D; Added tests for AABB3 frustum culling and extension methods; Added tests for AlignComponent layout behavior; Added tests for ConeMesh creation; Added tests for Flame extension utilities; Added tests for GameWidget hot reload, keyboard, lifecycle, and input handling; Added tests for HardwareKeyboardDetector and TapConfig; Added tests for HasSingleChildEffectController mixin; Added tests for Line3D mesh component generation; Added tests for PostProcessSequentialGroup execution order; Added tests for SpriteButtonComponent input handling; Added tests for experimental layout and reference components; Added tests for game mixins; Added tests for geometry utilities and raycasting; Added tests for math utilities; Added tests for new 3D and visual decorators; Added tests for shader resource creation and key parsing; Added unit and golden tests for the text rendering subsystem; Added unit tests for Circle, Polygon, Rectangle, and RoundedRectangle geometry shapes; Added unit tests for cache components; Added unit tests for camera behavior components; Added unit tests for component mixins and custom traversal; Added unit tests for effect controllers; Added unit tests for the new data-oriented particle system; Added widget and unit tests for event callback mixins; Added widget tests for Flame UI components; New benchmark suite for Flame Component System hot paths.
Dependencies
Flame Engine 1.38.0 and Monorepo Dependency Updates
This release updates the core Flame engine to version 1.38.0 and synchronizes all bridge packages and examples to use this version. Key dependency upgrades include audioplayers to ^6.2.0 in flame\_audio, forge2d to ^0.15.1 in flame\_forge2d, Rive to ^0.14.6 in flame\_rive, and Lottie to ^3.1.2 in flame\_lottie. The monorepo structure is standardized with SDK constraints set to \>=3.12.0 and Flutter constraints to \>=3.44.0 across all packages. New packages introduced in this release include flame\_gamepads for gamepad support, flame\_steering\_behaviors for AI steering algorithms, and flame\_typled (referenced in commits). Documentation dependencies are also updated, including Sphinx to 7.2.6 and Pygments to 2.20.0.
(dependencies) · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings — which rule fired, in which file, on which line, and how to fix it — are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.
Score
- CAI 54 → 62 (+7.3)
- Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.
Lenses
- Code Health 98 → 89 (-8.9)
- Architecture 99 → 97 (-1.7)
- Maturity 70 → 72 (+1.2)
- Readiness 38 → 48 (+9.2)
- Security 50 → 68 (+17.9)
Resolved (47)
- Change coupling: drag_callbacks.dart ↔ tap_callbacks.dart (packages/flame/lib/src/events/callbacks/drag_callbacks.dart)
- Change coupling: image_layer.dart ↔ renderable_tile_map.dart (packages/flame_tiled/lib/src/renderable_layers/image_layer.dart)
- Change coupling: move_effect.dart ↔ rotate_effect.dart (packages/flame/lib/src/effects/move_effect.dart)
- Change coupling: move_effect.dart ↔ scale_effect.dart (packages/flame/lib/src/effects/move_effect.dart)
- Change coupling: spatial_material.dart ↔ shader.dart (packages/flame_3d/lib/src/resources/material/spatial_material.dart)
- Coverage not included — suite not readable by the collector
- Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- High: security finding (details withheld)
- …and 27 more
New (352)
- Card._renderFront (cyclomatic 19) (doc/tutorials/klondike/app/lib/step3/components/card.dart)
- Card._renderFront (cyclomatic 19) (doc/tutorials/klondike/app/lib/step4/components/card.dart)
- Card._renderFront (cyclomatic 19) (doc/tutorials/klondike/app/lib/step5/components/card.dart)
- Change coupling: combined_effect.dart ↔ sequence_effect.dart (packages/flame/lib/src/effects/combined_effect.dart)
- Change coupling: events.dart ↔ gesture_detector_builder.dart (packages/flame/lib/events.dart)
- Change coupling: flame_game.dart ↔ gesture_detector_builder.dart (packages/flame/lib/src/game/flame_game.dart)
- CirclePolygonIntersections.intersect (cognitive 19) (packages/flame/lib/src/geometry/shape_intersections.dart)
- ClassTooLong: Component (packages/flame/lib/src/components/core/component.dart)
- ClassTooLong: _Lexer (packages/flame_jenny/jenny/lib/src/parse/tokenize.dart)
- ClassTooLong: _Parser (packages/flame_jenny/jenny/lib/src/parse/parse.dart)
- CollisionDetection.run (cognitive 16) (packages/flame/lib/src/collisions/collision_detection.dart)
- CombinedEffectController.advance (cognitive 23) (packages/flame/lib/src/effects/controllers/combined_effect_controller.dart)
- CombinedEffectController.recede (cognitive 23) (packages/flame/lib/src/effects/controllers/combined_effect_controller.dart)
- Component.componentsAtLocation (cognitive 16) (packages/flame/lib/src/components/core/component.dart)
- Dependency hygiene PARTLY measured — Python dependencies read, no exact pin to grade for currency
- Documentation: no project overview (packages/flame_spine/README.md)
- Duplicated block (10 lines × 2) (doc/tutorials/klondike/app/lib/step4/components/tableau_pile.dart)
- Duplicated block (10 lines × 2) (doc/tutorials/space_shooter/app/lib/step5/main.dart)
- Duplicated block (10 lines × 2) (examples/lib/stories/bridge_libraries/flame_jenny/jenny_command_lifecycle_example.dart)
- Duplicated block (10 lines × 2) (packages/flame_3d/lib/src/resources/material/spatial_material.dart)
- …and 332 more
Changes since last survey
- 56 commits — 40 feature/other, 16 fixes
By area
- packages/flame — 41 commits
- examples/lib — 5 commits
- doc/flame — 2 commits
- .github/workflows — 1 commit
- doc/README.md — 1 commit
- doc/bridge_packages — 1 commit
- doc/tutorials — 1 commit
- examples/pubspec.yaml — 1 commit
- packages/flame_forge2d — 1 commit
- packages/flame_svg — 1 commit
- packages/flame_texturepacker — 1 commit
Notable commits
- fix: chore: Bump dashbook to fix warning (#3990)
- fix: chore: Bump flame_svg to 2.0.0 on main after the hotfix release (#4029)
- fix: fix!: Do not delegate onDragCancel to onDragEnd by default (#3934)
- fix: fix!: Remove middle intersection point on shared line segments in collision detection (#4004)
- fix: fix!: Wait for children added in onLoad before marking a component as loaded (#3999)
- fix: fix!: Wait for the whole component tree to load before starting the game (#3998)
- fix: fix: Adapt to Flutter 3.47 (#3995)
- fix: fix: Correct parent context lookup on LocationContextEvent (#4036)
- fix: fix: Keep TextComponent glyphs in place when its paint changes (#4041)
- fix: fix: Recognize every input callbacks mixin when hit testing (#3994)
- fix: fix: Require touch slop before DragCallbacks accepts a drag (#4017)
- fix: fix: Reset AdvancedButtonComponent state when a tap is cancelled (#4049)
- fix: fix: Scan the lifecycle queue without its iterator in dequeueAdd/dequeueRemove (#4021)
- fix: fix: Stop stripping trailing digits from sprite names in flame_texturepacker (#3869)
- fix: fix: Unwind the context trace consistently after event delivery (#4037)
- fix: fix: Use full asset paths in the remaining examples and docs (#4027)
- change: chore!: Kill HasGameReference (#4030)
- change: chore!: Kill PanDetector and the old event system (#4031)
- change: chore!: Kill legacy Force Press event API (#3989)
- change: chore!: Kill legacy Vertical/Horizontal drag detectors (#3993)
- …and 36 more
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
flame-engine/flame was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 22 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit c35f9d803e9297561f53c4bad3f54182b644e0cf — the exact code this score is about.
- Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-821afab8930d.