This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
DjTranceFire's profile picture

Essentia Refill System

Started by DjTranceFire, 16 January 2015 - 08:05 AM
DjTranceFire #1
Posted 16 January 2015 - 09:05 AM
Hey guys.
I'm currently trying to automate my thaumcraft room.
I want something similiar to the jar refill system direwolf20 in his season on 1.6.4
I tried to find something on youtube/google but it seems like nothing works on 1.7.10

The codes i'm currently using are:
pastebin get 18pB7QM9 button
pastebin get R4cf3Bd1 essentia

after changing some variables to match my system and starting the codes i just get:


Java exception thrown

I'm new to all that lua stuff and i'm still learning.
But i have absolutly no idea what causes that problem.
I hope anyone here can help me to fix this problem.

Sorry for my bad english, i hope its not to hard to understand.
valithor #2
Posted 17 January 2015 - 08:14 PM
I would suggest adding prints throughout the code to attempt to narrow down exactly where it is erroring.
Bomb Bloke #3
Posted 17 January 2015 - 11:04 PM
I can tell you with reasonable certainty that it'll be one of the peripheral functions. I'm not 100% sure, but I've only seen that error when various types of peripheral have messed up (due to being called incorrectly, for eg).

Using unique print statements to work out which line is triggering the problem would be a good start.
Quintuple Agent #4
Posted 18 January 2015 - 12:58 AM
If you are using Thaumic Tinkerer (And by your code I beleve you are) I think I might know what the problem is.
I remember trying to write a program for an essentia graph and when I tried to use getAspects() on an empty container, It would throw back and error and crash the program out. I was able to get around this by making a table of all the essentia and using a loop that used getAspectCount() to check if the container has more than 0 of any aspect.
DjTranceFire #5
Posted 18 January 2015 - 07:16 AM
Hey guys.
Thank you for your answeres.
Because i'm new in lua and the code i'm trying to use is not mine,
its almost impossible for me to get an overview of it.
Because of that i dont realy know how to find the problem with prints.
@Quintuple Agent:
I just checked everything and all jars are filled so this cant be the problem :(/>
I hate errors that dont give any informations.. :x
ele72 #6
Posted 31 March 2015 - 04:05 PM
Hey,
I'm new to programming but I think I know what the problem is. The problem is here:
29 asp = peripheral.call(j, "getAspects")
30 countasp = peripheral.call(j, "getAspectCount", asp)
It gets the error "Java exception Thrown" when it tries to put in "asp" in the getAspectCount command.
I don't know how to fix this problem but I hope I could help you.