@@ -474,7 +474,9 @@ class CTFQuestOperatorRestriction: public CTFQuestRestriction
474474 CTFQuestRestriction *pNewRestriction = CreateRestrictionByName ( pszType, this );
475475 SCHEMA_INIT_CHECK ( pNewRestriction != NULL , " %s" , CFmtStr ( " Failed to create quest restriction name '%s' for '%s'" , pszType, GetConditionName () ).Get () );
476476
477+ #ifndef VALVE_PURE
477478 if (pNewRestriction != NULL )
479+ #endif
478480 {
479481 SCHEMA_INIT_CHECK ( pNewRestriction->BInitFromKV ( pSubKey, pVecErrors ), " Failed to init from KeyValues" );
480482
@@ -2308,12 +2310,17 @@ class CTFQuestEventListener : public CTFQuestEvaluator, public CGameEventListene
23082310
23092311 FOR_EACH_TRUE_SUBKEY ( pKVItem, pSubKey )
23102312 {
2311- // SCHEMA_INIT_CHECK( !m_pRestrictions, "%s", CFmtStr( "Too many input for operator '%s'.", GetConditionName() ).Get() );
2313+ #ifdef VALVE_PURE
2314+ SCHEMA_INIT_CHECK ( !m_pRestrictions, " %s" , CFmtStr ( " Too many input for operator '%s'." , GetConditionName () ).Get () );
2315+ #endif
23122316
23132317 const char *pszType = pSubKey->GetString ( " type" );
23142318 m_pRestrictions = CreateRestrictionByName ( pszType, this );
2315- // SCHEMA_INIT_CHECK( m_pRestrictions != NULL, "%s", CFmtStr( "Failed to create quest restriction name '%s' for '%s'", pszType, GetConditionName() ).Get() );
2319+ #ifdef VALVE_PURE
2320+ SCHEMA_INIT_CHECK ( m_pRestrictions != NULL , " %s" , CFmtStr ( " Failed to create quest restriction name '%s' for '%s'" , pszType, GetConditionName () ).Get () );
2321+ #else
23162322 if (m_pRestrictions != NULL )
2323+ #endif
23172324 {
23182325 SCHEMA_INIT_CHECK ( m_pRestrictions->BInitFromKV ( pSubKey, pVecErrors ), " Failed to init from KeyValues" );
23192326 }
@@ -2355,6 +2362,10 @@ class CTFQuestEventListener : public CTFQuestEvaluator, public CGameEventListene
23552362
23562363 virtual void FireGameEvent ( IGameEvent *pEvent ) OVERRIDE
23572364 {
2365+ #ifndef VALVE_PURE
2366+ // FIXME(mastercoms): disable quest restrictions
2367+ return ;
2368+ #endif
23582369 // This can happen when the player's SteamID isn't setup yet after a
23592370 // disconnect -> reconnect
23602371 if ( GetQuestOwner () == NULL )
@@ -2521,9 +2532,11 @@ class CTFQuestCountEvaluator : public CTFQuestEvaluator
25212532 {
25222533 const char *pszType = pSubKey->GetString ( " type" );
25232534 CTFQuestEvaluator *pNewCond = assert_cast< CTFQuestEvaluator* >( CreateEvaluatorByName ( pszType, this ) );
2524- // SCHEMA_INIT_CHECK( pNewCond && pNewCond->BInitFromKV( pSubKey, pVecErrors ), "Failed to init from KeyValues" );
2525-
2535+ #ifdef VALVE_PURE
2536+ SCHEMA_INIT_CHECK ( pNewCond && pNewCond->BInitFromKV ( pSubKey, pVecErrors ), " Failed to init from KeyValues" );
2537+ #else
25262538 if (pNewCond && pNewCond->BInitFromKV (pSubKey, pVecErrors))
2539+ #endif
25272540 {
25282541 const char *pszAction = pSubKey->GetString ( " action" , NULL );
25292542 SCHEMA_INIT_CHECK ( pszAction != NULL , " Missing action key" );
0 commit comments