15.07.2016, 10:52
Hi, I want /skiptutorial to work in the tutorial. All other commands must not work, except /skiptutorial. I tried making it with strfind, but it doesn't seem to work. There is also /unmute command which works when you are muted, but all other commands don't work when you are muted. I made /skiptutorial the same way, but it doesn't work. Anyways here's the code:
pTutorialStage doesn't affect it, because it's the other tutorial, pTutorial is the main one. What's wrong with it?
Код:
public OnPlayerCommandReceived(playerid, cmdtext[]) { if (!SQL_IsLogged(playerid) || (PlayerData[playerid][pTutorialStage] > 0 || PlayerData[playerid][pKilled] > 0 || PlayerData[playerid][pHospital] != -1)) return 0; if (PlayerData[playerid][pTutorial] > 0 && strfind(cmdtext, "/skiptutorial", true)) return 0; if (PlayerData[playerid][pMuted] && strfind(cmdtext, "/unmute", true)) { SendErrorMessage(playerid, "You are muted by the system."); return 0; }