Skip to content

Commit

Permalink
Add turbo rings for Fightboard right screen display (#786)
Browse files Browse the repository at this point in the history
  • Loading branch information
TheTrainGoes authored Jan 9, 2024
1 parent 7a22b1d commit bcf73ab
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/addons/i2cdisplay.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -795,6 +795,17 @@ void I2CDisplayAddon::drawFightboard(int startX, int startY, int buttonRadius, i
{
const int buttonMargin = buttonPadding + (buttonRadius * 2);

// inner circle for turbo enabled
if(gamepad->turboState.buttons & GAMEPAD_BUTTON_2) obdPreciseEllipse(&obd, startX + (buttonMargin * 3.625), startY * 1.25, buttonRadius - 3, buttonRadius - 3, 1, false); //P1 B3
if(gamepad->turboState.buttons & GAMEPAD_BUTTON_3) obdPreciseEllipse(&obd, startX + (buttonMargin * 4.625), startY - (buttonMargin / 4), buttonRadius - 3, buttonRadius - 3, 1, false); //P2 B4
if(gamepad->turboState.buttons & GAMEPAD_BUTTON_5) obdPreciseEllipse(&obd, startX + (buttonMargin * 5.625), startY - (buttonMargin / 4), buttonRadius - 3, buttonRadius - 3, 1, false); //P3 R1
if(gamepad->turboState.buttons & GAMEPAD_BUTTON_4) obdPreciseEllipse(&obd, startX + (buttonMargin * 6.625), startY - (buttonMargin / 4), buttonRadius - 3, buttonRadius - 3, 1, false); //P4 L1

if(gamepad->turboState.buttons & GAMEPAD_BUTTON_0) obdPreciseEllipse(&obd, startX + (buttonMargin * 3.625), startY + buttonMargin * 1.25, buttonRadius - 3, buttonRadius - 3, 1, false); //K1 B1
if(gamepad->turboState.buttons & GAMEPAD_BUTTON_1) obdPreciseEllipse(&obd, startX + (buttonMargin * 4.625), startY + buttonMargin - (buttonMargin / 4), buttonRadius - 3, buttonRadius - 3, 1, false); //K2 B2
if(gamepad->turboState.buttons & GAMEPAD_BUTTON_7) obdPreciseEllipse(&obd, startX + (buttonMargin * 5.625), startY + buttonMargin - (buttonMargin / 4), buttonRadius - 3, buttonRadius - 3, 1, false); //K3 R2
if(gamepad->turboState.buttons & GAMEPAD_BUTTON_6) obdPreciseEllipse(&obd, startX + (buttonMargin * 6.625), startY + buttonMargin - (buttonMargin / 4), buttonRadius - 3, buttonRadius - 3, 1, false); //K4 L2

obdPreciseEllipse(&obd, (startX + buttonMargin * 3.625), startY * 1.25, buttonRadius, buttonRadius, 1, pGamepad->pressedB3());
obdPreciseEllipse(&obd, (startX + buttonMargin * 4.625), startY - (buttonMargin / 4), buttonRadius, buttonRadius, 1, pGamepad->pressedB4());
obdPreciseEllipse(&obd, (startX + buttonMargin * 5.625), startY - (buttonMargin / 4), buttonRadius, buttonRadius, 1, pGamepad->pressedR1());
Expand Down

0 comments on commit bcf73ab

Please sign in to comment.