# RPG-More questions from a n00by

**URL:** <https://forum.kirupa.com/t/rpg-more-questions-from-a-n00by/198497>\
**Category:** programming\
**Created:** [August 25, 2006, 3:25pm UTC](https://forum.kirupa.com/t/rpg-more-questions-from-a-n00by/198497 "2006-08-25T15:25:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Holmesc](https://avatars.discourse-cdn.com/v4/letter/h/9f8e36/32.png) [@Holmesc](https://forum.kirupa.com/u/Holmesc)\
**Post date:** [August 25, 2006, 3:25pm UTC](https://forum.kirupa.com/t/rpg-more-questions-from-a-n00by/198497/1 "2006-08-25T15:25:31Z")

</div>

Hello!! I am currently making an RPG game for my website. Everything is going smoothly, except one small part - discarding from the inventory. In order for you to understand what I’m doing, I’m going to give some explanations of how this game is designed:

-The background/everything but the character (which I am calling the ‘area’) moves, not the character. The character is constantly in the center of the screen.  
-When the character touches an item (which is part of the area) their is a function for the item that makes it’s x & y coordinates equal the coordinates of the slot for the item.  
-To use/equip an item, the user has to hit a key that corresponds with the slot for the item.

So, I want some way to discard, be it clicking on the item, doing a certain keypress, etc. As long as it is not too complicated for the user (this is a hack and slash) to do when it’s safe, enemies are around, or even if their about to be eaten by a carnivorous rock (which will be one of the enemies:P). When the item is discarded, I don’t care whether it appears at the characters feet (this.\_y = guy\_y - 20) or, to just reset the item to where it originally was. If you can help me, please do (and thank you!).
