canvi de pc (toquejant Options)

This commit is contained in:
2025-06-14 16:28:36 +02:00
parent 4b8cc67b5c
commit 23e8f90274
27 changed files with 505 additions and 454 deletions

View File

@@ -28,7 +28,7 @@ void DefineButtons::render()
{
if (enabled_)
{
text_->writeCentered(x_, y_ - 10, lang::getText("[DEFINE_BUTTONS] PLAYER") + std::to_string(options.controllers.at(index_controller_).player_id));
text_->writeCentered(x_, y_ - 10, Lang::getText("[DEFINE_BUTTONS] PLAYER") + std::to_string(options.controllers.at(index_controller_).player_id));
text_->writeCentered(x_, y_, controller_names_.at(index_controller_));
text_->writeCentered(x_, y_ + 10, buttons_.at(index_button_).label);
}
@@ -135,9 +135,9 @@ bool DefineButtons::checkButtonNotInUse(SDL_GamepadButton button)
void DefineButtons::clearButtons()
{
buttons_.clear();
buttons_.emplace_back(lang::getText("[DEFINE_BUTTONS] FIRE_LEFT"), InputAction::FIRE_LEFT, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(lang::getText("[DEFINE_BUTTONS] FIRE_UP"), InputAction::FIRE_CENTER, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(lang::getText("[DEFINE_BUTTONS] FIRE_RIGHT"), InputAction::FIRE_RIGHT, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(lang::getText("[DEFINE_BUTTONS] START"), InputAction::START, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(lang::getText("[DEFINE_BUTTONS] SERVICE_MENU"), InputAction::SERVICE, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(Lang::getText("[DEFINE_BUTTONS] FIRE_LEFT"), InputAction::FIRE_LEFT, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(Lang::getText("[DEFINE_BUTTONS] FIRE_UP"), InputAction::FIRE_CENTER, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(Lang::getText("[DEFINE_BUTTONS] FIRE_RIGHT"), InputAction::FIRE_RIGHT, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(Lang::getText("[DEFINE_BUTTONS] START"), InputAction::START, SDL_GAMEPAD_BUTTON_INVALID);
buttons_.emplace_back(Lang::getText("[DEFINE_BUTTONS] SERVICE_MENU"), InputAction::SERVICE, SDL_GAMEPAD_BUTTON_INVALID);
}