Mastergalen (talk | contribs) m (1 revision) |
(No difference)
|
This tutorial will teach you how to setup a simple Clock for your computer.
For this version you'll need a Disk Drive at the left side (with Disk) & a Monitor on the right. (Tip: Creating this program on the Disk, will make the shutdown of the program easier.)
Start by editing the file "disk/clock" (from your Computer [cd /]):
-- Simple Clock -- Written by Galxis -- Posted to The Tekkit Wiki on 11/04/2012 while true do if disk.isPresent("left") then shell.run("monitor", "right", "time") sleep(5) end term.clear() shell.run("monitor", "right", "clear") <---- Otherwise the Monitor gets flooded! term.setCursorPos(1, 1) end
But if you would like to create it with a Redstone Input on the Back:
-- Simple Clock -- Written by Galxis -- Posted to The Tekkit Wiki on 11/04/2012 while true do if redstone.getInput("back") then shell.run("monitor", "right", "time") sleep(5) end term.clear() shell.run("monitor", "right", "clear") <--- Same as above! term.setCursorPos(1, 1) end
The Coding
The Command :)
As of the latest update for Tekkit, the command "time" can be inputted into a computer, which will reveal the time.
Do you need a wiki for your Minecraft mod/gaming wiki? We'll host it for free! Contact us.