Skip to content
This repository has been archived by the owner on Apr 2, 2021. It is now read-only.

Latest commit

 

History

History
26 lines (24 loc) · 750 Bytes

README.md

File metadata and controls

26 lines (24 loc) · 750 Bytes

foodchain

A predator-prey simulation in p5.js that can be played here.

Controls:

If you do not have a keyboard, a menu may be used inside the simulation.

  • Mouse to place a creature
  • Alt to toggle avoidance lines
  • Ctrl to toggle perception visualization
  • Enter to clear the screen
  • Spacebar to toggle targeting lines
  • 0-9 to select a preset
  • G to toggle species pie chart
  • M to cycle between display modes (dark mode, line mode)
  • N to toggle fading based on nutrition level
  • O to toggle motion blur
  • Q to toggle menu visibility

Creature types:

Press one of these keys to select a creature, then place with the mouse:

  • B = prey
  • F = food
  • H = hive
  • P = predator
  • S = swarm
  • V = fungus