Page 1 of 55

Official KaM Remake Bugs topic

PostPosted: 27 Dec 2011, 14:57
by Encaitar
I don't know for sure it's a bug, but it was something I noticed. I build four farms at the left side, and two swine farms to the right (see attachment). The swine farm closer to the farms got lots more grain than the swine farm further away. Maybe it has something to do how the delivery system works. It seems logical to me every swine farm gets approximately the same amount of grain, because the 'waiting-factor (the growth of a pig)' is more important than the fastest delivery of grain to a swine farm (the shortest walking time of a serf from farm to swine farm).

I hope I am understandable, as it's hard to explain...

Re: Official KaM Remake Bugs topic

PostPosted: 27 Dec 2011, 15:04
by Lewin
Yep that's a bug that effects all buildings. That swine farm is closer to the farms so the serfs will prefer it because it's less walking. (shorter deliveries are preferred) This is tricky because you don't want things to be carried further than necessary when there is a closer building available, (e.g. I might have a woodcutter and sawmill on each side of my village, in that case the trees should always go to the closest sawmill) but you also don't want buildings to become favourites. (as you showed here)
Not sure how to solve this...

Re: Official KaM Remake Bugs topic

PostPosted: 27 Dec 2011, 15:12
by GreatWhiteBear
hmm,
This map?
Mission 4?

Now, I don't know about programming or computer mechanics at all,
but maybe preferring the closest consumer to receive 50% of the corn and every next consumer 50% of the preceding one rounding it up at the last one.

Re: Official KaM Remake Bugs topic

PostPosted: 27 Dec 2011, 15:19
by Encaitar
Yep that's a bug that effects all buildings. That swine farm is closer to the farms so the serfs will prefer it because it's less walking. (shorter deliveries are preferred) This is tricky because you don't want things to be carried further than necessary when there is a closer building available, (e.g. I might have a woodcutter and sawmill on each side of my village, in that case the trees should always go to the closest sawmill) but you also don't want buildings to become favourites. (as you showed here)
Not sure how to solve this...
Well I do have a idea about that, but I don't know if it is easy to implement because I do not read Pascal. I suspect that every building is a object. In those objects the input sources and output sources are saved (e.g. for a swine farm -> input: 2 grain; output: 1 pig + 1 pig skin).

Maybe you should make a list from buildings that do not apply to the 'shorter deliveries are preferred' rule. Once a serf must deliver to anyone of those listed buildings, another rule shall take effect: check to every object what has the lowest input. Serf must deliver to the object that has the lowest input.

E.G. A serf must take a grain from a farm to a swine farm. As those building is one of the listed building (where 'shorter deliveries are preferred'-rule does not apply), the code checks all the 'swine farm'-objects and choses the lowest input as delivery point. The serfs takes the grain to the right farms, and piggies are being born there :D.

-------------------------
Edit:
hmm,
This map?
Mission 4?
Yep :D

Re: Official KaM Remake Bugs topic

PostPosted: 27 Dec 2011, 15:33
by Siegfried
Not sure how to solve this...
This won't solve it, but maybe make it less severe: include a "punishment" for inventory stocks. So if the building has one piece of resources in its inventory, add additional x squares to the calculated distance.

For example, if you choose x=3, then the first corn goes to the left swine farm, because the distance (20) is lower then the distance for the right swine farm (24).
The second corn still goes to the the left swine farm (20+3).

But the third corn would go to the right swine farm, because its distance (24) is smaller than that of the left swine farm (20+2x3 = 26). So buildings near each other still have an advantage, but it is a bit weaker than before, depending on how you choose x.

Please don't completely change the algorithm, because at the moment you have to think how to build your town in order to minimize transport time. I think that is important to put some focus away from the pure fighting and towards the economy.

Re: Official KaM Remake Bugs topic

PostPosted: 27 Dec 2011, 16:32
by Mau5trap
Not sure how to solve this...
This won't solve it, but maybe make it less severe: include a "punishment" for inventory stocks. So if the building has one piece of resources in its inventory, add additional x squares to the calculated distance.

For example, if you choose x=3, then the first corn goes to the left swine farm, because the distance (20) is lower then the distance for the right swine farm (24).
The second corn still goes to the the left swine farm (20+3).

But the third corn would go to the right swine farm, because its distance (24) is smaller than that of the left swine farm (20+2x3 = 26). So buildings near each other still have an advantage, but it is a bit weaker than before, depending on how you choose x.

Please don't completely change the algorithm, because at the moment you have to think how to build your town in order to minimize transport time. I think that is important to put some focus away from the pure fighting and towards the economy.
I don't really think there is a problem with this system. If the first house fills, the sefs would take the corn to the next. If the swine farm didnt fill and the serfs are not taking the wares to the other it means the first farm is in its maximum productivity, and it is using all the corn delivered (because otherwise it would be full), and so if you stop taking things there and take them to the other, or divide the corn between them, both would have only a 50% productivity that i think equals the same (not sure about how the system works but lewin might tell us)
So in my opinion the best thing to do is just make another farm ;)

Re: Official KaM Remake Bugs topic

PostPosted: 27 Dec 2011, 16:45
by T*AnTi-V!RuZz
I don't really think there is a problem with this system. If the first house fills, the sefs would take the corn to the next. If the swine farm didnt fill and the serfs are not taking the wares to the other it means the first farm is in its maximum productivity, and it is using all the corn delivered (because otherwise it would be full), and so if you stop taking things there and take them to the other, or divide the corn between them, both would have only a 50% productivity that i think equals the same (not sure about how the system works but lewin might tell us)
So in my opinion the best thing to do is just make another farm ;)
And what about when making weapons/armor?

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 16:49
by GreatWhiteBear
I tested it and another problem is that with Iron distribution everything goes to the nearest building being it weapons or armor.
That results in the problem of having more weapons or armor produced per amount of time.
Now I know why I had 50armor and only 3crossbows while having the distribution of iron and coal at 5-5.

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 16:53
by pawel95
Yes this is a big problem/bug mostly in the multiplayer HAHA i dont know with who i played one of the first match online. I build my coal mine near the gold melter and far away from the iron melter. HAHA many gold 0 iron--> 0 army :D but you can set in the settings, that they should only bring one corn to the horsefarm, so if one or two pieces are in the farm, the serfs will bring the other to an other building--Swine farm :D

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 16:55
by GreatWhiteBear
maybe I am just being captain obvious, but you can do that with coal too.

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 17:01
by pawel95
Yeah very good GWB, you are a big champion :? Do you really think that i only show on this setting when i played the remake the first time? I cant believe that someone make a complet remake of a good game and I havent time to think about, why my serfs dont transport coal to the iron melter!

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 17:38
by GreatWhiteBear
Sorry, I do not fully understand your point.

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 18:28
by =NL= Gila
I think you both do not understand eachother quit proper... But I thought everybody knows you can change the deliveries in the tab of deliveries of corn, iron, coal and wood...
You can also close the door of the structure to stop the delivery for a moment, but that would make it a little difficult if you are doing other things at the same time...

Anyway, its logical that the nearest building gets first to receive its products, thats how the game works with and thats how I learned to make farms next to the mill and swinefarm and horsefarm.
Like this:

farm - mill - farm - swinefarm - farm - horsefarm - farm

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 18:51
by Encaitar
Anyway, its logical that the nearest building gets first to receive its products, thats how the game works with and thats how I learned to make farms next to the mill and swinefarm and horsefarm.
Like this:

farm - mill - farm - swinefarm - farm - horsefarm - farm
Why is that logical? I always make the same houses at each other: farms, woodcutters, quarry, etc. I think that's much more convenient, as the inhabants of these houses can use the same resources (field -> farms, trees -> woodcutters, stone -> Stonemason, etc.). Besides, even in the Middle Ages this kind of thinking was being used. In big cities the streets were devided in guilds. Every member of such a guild would live in the same street (or streets if the guild covered several streets).

Re: Official KaM Remake r2736 Bugs topic

PostPosted: 27 Dec 2011, 19:03
by Krom
Take a look at this:

Let's say that Pigfarm can handle 1corn per minute and you have farms that overall produce 1.2 corn per minute at average.
Then closest pigfarm will be stocked fully and distant pigfarm will get only 1 of 5 corn.
In the game it will look like farm #1 is overstocked and the other one is understocked.
Now think about it at different angle - both pigfarms are working and consuming all the corn produced. If you force 50/50 split then overall production will be penalized by serfs having to carry half of the corn farther to 2nd pigfarm instead of 20%. Pigs production will be the same "number of corn = number of pigs", but due to route length it will take a little more time.

What is important here, is that you need to balance corn between different consumers! (Mill, pigfarm, stables) and that is done through menu ;)
In the end - build more farms! :)