A downloadable game for Windows and Linux

A game made for Lisp Game Jam 2017 (Easy Mode).

Overview

In the game you play as a "dog" whose task is to protect and herd a flock of sheep. The sheep will roam around the gameplay area, looking for food, and trying to avoid wolves and your character. After sheep are fed, you need to secure them by escorting them to the top part of the gameplay area. You need to save at least half of the flock to win a level.

The game employs a flocking algorithm for both sheep and wolves.

Installation

Ensure you have a working Lisp implementation (the game was developed on SBCL, but CCL should probably work too) and Quicklisp set up.

Download the files from this package. They'll contain two projects - the game, and the Parendeck 2D engine. Ensure both are visible in your Quicklisp's local projects (e.g. by symlinking those repositories in ~/quicklisp/local-projects).

Start your Lisp from the root directory of this game (lispjam-2017-04), and execute (ql:register-local-projects) and (ql:quickload :lispjam-2017-04-temporal). After that, run (ljgame:run).

I'll add binaries for Windows users when I figure out how to reliably deploy them. All help appreciated!

Gameplay

Controls

  • Left, Right - turn the player character
  • Up - accelerate
  • Down - slow down
  • F5 - toggle showing debugging information for flocking algorithm
  • F6 - toggle showing sight ranges of wolves and sheep
  • F7 - while holding it, you can use left mouse button to place a sheep, right mouse button to place a wolf, and middle mouse button to place a food pellet

Mechanics

Sheep want to eat food pellets. Eating two will turn the sheep white and enlarge it; this indicates that it is ready to be evacuated.

Wolves want to eat sheep. You lose the game if wolves eat more than half of your sheep.

Eating, in both cases, takes time, during which the wolf/sheep won't be moving much.

Technical

Both sheep and wolves are driven using a flocking algorithm. They'll group together within their respective species, chase food when hungry, run away from danger, and - most importantly - run away from player character. This last thing is what gives you the ability to direct sheep and chase away wolves.

All entities have limited sight range, so they'll only notice friends, food and danger in close proximity.

To view the realtime computation performed by entities, use F5 key. To see the sight ranges, use F6 key.

Troubleshooting

Game doesn't work - crashes, throws exceptions, etc.

E-mail me. If you can find engine.log file somewhere around the game directory, please send it to me too.

Game seems not able to find assets

Verify your Lisp's working directory is set to root of this repository. In Emacs / SLIME, you can use ",cd" in REPL to change the working directory.

Game runs slow

The code is pretty crappy (happens when writing in a hurry to meet the contest deadline), so it's nowhere near possible peak performance. I might optimize it in the future if there's interest.

To help me do that, please find and e-mail me the file perf-report.html. Also if you're using SBCL, try and run the game with (ljgame:run-with-profiling), and send me the file sb-sprof.txt.

Credits

This game's background was composed with assets from Tiny16 pack by Sharm.

The book "The Nature of Code" turned out to be very helpful in designing and implementing the flocking algorithm.

Download

Download
lispjam-deploy.zip 756 kB
Download
lispjam-win64.zip 20 MB

Install instructions

Installation

Ensure you have a working Lisp implementation (the game was developed on SBCL, but CCL should probably work too) and Quicklisp set up.

Download the files from this package. They'll contain two projects - the game, and the Parendeck 2D engine. Ensure both are visible in your Quicklisp's local projects (e.g. by symlinking those repositories in ~/quicklisp/local-projects).

Start your Lisp from the root directory of this game (lispjam-2017-04), and execute (ql:register-local-projects) and (ql:quickload :lispjam-2017-04-temporal). After that, run (ljgame:run).

I'll add binaries for Windows users when I figure out how to reliably deploy them. All help appreciated!

Leave a comment

Log in with itch.io to leave a comment.