26.06.2012, 19:11
Hey i have this spike scrip but i want it to work only with swat skin id 285 ,
here is the script.
here is the script.
PHP код:
dcmd_spike(playerid,params[])
{
#pragma unused params
new Float:plocx,Float:plocy,Float:plocz,Float:ploca;
GetPlayerPos(playerid, plocx, plocy, plocz);
GetPlayerFacingAngle(playerid,ploca);
CreateSpike(plocx,plocy,plocz,ploca);
return 1;
}
dcmd_rspike(playerid,params[])
{
#pragma unused params
for(new i = 0; i < sizeof(SpikeInfo); i++)
{
if(IsPlayerInRangeOfPoint(playerid, 2.0, SpikeInfo[i][sX], SpikeInfo[i][sY], SpikeInfo[i][sZ]))
{
if(SpikeInfo[i][sCreated] == 1)
{
SpikeInfo[i][sCreated]=0;
SpikeInfo[i][sX]=0.0;
SpikeInfo[i][sY]=0.0;
SpikeInfo[i][sZ]=0.0;
DestroyObject(SpikeInfo[i][sObject]);
return 1;
}
}
}
return 1;
}