We'd like to share early info on one of our key in-game mechanics: plant growth.

Posted by NaturallyIntelligent on Jan 4th, 2015

From Fruit to Seed to Plant

Patchman is capable of growing a wide variety of plants. If he's in the mood to. The most basic ones are apples and oranges. Like most of the plants they have a three stage lifecycle. Starting with a fruit, you can either eat it or throw it. When thrown on the ground, eventually it starts to rot. If it's on soil it rots faster. Once rotted it leaves behind a number of seeds. These seeds can be picked up and saved for later, or left to hatch and sprout:



What does he need so many oranges for? What does he need so many oranges for?

Once sprouted on wet soil the seed grows into a plant. Oranges and apples grow into trees, and for the purposes of demonstration the growth rate has been accelerated. The trees have more complex behavior than the seeds or fruits, they can be injured and require water to grow. The water is drawn from the soil and the soil can be watered with the aid of a watering can or rain. When the plant has reached a certain stage it can bear fruit and then these fruit drop off the tree and are available to the player. The old tree now requires a hoe to destroy it and free the soil for the next plant.

The trees can die on their own but right now we haven't added any animations for their death. They just disappear after a certain age, or once you hoe them to 0 health, or maybe they are damaged in other ways (yet to be revealed).

High Resolution Video (720p @ 60fps available)



Too many butterflies...?

Credit for the art goes to Ihor Motuz (character, animated plants, house)

and Karly MacDonald (scenery plants, backgrounds).

Development Outline

Internally these are represented as objects, there are separate objects for seed, fruit, and tree. Apples and oranges are similar enough that they don't need separate classes, but many of the other plants have their own classes:

----------------------------------------------------------------- ----- SEED ------------------------------------------------------ ----------------------------------------------------------------- function seed:new() function seed:init(x, y, kind) function seed:step() ----------------------------------------------------------------- ----- FRUIT ----------------------------------------------------- ----------------------------------------------------------------- function fruit:new() function fruit:init(x, y, kind) function fruit:step() function fruit:build_body(x, y) function fruit:decay_deck() ----------------------------------------------------------------- ----- TREE ------------------------------------------------------ ----------------------------------------------------------------- function tree:new() function tree:init(x, y, kind) function tree:step() function tree:wipe() function tree:visual_pause_step() function tree:activate() function tree:inactivate()

The apples and oranges are fairly realistic but as you explore further into the game the plants become weirder and stranger and more useful and... more fun!