-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
433 additions
and
64 deletions.
There are no files selected for viewing
4 changes: 3 additions & 1 deletion
4
data/scenarios/Testing/1780-structure-merge-expansion/00-ORDER.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
nonoverlapping-structure-merge.yaml | ||
root-map-expansion.yaml | ||
structure-composition.yaml | ||
sequential-placement.yaml | ||
sequential-placement.yaml | ||
coordinate-offset-propagation.yaml | ||
simultaneous-north-and-west-offset.yaml |
79 changes: 79 additions & 0 deletions
79
data/scenarios/Testing/1780-structure-merge-expansion/coordinate-offset-propagation.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
version: 1 | ||
name: Structure coordinate offset propagation | ||
author: Karl Ostmo | ||
description: | | ||
If a structure incorporates subplacements | ||
entailing negative offsets, its coordinate origin must be shifted. | ||
The updated coordinate origin should be propagated to parent structures | ||
and utilized to offset placement. | ||
robots: | ||
- name: base | ||
dir: north | ||
objectives: | ||
- goal: | ||
- Enjoy the view. | ||
condition: | | ||
return true | ||
solution: | | ||
noop | ||
known: [boulder, log, pixel (R), pixel (G), pixel (B), gold] | ||
world: | ||
structures: | ||
- name: micro | ||
structure: | ||
mask: '.' | ||
palette: | ||
'x': [stone, gold] | ||
map: | | ||
xx | ||
- name: block | ||
structure: | ||
mask: '.' | ||
palette: | ||
'x': [stone, pixel (R)] | ||
map: | | ||
xx | ||
xx | ||
- name: master | ||
structure: | ||
mask: '.' | ||
palette: | ||
'x': [stone, pixel (B)] | ||
placements: | ||
- src: block | ||
offset: [0, 1] | ||
- src: micro | ||
offset: [-2, 0] | ||
map: | | ||
..x | ||
..x | ||
..x | ||
- name: final | ||
structure: | ||
mask: '.' | ||
palette: | ||
'x': [stone, pixel (G)] | ||
placements: | ||
- src: master | ||
map: | | ||
x | ||
x | ||
x | ||
x | ||
dsl: | | ||
overlay | ||
[ {grass} | ||
, mask (y > -4 && y < 4 || x > -4 && x < 4) {stone} | ||
, mask (y > -2 && y < 2 || x > -2 && x < 2) {ice} | ||
, mask (y > -1 && y < 1 || x > -1 && x < 1) {dirt} | ||
] | ||
palette: | ||
'Ω': [grass, erase, base] | ||
mask: '.' | ||
placements: | ||
- src: final | ||
offset: [0, 0] | ||
upperleft: [0, 0] | ||
map: | | ||
Ω |
56 changes: 56 additions & 0 deletions
56
.../scenarios/Testing/1780-structure-merge-expansion/simultaneous-north-and-west-offset.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
version: 1 | ||
name: Northwest sibling structure coordinate offsets | ||
author: Karl Ostmo | ||
description: | | ||
Make sure that the second sibling is displayed correctly when there | ||
is a simultaneous negative-x and positive-y offset on the first sibling. | ||
robots: | ||
- name: base | ||
dir: north | ||
loc: [0, 2] | ||
objectives: | ||
- goal: | ||
- Enjoy the view. | ||
condition: | | ||
return true | ||
solution: | | ||
noop | ||
known: [pixel (R), gold] | ||
world: | ||
structures: | ||
- name: micro | ||
structure: | ||
mask: '.' | ||
palette: | ||
'x': [stone, gold] | ||
map: | | ||
x | ||
- name: block | ||
structure: | ||
mask: '.' | ||
palette: | ||
'x': [stone, pixel (R)] | ||
map: | | ||
xx | ||
xx | ||
- name: master | ||
structure: | ||
mask: '.' | ||
placements: | ||
- src: micro | ||
offset: [-1, 1] | ||
- src: block | ||
map: "" | ||
dsl: | | ||
overlay | ||
[ {grass} | ||
, mask (y > -4 && y < 4 || x > -4 && x < 4) {stone} | ||
, mask (y > -2 && y < 2 || x > -2 && x < 2) {ice} | ||
, mask (y > -1 && y < 1 || x > -1 && x < 1) {dirt} | ||
] | ||
mask: '.' | ||
placements: | ||
- src: master | ||
offset: [0, 0] | ||
upperleft: [0, 0] | ||
map: "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.