-
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
9 changed files
with
162 additions
and
9 deletions.
There are no files selected for viewing
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 |
---|---|---|
|
@@ -62,3 +62,4 @@ Achievements | |
1747-volume-command.yaml | ||
1777-capability-cost.yaml | ||
1775-custom-terrain.yaml | ||
1642-biomes.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,97 @@ | ||
version: 1 | ||
name: Demo sow command | ||
description: | | ||
Demonstrate growth restrictions. | ||
objectives: | ||
- id: harvested | ||
goal: | ||
- | | ||
`harvest` both `wheat`{=entity}. | ||
Only one should grow back. | ||
condition: | | ||
as base { | ||
c <- count "wheat"; | ||
return $ c == 2; | ||
} | ||
- id: western_wheat_regrew | ||
optional: true | ||
goal: | ||
- | | ||
Wheat in grass must not regrow | ||
condition: | | ||
observer <- robotnamed "observer"; | ||
as observer { | ||
ishere "wheat"; | ||
} | ||
prerequisite: harvested | ||
- goal: | ||
- | | ||
Go to the stone patch. | ||
This takes at least 10 ticks, | ||
by which time the | ||
`wheat`{=entity} would have grown back. | ||
Fails if the western wheat does grow back. | ||
condition: | | ||
goalbot <- robotnamed "goalbot"; | ||
baseLoc <- as base {whereami}; | ||
as goalbot { | ||
goalLoc <- whereami; | ||
return $ baseLoc == goalLoc; | ||
} | ||
prerequisite: | ||
logic: | ||
and: | ||
- harvested | ||
- not: western_wheat_regrew | ||
solution: | | ||
move; harvest; | ||
move; harvest; | ||
move; | ||
move; move; move; move; move; | ||
move; move; move; move; move; | ||
robots: | ||
- name: base | ||
dir: east | ||
devices: | ||
- treads | ||
- scythe | ||
- name: observer | ||
dir: east | ||
system: true | ||
- name: goalbot | ||
dir: east | ||
system: true | ||
entities: | ||
- name: wheat | ||
display: | ||
char: 'w' | ||
attr: gold | ||
description: | ||
- Grain | ||
properties: [known, pickable, growable] | ||
growth: [2, 4] | ||
biomes: [dirt] | ||
- name: scythe | ||
display: | ||
char: 'y' | ||
description: | ||
- Curved blade on a long handle | ||
properties: [known] | ||
capabilities: | ||
- harvest | ||
biomes: [dirt] | ||
known: [flower] | ||
world: | ||
default: [blank] | ||
palette: | ||
'.': [grass] | ||
'd': [dirt] | ||
's': [stone, null, goalbot] | ||
'w': [grass, wheat, observer] | ||
'W': [dirt, wheat] | ||
'B': [grass, null, base] | ||
upperleft: [-1, 1] | ||
map: | | ||
..dd.......... | ||
BwWd.........s | ||
.............. |
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
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