blob: 27833cc9bc642c12213512fdeddde6a8c4953457 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
#pragma once
struct TakeDamageInfo;
class cChunk;
class cPlayer;
class cMonster;
class cPawn;
class cWorld;
class cItems;
class cEntity;
struct TakeDamageInfo;
#include <chrono>
class cBehavior
{
public:
// Tick-related
virtual bool IsControlDesired(std::chrono::milliseconds a_Dt, cChunk & a_Chunk);
virtual bool ControlStarting(std::chrono::milliseconds a_Dt, cChunk & a_Chunk);
virtual bool ControlEnding(std::chrono::milliseconds a_Dt, cChunk & a_Chunk);
virtual void Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk);
virtual void PostTick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk);
virtual void PreTick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk);
// Other
virtual void OnRightClicked(cPlayer & a_Player);
virtual void Destroyed();
virtual void DoTakeDamage(TakeDamageInfo & a_TDI);
virtual ~cBehavior() {}
};
|