::Based on the reference information provided, I cannot find a direct solution to this specific issue. The code snippets do not reveal the exact implementation of inventory slot interactions or tool/item swapping mechanics.
To help diagnose the problem, I would need to ask:
Can you share the specific script handling inventory slot interactions, particularly the method responsible for moving tools and items between slots? Are you using the same script for both tool and item slots, or separate scripts?
The behavior you’re describing suggests there might be an issue in the logic for transferring items between tool and item inventories. Without seeing the specific implementation, I can only recommend carefully reviewing the code that handles inventory slot interactions.