REAMDE.md 1.5 KB

PIG

[](https://lut.im/HcRdslCjOf/U1376nq1P2LLSNaw.png)

PIG is a Procedural Island Generator. It is written in C++11. As of now it is a set of classes that generate differents maps for a island based upon eachother. It also includes an application for viewing the maps it makes, made with SFML. This repository includes documentation written in dutch in the docs/ folder.

Installation

To use the viewing application you will need to install SFML. You can download it from http://www.sfml-dev.org/ or you can install it using your operatings package manager. On Ubuntu:

sudo apt-get install libsfml-dev

To build you'll also need g++ and make. To install these on Ubuntu run:

sudo apt-get install g++ make

After installing these tools, you can clone this git repository and build it using:

make

And run it with:

./pws

The controls of the viewing application

Global controls

  • 'n' -> initialize a new heightmap
  • 'p' -> apply one pass to the current heightmap
  • 'f' -> finish the current heightmap
  • 'c' -> create a new map and immediately finish it
  • 'i' -> change heightmap smoothing to interpolation
  • 'a' -> change heightmap smoothing to average
  • 's' -> save the current screen to "screenshot.png"
  • 'd' -> toggle display of water
  • 'e' -> add rivers
  • 'q' -> update rivers
  • Esc -> close the program

Switch between views using the number keys

  • '1' -> heightmap view
  • '2' -> simple map view
  • '3' -> land map view
  • '4' -> lighted map view