added functions for the player inventory