blob: 3877857795dd9811cf5594359a14f55886bc6b16 (
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose: Base combat character with no AI
//
// $Workfile: $
// $Date: $
//
//-----------------------------------------------------------------------------
// $Log: $
//
// $NoKeywords: $
//=============================================================================//
#ifndef HL1_NPC_BARNACLE_H
#define HL1_NPC_BARNACLE_H
#include "hl1_ai_basenpc.h"
#include "rope_physics.h"
#define BARNACLE_BODY_HEIGHT 44 // how 'tall' the barnacle's model is.
#define BARNACLE_PULL_SPEED 8
#define BARNACLE_KILL_VICTIM_DELAY 5 // how many seconds after pulling prey in to gib them.
//=========================================================
// Monster's Anim Events Go Here
//=========================================================
#define BARNACLE_AE_PUKEGIB 2
//-----------------------------------------------------------------------------
// Purpose:
//-----------------------------------------------------------------------------
class CNPC_Barnacle : public CHL1BaseNPC
{
DECLARE_CLASS( CNPC_Barnacle, CHL1BaseNPC );
public:
void Spawn( void );
void InitTonguePosition( void );
void Precache( void );
CBaseEntity* TongueTouchEnt ( float *pflLength );
Class_T Classify ( void );
void HandleAnimEvent( animevent_t *pEvent );
void BarnacleThink ( void );
void WaitTillDead ( void );
void Event_Killed( const CTakeDamageInfo &info );
int OnTakeDamage_Alive( const CTakeDamageInfo &info );
DECLARE_DATADESC();
float m_flAltitude;
float m_flKillVictimTime;
int m_cGibs;// barnacle loads up on gibs each time it kills something.
bool m_fLiftingPrey;
float m_flTongueAdj;
float m_flIgnoreTouchesUntil;
public:
DEFINE_CUSTOM_AI;
};
#endif //HL1_NPC_BARNACLE_H
|