Jump to content
  • 0

pomoc PM Error 2 radky


BTomas

Dotaz

caute mam 2 errory  v pm

 

radek 100

dcmd(pm,           2, cmdtext);

radek 715

 

tam neni nic.. ;(

 

ale zde je kdyztak pulka  

dcmd_pm(playerid, params[])
{
    if (IsPlayerConnected(playerid))
	{
		new pos;
    	if (!params[0] || !(pos = chrfind(' ', params) + 1) || !params[pos]) return SendClientMessage(playerid, 0x99FF00AA, "Pouziti: /pm [id] [text]");
    	new id = strval(params), string[300];
    	if (strlen(params) > 100)           return SendClientMessage(playerid, 0x99FF00AA, "Zprava muze mit maximalni delku 100 symbolu.");
	    if (id == playerid)                 return SendClientMessage(playerid, 0x99FF00AA, "Nemuzes poslat soukromou zpravu sam sobe.");
    	if (!IsPlayerConnected(id))   		return SendClientMessage(playerid, 0x99FF00AA, "Hrac se zadanym id aktualne neni na serveru.");

		format(string, sizeof(string), "PM pro %s [%d]: %s", Jmeno(id), id, params[pos]);
		SendClientMessage(playerid, 0x99FF00AA, string);

		format(string, sizeof(string), "PM od %s [%d]: %s", Jmeno(playerid), playerid, params[pos]);
		SendClientMessage(id, 0x99FF00AA, string);

		PlayerPlaySound(id, 1085, 0.0, 0.0, 0.0);
		printf("PM: %s", string);
	}
	return 1;
}
dcmd(pm,           2, cmdtext);
public OnPlayerCommandText(playerid, cmdtext[])
{   
Link to comment
Share on other sites

4 odpovědí na tuto otázku

Recommended Posts

  • 0

A co konrétně ti to hlásí za chybu?

 

// Jo jinak, bude to v tomto:

 

dcmd(pm, 2, cmdtext);
public OnPlayerCommandText(playerid, cmdtext[])
{

 

 

To udělej na:

 

public OnPlayerCommandText(playerid, cmdtext[])

{
    dcmd(pm, 2, cmdtext);
    return 0;
}

 

Edited by Daniels
Link to comment
Share on other sites

  • 0

C:\Documents and Settings\Vul\Plocha\FilterScripts\mod.pwn(100) : error 010: invalid function or declaration
C:\Documents and Settings\Vul\Plocha\FilterScripts\mod.pwn(715) : warning 203: symbol is never used: "dcmd_pm"
Link to comment
Share on other sites

  • 0
C:\Documents and Settings\Vul\Plocha\FilterScripts\mod.pwn(100) : error 010: invalid function or declaration
C:\Documents and Settings\Vul\Plocha\FilterScripts\mod.pwn(715) : warning 203: symbol is never used: "dcmd_pm"

 

A to co sem ti tam dal nepomohlo?

Link to comment
Share on other sites

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