Rewrote day/night handling

Rewrote day/night handling. Much faster, requires no adding worlds to a concurrenthashmap or looping over them. It's also much easier to understand and modify. I made the changes inside the web editor so the commit looks like a mess.