You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
51 lines
1.5 KiB
51 lines
1.5 KiB
//========================================================= |
|
// Zombie |
|
//========================================================= |
|
|
|
// UNDONE: Don't flinch every time you get hit |
|
|
|
#include "extdll.h" |
|
#include "util.h" |
|
#include "cbase.h" |
|
#include "monsters.h" |
|
#include "schedule.h" |
|
|
|
|
|
//========================================================= |
|
// Monster's Anim Events Go Here |
|
//========================================================= |
|
#define ZOMBIE_AE_ATTACK_RIGHT 0x01 |
|
#define ZOMBIE_AE_ATTACK_LEFT 0x02 |
|
#define ZOMBIE_AE_ATTACK_BOTH 0x03 |
|
|
|
#define ZOMBIE_FLINCH_DELAY 2 // at most one flinch every n secs |
|
|
|
class CZombie : public CBaseMonster |
|
{ |
|
public: |
|
virtual void Spawn( void ); |
|
virtual void Precache( void ); |
|
void SetYawSpeed( void ); |
|
int Classify ( void ); |
|
virtual void HandleAnimEvent( MonsterEvent_t *pEvent ); |
|
virtual int IgnoreConditions ( void ); |
|
|
|
float m_flNextFlinch; |
|
|
|
virtual void PainSound( void ); |
|
virtual void AlertSound( void ); |
|
virtual void IdleSound( void ); |
|
virtual void AttackSound( void ); |
|
|
|
static const char *pAttackSounds[]; |
|
static const char *pIdleSounds[]; |
|
static const char *pAlertSounds[]; |
|
static const char *pPainSounds[]; |
|
static const char *pAttackHitSounds[]; |
|
static const char *pAttackMissSounds[]; |
|
|
|
// No range attacks |
|
BOOL CheckRangeAttack1 ( float flDot, float flDist ) { return FALSE; } |
|
BOOL CheckRangeAttack2 ( float flDot, float flDist ) { return FALSE; } |
|
virtual int TakeDamage( entvars_t *pevInflictor, entvars_t *pevAttacker, float flDamage, int bitsDamageType ); |
|
};
|
|
|