-
Bug
-
Resolution: Invalid
-
None
-
Minecraft 1.11.2
-
None
-
Unconfirmed
See also: Forge Issue Tracker
The Symptoms
When adding a larger number of buildings, the road networks get crazy large.
The Problem
For reference: See class c => func_176067_c => generateComponent
There is a 'total weight' variable i, which is calculated from the village's structureVillageWeightedPieceList sum of weights. After a component piece has reached its limit, it is removed from the list, but the total weight is not adjusted. This leads to an increasing amount of just torch roads returned later in the method.
Solution Approach
Subtract the removed components' weight from the total weight on removal. Test if total weight reached < 0 and if so, return with null from the method.