//----------------------------------------------------------------------------- // Returns an Edict instance from the given PlayerInfo instance. //----------------------------------------------------------------------------- bool EdictFromPlayerInfo( IPlayerInfo *pPlayerInfo, edict_t*& output ) { if (!pPlayerInfo) return false; return EdictFromUserid(pPlayerInfo->GetUserID(), output); }
//----------------------------------------------------------------------------- // Returns an index from the given UserID. //----------------------------------------------------------------------------- bool IndexFromUserid( unsigned int iUserID, unsigned int& output ) { edict_t* pEdict; if (!EdictFromUserid(iUserID, pEdict)) return false; return IndexFromEdict(pEdict, output); }
//----------------------------------------------------------------------------- // Returns a BaseEntity instance from the given UserID. //----------------------------------------------------------------------------- bool BaseEntityFromUserid( unsigned int iUserID, CBaseEntity*& output ) { edict_t* pEdict; if (!EdictFromUserid(iUserID, pEdict)) return false; return BaseEntityFromEdict(pEdict, output); }