blob: 33467a38e574045659c46986b53a4b3af5636267 (
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
|
//========= Copyright Valve Corporation, All rights reserved. ============//
// tf_bot_use_item.h
// Equip and consume an item
// Michael Booth, July 2011
#ifndef TF_BOT_USE_ITEM_H
#define TF_BOT_USE_ITEM_H
class CTFBotUseItem : public Action< CTFBot >
{
public:
CTFBotUseItem( CTFWeaponBase *item );
virtual ~CTFBotUseItem() { }
virtual ActionResult< CTFBot > OnStart( CTFBot *me, Action< CTFBot > *priorAction );
virtual ActionResult< CTFBot > Update( CTFBot *me, float interval );
virtual void OnEnd( CTFBot *me, Action< CTFBot > *nextAction );
virtual const char *GetName( void ) const { return "UseItem"; };
private:
CHandle< CTFWeaponBase > m_item;
CountdownTimer m_cooldownTimer;
};
#endif // TF_BOT_USE_ITEM_H
|