Commit Graph

4 Commits

Author SHA1 Message Date
Solaris
7755a83f5d Battery Percentage and Add More Details to Battery Loads. (#1913)
# Description

This PR is a direct port from goobstation. It allows you to see battery
percentage and more detailed device wattage.

Before:
![Before
change](https://github.com/user-attachments/assets/0c18d251-668c-4d83-900a-e82b585f79f7)

After:
![Battery Percentage
example](https://github.com/user-attachments/assets/bec4a4c5-5d1b-4177-b374-f1d1efd873a0)

---

# Related PRs
https://github.com/Goob-Station/Goob-Station/issues/33854 - Link is
dead(ArtisticRoomba)
https://github.com/Goob-Station/Goob-Station/issues/28487 - Link is
dead(Kevin Zheng)

---

# TODO

- [X] Port Battery Percentage over

---

# Changelog

🆑
- tweak: SMES/Substations/APC show battery percentage now
- tweak: All devices show full wattage in the power monitoring console.

Co-authored-by: Nathaniel Adams <60526456+Nathaniel-Adams@users.noreply.github.com>
Co-authored-by: VMSolidus <evilexecutive@gmail.com>
(cherry picked from commit d5ef8bc19dc885975e33f999543524df1cbeaeac)
2025-03-21 17:05:27 +03:00
chromiumboy
a37bf27456 Power monitoring console overhaul (#20927)
* Prototyping whole station wire map

* More prototyping

* Added icons for the different power distributors and toggleable cable displays

* Power cable layouts are now only sent to the client when the power monitor is open

* UI prototyping

* Power monitors can now see the sprites of distant entities, long entity names are truncated

* Updated how network devices are added to the player's PVS

* More feature prototypes

* Added source / load symbols

* Final prototype! Time to actually code it properly...

* Start of code clean up

* Continuing code clean up

* Fixed UI appearance

* Code clean up complete

* Removed unnecessary changes

* Updated how power values are calculated, added UI warnings for power sinks and power net checks

* Updated how power values are calculated again, added support for portable generators

* Removed unnecessary files

* Map beacons start toggled off, console map now works outside the station, fixed substation icon

* Made some of Sloth's requested changes. Power distributors don't blink anymore, unless selected

* Moved a number of static variables in PowerMonitoringHelper to sensible places in the main files. Added a NavMapTrackableComponent so that you can specify how individual entities appear on the navmap

* Updated the colors/positions of HV cables and SMESes to improve contrast

* Fixed SMES color in map legend

* Partially fixed auto-scrolling on device selection, made sublists alphabetical

* Changed how auto-scroll is handled

* Changed the font color of the console warning messages

* Reduced the font size of beacon labels

* Added the station name to the console

* Organized references

* Removed unwanted changes to RobustToolbox

* Fix merge conflict

* Fix merge conflict, maybe

* Fix merge conflict

* Updated outdated reference

* Fixed portable_generator.yml

* Implemented a number of requested changes, move bit masks to a shared component

* Navigate listings via the navmap

* First attempt at improving efficiency

* Second attempt at optimization, entity grouping added for solar panels

* Finished solar panel entity joining

* Finished major revisions, code clean up needed

* Finializing optimizations

* Made requested changes

* Bug fix, removed obsolete code

* Bug fixes

* Bug fixes

* STarted revisions

* Further revisions

* More revision

* Finalizing revisions. Need to make RT PR

* Code tidying

* More code tidying

* Trying to avoid merge conflicts

* Trying to avoid merge conflicts

* Removed use of PVS

* Improving efficiency

* Addressed a bunch of outstanding issues

* Clear old data on console refresh

* UI adjustments

* Made node comparison more robust. More devices can be combined into one entry

* Added missing component 'dirty'

(cherry picked from commit 1de682e23fd3cb832fa3328a7e6c4bd4b1a858f7)
2024-01-22 18:28:33 +01:00
wrexbe
bc68ac96dd Cleanup the namespaces (#8132) 2022-05-13 17:59:03 +10:00
20kdc
70cd3d18ca Power Monitoring Console (#7849) 2022-05-04 10:59:40 -07:00