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

Notifications

Started by MarcoPolo0306, 12 June 2018 - 02:55 PM
MarcoPolo0306 #1
Posted 12 June 2018 - 04:55 PM
A notifications API would be very cool to have. If an OS wanted to get a person's attention (say a program was done downloading) the blank bottom-right corner of the computer would turn a certain color (one of the colors from the color pallet)

How it would be used:


notifications.send("Hello World!", colors.lightBlue) -- sends a notification
notifications.receive(colors.lightBlue) -- receives all notifications and returns them as a table. If a color was provided, then it would return all notifications with that color
notifications.clear() -- Clears all notifacations.

The most recent notifications color will be displayed on the front of the screen.
CLNinja #2
Posted 12 June 2018 - 05:22 PM
If an OS wants to get a persons attention they can just rip user control away. A notification daemon isn't really useful. A menu for notifications with a hotkey or a button onscreen that might change colors or icons is the better way to go about doing it. There's very little screenspace as is, lets not take it up with another box that does nothing useful.

Edit: Not to mention, if there's something to have a notification about in your OS, i'm hoping it's a rednet or modem based chat, because otherwise you're doing something wrong.
Edited on 12 June 2018 - 03:23 PM
Lignum #3
Posted 12 June 2018 - 05:30 PM
While I've got nothing against notifications, this is way out of scope for ComputerCraft's API collection. It's something that should be implemented by players.
Jummit #4
Posted 12 June 2018 - 07:43 PM
This is not very low level like all the other craftOS default apis are. CraftOS only gives you the most basic of the basic, so this api would be very overkill.
osmarks #5
Posted 26 July 2018 - 11:51 AM
This sounds like something which could be implemented by players.