Plant growth

Hi,

Just added in when trees grow - basically you plant certain type of seed, after a period of time, it starts growing. Now at the moment, I’m just using a simple integer value for the grow time, I guess it be better if I could realistically in virtual game terms set a given time period, such as grow in a day or something, (can’t possibly do it grow in 1 years time, lol!). I was thinking of getting the start time when something is planted, set that in the tree class, then set an end time, something like:

Something like this: (When seed is planted)


long lEndTime = new Date().getTime() + 1000;

Then when lEndTime is reached, grow tree. I could also use a timer event (extend the TimerTask). What I want it to do is grow the trees at the same rate
on every computer it runs on.

Advice is much appreciated.

Thanks