Misc. response system code cleanup/QOL changes

This commit is contained in:
Blixibon 2021-03-18 00:34:31 -05:00
parent a05503e42b
commit 8bcb6263f5
3 changed files with 16 additions and 1 deletions

View File

@ -1078,7 +1078,6 @@ public:
const Rule &rule = rs.m_RulePartitions[ idx ];
bool bEnabled = rule.m_bEnabled;
Msg( "%s: %i\n", rs.m_RulePartitions.GetElementName( idx ), idx );
pSave->WriteBool( &bEnabled );
pSave->EndBlock();

View File

@ -326,6 +326,9 @@ namespace ResponseRules
void GetName( char *buf, size_t buflen ) const;
void GetResponse( char *buf, size_t buflen ) const;
#ifdef MAPBASE
void GetRule( char *buf, size_t buflen ) const;
#endif
const char* GetNamePtr() const;
const char* GetResponsePtr() const;
const ResponseParams *GetParams() const { return &m_Params; }

View File

@ -198,6 +198,19 @@ void CRR_Response::GetResponse( char *buf, size_t buflen ) const
GetName( buf, buflen );
}
#ifdef MAPBASE
//-----------------------------------------------------------------------------
// Purpose:
// Output : char const
//-----------------------------------------------------------------------------
void CRR_Response::GetRule( char *buf, size_t buflen ) const
{
Q_strncpy( buf, m_szMatchingRule, buflen );
}
#endif
const char* ResponseRules::CRR_Response::GetNamePtr() const
{
return m_szResponseName;