Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Meeting other robots #920

Merged
merged 21 commits into from
Dec 22, 2022
Merged

Meeting other robots #920

merged 21 commits into from
Dec 22, 2022

Conversation

byorgey
Copy link
Member

@byorgey byorgey commented Dec 16, 2022

Closes #306. Closes #931.

  • Renamed robot type to actor in anticipation of meeting other things besides robots.
  • meet : cmd (unit + actor) returns an arbitrary actor within Manhattan distance 1, if any.
  • meetAll : (b -> actor -> cmd b) -> b -> cmd b will run on every nearby actor.
  • Added antenna device to provide the commands.
  • Added "make a friend" challenge that requires the use of meet.

In preparation for making a `Location` type to represent world locations.
It had `loc` and `north` swapped, so `initRobot` was always creating
robots at location `(0,1)` with a *direction vector* given by whatever
the location was supposed to be, which makes no sense.

Now that `Location` and `Heading` are distinct types, this became a
type error.
Still need to add `meetAll`, and create a device that provides `meet` capability.
@byorgey byorgey marked this pull request as ready for review December 21, 2022 21:11
@byorgey byorgey requested review from xsebek and kostmo December 21, 2022 21:11
Copy link
Member

@kostmo kostmo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like it!

data/scenarios/Challenges/_friend/cat.sw Outdated Show resolved Hide resolved
data/scenarios/Challenges/friend.yaml Outdated Show resolved Hide resolved
byorgey and others added 3 commits December 22, 2022 06:05
Co-authored-by: Karl Ostmo <kostmo@gmail.com>
No longer necessary to wait after giving fish to the cat.
@byorgey byorgey added the merge me Trigger the merge process of the Pull request. label Dec 22, 2022
@mergify mergify bot merged commit 926cede into main Dec 22, 2022
@mergify mergify bot deleted the feature/meet branch December 22, 2022 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge me Trigger the merge process of the Pull request.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rename robot type to be more inclusive Commands to meet other robots
2 participants