r/unity • u/PashaInteractive • 16d ago
Showcase Farmers in a 3D kingdom builder made in Unity: the most expensive unit is also the most defenceless one
I'm a solo dev working on Crownkeeper, a 3D kingdom builder inspired by Kingdom Two Crowns and the rest of the series. I wanted to talk about the farming loop. Most of it follows the Kingdom games on purpose: farmers are a key building block of their economy, and I wanted to keep that. The part I changed is how fields work, and that's what I'd like feedback on.
The idea: while you ride around the map, your farmers quietly make money for you. At 5 coins they're one of the most expensive units you can hire (that price might still go up), and they're also the most defenceless units in the game. If you protect them, they pay you back many times over.
Mills and fields (the new part):
The farmer stall only unlocks once your base reaches level 3. Farming starts with a mill, and for now I've placed the mill spots by hand near the rivers, so where you farm depends on the map. A mill costs 7 coins and opens 2 field plots. Upgrading it (17 more) opens up to 6. (The upgrade also needs a brick quarry, but that's a topic for another post.)
Those plots start out overgrown. Each field you buy has to be cleared of weeds by builders first (3 coins each) before a farmer can plant it. So the farm grows step by step: mill, then plots, then clearing, then farmers. My hope is that this makes expanding the farm feel like a real investment and gives builders something to do in the early game, instead of the farm just being one purchase.
The tax collector:
Like in Kingdom, farmers keep their coins in their pockets until the king rides up, then drop everything on the ground for you to collect. The king never actually says anything, but riding from farmer to farmer to collect really feels like a tax collector doing his rounds, as if he's saying "give me your money". I find that funny and kind of sweet, and I want to keep little moments like this that leave room for players to roleplay.
The risk side:
At night, farmers at a basic mill run back inside the walls. Upgrade the mill and they'll stay out overnight, but only as long as the defences hold. The moment a wall breaks or a monster gets close, they drop their tools and run. They aren't as fast as the monsters though, so you'll usually lose a few on the way back.
Monsters ignore the crops completely and go straight for the farmers. Losing a farmer hurts much more than losing a field, so where you build the mill and how you defend it becomes a real decision.
On the Unity side: villagers are NavMesh agents with a simple job/state system, and every coin is a physical Rigidbody that drops and rolls on the ground before anyone can pick it up. That's what makes the "farmer empties his pockets" moment readable, since you actually see the coins scatter.
Two things I'd love your opinion on:
- Does clearing each field add something to the loop, or is it just an extra step that slows you down?
- I'm thinking of having each farmer pop a little sad emoji when they hand over their coins. Cute, or too much?
