11.02.2010, 14:49
Hi, i need help with making a cmd that spawns the objects and then another cmd to destroy them, i can't figure out how
here is my spawn object code
here is my spawn object code
pawn Код:
if(strcmp(cmd, "/test", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
CreateStreamObject(1238, 2585.6965332031, -2390.3012695313, 12.866736412048, 0.000000, 0.000000, 0.000000, 90.0); // I think i have to add a name to this object, but how
}
else
{
SendClientMessage(playerid, COLOR_GREY, "[Error] You are not authorized to use that command");
}
}
return 1;
}
pawn Код:
if(strcmp(cmd, "/destroytest", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
// What am i gonna do here to destroy the first object?
}
else
{
SendClientMessage(playerid, COLOR_GREY, "[Error] You are not authorized to use that command");
}
}
return 1;
}