User_OC 1 Posted April 4, 2015 Share Posted April 4, 2015 I want to automate the production of robots.Robot-builder is coming to assembler and runs the program: local robot = require("robot") local c = require("component") local ic = c.inventory_controller robot.select(1) ic.dropIntoSlot(3, 1, 1) robot.select(2) ic.dropIntoSlot(3, 5, 1) robot.select(3) ic.dropIntoSlot(3, 6, 1) robot.select(4) ic.dropIntoSlot(3, 4, 1) robot.select(5) ic.dropIntoSlot(3, 14, 1) robot.select(6) ic.dropIntoSlot(3, 17, 1) robot.select(7) ic.dropIntoSlot(3, 18, 1) robot.select(7) ic.dropIntoSlot(3, 19, 1) robot.select(8) ic.dropIntoSlot(3, 21, 1) robot.select(9) ic.dropIntoSlot(3, 20, 1) robot.select(11) ic.dropIntoSlot(3, 3, 1) robot.select(12) ic.dropIntoSlot(3, 7, 1) robot.use() -- ?????????? Location of components in the robot-builders: After assembly, the components are arranged as follows: I have a question: how can activate the button "Assemble"?Team "robot.use ()" does not include this button. Quote Link to post Share on other sites
0 Sangar 92 Posted April 5, 2015 Share Posted April 5, 2015 Since robots can't use external components, you'll need to have a computer trigger that, using the component the assembler exposes (`assembler.start()`). You can use networking or redstone to have the robot tell the computer to start the assembler. Quote Link to post Share on other sites
0 User_OC 1 Posted April 5, 2015 Author Share Posted April 5, 2015 Thank U. I'll try to experiment. If I fail, I have you to ask more questions. Okay? ---------Sorry - I use to translate Google-translate. Quote Link to post Share on other sites
0 User_OC 1 Posted April 5, 2015 Author Share Posted April 5, 2015 I connected the computer to the assembler (set next).On the computer I ran this program: local assembler = require("assembler") assembler.start() On-screen error: this module is not found.I is difficult to figure out which classes and libraries exist in OpenComputers and how they are related to specific modules (eg with Assembler).So I suggested a version of the program with the operator [assembler.start()] Quote Link to post Share on other sites
0 Sangar 92 Posted April 6, 2015 Share Posted April 6, 2015 (My answer, copied from MCF) The assembler is a component, what you're trying to do is load a library called "assembler" and call a method on that. What you want is to get the component library, then get the assembler component, and call the method on that: require("component").assembler.start() Do note that robots can't interact with external components, so you'll need to have a computer call that. You can have your robot communicate with a computer making that call using redstone signals or OC networking. Quote Link to post Share on other sites
0 User_OC 1 Posted April 6, 2015 Author Share Posted April 6, 2015 Thank you, it works. Quote Link to post Share on other sites
0 User_OC 1 Posted April 13, 2015 Author Share Posted April 13, 2015 There is a new problem. We have assembled a robot. But how to activate it? How to make automatic pressing "Turn on"? Optional (if not hard):- How robots can exchange items?- The robot can access the inventory of another robot? Quote Link to post Share on other sites
0 dgelessus 26 Posted April 13, 2015 Share Posted April 13, 2015 Any kind of computer (including robots) can be powered on by sneak-right-clicking, but I don't think robots can "sneak"... Item exchange between robots shouldn't be hard, you should be able to put items into the other robot as if it were a chest. Quote Link to post Share on other sites
0 User_OC 1 Posted April 13, 2015 Author Share Posted April 13, 2015 Here we are talking about automating this process.If you use the right button [robot.use ()], to open the robot,and then the left button [robot.swing ()], to press the power button on the robot,the robot will not turn on, these commands do not work. local robot = require("robot") robot.use() robot.swing() Quote Link to post Share on other sites
0 dgelessus 26 Posted April 13, 2015 Share Posted April 13, 2015 Robots can't use GUIs, so in this case robot.use() does nothing. If you run robot.swing() afterwards it will try to punch/mine the robot. The reason why I suggested the sneak-right-click method was because that doesn't require any GUI interaction, but unfortunately robots cannot do a sneak-use, so that isn't an option either. Quote Link to post Share on other sites
0 User_OC 1 Posted April 13, 2015 Author Share Posted April 13, 2015 If I can not automatically turn on the robot,this means that:- It is impossible to implement automated production robots.- Can not be automated production chains with these robots.The only hope - is the guru OpenComputers and programming Sangar. Quote Link to post Share on other sites
0 Molinko 43 Posted April 13, 2015 Share Posted April 13, 2015 I thinks its possible to have wake functions for the robot. Either through the redstone card or with the modem card. Pretty sure you can do it with modem. Something like modem.setWakeMessage(string) Also redstone.setWakeThreshold(numberStrength) Quote Link to post Share on other sites
0 dgelessus 26 Posted April 13, 2015 Share Posted April 13, 2015 The question is whether that setting is stored on the actual card item. If not, then there would be no way to set that setting on a fresh robot without manually powering it on. Quote Link to post Share on other sites
0 natedogith1 4 Posted April 14, 2015 Share Posted April 14, 2015 Actually, you can sneak-right-click with a robot, you just need to pass in true as the second argument. And it seems you can indeed shift-right-click (with an empty hand) to turn on computers and robots, so glad I learned this! Quote Link to post Share on other sites
0 User_OC 1 Posted May 9, 2015 Author Share Posted May 9, 2015 Actually, you can sneak-right-click with a robot, you just need to pass in true as the second argument. And it seems you can indeed shift-right-click (with an empty hand) to turn on computers and robots, so glad I learned this! :D Thank you very much! The robot turns on. local robot = require("robot") robot.use(3, true) This command works. Now it will be possible to do fully automatic cycle for the production of robots. Some robots will make other robots, and they in turn will perform the necessary work in the automatic mode - miners, farmers, construction of buildings, etc .. ---------- It remains only to solve the problem with the recording to hard disk needed robot programs. Quote Link to post Share on other sites
0 kevinkk525 8 Posted May 11, 2015 Share Posted May 11, 2015 OMG. thanks for sharing a way of building Skynet in Minecraft! Kind of awesome. If i have some time left I will develop Skynet Quote Link to post Share on other sites
0 User_OC 1 Posted May 23, 2017 Author Share Posted May 23, 2017 Hello! How can I turn off the computer? The robot is in front of the computer. If you execute this command, the computer will turn on: robot.use(3, true) Tried these commands, but the computer does not turn off: robot.use(3, false) robot.swing(3) Quote Link to post Share on other sites
I want to automate the production of robots.
Robot-builder is coming to assembler and runs the program:
Location of components in the robot-builders:
After assembly, the components are arranged as follows:
I have a question: how can activate the button "Assemble"?
Team "robot.use ()" does not include this button.
Link to post
Share on other sites