diff options
| author | Marius "Teelevision" Neugebauer <marius@teele.eu> | 2014-04-02 02:41:20 +0200 |
|---|---|---|
| committer | Marius "Teelevision" Neugebauer <marius@teele.eu> | 2014-04-02 02:41:20 +0200 |
| commit | 461e9be9a6dc90e9ef5c1b365205906c1d6c8431 (patch) | |
| tree | 61bd1e3bc91a868cb930682c8db1da164a2ab4b7 /src/game/server/entities/character.h | |
| parent | c207f70e19fa4cc9389f547b1bf5470634fa2af1 (diff) | |
| download | zcatch-461e9be9a6dc90e9ef5c1b365205906c1d6c8431.tar.gz zcatch-461e9be9a6dc90e9ef5c1b365205906c1d6c8431.zip | |
started bot detection
Diffstat (limited to 'src/game/server/entities/character.h')
| -rw-r--r-- | src/game/server/entities/character.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/game/server/entities/character.h b/src/game/server/entities/character.h index ece33e45..4d615324 100644 --- a/src/game/server/entities/character.h +++ b/src/game/server/entities/character.h @@ -67,6 +67,14 @@ public: void Freeze(int Tick); int m_FreezeTicks; + + // bot detection + struct LastPosition { + float x; + float y; + }; + bool HasBeenThereRecently(float x, float y, const LastPosition *&pos, int firstTick, int lastTick) const; + bool AimedAtCharRecently(float aimX, float aimY, const CCharacter *c, const LastPosition *&pos, const LastPosition *&posVictim, int firstTick); private: // player controlling this character @@ -134,6 +142,10 @@ private: int m_ReckoningTick; // tick that we are performing dead reckoning From CCharacterCore m_SendCore; // core that we should send CCharacterCore m_ReckoningCore; // the dead reckoning core + + // bot detection + LastPosition *m_LastPositions; + int m_LastPositionsSize; }; |