[Question] how to detect day or night ?

A place to talk to other users about the mod.
Post Reply
User avatar
BigShinyToys
Posts: 836
Joined: Fri Jul 08, 2011 9:53 pm

[Question] how to detect day or night ?

Post by BigShinyToys »

So I built this.
Spoiler
Show
Image
Image
Image
and I want it to open during the day but close at night I remembered that this was possible but can't work out how to do it. If you could be so kind as to remind me thanks in advance.
User avatar
Elevatator
Posts: 573
Joined: Tue Jan 03, 2012 6:32 pm

Re: [Question] how to detect day or night ?

Post by Elevatator »

a lens and a detector block.
⠀⠀⠀⢀⣀⣠⣤⣤⣤⣶⣶⣶⣦⡀
⠀⠀⢠⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣦
⠀⢀⣾⣿⣿⠟⠉⠀⠀⠀⠀⠈⠻⣿⣿⣷⣄
⠀⣼⣿⣿⠏⠀⠀⠀⠀⠀⠀⠀⠀⠘⣿⣿⣿⣧
⣰⣿⣿⣿⡀⠀⢀⣴⣾⠿⣵⣦⠀⠀⣿⣿⣿⠇
⠙⢿⣿⣿⣇⠀⠈⠛⠁⠀⠈⠁⠀⣠⣿⣿⡏
⠀⠀⠻⣿⣿⣷⣤⣀⣀⢀⣀⣠⣾⣿⣿⡿
⠀⠀⠀⠈⢻⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡥⠤⠒⣢
⠀⠀⠀⠀⣀⣽⣿⣿⡿⠿⠿⠛⠉⠁⣀⣤⣶⠟⠁
⠀⠀⢴⣭⣥⣶⣾⣿⡇⠀⠀⠀⠀⢸⣿⣿⠁
⠀⠀⠀⠀⢀⣿⣿⣿⡷⠀⠀⠀⠀⢸⣿⣿⣧⡀
⠀⠀⠀⠀⢾⣿⣿⣿⣤⣤⣤⣤⣤⣼⣿⣿⣿⠇
⠀⠀⠀⠀⠀⠀⠉⠉⠉⠉⠉⠉⠉⠉⠉⠁
User avatar
BigShinyToys
Posts: 836
Joined: Fri Jul 08, 2011 9:53 pm

Re: [Question] how to detect day or night ?

Post by BigShinyToys »

Elevatator wrote:a lens and a detector block.
In what configuration ?
User avatar
Toyi
Posts: 40
Joined: Sun Apr 29, 2012 2:47 pm

Re: [Question] how to detect day or night ?

Post by Toyi »

BigShinyToys wrote:In what configuration ?
Place the lens' light input looking to the sky (must have a clear view) and just one block below place the detector block also looking up.

Take note that you must leave the area around your lens free of torches or another artificial lights or it won't work. Personally I use half slabs around it so no monsters can spawn near my day/night detector array.
dawnraider wrote: Ah, yes. I always love gathering info through violence ;) Anyways, nice job on starting this up!
Image
User avatar
BigShinyToys
Posts: 836
Joined: Fri Jul 08, 2011 9:53 pm

Re: [Question] how to detect day or night ?

Post by BigShinyToys »

Is this meant to work ?
Image

If yes then is this a bug ? else what have I done wrong?
User avatar
Last_Jedi_Standing
Posts: 89
Joined: Sat Jul 28, 2012 8:41 pm

Re: [Question] how to detect day or night ?

Post by Last_Jedi_Standing »

BigShinyToys wrote:Is this meant to work ?

If yes then is this a bug ? else what have I done wrong?
The output of the lens needs to actually be touching the detector block.
DO-RO'IK VONG PRATTE!
User avatar
BigShinyToys
Posts: 836
Joined: Fri Jul 08, 2011 9:53 pm

Re: [Question] how to detect day or night ?

Post by BigShinyToys »

Thanks Last_Jedi_Standing I never thought to put it right on top I thought that would produce always on for some reason.

This set up works
Spoiler
Show
Image
Image
User avatar
Poppycocks
Posts: 825
Joined: Thu Dec 22, 2011 2:11 pm

Re: [Question] how to detect day or night ?

Post by Poppycocks »

Make sure to put it into a tunnel topped off with slabs, you don't want it to activate due to torchlight - and you don't want mobs running on top of it either.
User avatar
BigShinyToys
Posts: 836
Joined: Fri Jul 08, 2011 9:53 pm

Re: [Question] how to detect day or night ?

Post by BigShinyToys »

Poppycocks wrote:Make sure to put it into a tunnel topped off with slabs, you don't want it to activate due to torchlight - and you don't want mobs running on top of it either.
good idea I have encased it in a 5 hight obsidian pipe caped with slabs.
Ancilangeli
Posts: 80
Joined: Sun Jul 22, 2012 12:36 am

Re: [Question] how to detect day or night ?

Post by Ancilangeli »

i just facepalmed sooooo hard...
i too thought it would detect the lens itself rather than converting the 2 block tall combination into a single entity (because in my mind that is what it is doing).
the bad part is that my lens testing area was much bigger (and even tested the effect at different y levels) and i never thought to at least test it. im such a noob
how to take a no like a sir
Spoiler
Show
a forum user after being told they couldnt do something wrote:Alright, that's all I wanted to know, thank you very much.

I think that this closes the issue. Thread can be locked.
tom_savage
Posts: 258
Joined: Tue Aug 21, 2012 1:48 pm

Re: [Question] how to detect day or night ?

Post by tom_savage »

I facepalmed so hard when I saw the answer to this. I feel like a moron.
Post Reply