rhn's continued adventures: a build journal, guide collection etc.

  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
Nice and simple script. Could be more modular though :p
Could you elaborate on what you mean by modular?

If you mean the placement of computer/monitors then I thought about it(still am thinking). I could make the user specify the sides of the monitor and energy cell when running the program, but that would cause problems with resuming upon reloading the computer. I would instead need to do some kind of detecting of which sides the monitors and energy cells are attached to. I have some code bits tugged away to detect where a monitor is attached, but just not sure how to detect where the Energy cell is(or how to tackle different kinds of energy storage devices).

If you mean the code, then yeah its messy. I am not good at coding :p

I might do a version that do not have/need the Monitor. Just initially thought it would be a nice addition to have and the monitor fitted so nicely on top of the computer/energycell :p
 

Arkandos

New Member
Jul 29, 2019
349
0
0
Modular by way of letting the computer itself detect on which side the monitor and energycell is on. This would allow it to work over wired networks too!
I'll find the exact methods for it later.
 

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
Modular by way of letting the computer itself detect on which side the monitor and energycell is on. This would allow it to work over wired networks too!
I'll find the exact methods for it later.
Alright, have no idea how to handle cabled stuff, but managed to pull it off so that the code will now on its own detect which sides of the computer the Monitors and storage cells are attached to. By doing this I have to make it look specifically for the names of the specific blocks, so the code now only works with TE3 Energy cells and EnderIO Capacitor banks(let me know if there are more that should be added).

Make sure to leave the back of the computer free however, as this is the side that will output the redstone signal to control the engines!

I also added the option to use the code without the Monitors. The script will warn you that no monitors are attached, but will continue to do its power regulation.

Energy storage monitor v2:
http://pastebin.com/Uqq1WBJ1

Updated the original post as well to contain this.
 
Last edited:

Arkandos

New Member
Jul 29, 2019
349
0
0
Wired networks function just like having the peripheral next to the computer, but instead of
Code:
peripheral.wrap("left")
you do
Code:
peripheral.wrap("cofh_thermalexpansion_energycell_1")
or whatever the name of the peripheral is.

Your program should be good enough to be able to handle that.
 
  • Like
Reactions: rhn

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
Wired networks function just like having the peripheral next to the computer, but instead of
Code:
peripheral.wrap("left")
you do
Code:
peripheral.wrap("cofh_thermalexpansion_energycell_1")
or whatever the name of the peripheral is.

Your program should be good enough to be able to handle that.
Doh, ofc... Already seen this done lol. I will just add it so it looks for the devices wired after having looked for them adjacent.

EDIT: Ehm actually, how do I detect if there is actually any attached through wired modems? Using the peripheral.getType() to test if there are any adjacent to the computer. How do you test if there actually is a "cofh_thermalexpansion_energycell_1"? Just trying to do the peripheral.wrap("cofh_thermalexpansion_energycell_1") without there being one would result in an error, wouldn't it?.
 
Last edited:

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
Glad to be of assistance :D

Not often I get to use my computercraft knowledge on these forums.

Edit: This should do the trick: peripheral.getNames
You sure are testing the limits of my programming skills.... And expanding them a bit :p


Now with wired modem support for both Monitor and Energy storage devices. Will automatically detect the devices no matter which number in the numerical adress is assigned to the device(will still detect a monitor if it is given the address: "monitor_15"). Directly adjacent devices still take priority however.

Energy storage monitor v3:
http://pastebin.com/rjfa4ymR
 

trajing

New Member
Jul 29, 2019
3,091
-14
1
Could you make it support multiple monitors?
Now this is just a game of "How good can you Lua?"
 

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
Could you make it support multiple monitors?
Now this is just a game of "How good can you Lua?"
New addition to my scripts:
Code:
if user.name == "trajing" then
  print(NO!)
  return
end

:p

(just to make sure noone thinks it is actually real, the user.name is made up :p).
 
Last edited:

Arkandos

New Member
Jul 29, 2019
349
0
0
Could you make it support multiple monitors?
Now this is just a game of "How good can you Lua?"
Multiple monitors as in writing different stuff on different monitors? That would be quite hard.

But just writing the same info on several? Quite easy.
 

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
Multiple monitors as in writing different stuff on different monitors? That would be quite hard.

But just writing the same info on several? Quite easy.
Yeah wouldn't be too hard. Would require a bit of rewrite of the monitor locating part to actually look for multiple monitors. Right now it just stops once if finds the first one.(or actually if multiple are attached by wired modem, it will use the last one on the list I think).
 

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
So there was actually a reason why I started making this particular script at this particular moment:

jvgaeXD.png

I needed some setup to use use all that lovely Ethanol produced. Problem is I wanted a solution that was "on demand power", so it had to have no "heatup" periods. So Boilers etc. were out of the picture and could simply not think of anything better/more energy dense than Compression Dynamos. So I bring you 100 Compression Dynamos :p

s9cQdob.png


The Dynamos are arranged into towers of 3x3 (5x5 if you count the Red alloy wire). All controlled from the Computer.
m7XS8Ck.png


And the output of the Resonant Energy cell is controlled by wireless redstone signal from the main RF hub:
uWmxtRP.png


This way the the Compression Dynamos is the tertiary energy supply. Primary is the BigReactor Turbine running constantly producing 20k RF/t, secondary is the passive BigReactor automatically kicking in once RF storage drops low enough and then the tertiary is the Compression Dynamos kicking in when energy levels drop even further.


I am currently considering changing some configs to improve power consumption of different items. Simply not really using a whole lot of power with the current setup. The passive BigReactor is only running about a 1/4th of the time, despite all the power from the turbine being sunk into the MFR laser drill. So might increase the energy cost of things like my Quarry+ etc(already changed it to a unenchanted quarry+ to use more power).
 

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
Was just down in my ME center to check on the power consumption(was planning a redesign of the IC2 energy hub), when I noticed how large my network have actually become :p

Main network:
U8V6Euc.png

AvbFlrA.png


Subnetworks:
Nuclear refinery network:
LrEX4Gz.png


Bee network:
WPljiEA.png


Autocrafting network:
Pw58NZ0.png
 
  • Like
Reactions: Tompa974 and E_DM_B

iNd3x

New Member
Jul 29, 2019
104
0
0
That is probably the biggest ME system i've seen by now!

Just wondering, how's your fps with all these things going on?
 

rhn

Too Much Free Time
Nov 11, 2013
5,706
4,420
333
That is probably the biggest ME system i've seen by now!

Just wondering, how's your fps with all these things going on?
Heh. 30ish at a new session, then slowly declining over a few hours towards something like 12-15fps :p
Restarting the client every 3 hours or so due to it just getting too low. Also most of the time when building inside my base I decrease the render distance to short. Really no need to render to far in a enclosed space. That helps a bit.

I have disabled the cable flashing btw, in the AE config. Didn't seem to help one bit however :p
 
  • Like
Reactions: masterzh