Quote:
Originally Posted by AmigaBlizzard
First of all, using sscanf to extract the full text inside params and copy it back into params is quite useless.
Just delete that line as it won't do anything, except check if params is empty.
Replace the sscanf line by
PHP Code:
if (strlen(params) == 0) return SendUsageMSG(playerid, "/addhint [TEXT]");
For storing the entered text into your enum, use format:
PHP Code:
format(hInfo[hintid][hText], 50, params);
Using "hInfo[hintid][hText] = params[50]", you were only copying the 51st character into your hText variable (or the text starting from the 51st character till the end, which would never be anything because the length of your text is limited by 50 characters.
|
Worked, thank you so much!