Someone want to make a computercraft program for me?

  • Please make sure you are posting in the correct place. Server ads go here and modpack bugs go here
  • 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

Throwtex

New Member
Jul 29, 2019
5
0
0
I am trying to make a program that allow me to do following:
-Count seconds
-check for redstone signal(lever)
-give out two seprate redstone signasl after coountdown with delay between
-repeat this over and over again

It should not run unless given redstone signal. The purpose of this is to make my own mining machine. i have tried a couple of times, but could never find out how to do it. i am a noob at CC...

Hope there are someone that can make my idea to life!
 
I am trying to make a program that allow me to do following:
-Count seconds
-check for redstone signal(lever)
-give out two seprate redstone signasl after coountdown with delay between
-repeat this over and over again

It should not run unless given redstone signal. The purpose of this is to make my own mining machine. i have tried a couple of times, but could never find out how to do it. i am a noob at CC...

Hope there are someone that can make my idea to life!
Code:
while true do
sleep(60)
   if redstone.getInput("back") == true then
      redstone.setOutput("right", true)
      sleep(10)
      redstone.setOutput("left", true)
      sleep(10)
      redstone.setOutput("right", false)
      sleep(10)
      redstone.setOutput("left", false)
   end
end
Something like that?
 
Last edited:
Code:
while true do
sleep(60)
   if redstone.getInput("back") == true do
      redstone.setOutput("right", true)
      sleep(10)
      redstone.setOutput("left", true)
      sleep(10)
      redstone.setOutput("right", false)
      sleep(10)
      redstone.setOutput("left", false)
   end
end
Something like that?

I am getting a error message?:
bios:367: [string "test"]:3: 'then' expected
 
I am getting a error message?:
bios:367: [string "test"]:3: 'then' expected
Oh.. bollocks... Just another programming noobs continuing nemesis of an error. Replace the "do" with "then" :P