Vexatos / Computronics

A ComputerCraft/OpenComputers addon mod.
125 stars 51 forks source link

Real-time clock #87

Closed XeonSquared closed 9 years ago

XeonSquared commented 9 years ago

I was just talking to Vexatos and thought it would be a great idea to have a component that fires events for every world tick, possibly programmable for every x world ticks. Just thought it'd be cool.

Vexatos commented 9 years ago

@asiekierka @fnuecke I need opinions on this because I have no idea if it's a good idea or not.

fnuecke commented 9 years ago

I'm not sure what the expected advantage over event.timer would be. Except that that's part of OpenOS - but it's easy to recreate for custom OSes, and I'm not sure you'd want to make a custom OS depend on an optional component?

On the contrary, I can see this spamming the signal queue pretty badly in a possibly unexpected manner (as opposed to writing Lua code that calls pushSignal yourself), which increases the likelihood of other signals being dropped (and in the worst case, people thinking it's a bug).

Vexatos commented 9 years ago

Yea, it would probably push a LOT of signals.

SoniEx2 commented 9 years ago

A real clock (as in system time) would be nicer

Vexatos commented 9 years ago

I guess I won't do it, @fnuecke is right about the event spam.