OSDN Git Service

Add GetCurrentHP() and GetMaxHP() to Square class.
authorDeskull <deskull@users.sourceforge.jp>
Tue, 11 Mar 2014 11:54:08 +0000 (20:54 +0900)
committerDeskull <deskull@users.sourceforge.jp>
Tue, 11 Mar 2014 11:54:08 +0000 (20:54 +0900)
Deeangband/Square.cpp
Deeangband/Square.h

index ae11208..df0832b 100644 (file)
@@ -45,5 +45,12 @@ Feature *Square::getFeaturePtr(void)
        return NULL;
 }
 
+const HP Square::GetCurrentHP(void)
+{
+       return this->hitPoint;
+}
 
-
+const HP Square::GetMaxHP(void)
+{
+       return this->maxPoint;
+}
index c9a0803..8c35362 100644 (file)
@@ -61,4 +61,16 @@ public:
         */
        bool Square::TakeEffect(Effect *effectPtr, POWER amount);
 
+       /*!
+        * @brief \8c»\8dÝ\82Ì\92n\8c`HP\82ð\95Ô\82·
+        * @return \8c»\92n\8c`HP
+        */
+       const HP Square::GetCurrentHP(void);
+
+       /*!
+        * @brief \8dÅ\91å\82Ì\92n\8c`HP\82ð\95Ô\82·
+        * @return \8dÅ\91å\92n\8c`HP
+        */
+       const HP Square::GetMaxHP(void);
+
 };