Rename `uu`

master
Rob Pilling 2024-07-02 08:42:50 +01:00
parent f8e854403a
commit acd9b3be94
1 changed files with 4 additions and 4 deletions

View File

@ -19,7 +19,7 @@
return COLORS.low; return COLORS.low;
}; };
function draw(_self, uu) { function draw(_self, pwrOverride) {
let x = this.x; let x = this.x;
let y = this.y; let y = this.y;
if (x != null && y != null) { if (x != null && y != null) {
@ -38,7 +38,7 @@
// Show percentage // Show percentage
g.setFontAlign(0,0); g.setFontAlign(0,0);
g.setFont('Vector',16); g.setFont('Vector',16);
this.drawText(l, uu); this.drawText(l, pwrOverride);
} }
old_x = this.x; old_x = this.x;
old_y = this.y; old_y = this.y;
@ -53,8 +53,8 @@
let drawText; let drawText;
if(E.getPowerUsage){ if(E.getPowerUsage){
drawText = function(l, uu) { drawText = function(l, pwrOverride) {
const u = uu == null ? E.getPowerUsage().total : uu; const u = pwrOverride == null ? E.getPowerUsage().total : pwrOverride;
// text colour is based off power usage // text colour is based off power usage
// colour height is based off time left, higher = more // colour height is based off time left, higher = more