This is a read-only snapshot of the ComputerCraft forums, taken in April 2020.
SebaTeck's profile picture

Monitor Clock+Decoration scale

Started by SebaTeck, 10 October 2012 - 12:42 PM
SebaTeck #1
Posted 10 October 2012 - 02:42 PM
Asking a god of LUA again v.v
2 day ago i wont to make this on my monitor,so i can use a old program

print"l Color l Decimal l Hexadecimal l Binary "
print"l colors.white l 1 l 0x1 l 0000000000000001"
print"l colors.orange l 2 l 0x2 l 0000000000000010"
print"l colors.magenta l 4 l 0x4 l 0000000000000100"
print"l colors.lightBlue l 8 l 0x8 l 0000000000001000"
print"l colors.yellow l 16 l 0x10 l 0000000000010000"
print"l colors.lime l 32 l 0x20 l 0000000000100000"
print"l colors.pink l 64 l 0x40 l 0000000001000000"
print"l colors.gray l 128 l 0x80 l 0000000010000000"
print"l colors.lightGray l 256 l 0x100 l 0000000100000000"
print"l colors.cyan l 512 l 0x200 l 0000001000000000"
print"l colors.purple l 1024 l 0x400 l 0000010000000000"
print"l colors.blue l 2048 l 0x800 l 0000100000000000"
print"l colors.brown l 4096 l 0x1000 l 0001000000000000"
print"l colors.green l 8192 l 0x2000 l 0100000000000000"
print"l colors.red l 16384 l 0x4000 l 0100000000000000"
print"l colors.black l 32768 l 0x8000 l 1000000000000000"
then i wont a clock to
while true do
shell.run("time")
sleep(0.5)
but i realised that its too big D:
so how i a make the time script stay in a precise place
and how i combine the colors thing and the clock and at same time a minor scale of text?? D:
(sorry for my very bad english e.e)
jag #2
Posted 10 October 2012 - 02:52 PM
Is it too big? Even on a maximum sized monitor?
SebaTeck #3
Posted 10 October 2012 - 03:03 PM
Its too big -.-"" i want something smaller
Ditto8353 #4
Posted 10 October 2012 - 03:24 PM
This should print the server time at the bottom right of the screen. Still working on the color display solution…
You can't make the font any smaller, but would displaying only a few lines at a time be ok?


do
local t = textutils.formatTime(os.time())
local x,y = term.getSize()
x = x - string.len(t) + 1
term.setCursorPos(x,y)
term.write(t)
end
Ditto8353 #5
Posted 10 October 2012 - 05:03 PM
Oh… Read this:

http://www.computercraft.info/forums2/index.php?/topic/4521-how-to-set-the-scale-of-text-on-a-monitor/