summaryrefslogtreecommitdiffstats
path: root/labb4/Junk.h
diff options
context:
space:
mode:
Diffstat (limited to 'labb4/Junk.h')
-rw-r--r--labb4/Junk.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/labb4/Junk.h b/labb4/Junk.h
new file mode 100644
index 0000000..a4d6cca
--- /dev/null
+++ b/labb4/Junk.h
@@ -0,0 +1,29 @@
+/**
+ * Copyright (C) David Wolfe, 1999. All rights reserved.
+ * Ported to Qt and adapted for TDDD86, 2015.
+ */
+
+#ifndef JUNK_H
+#define JUNK_H
+
+#include "Robot.h"
+#include <QGraphicsScene>
+
+class Junk : public Robot {
+public:
+ Junk();
+ Junk(Robot c);
+
+ /*
+ * Draws this junk onto the given QGraphicsScene.
+ */
+ void draw(QGraphicsScene* scene) const;
+
+ void moveTowards(const Unit& u) const;
+
+ bool attacks(const Unit& u) const;
+
+ unsigned int getCollisionCount() const;
+};
+
+#endif // JUNK_H