CLOCKS

  • 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

NHsports123

New Member
Jul 29, 2019
15
0
0
How do I make a working clock that displays AM and PM time? I made one that displays one time but does not auto-update. So, how would I make an auto-updating, or looping clock?

Thanks!
 

Yusunoha

New Member
Jul 29, 2019
6,440
-4
0
How do I make a working clock that displays AM and PM time? I made one that displays one time but does not auto-update. So, how would I make an auto-updating, or looping clock?

Thanks!

depends, do you want to make a clock with computercraft?
 

JuliCash

New Member
Jul 29, 2019
95
0
0
There is also a Time-Card for Industrial Information Panel from IC2
I like the look, and you can determine the color expand the size
 

NHsports123

New Member
Jul 29, 2019
15
0
0
I'm on Yogcraft, if that helps. I just want to make a simple AM/PM 1 X 2 clock that displays the time in the Minecraft world.
 

MilConDoin

New Member
Jul 29, 2019
1,204
0
0
I'm on Yogcraft, if that helps. I just want to make a simple AM/PM 1 X 2 clock that displays the time in the Minecraft world.
What do you mean with this? One block a RP2 sequencer synced to worldtime (IIRC you'll need to set it to 5 minutes), the other a lamp which is lit on PM and off on AM?
 

Zjarek_S

New Member
Jul 29, 2019
802
0
0
Her you are, simple 1 x 2 clock that displays the time in the minecraft world:
3pqBa4c.png


If you just want lights for AM and PM, you can make something like this: http://imgur.com/a/R8Zxq ,sequencer is set to 5 minutes, rotate it to match lights to AM/PM cycle.
 

NHsports123

New Member
Jul 29, 2019
15
0
0
What do you mean with this? One block a RP2 sequencer synced to worldtime (IIRC you'll need to set it to 5 minutes), the other a lamp which is lit on PM and off on AM?

All I want to do is make a monitor that says "The time is" then displays the current minecraft world time in AM and PM.
 

MilConDoin

New Member
Jul 29, 2019
1,204
0
0
All I want to do is make a monitor that says "The time is" then displays the current minecraft world time in AM and PM.
So you want a computer connected to a monitor, which displays the time? Why didn't you say so from the beginning?
Since you're able to output the time once, just make a while true do loop around it with a sleep(1) somewhere in there.
 

NHsports123

New Member
Jul 29, 2019
15
0
0
Of course I understand a 24-hour clock, obviously. But in my country we go by the 12-hour clock and so I want to make that one. Where is the IC2 Information Guide? Should I just search "IC2 Clock"?

Thanks for the help so far, by the way. :)
 

NHsports123

New Member
Jul 29, 2019
15
0
0
What the hell do you think I've been doing? Your link doesn't help, by the way. I know how to make a clock, but I want a LOOPING clock. You know, one that tells the current time.
 

SkyBoy96

New Member
Jul 29, 2019
100
0
0
What the hell do you think I've been doing? Your link doesn't help, by the way. I know how to make a clock, but I want a LOOPING clock. You know, one that tells the current time.
Code:
While true do
--insert code from link here
end
 

Mikey_R

New Member
Jul 29, 2019
382
0
0
You do know that, as far as I know, it isn't possible. Even if you made a clock that kept Minecraft time, as soon as you slept in a bed it would mess it up.

Minecraft doesn't keep track of time, just that, after X mins (I forget how long a day is) it turns into night, then after Y mins it turns into day. There is no clock in Minecraft that says it's 7 pm, therefore go to night.

So, as long as you never sleep you should be able to make one, which wouldn't be hard.

I suspect, in Minecraft 1.5.1 it could be possible, but only because of different redstone signal strengths, meaning you can hook up a daylight sensor to a computer (which I am assuming will have the functionality to detect differing redstone strengths), at least then you could make it auto set the time when the redstone signal changes strength.

Also, that link is helpful. Using just that one page (and one other as I forgot the command to clear the screen) I now have a computer which shows a time and refreshes every second. Ontop of that, it;s really simple and uses only 7 lines. It could be possible to make it shorter, but I just wanted something that worked. Again, it's not accurate to Minecraft time, but then again, it never could be.
 

NHsports123

New Member
Jul 29, 2019
15
0
0
You do know that, as far as I know, it isn't possible. Even if you made a clock that kept Minecraft time, as soon as you slept in a bed it would mess it up.

Minecraft doesn't keep track of time, just that, after X mins (I forget how long a day is) it turns into night, then after Y mins it turns into day. There is no clock in Minecraft that says it's 7 pm, therefore go to night.

So, as long as you never sleep you should be able to make one, which wouldn't be hard.

I suspect, in Minecraft 1.5.1 it could be possible, but only because of different redstone signal strengths, meaning you can hook up a daylight sensor to a computer (which I am assuming will have the functionality to detect differing redstone strengths), at least then you could make it auto set the time when the redstone signal changes strength.

Also, that link is helpful. Using just that one page (and one other as I forgot the command to clear the screen) I now have a computer which shows a time and refreshes every second. Ontop of that, it;s really simple and uses only 7 lines. It could be possible to make it shorter, but I just wanted something that worked. Again, it's not accurate to Minecraft time, but then again, it never could be.

The link doesn't say how to loop, and when I looked up how to loop I got confused because I'm very new at this and I'm a terrible programmer. I can make a clock which shows one time, but I don't know how to make it refresh constantly.[DOUBLEPOST=1364760409][/DOUBLEPOST]
Code:
While true do
--insert code from link here
end

I put that in and it didn't work for me.
 

Mikey_R

New Member
Jul 29, 2019
382
0
0
Mine was a bit different.
Code:
i = 1
while i == 1 do
term.clear()
term.setCursorPos(1,1)
print(textutils.formatTime(os.time(), boolean))
sleep(1)
end

The term.clear and term.setSursorPos just clear the screen and resets the cursor so it always puts the time on the top line.

The sleep is just so that there is a delay between time refreshes, no point having it refresh every tick.

The while i == 1 do
"code"
end

Is just an infinite Do loop. I set the variable i to be 1 at the start, so it is always true and so always loops. You could replace the first 2 lines with 'while true do' and it should still work.