Get Battery Percentage (OS) #8692
Replies: 2 comments 1 reply
-
This was attempted a while ago, but was removed because the implementation was never completed. That said, the Web platform has also removed its battery status API (as it could be used to fingerprint users, leading to privacy issues). This means an implementation in Godot wouldn't be able to work in web exports. |
Beta Was this translation helpful? Give feedback.
-
Getting the power status and percentage sounds pretty useful, especially for mobile games, which may want to account for it without user intervention. Never had a chance to use the methods in 3.x, but I always thought their existence was neat. |
Beta Was this translation helpful? Give feedback.
-
There was once a function like this - OS.get_power_percent_left()
I dont know why it was removed but I would like to request the following functions:
OS.get_battery_percent()
OS.get_battery_status()
With status "-1" = stationary PC, "0" = not connected, "1" = charging.
I have a Windows implementation that looks like this:
Beta Was this translation helpful? Give feedback.
All reactions