I need some help with an inventory system

I am making a dungeon game and I need a great inventory system that allows me to drop items and pick up items. Similar to the Minecraft hotbar, and I can drop an item and replace it with something else. Although I only have one item in the game currently and was wondering why it kept multiply in my inventory so much as you collect more of it. I haven’t added the feature to delete the item in the inventory when I drop it so don’t bother about that. I just need help on why it kept multiplying in the inventory. I checked the code multiple times and I couldn’t find anything wrong with it. Can someone pls help me find a solution to this. It may seem complicated, but play the game and pick up three potions and you’ll see what im saying.

Game link. Flowlab Game Creator - Dungeon Rpg

Never mind I fixed that. But if someone can help me find a solution for when I drop the item, it will disappear in the inventory. Also sorry for all of the code. I couldn’t find a more easier way.

Edit: I also need help with making an E button appear above each item. I used a similar version of JR 01’s design, but I wanted the E button to appear above the item not the player.

Also sorry if i’m asking a lot. I kinda have a lot of problems with my game.

make it attach the e and the e becomes visible within the proximity of your choic

make it attach the e and the e becomes visible within the proximity of your choice

or ill make my own

I actually figured out why it wasnt working and Ill fix it later today. Now I just need help with the dropping of the items.