diff --git a/data/entities.yaml b/data/entities.yaml index e3a85d7700..da5f4f7d73 100644 --- a/data/entities.yaml +++ b/data/entities.yaml @@ -497,7 +497,7 @@ description: - A robot with a boat equipped can float on top of water without drowning. - | - Note: most devices are automatically equipped on robots that + **NOTE:** most devices are automatically equipped on robots that will require them; but this doesn't work in the case of boats since floating is not associated with any particular command. To manually ensure a boat is equipped on a robot, just add the special command `require "boat"` to the robot's program. diff --git a/data/scenarios/Challenges/Ranching/gated-paddock.yaml b/data/scenarios/Challenges/Ranching/gated-paddock.yaml index 144740893b..9552aaa962 100644 --- a/data/scenarios/Challenges/Ranching/gated-paddock.yaml +++ b/data/scenarios/Challenges/Ranching/gated-paddock.yaml @@ -142,7 +142,7 @@ objectives: create specialDrill; equip specialDrill; - // NOTE: System robots can walk on water + // **NOTE:** System robots can walk on water // so we only need this if we want to // demo the algorithm with a player robot. // create "boat"; diff --git a/data/scenarios/Tutorials/bind2.yaml b/data/scenarios/Tutorials/bind2.yaml index c763cb4351..71c562b717 100644 --- a/data/scenarios/Tutorials/bind2.yaml +++ b/data/scenarios/Tutorials/bind2.yaml @@ -13,7 +13,7 @@ objectives: - | Build a robot to retrieve and restore the mystery artifact to its proper place! - | - Note: If you find yourself stuck, you can select "Start over" from + **NOTE:** If you find yourself stuck, you can select "Start over" from the "Quit" (**Ctrl+Q**) dialog. condition: | try { @@ -38,7 +38,7 @@ objectives: For example, `grab` has type `cmd text`{=type}, and returns the name of the grabbed entity as a text value. - | - To use the result of a command later, you need "bind notation", which + To use the result of a command later, you need _bind notation_, which consists of a variable name and a leftwards-pointing arrow before the command. For example: - | diff --git a/data/scenarios/Tutorials/build.yaml b/data/scenarios/Tutorials/build.yaml index 353823b82e..2fa71beb8d 100644 --- a/data/scenarios/Tutorials/build.yaml +++ b/data/scenarios/Tutorials/build.yaml @@ -18,7 +18,7 @@ objectives: Build a robot to harvest the `flower`{=entity} and place it next to the `water`{=entity}. - | - TIP: Newly built robots start out facing the same + **TIP:** Newly built robots start out facing the same direction as their parent, which in the tutorials will always be north. condition: | try { diff --git a/data/scenarios/Tutorials/conditionals.yaml b/data/scenarios/Tutorials/conditionals.yaml index 30b7697432..c5f83e2e10 100644 --- a/data/scenarios/Tutorials/conditionals.yaml +++ b/data/scenarios/Tutorials/conditionals.yaml @@ -42,13 +42,13 @@ objectives: must also be in curly braces: the type of `build` is `{cmd a} -> cmd robot`{=type}. - | - TIP: Note that `if` requires a `bool`{=type}, not a `cmd bool`{=type}! So you cannot directly say + **TIP:** Note that `if` requires a `bool`{=type}, not a `cmd bool`{=type}! So you cannot directly say `if (ishere "very small rock") {...} {...}`{=snippet}. Instead you can write `b <- ishere "very small rock"; if b {...} {...}`{=snippet}. You might enjoy writing your own function of type `cmd bool -> {cmd a} -> {cmd a} -> cmd a`{=type} to encapsulate this pattern. - | - TIP: the two branches of an `if` must have the same type. In particular, + **TIP:** the two branches of an `if` must have the same type. In particular, `if ... {grab} {}`{=snippet} is not allowed, because `{grab}` has type `{cmd text}`{=type} whereas `{}` has type `{cmd unit}`{=type}. In this case `{grab; return ()}` has the right type. diff --git a/data/scenarios/Tutorials/craft.yaml b/data/scenarios/Tutorials/craft.yaml index 60307372b2..885914798c 100644 --- a/data/scenarios/Tutorials/craft.yaml +++ b/data/scenarios/Tutorials/craft.yaml @@ -16,7 +16,7 @@ objectives: - Your goal is to make a `branch predictor`{=entity}, so you will have to make some `branch`{=entity}es first. - | - Note: when used after opening quotes in the REPL, the Tab key can cycle through + **NOTE:** when used after opening quotes in the REPL, the Tab key can cycle through possible completions of a name. E.g., type: - | `> make "br[Tab][Tab]`{=snippet} diff --git a/data/scenarios/Tutorials/def.yaml b/data/scenarios/Tutorials/def.yaml index c61de73268..97ebe3d67e 100644 --- a/data/scenarios/Tutorials/def.yaml +++ b/data/scenarios/Tutorials/def.yaml @@ -20,15 +20,15 @@ objectives: use of new definitions, it should be possible to complete this challenge in just a few lines of code. - | - TIP: your base is at coordinates `(0,0)`, and the `flower`{=entity} is at `(16,4)`, which + **TIP:** your base is at coordinates `(0,0)`, and the `flower`{=entity} is at `(16,4)`, which you can confirm by clicking in the world map panel. When you click on a cell, its contents and coordinates are shown in the lower left. - | - TIP: the type annotation in a definition is optional. You could also write + **TIP:** the type annotation in a definition is optional. You could also write `def m4 = move; move; move; move end`{=snippet}, and Swarm would infer the type of `m4`{=snippet}. - | - TIP: writing function definitions at the prompt is annoying. + **TIP:** writing function definitions at the prompt is annoying. You can also put definitions in a `.sw`{=path} file and load it with the `run` command. Check out https://github.com/swarm-game/swarm/tree/main/editors diff --git a/data/scenarios/Tutorials/farming.yaml b/data/scenarios/Tutorials/farming.yaml index 9908a8d6a2..f40b798597 100644 --- a/data/scenarios/Tutorials/farming.yaml +++ b/data/scenarios/Tutorials/farming.yaml @@ -27,7 +27,7 @@ objectives: a field of `lambda`{=entity}s and then program one or more robots to harvest them in an automated way. - | - TIP: the `ishere` command can be used to test for the presence of a + **TIP:** the `ishere` command can be used to test for the presence of a (fully-grown) `lambda`{=entity}, and the `has` command can be used to test whether a robot has a `lambda`{=entity} in its inventory. condition: | diff --git a/data/scenarios/Tutorials/move.yaml b/data/scenarios/Tutorials/move.yaml index 23d975e4b3..0d6be79e72 100644 --- a/data/scenarios/Tutorials/move.yaml +++ b/data/scenarios/Tutorials/move.yaml @@ -23,7 +23,9 @@ objectives: - | Previously you could move twice by chaining the move command: - | + ``` move; move + ``` - To reuse that command without having to retype it press the upward arrow on your keyboard. This will allow you to select previous commands. - Ahead of you is a six steps long corridor. Move to its end, i.e. the diff --git a/data/scenarios/Tutorials/place.yaml b/data/scenarios/Tutorials/place.yaml index 592cd83874..e176379730 100644 --- a/data/scenarios/Tutorials/place.yaml +++ b/data/scenarios/Tutorials/place.yaml @@ -27,7 +27,7 @@ objectives: - Your goal is to collect 6 `spruce`{=entity} trees. You can speed this up by planting more trees. - | - TIP: You can get a sneak peak at a feature we will explain later and type: + **TIP:** You can get a sneak peak at a feature we will explain later and type: ``` def t = move; place "spruce"; harvest; end ``` diff --git a/data/scenarios/Tutorials/types.yaml b/data/scenarios/Tutorials/types.yaml index d479609d13..4bc4486e84 100644 --- a/data/scenarios/Tutorials/types.yaml +++ b/data/scenarios/Tutorials/types.yaml @@ -12,7 +12,7 @@ objectives: its type will be displayed in gray text at the top right of the window. - For example, if you try typing `move`, you can see that it has type `cmd unit`{=type}, which means that `move` is a command which - returns a value of the unit type (also written `()`). + returns a value of the `unit`{=type} type (also written `()`). - As another example, you can see that `turn` has type `dir -> cmd unit`{=type}, meaning that `turn` is a function which takes a direction as input and results in a command. diff --git a/data/scenarios/Tutorials/world101.yaml b/data/scenarios/Tutorials/world101.yaml index d9ce6de01a..5fdca2d6bf 100644 --- a/data/scenarios/Tutorials/world101.yaml +++ b/data/scenarios/Tutorials/world101.yaml @@ -43,7 +43,7 @@ objectives: - Now that you have a harvester, you can use `harvest` instead of `grab` whenever you pick up a growing item (check for the word "growing" at the top of the item description), to leave behind a seed that will regrow. - - "TIP: since you only have a single harvester device for now, whenever you + - "**TIP:** since you only have a single harvester device for now, whenever you send out a robot to harvest something, try programming it to come back to the base when it is done. Then, execute `salvage` to get the harvester back, so you can reuse it in another robot later." @@ -51,7 +51,7 @@ objectives: define and use parameterized commands. Scan some things and use the process of elimination to find one. Since lambdas regrow, once you find one, try getting it with `harvest`. - - "TIP: remember that you can click on cells in the world to see their + - "**TIP:** remember that you can click on cells in the world to see their coordinates." condition: | try { as base {has "lambda"} } {return false}