arreglos en Console i SS

This commit is contained in:
2026-03-29 14:24:20 +02:00
parent d6ecadfd3a
commit 2fe79de1d8
3 changed files with 7 additions and 6 deletions

View File

@@ -114,24 +114,24 @@ static const std::vector<ConsoleCommand> COMMANDS = {
// SS [ON|OFF|SIZE] — Supersampling
{.keyword = "SS", .execute = [](const std::vector<std::string>& args) -> std::string {
if (!args.empty() && args[0] == "SIZE") {
if (!Options::video.supersampling) { return "Supersampling OFF"; }
if (!Options::video.supersampling) { return "Supersampling is OFF: no texture"; }
const auto [w, h] = Screen::get()->getSsTextureSize();
if (w == 0) { return "SS texture: not active"; }
return "SS texture: " + std::to_string(w) + "x" + std::to_string(h);
}
if (args.empty()) {
Screen::get()->toggleSupersampling();
return std::string("Supersampling ") + (Options::video.supersampling ? "ON" : "OFF");
return std::string("PostFX Supersampling ") + (Options::video.supersampling ? "ON" : "OFF");
}
if (args[0] == "ON") {
if (Options::video.supersampling) { return "Supersampling already ON"; }
Screen::get()->toggleSupersampling();
return "Supersampling ON";
return "PostFX Supersampling ON";
}
if (args[0] == "OFF") {
if (!Options::video.supersampling) { return "Supersampling already OFF"; }
Screen::get()->toggleSupersampling();
return "Supersampling OFF";
return "PostFX Supersampling OFF";
}
return "Usage: SS [ON|OFF|SIZE]";
}},