Page 1 of 1

Better Robot Notifications

Posted: Fri Feb 03, 2017 6:50 am
by PeteTheLich
Instead of this gigantic flashing monstrosity

Image

It'd be nice to have a "construction zone" drawn either the same box as the deconstruction planner or the 2 furthest items in a blueprint to draw a box

especially for large construction zones im sure it would be easier on the CPU than having to constantly draw 500 sprites overlapping and remove them

could also put a transparency slider in the options if the box is too obtrusive and just put a single robot marker


to take it one step further when you mouse over the zone it could read out what is being done there or missing

you could mouse over your outpost
"oh they need more repair packs"

"these robots are removing trees"

"construction additional solar panel arrays"

Re: Better Robot Notifications

Posted: Fri Feb 03, 2017 7:15 pm
by Adil
Seems like a good idea.

Re: Better Robot Notifications

Posted: Fri Feb 03, 2017 10:02 pm
by ssilk
I like it.
Added to viewtopic.php?f=80&t=16566 Alerts, Alert-Info (Map), visible/audible Indication

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 3:49 am
by Rseding91
The game has no concept of blueprints when it comes to showing an alert like that.

All the game knows is: there's a ghost within a logistic network range that doesn't have a robot available to build it (or what ever else the alert is) and so it shows an alert.
  • It doesn't know about any other ghosts that may exist
  • It doesn't have any idea what other alerts exist
  • It doesn't know if there are other logistic networks that might be able to service the ghost
It simply knows the current network it found that overlaps with the ghost can't service it due to what ever alert it shows: out of robots, out of items, and so on.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 5:47 am
by Adil
Well, that's insightful about game inner workings, but it doesn't make
PeteTheLich wrote:gigantic flashing monstrosity
go away.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 6:09 pm
by Xeanoa
Adil wrote:Well, that's insightful about game inner workings, but it doesn't make
PeteTheLich wrote:gigantic flashing monstrosity
go away.
One option would be to not draw overlapping triangles, and instead draw a counter on them that counts the amount of triangles not drawn +1.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 6:27 pm
by Optera
Xeanoa wrote:
Adil wrote:Well, that's insightful about game inner workings, but it doesn't make
PeteTheLich wrote:gigantic flashing monstrosity
go away.
One option would be to not draw overlapping triangles, and instead draw a counter on them that counts the amount of triangles not drawn +1.
A good practice.
I use that whenever I have to display positions on a map. Depending on zoom and pan it groups overlapping markers on the fly inside the map draw routines. It's a really cheap check if one marker overlaps with another and run a counter, and can even be run in a separate thread.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 7:56 pm
by Rseding91
Optera wrote:A good practice.
I use that whenever I have to display positions on a map. Depending on zoom and pan it groups overlapping markers on the fly inside the map draw routines. It's a really cheap check if one marker overlaps with another and run a counter, and can even be run in a separate thread.
It's not cheap at all. It's O(N^2) complexity to make sure that rendering alerts never overlap other alerts. More so if you want to account for the fact the alert icon is a triangle.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 8:39 pm
by Optera
Rseding91 wrote:
Optera wrote:A good practice.
I use that whenever I have to display positions on a map. Depending on zoom and pan it groups overlapping markers on the fly inside the map draw routines. It's a really cheap check if one marker overlaps with another and run a counter, and can even be run in a separate thread.
It's not cheap at all. It's O(N^2) complexity to make sure that rendering alerts never overlap other alerts. More so if you want to account for the fact the alert icon is a triangle.
Not cheap? I drew several hundred pins in bing maps like this in "real time" (actual map update time was 1-5s or on user interaction): store bounding box, if bounding box overlaps counter of existing shape ++1 otherwise draw shape. For map visualization it's sufficient to use bounding boxes instead of actual shapes.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 9:12 pm
by Xeanoa
How could drawing a few alerts ever use enough processing time to worry about it? They're usually not present, usually done within a couple minutes, and don't need to be updated every tick.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 9:18 pm
by Rseding91
Optera wrote:Not cheap? I drew several hundred pins in bing maps like this in "real time" (actual map update time was 1-5s or on user interaction): store bounding box, if bounding box overlaps counter of existing shape ++1 otherwise draw shape. For map visualization it's sufficient to use bounding boxes instead of actual shapes.
That's not cheap or fast at all... Right now it takes a fraction of a millisecond to draw all of the triangles at O(1) complexity.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 9:18 pm
by Rseding91
Xeanoa wrote:How could drawing a few alerts ever use enough processing time to worry about it? They're usually not present, usually done within a couple minutes, and don't need to be updated every tick.
Because everything in the game has to scale. If it's "ok" with 100-200 alerts and then "complete garbage" when there's 1000-5000 that's unacceptable.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 9:23 pm
by Xeanoa
Rseding91 wrote:when there's 1000-5000 that's unacceptable.
Does that mean it will be possible to dispatch robots at a higer rate per tick than the current limit? If not, why worry about it?

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 9:33 pm
by Rseding91
Xeanoa wrote:
Rseding91 wrote:when there's 1000-5000 that's unacceptable.
Does that mean it will be possible to dispatch robots at a higer rate per tick than the current limit? If not, why worry about it?
You can have alerts for multiple things going off at once. Missing robots, missing materials, multiple players and so on.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 9:42 pm
by Xeanoa
Rseding91 wrote:
Xeanoa wrote:
Rseding91 wrote:when there's 1000-5000 that's unacceptable.
Does that mean it will be possible to dispatch robots at a higer rate per tick than the current limit? If not, why worry about it?
You can have alerts for multiple things going off at once. Missing robots, missing materials, multiple players and so on.
Then how about this: One alert per type per chunk. Since you already know which chunk the alert is on, it should be reasonably easy to group them up this way? Some overlapping is to be expected at lower zoom levels, but it's way better than what we have currently. You could even add zoom level breaking points at which you group 2x2 chunks or 3x3 chunks.

Re: Better Robot Notifications

Posted: Sat Feb 04, 2017 10:14 pm
by aubergine18
For on-map notifications the approach taken by Colossal Order's "Cities Skylines" game is worth consideration.

It limits number of same icons shown within a given area based on map zoom. Zoom all the way out and you might only see one icon for a particular type of notification within a map chunk. Zoom in more and there might be up to 4 icons of a given type per chunk (one per quadrant of the chunk).. zoomed all the way in you'd see all of them.

EDIT: Just realised this sort of thing already mentioned above. I need more sleep lol.

Re: Better Robot Notifications

Posted: Sun Feb 05, 2017 2:16 pm
by ssilk
To make this feature useful, it would be enough to show one alert per chunk (which is then also the smalles/biggest area).
It would make sense to show this alert symbol on the first place it finds and if there are others in the same chunk a number, how many.

Re: Better Robot Notifications

Posted: Thu Apr 27, 2017 1:11 am
by PeteTheLich
So as a work around all I did was replace the robot sprite with a pixel square

(outlined in this reddit post)
https://www.reddit.com/r/factorio/comme ... ot_alerts/

Would it be possible to have it use a separate icon for the notification and whats drawn on the screen?

https://gfycat.com/GeneralBronzeCapybara

Since this looks substantially better than before with basically no change