P2P Energy Tunnels are 1:1 not 1:N
yueh opened this issue ยท 0 comments
Description
P2P tunnels for RF and ForgeEnergy are currently 1:1 connections, but these should be 1 input, N outputs.
It is also up to discussion whether the current behaviour should be kept or changed.
The current one is to iterate over all outputs and distribute the energy in a first come first serve way. But with additionally skipping random outputs. Which makes a bit non deterministic.
An alternative would be to distribute it in equal amounts over all outputs, without any random skipping. This would prevent the back of the list from potentially starving should the first few consume everything.
But the downside would be that a trivial approach would limit the throughput to 1/#numberOfOutputs and no single output ever recieving more than this amount.
Maintaining a secondary overflow could prevent it, so every output would receive their share plus whatever was left over from the previous output