Author Topic: Farming  (Read 912 times)

Offline Chris

  • Game Owner
  • Level 35
  • *
  • Posts: 2,217
  • Reputation: +28/-1
    • View Profile
Farming
« on: October 12, 2011, 02:45:44 PM »
For a medieval themed game. The basic mechanic is standard energy bar which replenish over time, you use it to perform actions.

Each player has some amount of land, he can use it grow plants and sell for profit. He can also raise some livestock. If the player doesn't want to deal with farming he has an option to rent the land and get a regular income (much less profitable than growing and selling stuff but he doesn't need to spend energy).

Now, how this system could work?
(agriculture will be quite important for that game so I'm looking for medium or heavy detail solutions)



I'm thinking about something along the lines: you spend some energy to plow and seed the field, then wait, then spend energy again to make harvest and the cycle repeats. I'm not sure how to fit there the livestock, also how to deal with the waiting part.

Offline Barrikor

  • Level 21
  • *
  • Posts: 248
  • Reputation: +3/-0
    • View Profile
Re: Farming
« Reply #1 on: October 12, 2011, 04:56:31 PM »
I'm not sure how to fit there the livestock, also how to deal with the waiting part.

Since plowing is an important factor, maybe livestock could use unplowed fields + some sort of upkeep
Projects: Pith Framework (at 0.5), CactusGUI (at 0.3)

Offline Chris

  • Game Owner
  • Level 35
  • *
  • Posts: 2,217
  • Reputation: +28/-1
    • View Profile
Re: Farming
« Reply #2 on: October 12, 2011, 05:27:45 PM »
Livestock could produce manure, which boosts plants production, so it would be one reason to keep your estate diversified.

As for unploved fields for livestock, in the past they were leaving 1/4 of the land "unoccupied" to let the ground "rest". I guess this could be used as pasture? Later they invented 1/3 system (rotation of crops) where no land had to rest, which would mean no more free land for grazing...
Nowadays, the land has classes (based on fertility) and the worse one is used as pasture. That's how it goes for history and realism, not sure if usable for a game.

Offline pirategaspard

  • Level 9
  • *
  • Posts: 46
  • Reputation: +1/-0
    • View Profile
    • PointClickPress
Re: Farming
« Reply #3 on: October 12, 2011, 08:47:50 PM »
Livestock and Crops could work similar, each with growing and harvesting time and requirements

Crops
Require:
fields plowed
Harvest:
x time until harvest
Effects:
after harvest fields are unfertilized & unplowed
Extra:
fertilized fields increase yield, and/or decrease harvest time

Livestock
Require:
fields are grass
Harvest:
x time until harvest (slaughter for meat)
y time until harvest (milk - possibly a limit on the times you could get milk)
Effects:
z time increases field fertalization
Extra:
x time for livestock to deplete grass and to turn into unplowed field

Fields
Properties:
Soil is:
  • plowed
  • unplowed
  • grass
Fertilized: 0-100%
Extra:
x time for unplowed to turn into grass
y time to plow unplowed field
z time to plow grass field
livestock could be used to reduce plowing time.


Offline Harkins

  • Level 28
  • **
  • Posts: 424
  • Reputation: +11/-2
  • Coder, blogger, entrepreneur.
    • View Profile
    • Push CX - Blog
Re: Farming
« Reply #4 on: October 12, 2011, 10:37:50 PM »
For a medieval themed game. The basic mechanic is standard energy bar which replenish over time, you use it to perform actions.

I like to call these fun meters. When the meter runs out, you're not allowed to enjoy the game anymore.

Visit #bbg on irc.freenode.net to talk browser games anytime.

Offline Harkins

  • Level 28
  • **
  • Posts: 424
  • Reputation: +11/-2
  • Coder, blogger, entrepreneur.
    • View Profile
    • Push CX - Blog
Re: Farming
« Reply #5 on: October 12, 2011, 10:42:54 PM »
As for unploved fields for livestock, in the past they were leaving 1/4 of the land "unoccupied" to let the ground "rest". I guess this could be used as pasture? Later they invented 1/3 system (rotation of crops) where no land had to rest, which would mean no more free land for grazing...
Nowadays, the land has classes (based on fertility) and the worse one is used as pasture. That's how it goes for history and realism, not sure if usable for a game.

You could use Conway's Game of Life to iterate which fields grow and which don't. Make it so player's can't choose every individual field they get to plant, they have to click groups at once, like a stamp. Then the players who best envision the way the field will grow and evolve will get more crops - player skill, not character skill.

Visit #bbg on irc.freenode.net to talk browser games anytime.

Offline Chris

  • Game Owner
  • Level 35
  • *
  • Posts: 2,217
  • Reputation: +28/-1
    • View Profile
Re: Farming
« Reply #6 on: October 13, 2011, 03:44:30 AM »
For fields harvest and milking cows I could have just two timers. But what about slaughtering? I mean these animals should be in different stages of growth and you definitly don't want to slaughter all animals of the same type at once (you want to leave at least 2 for further breeding :D). It can't work the same was as harvest.

I'm also concerned with amount of data (coding issue), it should be as light as possible (so no separate bookkeeping of every single chicken). I'm thinking about 5 separate variables per animal type defining the age of animal. So pig1 is newborn, pig2 is young, pig3 is can breed, pig4 can breed and is best for slaughter, pig5 is old one and bring less meat when slaughtered since you waited too long. Every 5 hours (global timer, not stored on the player table) all animals move 1 age class up.


For a medieval themed game. The basic mechanic is standard energy bar which replenish over time, you use it to perform actions.

I like to call these fun meters. When the meter runs out, you're not allowed to enjoy the game anymore.
LOL, there are only 2 options for a browser game, either the meter/points/turns or the clock. There are no other options. I find the meter much more civilized and human friendly than the clock where you have to check every X minutes/hours.
« Last Edit: October 13, 2011, 03:46:58 AM by Chris »

Offline pirategaspard

  • Level 9
  • *
  • Posts: 46
  • Reputation: +1/-0
    • View Profile
    • PointClickPress
Re: Farming
« Reply #7 on: October 13, 2011, 06:39:29 AM »
As for unploved fields for livestock, in the past they were leaving 1/4 of the land "unoccupied" to let the ground "rest". I guess this could be used as pasture? Later they invented 1/3 system (rotation of crops) where no land had to rest, which would mean no more free land for grazing...
Nowadays, the land has classes (based on fertility) and the worse one is used as pasture. That's how it goes for history and realism, not sure if usable for a game.

You could use Conway's Game of Life to iterate which fields grow and which don't. Make it so player's can't choose every individual field they get to plant, they have to click groups at once, like a stamp. Then the players who best envision the way the field will grow and evolve will get more crops - player skill, not character skill.

Cellular Automata is I think what you are talking about. If you had a field of Conway's Game of Life you might just harvest "gliders" :P
http://mathworld.wolfram.com/CellularAutomaton.html

Offline pirategaspard

  • Level 9
  • *
  • Posts: 46
  • Reputation: +1/-0
    • View Profile
    • PointClickPress
Re: Farming
« Reply #8 on: October 13, 2011, 10:37:41 AM »
For fields harvest and milking cows I could have just two timers. But what about slaughtering? I mean these animals should be in different stages of growth and you definitly don't want to slaughter all animals of the same type at once (you want to leave at least 2 for further breeding :D). It can't work the same was as harvest.

I'm also concerned with amount of data (coding issue), it should be as light as possible (so no separate bookkeeping of every single chicken). I'm thinking about 5 separate variables per animal type defining the age of animal. So pig1 is newborn, pig2 is young, pig3 is can breed, pig4 can breed and is best for slaughter, pig5 is old one and bring less meat when slaughtered since you waited too long. Every 5 hours (global timer, not stored on the player table) all animals move 1 age class up.


Making a global timer would certainly be more efficient if you're going to keep track of the individual animals. I was thinking it would be more simple, that at the end of the timer you could sell animals if you wanted, otherwise you'd have to wait until the timer ended again. Of course that could be a global timer as well.  Over time you'd gain or lose livestock population using some simple formula that based the results on the size of your herd.

Offline Chris

  • Game Owner
  • Level 35
  • *
  • Posts: 2,217
  • Reputation: +28/-1
    • View Profile
Re: Farming
« Reply #9 on: October 14, 2011, 07:02:01 AM »
Quote
at the end of the timer you could sell animals if you wanted, otherwise you'd have to wait until the timer ended again
What you mean at the end of the timer? Like player will have 1 second to do so? At the very least there has to be some period, timeframe, not a point of time. Anyway, I don't like the limit of when you can sell livestock. It does not fit with the rest of the game, I think I will need to allow players sell and buy livestock anytime...

Overall, we have 3 "timers":
- harvest, this can be done at a fixed time the same for all players (seasons)
- milking & breeding, this probably could be global fixed time like harvest
- slaughter, this should be done anytime at player's will (this is a problematic one)

Offline Barrikor

  • Level 21
  • *
  • Posts: 248
  • Reputation: +3/-0
    • View Profile
Re: Farming
« Reply #10 on: October 15, 2011, 07:51:12 PM »
Could the game just auto-slaughter (?) most of the full grown meat-livestock at some point and add food to the player's resources?
Projects: Pith Framework (at 0.5), CactusGUI (at 0.3)

Offline Chris

  • Game Owner
  • Level 35
  • *
  • Posts: 2,217
  • Reputation: +28/-1
    • View Profile
Re: Farming
« Reply #11 on: October 16, 2011, 04:21:07 AM »
Could the game just auto-slaughter (?) most of the full grown meat-livestock at some point and add food to the player's resources?
It would not fit with the "game scale". You are more like a peasant, it would simply not fit to make this automated. I could go with automatic feeding the livestock but milking cows and slaughtering pigs really should be done by the player personally ("sorry guy for a minute, I have to login to a game because I have not milked my cow yet" :D).

Offline Barrikor

  • Level 21
  • *
  • Posts: 248
  • Reputation: +3/-0
    • View Profile
Re: Farming
« Reply #12 on: October 16, 2011, 03:31:03 PM »
Ok I get it now  :)

I was thinking about it too zoomed-out.
Projects: Pith Framework (at 0.5), CactusGUI (at 0.3)

Offline pirategaspard

  • Level 9
  • *
  • Posts: 46
  • Reputation: +1/-0
    • View Profile
    • PointClickPress
Re: Farming
« Reply #13 on: October 17, 2011, 08:14:05 AM »
Quote
at the end of the timer you could sell animals if you wanted, otherwise you'd have to wait until the timer ended again
What you mean at the end of the timer? Like player will have 1 second to do so? At the very least there has to be some period, timeframe, not a point of time. Anyway, I don't like the limit of when you can sell livestock. It does not fit with the rest of the game, I think I will need to allow players sell and buy livestock anytime...

If it was turn-based, I was thinking kinda like how Nukes or Gifts work in Galactic Imperator: after a certain amount of time your ability to slaughter would return for a turn. So when you logged back in you'd have that option again for that turn, but after choosing to slaughter you'd have to wait.  But that doesn't sound like the direction you are going anyway.

Is this new game not turn-based?  Is it a RTS peasant-farmer game? That'd be interesting. :P

Overall, we have 3 "timers":
- harvest, this can be done at a fixed time the same for all players (seasons)
- milking & breeding, this probably could be global fixed time like harvest
- slaughter, this should be done anytime at player's will (this is a problematic one)

If it can be done anytime then I guess tracking the individual animals status would make sense. That way a player will have to log in to slaughter when the animal is in perfect condition or else miss the opportunity.

Offline Chris

  • Game Owner
  • Level 35
  • *
  • Posts: 2,217
  • Reputation: +28/-1
    • View Profile
Re: Farming
« Reply #14 on: October 17, 2011, 01:58:47 PM »
It's for my Europe1300 http://community.bbgamezone.net/projects/europe-1300/

You are not necessarily a peasant and you are not necessarily to focus on farming. But everyone will have a plot of land, so, unless you rent the land for direct income you should dwell into farming, at least as a side activity :)
I guess, for some players it will be a peasant-farmer game :D

Tracking the individual animals does not sound good (performance vise). I would rather track groups of animals.


Feeding animals:
I think feeding should be automatic, there is enough hassle with all this milking :) Maybe you assign/prepare food for each animals group (deposit hay in the barn = cows will eat it; in pigsty = pigs will eat it) and these eat it automaticly as needed?
What happens if you can't feed animals? Will these die? Or only stop growing and giving milk? What happens if you have fodder only for part of animals in the group? Will just some of them grow?

Milking/shearing:
You need to spend some energy to milk the cow, also the cow should produce the milk, also it should be done the way that you are to milk the cow once per day. How to do it?
I was thinking of "milkmeter", when it reach 80% you can milk the cow by spending a fixed amount of energy x number of cows. When it exceed 100% the rest is wasted. But this system is not necessarily the best one (like if you buy the cow when the milkmeter is full you instantly get more milk during next milking)...
Another method could be some "milk count" which determine the milk accumulated in all cows you have (where max is equal to number of cows X cow capacity). But this one again has problems, if you sell/slaughter a cow then instantly the milk count goes up (because the old cow already accumulated some milk and added it to the count but 1 cow was removed so the max was lowered)...


Offline Barrikor

  • Level 21
  • *
  • Posts: 248
  • Reputation: +3/-0
    • View Profile
Re: Farming
« Reply #15 on: October 20, 2011, 12:44:35 PM »
What if you separated the milk cows from the beef cows?

(irl, farmers don't milk the beef cows nowadays, but they probably did in the 1300s though)
Projects: Pith Framework (at 0.5), CactusGUI (at 0.3)

Offline Chris

  • Game Owner
  • Level 35
  • *
  • Posts: 2,217
  • Reputation: +28/-1
    • View Profile
Re: Farming
« Reply #16 on: October 20, 2011, 01:31:58 PM »
What if you separated the milk cows from the beef cows?

(irl, farmers don't milk the beef cows nowadays, but they probably did in the 1300s though)
This won't change anything. There still are cow diseases, buy and sell transactions. The amount of animals will be changing.
Plus, as you said, they didn't do it back then.

 


SimplePortal 2.3.3 © 2008-2010, SimplePortal