TeamDman / SuperFactoryManager

Mozilla Public License 2.0
57 stars 20 forks source link

[BUG] Round Robin selecting different targets in same operation #166

Open Maverick238 opened 2 months ago

Maverick238 commented 2 months ago

Using the latest ATM9 Version.

The following program is used.

every 20 ticks do
  INPUT item::, fluid:: FROM RECIPE_INPUT
  OUTPUT item::, fluid:: TO BUFFER_TARGET ROUND ROBIN BY BLOCK
  FORGET

  INPUT item::, fluid:: FROM EACH EBF_OUTPUT
  OUTPUT Item::, fluid:: TO RECIPE_OUTPUT
end

When using the OUTPUT operation here it chooses different ROUND ROBING targets for the fluid and the items. As far as my understanding goes it should be the same right ? If not is there an option to make it the same so recipes can safely be transported from a Ingredient Buffer to a e.g. GT Machine ?

TeamDman commented 1 month ago

caused by https://github.com/TeamDman/SuperFactoryManager/blob/b6e689314b2ec9c2d62e4d532c125d2fd879df8b/src/main/java/ca/teamdman/sfml/ast/InputStatement.java#L110-L131

https://github.com/TeamDman/SuperFactoryManager/blob/b6e689314b2ec9c2d62e4d532c125d2fd879df8b/src/main/java/ca/teamdman/sfm/common/resourcetype/ResourceType.java#L105-L127

which has the resource type as the outer loop instead of the block positions

This is also present in OutputStatement