return this->savings.GetVolition();
}
- Coordinates *Creature::GetPosition(void)
- {
- return &(this->position);
- }
-
SOUL Creature::GetCurrentSoul(void)
{
return this->currentSoul;
#include "HaveGameTime.h"
#include "HaveHp.h"
#include "HaveSymbol.h"
+#include "HavePosition.h"
#include "Item.h"
#include "GameConstants.h"
#include "GameInstance.h"
* <li>\8f\8a\8e\9d\83X\83L\83\8b\88ê\97\97 / Current Pisition</li>
* </ul>
*/
- class Creature : public GameInstance, public HaveSymbol, public HaveHp, public HaveGameTime
+ class Creature : public GameInstance, public HaveSymbol, public HaveHp, public HaveGameTime, public HavePosition
{
private:
SavingTable savings; //!< \83Z\81[\83r\83\93\83O
ID floorID; //!< \8c»\8dÝ\82¢\82é\83t\83\8d\83AID
- Coordinates position; //!< \8c»\8dÀ\95W
std::vector<Item> itemList; //!< \8f\8a\8e\9d\83A\83C\83e\83\80\83\8a\83X\83g
std::map<TAG, SKILL_EXP> skillExpList; //!< \83X\83L\83\8b\8co\8c±\92l\83\8a\83X\83g
VO Creature::GetVolitionSaving(void);
/*!
- * @brief \83N\83\8a\81[\83`\83\83\81[\82Ì\8c»\8dÝ\88Ê\92u\82ð\95Ô\82·
- * @return \83N\83\8a\81[\83`\83\83\81[\8c»\8dÝ\88Ê\92u\82ð\8e¦\82·Coordinates
- */
- Coordinates *Creature::GetPosition(void);
-
- /*!
* @brief \83N\83\8a\81[\83`\83\83\81[\82Ì\8f\8a\8e\9d\95i\83\8a\83X\83g\82ð\95Ô\82·
* @return \83N\83\8a\81[\83`\83\83\81[\8f\8a\8e\9d\95i\83\8a\83X\83g\83}\83b\83v
*/
Color symColor = creatureIt->second->GetSymbolColor();
SDL_Color sdlSymCol = {(Uint8)symColor.GetRed(), (Uint8)symColor.GetGreen(), (Uint8)symColor.GetBlue(), (Uint8)symColor.GetAlpha()};
sprintf_s(symBuf, 5, "%s", creatureIt->second->GetSymbol().c_str());
- SDL_Rect blitRect = {240 + creatureIt->second->GetPosition()->GetX() * 24, creatureIt->second->GetPosition()->GetY() * 24 , 24, 24};
+ SDL_Rect blitRect = {240 + creatureIt->second->GetPosition().GetX() * 24, creatureIt->second->GetPosition().GetY() * 24 , 24, 24};
symbolSurface = TTF_RenderUTF8_Blended(font, toUTF8(symBuf).c_str(), sdlSymCol);
blitRect.x += (24 - symbolSurface->w) / 2;
blitRect.y += (24 - symbolSurface->h) / 2;
#include "SavingTable.h"
#include "HaveGameTime.h"
#include "HaveSymbol.h"
+#include "HavePosition.h"
BOOST_CLASS_VERSION(Item, 1);
* @class Item
* @brief \83A\83C\83e\83\80\82Ì\83N\83\89\83X
*/
- class Item : public ItemTemplate, public GameInstance, public HaveSymbol, public HaveGameTime
+ class Item : public ItemTemplate, public GameInstance, public HaveSymbol, public HaveGameTime, public HavePosition
{
private: