Hey there. I'm currently programming a small 2D, RPG game and today I have included a function which opens up an inventory.
So the problem is that whenever I press any key, the inventory closes. Is there a way to avoid this and allow the user to interact with the inventory window as long as it is open?Code:void OpenInventory() { if(key [KEY_I]) { draw_sprite(backbuffer, inventory, 500, 250); readkey(); } }