Pack Textures/ into atlases and render the world from them
Engine bump brings MrGameEng.Atlases (atlas builder + runtime loader). Textures/ (2747 images) is packed by MrGameEng.AtlasTool into 10 atlases (93 pages) under Assets/Atlases, loaded through generated handles. Beings now draw pawn bodies, forest cells grow trees (both Y-sorted), and the dev console gains 'atlas [name] [filter]' for inspection. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@@ -25,6 +25,19 @@ dotnet run --project src/LittleSim -c Release # measure perf in Release only
|
||||
dotnet test LittleSim.sln # runs the engine test suites
|
||||
```
|
||||
|
||||
## Texture atlases
|
||||
|
||||
Source images live in `Textures/` (committed); the game only loads packed atlases from
|
||||
`src/LittleSim/Assets/Atlases` (also committed — the asset generator emits
|
||||
`GameAssets.Atlases.*` handles for them). After changing `Textures/`, rebuild with:
|
||||
|
||||
```
|
||||
dotnet run --project engine/tools/MrGameEng.AtlasTool -c Release -- Textures src/LittleSim/Assets/Atlases --group-depth 2
|
||||
```
|
||||
|
||||
Rebuilds are incremental (unchanged groups are skipped). Region keys are paths relative
|
||||
to `Textures/` without extension: `atlas.GetRegion("Things/Plant/TreeOak/TreeOakA")`.
|
||||
|
||||
## Submodule workflow
|
||||
|
||||
Engine changes are committed **inside `engine/` first** (engine repo, its commit style),
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
{
|
||||
"version": 1,
|
||||
"name": "Terrain.Surfaces",
|
||||
"pageSize": 2048,
|
||||
"padding": 2,
|
||||
"pages": [
|
||||
{
|
||||
"file": "Terrain.Surfaces.atlas.0.png",
|
||||
"width": 256,
|
||||
"height": 128
|
||||
}
|
||||
],
|
||||
"regions": [
|
||||
{
|
||||
"key": "Terrain/Surfaces/Marsh",
|
||||
"page": 0,
|
||||
"x": 2,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "Terrain/Surfaces/Marsh_bright",
|
||||
"page": 0,
|
||||
"x": 68,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
}
|
||||
]
|
||||
}
|
||||
|
After Width: | Height: | Size: 1.6 KiB |
|
After Width: | Height: | Size: 169 KiB |
|
After Width: | Height: | Size: 202 KiB |
|
After Width: | Height: | Size: 238 KiB |
|
After Width: | Height: | Size: 206 KiB |
|
After Width: | Height: | Size: 281 KiB |
|
After Width: | Height: | Size: 258 KiB |
|
After Width: | Height: | Size: 350 KiB |
|
After Width: | Height: | Size: 207 KiB |
|
After Width: | Height: | Size: 256 KiB |
|
After Width: | Height: | Size: 266 KiB |
|
After Width: | Height: | Size: 275 KiB |
|
After Width: | Height: | Size: 357 KiB |
|
After Width: | Height: | Size: 233 KiB |
|
After Width: | Height: | Size: 423 KiB |
|
After Width: | Height: | Size: 172 KiB |
|
After Width: | Height: | Size: 218 KiB |
|
After Width: | Height: | Size: 316 KiB |
|
After Width: | Height: | Size: 540 KiB |
|
After Width: | Height: | Size: 427 KiB |
|
After Width: | Height: | Size: 488 KiB |
|
After Width: | Height: | Size: 267 KiB |
|
After Width: | Height: | Size: 304 KiB |
|
After Width: | Height: | Size: 285 KiB |
|
After Width: | Height: | Size: 194 KiB |
|
After Width: | Height: | Size: 326 KiB |
|
After Width: | Height: | Size: 657 KiB |
|
After Width: | Height: | Size: 1.1 MiB |
|
After Width: | Height: | Size: 509 KiB |
|
After Width: | Height: | Size: 911 KiB |
|
After Width: | Height: | Size: 1.0 MiB |
|
After Width: | Height: | Size: 992 KiB |
|
After Width: | Height: | Size: 717 KiB |
|
After Width: | Height: | Size: 1.0 MiB |
|
After Width: | Height: | Size: 1.1 MiB |
|
After Width: | Height: | Size: 167 KiB |
|
After Width: | Height: | Size: 789 KiB |
|
After Width: | Height: | Size: 1.5 MiB |
|
After Width: | Height: | Size: 169 KiB |
|
After Width: | Height: | Size: 169 KiB |
|
After Width: | Height: | Size: 202 KiB |
|
After Width: | Height: | Size: 203 KiB |
|
After Width: | Height: | Size: 230 KiB |
|
After Width: | Height: | Size: 419 KiB |
|
After Width: | Height: | Size: 580 KiB |
|
After Width: | Height: | Size: 466 KiB |
|
After Width: | Height: | Size: 1.5 MiB |
|
After Width: | Height: | Size: 257 KiB |
|
After Width: | Height: | Size: 428 KiB |
|
After Width: | Height: | Size: 229 KiB |
|
After Width: | Height: | Size: 663 KiB |
|
After Width: | Height: | Size: 736 KiB |
|
After Width: | Height: | Size: 692 KiB |
|
After Width: | Height: | Size: 548 KiB |
|
After Width: | Height: | Size: 479 KiB |
|
After Width: | Height: | Size: 519 KiB |
|
After Width: | Height: | Size: 485 KiB |
|
After Width: | Height: | Size: 575 KiB |
|
After Width: | Height: | Size: 734 KiB |
|
After Width: | Height: | Size: 526 KiB |
|
After Width: | Height: | Size: 260 KiB |
|
After Width: | Height: | Size: 461 KiB |
|
After Width: | Height: | Size: 555 KiB |
|
After Width: | Height: | Size: 431 KiB |
|
After Width: | Height: | Size: 488 KiB |
|
After Width: | Height: | Size: 501 KiB |
|
After Width: | Height: | Size: 498 KiB |
|
After Width: | Height: | Size: 517 KiB |
|
After Width: | Height: | Size: 314 KiB |
|
After Width: | Height: | Size: 293 KiB |
|
After Width: | Height: | Size: 352 KiB |
|
After Width: | Height: | Size: 379 KiB |
|
After Width: | Height: | Size: 296 KiB |
|
After Width: | Height: | Size: 226 KiB |
|
After Width: | Height: | Size: 454 KiB |
|
After Width: | Height: | Size: 1.1 MiB |
|
After Width: | Height: | Size: 1.2 MiB |
|
After Width: | Height: | Size: 563 KiB |
|
After Width: | Height: | Size: 305 KiB |
|
After Width: | Height: | Size: 197 KiB |
|
After Width: | Height: | Size: 442 KiB |
|
After Width: | Height: | Size: 827 KiB |
|
After Width: | Height: | Size: 676 KiB |
|
After Width: | Height: | Size: 919 KiB |
|
After Width: | Height: | Size: 264 KiB |
|
After Width: | Height: | Size: 647 KiB |
|
After Width: | Height: | Size: 1.9 MiB |
|
After Width: | Height: | Size: 455 KiB |
@@ -0,0 +1,63 @@
|
||||
{
|
||||
"version": 1,
|
||||
"name": "Things.World",
|
||||
"pageSize": 2048,
|
||||
"padding": 2,
|
||||
"pages": [
|
||||
{
|
||||
"file": "Things.World.atlas.0.png",
|
||||
"width": 1024,
|
||||
"height": 256
|
||||
}
|
||||
],
|
||||
"regions": [
|
||||
{
|
||||
"key": "Things/World/WorldObjects/Expanding/PirateOutpost",
|
||||
"page": 0,
|
||||
"x": 2,
|
||||
"y": 2,
|
||||
"w": 128,
|
||||
"h": 128
|
||||
},
|
||||
{
|
||||
"key": "Things/World/WorldObjects/Expanding/Town",
|
||||
"page": 0,
|
||||
"x": 132,
|
||||
"y": 2,
|
||||
"w": 128,
|
||||
"h": 128
|
||||
},
|
||||
{
|
||||
"key": "Things/World/WorldObjects/Expanding/TownRough",
|
||||
"page": 0,
|
||||
"x": 262,
|
||||
"y": 2,
|
||||
"w": 128,
|
||||
"h": 128
|
||||
},
|
||||
{
|
||||
"key": "Things/World/WorldObjects/Expanding/Village",
|
||||
"page": 0,
|
||||
"x": 392,
|
||||
"y": 2,
|
||||
"w": 128,
|
||||
"h": 128
|
||||
},
|
||||
{
|
||||
"key": "Things/World/WorldObjects/Expanding/VillageRough",
|
||||
"page": 0,
|
||||
"x": 522,
|
||||
"y": 2,
|
||||
"w": 128,
|
||||
"h": 128
|
||||
},
|
||||
{
|
||||
"key": "Things/World/WorldObjects/Expanding/VillageSavage",
|
||||
"page": 0,
|
||||
"x": 652,
|
||||
"y": 2,
|
||||
"w": 128,
|
||||
"h": 128
|
||||
}
|
||||
]
|
||||
}
|
||||
|
After Width: | Height: | Size: 22 KiB |
@@ -0,0 +1,127 @@
|
||||
{
|
||||
"version": 1,
|
||||
"name": "UI.Buttons",
|
||||
"pageSize": 2048,
|
||||
"padding": 2,
|
||||
"pages": [
|
||||
{
|
||||
"file": "UI.Buttons.atlas.0.png",
|
||||
"width": 1024,
|
||||
"height": 128
|
||||
}
|
||||
],
|
||||
"regions": [
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconAnimals",
|
||||
"page": 0,
|
||||
"x": 2,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconArchitect",
|
||||
"page": 0,
|
||||
"x": 68,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconAssign",
|
||||
"page": 0,
|
||||
"x": 134,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconFactions",
|
||||
"page": 0,
|
||||
"x": 200,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconHistory",
|
||||
"page": 0,
|
||||
"x": 266,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconMechanoids",
|
||||
"page": 0,
|
||||
"x": 332,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconMenu",
|
||||
"page": 0,
|
||||
"x": 398,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconQuests",
|
||||
"page": 0,
|
||||
"x": 464,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconResearch",
|
||||
"page": 0,
|
||||
"x": 530,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconRestrict",
|
||||
"page": 0,
|
||||
"x": 596,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconSchedule",
|
||||
"page": 0,
|
||||
"x": 662,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconWildlife",
|
||||
"page": 0,
|
||||
"x": 728,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconWork",
|
||||
"page": 0,
|
||||
"x": 794,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
},
|
||||
{
|
||||
"key": "UI/Buttons/MainButtons/IconWorld",
|
||||
"page": 0,
|
||||
"x": 860,
|
||||
"y": 2,
|
||||
"w": 64,
|
||||
"h": 64
|
||||
}
|
||||
]
|
||||
}
|
||||
|
After Width: | Height: | Size: 12 KiB |
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"version": 1,
|
||||
"name": "UI.Overlays",
|
||||
"pageSize": 2048,
|
||||
"padding": 2,
|
||||
"pages": [
|
||||
{
|
||||
"file": "UI.Overlays.atlas.0.png",
|
||||
"width": 256,
|
||||
"height": 256
|
||||
}
|
||||
],
|
||||
"regions": [
|
||||
{
|
||||
"key": "UI/Overlays/NeedsPower",
|
||||
"page": 0,
|
||||
"x": 2,
|
||||
"y": 2,
|
||||
"w": 128,
|
||||
"h": 128
|
||||
}
|
||||
]
|
||||
}
|
||||