I've not been clear enough.
I'm creating a platform game where the player can visit towns and enter shops to buy items.
When he enters a building, the interior of the shop appear and the items are displayed. Those items are already in the layout.
Now my aim is this :
When the player collided with an item, he can click a button to buy it. When bought, a copy of this item appear near the player.
The problem is there are many different items and I would like to avoid to create one line of code for each one of them to create a copy of the item purchased.
Is there a way to clone an object from the layout during an event ?