Ungetested:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp("/eventpickup", cmdtext))
{
if(IsPlayerAdmin(playerid)) //Deine Admin Variable
{
new Float:x, Float:y, Float:z;
GetPlayerPos(playerid, x, y, z);
HealPickup = CreateDynamicPickup(1240, 1, x, y, z, -1,-1,-1, 100.0);
SendClientMessage(playerid, -1, "Eventpickup {00FF00}erfolgreich{FFFFFF} erstellt");
return 1;
}
if(!strcmp("/eventpickup", cmdtext))
{
if(IsPlayerAdmin(playerid)) //Deine Admin Variable
{
DestroyDynamicPickup(HealPickup);
SendClientMessage(playerid, -1, "Eventpickup {00FF00}erfolgreich {FFFFFF}gelöscht.");
return 1;
}
}
}
return 0;
}