Open TheLargeCactus opened 6 years ago
Powercells don't work like that. All linked powercells access the same pool of energy. They don't send energy to each other. They access a single big energy pool and all have equal access. i.e. if you have five powercells they can each at the same time extract the full amount from that pool (unless power is gone)
Forgive me if I'm misunderstanding but as long as the output values of the individual cells subtract their output/tick in some order (i.e. they aren't asynchronous) couldn't you arrange that data structure as a priority queue? Or does the output scale down proportionally if demand > energy stored?
um I'm not understanding the issue myself right now. What exactly is the problem that you're trying to solve?
Here's what I think the issue is: suppose powercells A and B are linked together, and each one is connected to a machine that needs 1000RF/t. If only 1500RF is available, which powercell should get to output the full 1000 and which should only get 500?
Ah ok you mean like that. Well that's undefined. It just depends on which machine ticks first
As @josephcsible said, my request would be a way to allow for one powercell to receive power potentially before another. It would allow me to prioritize machinery that needed power over a machine that did not necessarily need power to keep the overall system running. All receiving powercells could queue up each tick to receive power and their priority would determine which powercells draw from the pool first, leaving less power for other receiving powercells, with a similar feature for powercells trying to send power to the pools, with higher priority sending cells getting to add power to the pool before lower priority cells.
That's really very complicated to implement and I think this situation is rarely useful in practice.
Also note that RFTools actually has methods for you to manage this yourselves. There is the power relay block which can be made to throttle power at some side (i.e. limit to 500RF/t or some other number) on a redstone signal. Combine that with a power monitor and you can (for example) easily make a setup where you prevent power to some machine is the amount of power in the storage cell is less then X%
Reviving this from the dead. It'd be a super useful thing, since otherwise I'm going to have to dedicate a room in my base to having tiered power cells with redstone comparator links manipulating a system of power relays, instead of just a priority system.
Example: Solar + wind generates X My raw-required-base stuff should take priority. Always fill up the MFSU and power the AE2 energy acceptor first. Next, any machines running dynamic jobs should use up any power they need/can on top of that. Anything that's left over can go to molecular transformer/quantum quarry, in whatever order they tick.
If there was just a priority number on the power cells, I'd just have 4 power cells (one input and 3 output), sharing the same energy pool, and priority dispersing the power. But instead I'm going to need to set up 2 powercells for power generation, into a power relay, one face to a power cell which will buffer/power the tier 1 base stuff and one face into another power cell. Comparator off the base powercell back into the power relay to decide whether to send anything into the second tier power cell. Then second tier power cell has a power relay to split its power to tier 2 power cell and a tier 3 input power cell, etc. tiering down. Gotta do what you gotta do, but that's not very clean, and the current behavior not being "split the output awkwardly as if it were all connected by fluxduct" but instead is "random", so sometimes my base stops working while the quarry is powered and sometimes my base works while nothing else does, is very strange behavior. :(
A likely simpler implementation but still highly useful answer would be priority output on the power relay. You could at least then fork your tiers with a power relay without having to dump into extra levels of power cells unless you really wanted some complex buffering/tiering.
Add a priority modifier to your multiblock powercells! Higher priority values indicate which powercells should receive/send power first. A higher priority powercell that is sending RF should send to other powercells before a lower priority cell and receiving powercells with a higher priority should receive before other receiving powercells.