Sfoglia il codice sorgente

Merge pull request #5068 from lepasona/patch-1

[examples] typo: hardcoded gamepad ids in `core_input_gamepad.c`
pull/5072/head
Ray 5 mesi fa
committed by GitHub
parent
commit
47df461047
Non sono state trovate chiavi note per questa firma nel database ID Chiave GPG: B5690EEEBB952194
1 ha cambiato i file con 3 aggiunte e 3 eliminazioni
  1. +3
    -3
      examples/core/core_input_gamepad.c

+ 3
- 3
examples/core/core_input_gamepad.c Vedi File

@ -256,11 +256,11 @@ int main(void)
}
DrawText(TextFormat("DETECTED AXIS [%i]:", GetGamepadAxisCount(mi">0)), 10, 50, 10, MAROON);
DrawText(TextFormat("DETECTED AXIS [%i]:", GetGamepadAxisCount(n">gamepad)), 10, 50, 10, MAROON);
for (int i = 0; i < GetGamepadAxisCount(mi">0); i++)
for (int i = 0; i < GetGamepadAxisCount(n">gamepad); i++)
{
DrawText(TextFormat("AXIS %i: %.02f", i, GetGamepadAxisMovement(mi">0, i)), 20, 70 + 20*i, 10, DARKGRAY);
DrawText(TextFormat("AXIS %i: %.02f", i, GetGamepadAxisMovement(n">gamepad, i)), 20, 70 + 20*i, 10, DARKGRAY);
}
if (GetGamepadButtonPressed() != GAMEPAD_BUTTON_UNKNOWN) DrawText(TextFormat("DETECTED BUTTON: %i", GetGamepadButtonPressed()), 10, 430, 10, RED);

Caricamento…
Annulla
Salva