Mercurial > parpg-core
diff src/parpg/gamescenecontroller.py @ 146:6e1eb964a6e5
Fixed dropping items on the map.
author | KarstenBock@gmx.net |
---|---|
date | Mon, 03 Oct 2011 18:25:31 +0200 |
parents | 3dddf09377b8 |
children | 7214224b8d83 |
line wrap: on
line diff
--- a/src/parpg/gamescenecontroller.py Mon Oct 03 14:12:17 2011 +0200 +++ b/src/parpg/gamescenecontroller.py Mon Oct 03 18:25:31 2011 +0200 @@ -245,11 +245,13 @@ .getExactLayerCoordinates() commands = ({"Command": "ResetMouseCursor"}, {"Command": "StopDragging"}) - self.model.game_state.getObjectById("PlayerCharacter").fifeagent.approach([coord.x, - coord.y], - DropItemAction(self, - data_drag.dragged_item, - commands)) + player_char = (self.model.game_state. + getObjectById("PlayerCharacter")) + action = DropItemAction(self, + data_drag.dragged_item, + commands) + player_char.fifeagent.behaviour.approach([coord.x, coord.y], + action) else: self.model.movePlayer(self.model.getCoords(scr_point)) elif(evt.getButton() == fife.MouseEvent.RIGHT):