Picking up an item on the ground without directly picking it up

So I’ve had an idea of having players pick up items by interacting with a proximityprompt attached to them (kind of like how Isle does it)

Problem is, I don’t know of any way of moving an item into a players inventory from the item itself.

Teleporting the item into the player wouldn’t work as I don’t want contact pickups.

Deleting the item and manifesting a clone into the backpack could work but that sounds unnecessarily complex.

As far as I know there is no built-in way of transferring an item into the backpack directly.

An easy way would be that if the proximityprompt is triggered, the part parent is the player backpack

1 Like

ProximityPrompt.Triggered passes the player who interacted with the prompt as argument to the callback function so you can use

prompt.Triggered:Connect(function(player)
    item.Parent = player.Backpack
end)
1 Like

Wasn’t aware you could just parent stuff to the backpack like that, thanks.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.