Ejemplo n.º 1
0
bool NFCPVPMatchRedisModule::DeletePlayerRoomID(const NFGUID& self, const NFGUID& xRoomID)
{
	NF_SHARE_PTR<NFINoSqlDriver> pNoSqlDriver = m_pNoSqlModule->GetDriverBySuitConsistent();
    if (pNoSqlDriver)
    {
        std::string strKey = MakePlayerRoomKey();
        return pNoSqlDriver->HDel(strKey, self.ToString());
    }

    return false;
}
Ejemplo n.º 2
0
bool NFCPVPMatchRedisModule::DeleteRoomInfo(const NFGUID& xRoomID)
{
	NF_SHARE_PTR<NFINoSqlDriver> pNoSqlDriver = m_pNoSqlModule->GetDriverBySuitConsistent();
    if (pNoSqlDriver)
    {
        std::string strKey = MakePvpRoomRedisKey();
        std::string strData;
        if (pNoSqlDriver->HDel(strKey, xRoomID.ToString()))
        {
            return true;
        }
    }

    return false;
}
Ejemplo n.º 3
0
bool NFCPVPMatchRedisModule::DeleteStatusRoomID(const int nPVPMode, const int nGrade, const int nStatus, const NFGUID& xRoomID)
{
	NF_SHARE_PTR<NFINoSqlDriver> pNoSqlDriver = m_pNoSqlModule->GetDriverBySuitConsistent();
    if (pNoSqlDriver)
    {
        std::string strKey = MakeStatusRoomIDRedisKey(nPVPMode, nGrade, nStatus);
        std::string strData;

        std::vector<std::string> valueVec;
        if (pNoSqlDriver->HDel(strKey, xRoomID.ToString()))
        {
            return true;
        }
    }

    return false;
}
Ejemplo n.º 4
0
bool NFCPVPMatchRedisModule::DeletetStatusRoomID(const int nPVPMode, const int nGrade, const int nStatus, const std::vector<NFGUID>& xRoomIDList)
{
	NF_SHARE_PTR<NFINoSqlDriver> pNoSqlDriver = m_pNoSqlModule->GetDriverBySuitConsistent();
    if (pNoSqlDriver)
    {
        std::string strKey = MakeStatusRoomIDRedisKey(nPVPMode, nGrade, nStatus);
        std::string strData;

        for (int i = 0; i < xRoomIDList.size(); ++i)
        {
            pNoSqlDriver->HDel(strKey, xRoomIDList[i].ToString());
        }

        return true;
    }

    return false;
}
Ejemplo n.º 5
0
bool NFCPVPMatchRedisModule::DeleteRoomInfoList(const std::vector<NFGUID>& xRoomIDList)
{
	NF_SHARE_PTR<NFINoSqlDriver> pNoSqlDriver = m_pNoSqlModule->GetDriverBySuitConsistent();
    if (pNoSqlDriver)
    {
        std::string strKey = MakePvpRoomRedisKey();
        std::vector<std::string> vFields;

        for (int i = 0; i < xRoomIDList.size(); ++i)
        {
            pNoSqlDriver->HDel(strKey, xRoomIDList[i].ToString());
        }

        return true;
    }

    return false;
}