L-seed-0.1: Plant growing programming game

Lseed.Logic

Description

This module is mostly a general dump...

Synopsis

Documentation

lightAngle :: Double -> AngleSource

Given the fraction of the time passed, returnes the angle of the sunlight

remainingGrowth :: (a -> GrowthState) -> Planted a -> DoubleSource

Calculates the length to be grown

applyGenome :: RandomGen g => Angle -> g -> GrowingGarden -> GrowingGardenSource

For all Growing plants that are done, find out the next step This involves creating new plants if some are done

growPlanted :: GrowingPlanted -> Double -> Double -> GrowingPlantedSource

Applies an L-System to a Plant, putting the new length in the additional information field

applyGrowth :: Double -> GrowingPlanted -> GrowingPlantedSource

Applies Growth at given fraction, leaving the target length in place