20.08.2011, 02:25
Hello !
I'm working at a selfmade script better said im learning Scripting.
My CMD are /show & /show ID -
With this both COMMAND'S i want to show a Person where I am.
This Person can see me on the Radar Map, if I Use this Command.
The Command and all works, but it doesn't came a showmarker or marker on the radar better said Map.
Here ist my PAWN Code :
I'm working at a selfmade script better said im learning Scripting.
My CMD are /show & /show ID -
With this both COMMAND'S i want to show a Person where I am.
This Person can see me on the Radar Map, if I Use this Command.
The Command and all works, but it doesn't came a showmarker or marker on the radar better said Map.
Here ist my PAWN Code :
PHP код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp(cmdtext, "/show", true,5) == 0)
{
if(IsPlayerConnected(playerid))
{
new str[70], pname[16]; GetPlayerName(playerid, pname, 16);
if(!strlen(cmdtext[6])) {
for(new i=0; i<=GetMaxPlayers(); i++) {
if(IsPlayerConnected(i)) {
format(str, 70, " %sIst nun fьr Alle Sichtbar",pname);
SendClientMessage(i,0xFF00EBFF,str);
SetPlayerMarkerForPlayer(i,playerid,0xFF00EBFF); }}}
else {
new id=strval(cmdtext[6]);
if(IsPlayerConnected(id)) {
format(str, 70, " %sIst nun fьr dich Sichtbar",pname);
SendClientMessage(id,0xFFFF00FF,str);
SetPlayerMarkerForPlayer(id,playerid,0xFF00EBFF); }}
SetPlayerColor(playerid,0xFF00EBFF);
SendClientMessage(playerid, 0xFF00EBFF,"Du bist nun fьr alle Sichtbar!" );
}
}
return 1;
}