Mercurial > fife-parpg
diff engine/core/view/renderers/cellselectionrenderer.h @ 255:51cc05d862f2
Merged editor_rewrite branch to trunk.
This contains changes that may break compatibility against existing clients.
For a list of changes that may affect your client, see: http://wiki.fifengine.de/Changes_to_pychan_and_FIFE_in_editor_rewrite_branch
author | cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Mon, 08 Jun 2009 16:00:02 +0000 |
parents | 90005975cdbb |
children | 16c2b3ee59ce |
line wrap: on
line diff
--- a/engine/core/view/renderers/cellselectionrenderer.h Wed Jun 03 19:29:52 2009 +0000 +++ b/engine/core/view/renderers/cellselectionrenderer.h Mon Jun 08 16:00:02 2009 +0000 @@ -31,10 +31,13 @@ // First block: files included from the FIFE root src directory // Second block: files included from the same folder #include "view/rendererbase.h" +#include "model/structures/location.h" namespace FIFE { class RenderBackend; + /** CellSelectionRenderer renders a frame around selected cells. + */ class CellSelectionRenderer: public RendererBase { public: /** constructor. @@ -52,22 +55,31 @@ void render(Camera* cam, Layer* layer, std::vector<Instance*>& instances); + /** Returns the renderer name */ std::string getName() { return "CellSelectionRenderer"; } /** returns instance used in given view */ static CellSelectionRenderer* getInstance(IRendererContainer* cnt); + /** Deselects all locations */ void reset(); /** Selects given location on map - * If NULL is given, deselects + */ + void selectLocation(const Location* loc); + + /** Deselects given location on map */ - void selectLocation(Location* loc); + void deselectLocation(const Location* loc); + + /** Returns selected locations + */ + const std::vector<Location> getLocations() const { return m_locations; } private: - // selected location - Location* m_loc; + // selected locations + std::vector<Location> m_locations; }; }