1
0
Fork 0
cuberite-2a/src/Mobs/Villager.h

51 lines
708 B
C
Raw Normal View History

#pragma once
#include "PassiveMonster.h"
class cVillager :
public cPassiveMonster
{
typedef cPassiveMonster super;
public:
enum eVillagerType
{
vtFarmer = 0,
vtLibrarian = 1,
vtPriest = 2,
vtBlacksmith = 3,
vtButcher = 4,
vtGeneric = 5,
vtMax
} ;
cVillager(eVillagerType VillagerType);
CLASS_PROTODEF(cVillager);
virtual void DoTakeDamage(TakeDamageInfo & a_TDI) override;
2014-01-27 13:40:31 +00:00
virtual void Tick (float a_Dt, cChunk & a_Chunk) override;
void HandleFarmer();
bool IsBlockFarmable(BLOCKTYPE a_BlockType);
int GetVilType(void) const { return m_Type; }
private:
int m_ActionCountDown;
int m_Type;
2014-01-27 13:40:31 +00:00
bool m_DidFindCrops;
Vector3i m_CropsPos;
} ;