diff options
| author | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
|---|---|---|
| committer | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
| commit | 3bf9df6b2785fa6d951086978a3e66f49427166a (patch) | |
| tree | 2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /public/dme_controls/AnimSetAttributeValue.h | |
| download | archived-source-engine-2018-hl2-src-master.tar.xz archived-source-engine-2018-hl2-src-master.zip | |
Diffstat (limited to 'public/dme_controls/AnimSetAttributeValue.h')
| -rw-r--r-- | public/dme_controls/AnimSetAttributeValue.h | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/public/dme_controls/AnimSetAttributeValue.h b/public/dme_controls/AnimSetAttributeValue.h new file mode 100644 index 0000000..b23f273 --- /dev/null +++ b/public/dme_controls/AnimSetAttributeValue.h @@ -0,0 +1,65 @@ +//========= Copyright Valve Corporation, All rights reserved. ============// +// +// Purpose: +// +//============================================================================= + +#ifndef ANIMSETATTRIBUTEVALUE_H +#define ANIMSETATTRIBUTEVALUE_H +#ifdef _WIN32 +#pragma once +#endif + +#include "tier1/utldict.h" + + +//----------------------------------------------------------------------------- +// Forward declarations +//----------------------------------------------------------------------------- +class CDmAttribute; + + +//----------------------------------------------------------------------------- +// AnimationControlType +//----------------------------------------------------------------------------- +enum AnimationControlType_t +{ + ANIM_CONTROL_INVALID = -1, + + ANIM_CONTROL_VALUE = 0, + ANIM_CONTROL_BALANCE, + ANIM_CONTROL_MULTILEVEL, + + ANIM_CONTROL_COUNT, +}; + + +struct AttributeValue_t +{ + AttributeValue_t() + { + // Default values + m_pValue[ANIM_CONTROL_VALUE] = 0.0f; + m_pValue[ANIM_CONTROL_BALANCE] = 0.5f; + m_pValue[ANIM_CONTROL_MULTILEVEL] = 0.5f; + } + + float m_pValue[ANIM_CONTROL_COUNT]; +}; + +struct AnimationControlAttributes_t : public AttributeValue_t +{ + AnimationControlAttributes_t() + { + // Default values + m_pAttribute[ANIM_CONTROL_VALUE] = 0; + m_pAttribute[ANIM_CONTROL_BALANCE] = 0; + m_pAttribute[ANIM_CONTROL_MULTILEVEL] = 0; + } + + CDmAttribute* m_pAttribute[ANIM_CONTROL_COUNT]; +}; + +typedef CUtlDict< AnimationControlAttributes_t, unsigned short > AttributeDict_t; + +#endif // ANIMSETATTRIBUTEVALUE_H
\ No newline at end of file |