mirror of
https://github.com/mapbase-source/source-sdk-2013.git
synced 2025-02-10 22:08:50 +03:00
Added ability to translate actbusy forced move activity translation
This commit is contained in:
parent
9b84980a77
commit
6b13b83231
@ -1802,6 +1802,20 @@ bool CAI_ActBusyBehavior::PlayAnimForActBusy( busyanimparts_t AnimPart )
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef MAPBASE
|
||||||
|
//-----------------------------------------------------------------------------
|
||||||
|
// Purpose: Get the busy's move activity
|
||||||
|
//-----------------------------------------------------------------------------
|
||||||
|
Activity CAI_ActBusyBehavior::GetMoveActivityForActBusy()
|
||||||
|
{
|
||||||
|
busyanim_t *pBusyAnim = g_ActBusyAnimDataSystem.GetBusyAnim( m_iCurrentBusyAnim );
|
||||||
|
if ( !pBusyAnim )
|
||||||
|
return m_ForcedActivity;
|
||||||
|
|
||||||
|
return pBusyAnim->bTranslateActivity ? GetOuter()->TranslateActivity( m_ForcedActivity ) : m_ForcedActivity;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
// Purpose:
|
// Purpose:
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
@ -2030,7 +2044,11 @@ void CAI_ActBusyBehavior::StartTask( const Task_t *pTask )
|
|||||||
// If we have a forced activity, use that. Otherwise, walk.
|
// If we have a forced activity, use that. Otherwise, walk.
|
||||||
if ( m_ForcedActivity != ACT_INVALID && m_ForcedActivity != ACT_RESET )
|
if ( m_ForcedActivity != ACT_INVALID && m_ForcedActivity != ACT_RESET )
|
||||||
{
|
{
|
||||||
|
#ifdef MAPBASE
|
||||||
|
GetNavigator()->SetMovementActivity( GetMoveActivityForActBusy() );
|
||||||
|
#else
|
||||||
GetNavigator()->SetMovementActivity( m_ForcedActivity );
|
GetNavigator()->SetMovementActivity( m_ForcedActivity );
|
||||||
|
#endif
|
||||||
|
|
||||||
// Cover is void once I move
|
// Cover is void once I move
|
||||||
Forget( bits_MEMORY_INCOVER );
|
Forget( bits_MEMORY_INCOVER );
|
||||||
|
@ -167,6 +167,9 @@ private:
|
|||||||
void NotifyBusyEnding( void );
|
void NotifyBusyEnding( void );
|
||||||
bool HasAnimForActBusy( int iActBusy, busyanimparts_t AnimPart );
|
bool HasAnimForActBusy( int iActBusy, busyanimparts_t AnimPart );
|
||||||
bool PlayAnimForActBusy( busyanimparts_t AnimPart );
|
bool PlayAnimForActBusy( busyanimparts_t AnimPart );
|
||||||
|
#ifdef MAPBASE
|
||||||
|
Activity GetMoveActivityForActBusy();
|
||||||
|
#endif
|
||||||
void PlaySoundForActBusy( busyanimparts_t AnimPart );
|
void PlaySoundForActBusy( busyanimparts_t AnimPart );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user