Skip to content

Instantly share code, notes, and snippets.

@IntegerMan
Created October 21, 2019 04:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save IntegerMan/103c58cda354f3e32eb09854b5b425ef to your computer and use it in GitHub Desktop.
Save IntegerMan/103c58cda354f3e32eb09854b5b425ef to your computer and use it in GitHub Desktop.
let handleDogMove state otherActor =
if otherActor.ActorKind = Rabbit then
{state with World = {world with
Rabbit = {world.Rabbit with IsActive = false}
Doggo = {world.Doggo with Pos = pos}
}}
else
{state with SimState = Lost; World = {world with
Squirrel = {world.Squirrel with IsActive = false}
Doggo = {world.Doggo with Pos = pos}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment