15.08.2014, 15:49
Or, if you're already using sscanf you can use its "quiet" option for type checking without the need for an extra function. But most of the time you do need to store what was entered and so this also saves you the use of strval.
pawn Код:
if(sscanf(inputtext, "{i}"))