summaryrefslogtreecommitdiff
path: root/src/game/Tool.h
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2012-01-23 10:50:48 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2012-01-23 10:50:48 (GMT)
commit8a65c395f490baea3b55f1418207c4ee172a2b3a (patch)
tree261957afa7218bd67d4a59c32594488aff269861 /src/game/Tool.h
parent8c0678fa48f9598a5ade2d4960c46bfea7e6abef (diff)
downloadpowder-8a65c395f490baea3b55f1418207c4ee172a2b3a.zip
powder-8a65c395f490baea3b55f1418207c4ee172a2b3a.tar.gz
Element menu
Diffstat (limited to 'src/game/Tool.h')
-rw-r--r--src/game/Tool.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/game/Tool.h b/src/game/Tool.h
index 842f4a2..4777e6d 100644
--- a/src/game/Tool.h
+++ b/src/game/Tool.h
@@ -15,10 +15,10 @@ using namespace std;
class Tool
{
protected:
- int toolID, colRed, colBlue, colGreen;
+ int toolID;
string toolName;
public:
- Tool(int id, string name, int r, int b, int g):
+ Tool(int id, string name, int r, int g, int b):
toolID(id),
toolName(name),
colRed(r),
@@ -26,16 +26,18 @@ public:
colBlue(b)
{
}
+ string GetName() { return toolName; }
virtual ~Tool() {}
virtual void Draw(Simulation * sim, Brush * brush, ui::Point position) {}
virtual void DrawLine(Simulation * sim, Brush * brush, ui::Point position1, ui::Point position2) {}
virtual void DrawRect(Simulation * sim, Brush * brush, ui::Point position1, ui::Point position2) {}
+ int colRed, colBlue, colGreen;
};
class ElementTool: public Tool
{
public:
- ElementTool(int id, string name, int r, int b, int g):
+ ElementTool(int id, string name, int r, int g, int b):
Tool(id, name, r, g, b)
{
}