CleverRaven/Cataclysm-DDA — pull request #8896 by jcd000 (2014-09-08 18:23:57+00:00)
Title: 1. All the tree harvesting functions that are based on seasonal harvest ...

...have been rolled into one.

reason: it was code duplication

2. The season & harvestable material from a tree has been Jsonified
reason: to make it easier to add new trees. Also build some kind of
framework around tree farming to later implement my other ideas (trees that
grow and die over time)

3. Trees are now harvestable once every year
reason: realism. before, a harvestable tree (or bush) would become a
simple tree (or shrub) on harvest. This makes it harder to stay in the
same location for too long, as the trees, shubs & forests are all
getting used up. This might be realistic for lots of gatherers, but in
the case of just one person, the forests should be a renewable resource.
(again i later plan to make trees plantable and make forests spawn trees
over time)

PS. I am not an experienced programmer and moreover have virtually no experience in c++.
I recently have spent lots of time over cata dda code and some c++ manuals just to understand what happens in the code.
This means that i expect my code to possibly be terrible and in need of rework.
I also half-expect that my new functions (esp in map.h) is a bad (performance-wise) move to implement this. I base this on the fact that both in the farming and the brewing code this haven't been done, but it was the solution i could find with my current knowledge.

Sooo, criticize at will, but please point me on how to make my code better if possible.. ;)