Jump to content

Question

Posted

Salutare.

Am o intampinat o problema cu functia onplayercommandtext dupa ce am integrat un FS in onplayercommandtext.

Deci orice comanda as executa imi zice "Server Unknown command", am adaugat

    new pos, funcname[32];
	while(cmdtext[++pos] > ' ')
	{
		funcname[pos-1] = tolower(cmdtext[pos]);
	}
	strins(funcname, "cmd_", 0, sizeof(funcname));
	while (cmdtext[pos] == ' ') pos++;
	if(!cmdtext[pos])
	{
		return CallLocalFunction(funcname, "is", playerid, "\1");
	}
Si 
return CallLocalFunction(funcname, "is", playerid, cmdtext[pos]);[/code]

la sfarsit-ul functiei dupa ultima comanda, am adaugat codu asta ca sa functioneze niste comenzi "scriptate" in zcmd, merg si cele vechi doar ca imi da dupa cum am zis "Server Unknown command" si nu imi arata de exemplu USAGE: /ban [playerid/PartOfName] [reason] la comanda /ban.In schimb, comenzile adaugate si "scriptate" in zcmd merg.

signature.php?bg=000000&text=FFFFFF&border=a0a0a0&ip=93.119.26.222&port=7777&bg_image=

1 answer to this question

Recommended Posts

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.