mirror of
https://github.com/DrBeef/Raze.git
synced 2025-01-19 07:31:03 +00:00
- adapted cheat input handler to treat spaces as '0' when entering parts of numeric fields.
This commit is contained in:
parent
fa586d6d7c
commit
3864dcfc17
1 changed files with 2 additions and 2 deletions
|
@ -69,10 +69,10 @@ static bool CheatAddKey (cheatseq_t *cheat, uint8_t key, bool *eat)
|
||||||
cheat->Pos = cheat->Sequence;
|
cheat->Pos = cheat->Sequence;
|
||||||
cheat->CurrentArg = 0;
|
cheat->CurrentArg = 0;
|
||||||
}
|
}
|
||||||
if (*cheat->Pos == '#' && key >= '0' && key <= '9')
|
if (*cheat->Pos == '#' && (key >= '0' && key <= '9') || key == ' ')
|
||||||
{
|
{
|
||||||
*eat = true;
|
*eat = true;
|
||||||
cheat->Args[cheat->CurrentArg++] = key;
|
cheat->Args[cheat->CurrentArg++] = key == ' ' ? '0' : key;
|
||||||
cheat->Pos++;
|
cheat->Pos++;
|
||||||
}
|
}
|
||||||
else if (upperforlower[key] == upperforlower[*cheat->Pos])
|
else if (upperforlower[key] == upperforlower[*cheat->Pos])
|
||||||
|
|
Loading…
Reference in a new issue