Basic Terrarium – Plants and Herbivores

The bulk of our work in setting up our terrarium is going to be building the plants, agents that eat plants (herbivores), and agents that eat agents that eat plants (carnivores). We will start with our most basic form of terrarium inhabitant, the plant. Terrarium plants are not unlike their natural cousins; they continually increase in energy by just existing. When they reach a certain size, they also begin discharging seeds that produce more plants and so on. Open up Unity and follow along to create our first Terrarium inhabitant, the plant:

  1. Open the Terrarium scene where we last left it and from the menu select GameObject | Create Empty. Rename the new object Plant.
  2. Drag the Plant object onto the ...

Get Learn Unity ML-Agents - Fundamentals of Unity Machine Learning now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.