- Blood: fixed parser for 'mario' cheat to treat a leading space for the level number as 0.

This commit is contained in:
Christoph Oelckers 2021-07-25 11:53:20 +02:00
parent b23db149e3
commit fa586d6d7c

View file

@ -267,7 +267,8 @@ static int parseArgs(char *pzArgs, int *nArg1, int *nArg2)
if (!nArg1 || !nArg2 || strlen(pzArgs) < 3)
return -1;
*nArg1 = pzArgs[0] - '0';
*nArg2 = (pzArgs[1] - '0')*10+(pzArgs[2]-'0');
int a1 = pzArgs[1] == ' ' ? 0 : pzArgs[1] - '0';
*nArg2 = a1 * 10 + (pzArgs[2] - '0');
return 2;
}