Help With RemovePlayerAttachedObject
#1

hello guys im making a simple commande for exemple when you use /call it attaching a phone to your hand

SetPlayerAttachedObject(playerid, 6, 18865, 6, 0.120000, 0.040000, -0.003500, 0, 100, 100, 1.4, 1.4, 1.4);

the probleme is i dont know how to remove it when i do /hangup

RemovePlayerAttachedObject (playerid, 18865); ??

thanks for the answer
Reply
#2

pawn Код:
new phone = SetPlayerAttachedObject(playerid, 6, 18865, 6, 0.120000, 0.040000, -0.003500, 0, 100, 100, 1.4, 1.4, 1.4);
if(IsPlayerAttachedObjectSlotUsed(playerid, 6)) RemovePlayerAttachedObject(playerid, phone);
Reply
#3

it dsnt working
Reply
#4

pawn Код:
SetPlayerAttachedObject(playerid, 6, 18865, 6, 0.120000, 0.040000, -0.003500, 0, 100, 100, 1.4, 1.4, 1.4);
if(IsPlayerAttachedObjectSlotUsed(playerid, 6)) RemovePlayerAttachedObject(playerid, 6);
sorry i made mistake remove works with its slot index only where 6 is the index of your object
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)