Skip to content

Beirdo/Lacuna-Automation

 
 

Repository files navigation

This is a simple client implementation for Lacuna Expanse (https://lacunaexpanse.com/),
with some ability to automate building on your planets.

This client is not as complete as Games::Lacuna::Client,
but it does make reasonable attempts to handle cache invalidation properly.

The main scripts of interest are:

activities
  Give a brief overview of what each planet is working on,
  both in the build queue and in the individual work queues.

show_planet [--body Name]
  Give a text representation of the status of one of your planets.

build_queue [--body Name] [--queue Name]
  Try to build / upgrade something on one of your planets,
  based on a queue of desired builds.
  This is intended to be run from cron, once per minute, for each planet.
  It doesn't do any real locking, though, and it outputs to stdout and stderr,
  so you probably want to put it in a wrapper script.
  Look at the sample build queue template for an idea of how to format the build queue.

park_ranger [--body Name]
  Try to throw parties in all parks on the planet.
  This is intended to be run from cron, once per minute,
  for each planet where you want continuous parties.

trashman [--body Name]
  Recycle some waste if capacity > half full.
  Distributes the waste proportionally to space available in ore, water, and energy.
  This will recycle waste in chunks of about 10 minutes duration.

scowler [--body Name]
  Shoot some waste into the local star if capacity > 3/4 full.

repairman [--body Name]
  Repair any damaged buildings.

archaeologist [--body Name] --ore type
  Search for a glyph in a bunch of ore.

trade_push --body Name --target Name --ship Name --cargo 'stuff' [--stay]
  Push some resources between two planets.
  The cargo is specified either as a single resource name
  (in which case the ship will be fully filled),
  or as a json hash of resource : quantity mappings.

exchange --body Colony --body Supplier [--ship NamePattern]
  Supply the Colony with as close to equal amounts of each food and ore
  as possible, keep it supplied with water and energy, and also cart away
  excess waste.  You must have ships parked at each planet, named to match
  the NamePattern (which defaults to the space-separated --body arguments).

cron_target.template
  Sample wrapper script for build_queue, park_ranger, repairman, and trashman.

project.pl [--body Name]
  Try to predict resource levels and completion times for a sequence of builds.
  Only supports buildings you already have at least one copy of on the planet,
  due to limitations of the API.

get_json [element/path [file ...]]
  This pretty-prints json, optionally selecting just a portion of the input
  (picking hash elements per the supplied path).
  Input is from stdin, or files named after the element path.

About

This is a client implementation and set of scripts for automating portions of playing Lacuna Expanse

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Perl 100.0%