[Python] RoC Calculator

pizzawolf14

New Member
Jul 29, 2019
566
0
0
Hey everybody o/

I was playing RoC in my custom modpack earlier today and I was punching numbers into my calculator to find just how slow my 2-gasoline engine extractor was actually going. I got bored of the TI-83 stone age edition, so I decided to make a quick Python calculator for a couple of RoC machines, and came up with this. I got the formulas from here and I pray to @Reika that they are right...

http://www.mediafire.com/view/8igene46sc4ge82/RoC_calc.py

It is in Python, as that is the only language I feel even a little comfortable coding in. I'm pretty sure this means you will have to have Python on your computer in order to run the program. If somebody could translate it into Java (is that even possible?) then I'd be grateful. You can even comment your name in it if you want :p

Basically the program asks you for what machine you are using, the input torque (in Nm) and the input speed (in rad/s). It then looks to see if it supports your machine, makes sure you have sufficient energy, and finally outputs the time in ticks that it'll take your items to process. The initial input is spelling sensitive, but not case sensitive, so you can do all caps, no caps, or whatever caps you like. Yes, I know it's poorly coded, but I'm pretty new to this so bear with me. Suggestions (features or simplifying) are always accepted.

Extractor
Bedrock Breaker
Fractionation Unit
Fermenter
I plan to add a GUI once I learn how to and of course add support for more machines.
 

madnewmy

New Member
Jul 29, 2019
1,119
0
0
I usualy plug the numbers in wolfram :p

I wish i could use that program but don't have python thingy :(

And you should focus on adding the 'necessary to progression' mods (which you seem like doing)
 

pizzawolf14

New Member
Jul 29, 2019
566
0
0
I usualy plug the numbers in wolfram :p

I wish i could use that program but don't have python thingy :(

And you should focus on adding the 'necessary to progression' mods (which you seem like doing)
I'm learning Java, and assuming they are similar, this'll be easy to rewrite. It's a pretty introductory Python program.

While on the topic, what is the best free java IDE? Really all I need is syntax highlighting.

Edit: until I get it rewritten, you can download python here: https://www.python.org
 
Last edited:

einsteinsci

New Member
Jul 29, 2019
109
0
0
I'm learning Java, and assuming they are similar, this'll be easy to rewrite. It's a pretty introductory Python program.

While on the topic, what is the best free java IDE? Really all I need is syntax highlighting.

Edit: until I get it rewritten, you can download python here: https://www.python.org

IntelliJ by a long shot. Its syntax highlighting is highly customizeable (more so than eclipse) and its autocomplete requires fewer keystrokes.