Jump to content
  • Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal
  • 0
Murlocking

Adding duration to robot.use() function

Question

Hello, I made a big post in the request section about 3 programs that I'm trying to built.
I'm fairly new to Lua, I would say I started learning yesterday but that would be a lie since I've played a bit with ComputerCraft without really knowing what I was doing, until yesteday!

I think I made 3 really good programs and I can't wait to update/edit my post with my new information, but my post didn't get reviewed yet so it's not showing up in that section for now.

Anyway.. I was wondering if first, is it possible for a robot to use the right-click function "robot.use()" constantly instead of having it spam 

the right-click. 
I'm asking for that because I have my Robot equipped with  Watering Can from Extra Utilities and when I use this :
 

local robot : require("robot")
 
while true do
robot.use()          
end
 
It does what I want too but It kinda looks stupid and also collect the item from the block in front of it constantly (bushes from Tinker'sConstruct), that's the annoying part. I would not mind if it only collected once when the program run but it does it everytime the command run instead.

I tried to give the function a few arguments, but everytime I do it, it only affect the sides instead of the duration.
And I also read that duration is only simulated, does that mean it's impossible to have a robot constantly hold the right-click and produce an "effect"/action?

I bet it's really simple and I just didn't know the correct format(syntax) :D

Thank you for helping me!
Link to post
Share on other sites

1 answer to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.