Made the inventory working, also attached the proper key functions to it.