LOG_ERROR( "Failed to hook prop: %s from table: %s", propName, tableName ) GetProp( tableName, propName, &recvProp ) LOG_ERROR( "Failed to find offset for prop: %s from table: %s", propName, tableName ) īool CNetworkedVariableManager::HookProp( const char *tableName, const char *propName, RecvVarProxyFn function ) Int offset = GetProp( tableName, propName ) Int CNetworkedVariableManager::GetOffset( const char *tableName, const char *propName ) RecvTable *recvTable = clientClass->m_pRecvTable LOG_ERROR( "ClientClass was not found" ) RecvTable *GetTable( const char *tableName ) Įxtern CNetworkedVariableManager *g_NetworkedVariableManager ĬNetworkedVariableManager *g_NetworkedVariableManager = 0 ĬNetworkedVariableManager::CNetworkedVariableManager( void )ĬlientClass *clientClass = g_InterfaceManager->Client()->GetOriginalMethod( INDEX_GETALLCLASSES )( g_InterfaceManager->Client()->thisptr() ) Int GetProp( RecvTable *recvTable, const char *propName, RecvProp **prop = 0 ) uses recursion to return a the relative offset to the given prop and sets the prop param Int GetProp( const char *tableName, const char *propName, RecvProp **prop = 0 ) wrapper so we can use recursion without too much performance loss calls GetProp wrapper to get prop and sets the proxy of the propīool HookProp( const char *tableName, const char *propName, RecvVarProxyFn function ) Int GetOffset( const char *tableName, const char *propName ) calls GetProp wrapper to get the absolute offset of the prop stores all tables, and all props inside those I needed a way to hook networked props/get offsets simply in the source engine, so I implemented ghetto's/altimor's recursive solution in my netvars class. and the height of the chickens hull is ~23 The pelvis hitbox is very big, almost like a bounding box tbh. Return strstr( studioHeader->name, "chicken" ) Studiohdr_t *studioHeader = g_InterfaceManager->ModelInfo()->GetVTable()->GetStudiomodel( model ) The chickens all have the clientclass CDynamicProp, and you can check wether it's a chicken or not by checking model name Ex:
HITBOX_CHICKEN_CLAVICAL, // gg misspell valve?