mirror of
https://github.com/rwengine/openrw.git
synced 2024-09-15 15:02:34 +02:00
rwgame: do not copy cheat names
This commit is contained in:
parent
5edead61d0
commit
a9f009f97f
@ -170,7 +170,7 @@ void RWGame::handleCheatInput(char symbol) {
|
|||||||
cheatInputWindow = cheatInputWindow.substr(1) + symbol;
|
cheatInputWindow = cheatInputWindow.substr(1) + symbol;
|
||||||
|
|
||||||
// Helper to check for cheats
|
// Helper to check for cheats
|
||||||
auto checkForCheat = [this](std::string cheat,
|
auto checkForCheat = [this](const std::string& cheat,
|
||||||
std::function<void()> action) {
|
std::function<void()> action) {
|
||||||
RW_CHECK(cheatInputWindow.length() >= cheat.length(), "Cheat too long");
|
RW_CHECK(cheatInputWindow.length() >= cheat.length(), "Cheat too long");
|
||||||
size_t offset = cheatInputWindow.length() - cheat.length();
|
size_t offset = cheatInputWindow.length() - cheat.length();
|
||||||
|
Loading…
Reference in New Issue
Block a user