Drag and drop

From Post-Apocalyptic RPG wiki

Jump to: navigation, search

Submitted code proposal.png This article features an submitted code proposal.

Submitted code proposals are currently under consideration for implementation.

A proposal for a drag and drop interface for the inventory.



  • To provide a clean, efficient way to manage your inventory.
  • Have a well-coded drag and drop interface that can be used elsewhere in the game.



The coding will be done in Python with the FIFE engine. The Pychan library will be used.

  • There will be a certain size grid of ImageButtons. When clicked they will activate a dragging function while the left mouse button is held down. A dropping function will be called when the left mouse button is released. The image of the ImageButton clicked will follow the cursor and be "put down" onto the ImageButton that it is released on.
  • The inventory window will be a PyChan window, so it can be easily transferred from a standalone testing application to the main game.
  • The layout will be in an XML file.


A screenshot of the development so far is: Inv screenshot 3-19-09.PNG

Personal tools