- Joined
- Jul 7, 2007
- Messages
- 962
- Reaction score
- 161
got bored scrolled through this thought id correct a few
/////////////////////////////// this one is not needed really but whatever
/////////////////////////////////// this is pretty needed lol!!!!!
/////////////////////////////////// and just fyi this is quicker and a better way
if there is any syntax error blame notepad.
Enjoy.
/////////////////////////////// this one is not needed really but whatever
Code:
case MC_NET_CLEAR:
{
if (pCommand->GetSenderUID() == GetUID()) //GetUID() gets server uid although uid low is always 2 for the server but w/e
{
MUID uid;
if (pCommand->GetParameter(&uid, 0, MPT_UID)==false) break;
OnNetClear(uid);
}
return true;
}
break;
/////////////////////////////////// this is pretty needed lol!!!!!
Code:
case MC_NET_BANPLAYER_FLOODING :
{
if (pCommand->GetSenderUID() != GetUID()) return true; //why remove a packet that disconnects flooders when u can uid check it as it originates from mserver lol
MUID uidPlayer;
pCommand->GetParameter(&uidPlayer, 0, MPT_UID);
if (MGetServerConfig()->IsUseBlockFlooding())
{
MMatchObject* pObj = GetObject( uidPlayer );
if( pObj && pObj->GetDisconnStatusInfo().GetStatus() == MMDS_CONNECTED)
{
if( pObj->GetAccountName() ) {
LOG(LOG_PROG,"Ban Player On Flooding - (MUID:%d%d, ID:%s)"
, uidPlayer.High, uidPlayer.Low, pObj->GetAccountName());
} else {
LOG(LOG_PROG,"Ban Player On Flooding - (MUID:%d%d, ID:%s)"
, uidPlayer.High, uidPlayer.Low);
}
pObj->DisconnectHacker( MMHT_COMMAND_FLOODING );
}
else
{
LOG(LOG_PROG,"Ban Player On Flooding - Can't Find Object");
}
}
}
break;
/////////////////////////////////// and just fyi this is quicker and a better way
Code:
strSQL.Format(g_szDB_GET_LOGININFO, m_DBFilter.Filtering(szUserID).c_str());
if there is any syntax error blame notepad.
Enjoy.
Last edited: