Website Summary Files Commits Branches @commit @diff @stats
path: root / DiamondProblemAndPolymorphism / Chess / Rook.hpp
diff options
context:
space:
mode:
1 files changed, 2 insertions, 1 deletions
-rw-r--r--DiamondProblemAndPolymorphism/Chess/Rook.hpp3
diff --git a/DiamondProblemAndPolymorphism/Chess/Rook.hpp b/DiamondProblemAndPolymorphism/Chess/Rook.hpp
index 576920a..d973870 100644
--- a/DiamondProblemAndPolymorphism/Chess/Rook.hpp
+++ b/DiamondProblemAndPolymorphism/Chess/Rook.hpp
@@ -1,3 +1,4 @@
+#pragma once
#include "Figure.hpp"
class Rook : virtual public Figure
@@ -13,7 +14,7 @@ public:
};
-bool Rook::Move(int xNew, int yNew);
+bool Rook::Move(int xNew, int yNew)
{
if (!isValidCoord(xNew, yNew))
return false;