theFox6 / microexpansion

[MT Mod] You can finally get rid of all your chests, and replace them with a single, centralized station.
https://content.minetest.net/packages/theFox/microexpansion/
MIT License
3 stars 8 forks source link

Add some limits #12

Open AmyMoriyama opened 2 years ago

AmyMoriyama commented 2 years ago

Is your feature request related to a problem? Please describe. Players can put drives inside drives inside drives. There seems to be no limit to the number of drives accessed from one controller.

Describe the solution you'd like 1: Prevent drives from being able to be put into other drives. 2: Limit the number of drives that a controller can access. 3: Limit the number of controllers a terminal can access. 4: Allow all these limits to be tweaked via settings file.

Describe alternatives you've considered n/a

Additional context n/a

theFox6 commented 1 year ago

The latest release prevents drives within drives.

I feel like the number of drives should be limited by something like energy cost in the future, which could be set to be linear or exponential.

It is in fact a problem, that terminals can connect to multiple controllers, which causes all sorts of unexpected behavior.

Thanks for your suggestions, I'll implement them if I have more time to develop my mod.

beepbopbeepboop commented 8 months ago

I've fixed this in my pull request. We use linear energy for most of the network, and logarithmic energy on things like wireless remotes and quantum bridges. We can have a capacity or a usage based component as well. ae2 has a capacity component. The autocrafter isn't yet wired in as the energy demand is a static, slow changing value. For dynamic demands, we need to have a storage component to buffer changes in demand without the network going dark. Presently there is a 2 second drop out as one builds out their network as the generation catches up with demand. Hard to notice, but I like the subtle mechanic. Most of the static costs are similar to ae2.

beepbopbeepboop commented 8 months ago

Oh, and I relax drive in drive some, as drives that are empty need to be able to be in the system for autocrafting reasons. Also, keep in mind, in ae2, you can put drives in chests, and put a storage interface on the chest, so, it isn't actually unreasonable to do that. I have most of the code for the storage interface in my request, but it is disabled due to robustness for now.