18.04.2011, 00:31
Es posible
https://sampwiki.blast.hk/wiki/SetPlayerAttachedObject
EDIT: para remover los objectos yo utilizo este comando
pawn Код:
if (strcmp("/tortuga", cmdtext, true) == 0)
{
new Float:scala = 2;
SetPlayerAttachedObject(playerid, 3, 1609, 2,0,0,0,0,0,0,scala,scala,scala); //Attach a turtle to the playerid's head, with the index of 3!
return 1;
}
EDIT: para remover los objectos yo utilizo este comando
pawn Код:
if(strcmp("/rao",cmdtext,true) == 0 || strcmp("/removeattachedobject",cmdtext,true) == 0)
{
new total,str[128];
for(new i=0; i < 5; i++)
{
if(IsPlayerAttachedObjectSlotUsed(playerid,i))
{
RemovePlayerAttachedObject(playerid,i);
total++;
}
}
if(total == 0) return
SendClientMessage(playerid,YELLOW,"No tienes nigun objecto atado que puedas borrar");
format(str,sizeof(str),"Borrastes todos tus objectos atados || Total %d",total);
SendClientMessage(playerid,YELLOW,str);
return 1;
}