23.11.2010, 07:26
Hey,
Im trying to get what the player says,
Example: Inputtex,CommandText,
This is what I have for my Radio Code and its not working, Its displaying everything but what the player has said,
Im trying to get what the player says,
Example: Inputtex,CommandText,
This is what I have for my Radio Code and its not working, Its displaying everything but what the player has said,
pawn Код:
COMMAND:r(playerid,params)
{
new UnitIdentifier[512];
new cmdtext[100];
new playername[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername, sizeof(playername));
UnitIdentifier = dini_Get("UnitIDs.txt",playername);
new erpstring[128];
if(PlayerTeam[playerid] == Team_Sheriff || PlayerTeam[playerid] == Team_LVPD || PlayerTeam[playerid] == Team_Fire){
if(dini_Exists("UnitIDs.txt")){
if(strlen(dini_Get("UnitIDs.txt",playername))!=0) {
GetPlayerName(playerid, playername, sizeof(playername));
format(erpstring, sizeof(erpstring), "(DCPCOM) %s %d: %s, over.", UnitIdentifier, playerid,cmdtext[3] );
SendMessageToLaw(erpstring);
}else{
GetPlayerName(playerid, playername, sizeof(playername));
format(erpstring, sizeof(erpstring), "(DCPCOM) Unit %d: %s, over.", playerid, cmdtext[3]);
SendMessageToLaw(erpstring);
SendClientMessage(playerid,COLOR_YELLOW,erpstring);
}
}
}
return 1;
}