Miniature map view of a 2D world. More...
| Import Statement: | import Clayground.World |
Minimap2d displays a scaled-down view of a ClayWorld2d, showing entities as simple shapes based on type mapping.
Example usage:
import Clayground.World Minimap2d { world: gameWorld width: 200; height: 150 anchors.right: parent.right anchors.top: parent.top typeMapping: new Map([ ["Player", playerDotComponent], ["Enemy", enemyDotComponent] ]) Component { id: playerDotComponent; Rectangle { color: "green" } } Component { id: enemyDotComponent; Rectangle { color: "red" } } }
The world to display. Required.
Map of entity type names to QML Components for rendering.