Skip to content

Commit

Permalink
fix scenarios using x and y in world description
Browse files Browse the repository at this point in the history
  • Loading branch information
byorgey committed Jun 25, 2024
1 parent 04e5bd8 commit 3ad94a4
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion data/scenarios/Challenges/Ranching/beekeeping.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@ world:
in
overlay
[ {grass}
, mask (flowers && (x + y) % 3 == 0) {wildflower}
, mask (flowers && (x - y) % 3 == 0) {wildflower}
, mask (rubble && (x + y) % 2 == 0) {rock}
, mask rock {rock}
, mask trees {tree}
Expand Down
4 changes: 2 additions & 2 deletions data/scenarios/Challenges/gallery.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,8 @@ world:
dsl: |
overlay
[ {terrain: stone}
, if (x/5 + y/5) % 2 == 0 then {terrain: dirt} else {blank}
, if (((x + 3) % 20)/11 + ((y + 3) % 20)/11) == 0 then {terrain: grass} else {blank}
, if (x/5 + (-y)/5) % 2 == 0 then {terrain: dirt} else {blank}
, if (((3 - y) % 20)/11 + ((x + 3) % 20)/11) == 0 then {terrain: grass} else {blank}
]
upperleft: [0, 11]
offset: false
Expand Down
2 changes: 1 addition & 1 deletion data/scenarios/Challenges/wave.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ world:
dsl: |
overlay
[ {dirt, water}
, if (x + y / 2) % 5 == 0 then {dirt, wavy water} else {blank}
, if (x / 2 - y) % 5 == 0 then {dirt, wavy water} else {blank}
]
upperleft: [-3, 6]
offset: false
Expand Down
2 changes: 1 addition & 1 deletion data/scenarios/Fun/horton.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ world:
[ {dirt}
, mask (patch) {boulder}
, mask (prize) {flower}
, mask (y < -80 || y > 80 || x < -60 || x > 60) (overlay [{water}])
, mask (x < -80 || x > 80 || y < -60 || y > 60) (overlay [{water}])
]
upperleft: [-4, 4]
offset: false
Expand Down
4 changes: 2 additions & 2 deletions data/scenarios/Testing/1535-ping/1535-in-range.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,8 +75,8 @@ world:
dsl: |
overlay
[ {terrain: stone}
, if (x/5 + y/5) % 2 == 0 then {terrain: dirt} else {blank}
, if ((x + 3) % 19)/12 + (y % 19)/12 == 0 then {terrain: grass} else {blank}
, if (x/5 + (-y)/5) % 2 == 0 then {terrain: dirt} else {blank}
, if ((3 - y) % 19)/12 + (x % 19)/12 == 0 then {terrain: grass} else {blank}
]
palette:
'B': [blank, null, base]
Expand Down
4 changes: 2 additions & 2 deletions data/scenarios/Testing/1535-ping/1535-out-of-range.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ world:
dsl: |
overlay
[ {terrain: blank}
, if (x/4 + y/4) % 2 == 0 then {terrain: dirt} else {blank}
, if ((x + 3) % 19)/12 + (y % 19)/12 == 0 then {terrain: grass} else {blank}
, if (x/4 + (-y)/4) % 2 == 0 then {terrain: dirt} else {blank}
, if ((3 - y) % 19)/12 + (x % 19)/12 == 0 then {terrain: grass} else {blank}
]
palette:
'B': [stone, null, base]
Expand Down

0 comments on commit 3ad94a4

Please sign in to comment.