Lobby Website Chat

Page 3 of 3 FirstFirst 123
Results 31 to 42 of 42
  1. #31
    Good Guy George qet123 is offline
    MemberRank
    Apr 2009 Join Date
    DesertLocation
    1,432Posts

    Re: Lobby Website Chat

    Quote Originally Posted by Vusion View Post
    Great, you can apply the maths. Who can't, lmao. You've already shown you hardly can do anything on your own. Every release you've made or contributed to has to be flawed.
    LOL, just done what Wizkidje, and it's spam bot omg.

  2. #32
    Praise the Sun! Solaire is offline
    MemberRank
    Dec 2007 Join Date
    Undead BurgLocation
    2,862Posts

    Re: Lobby Website Chat

    Quote Originally Posted by Vusion View Post
    Was talking about something similar with SuperWaffle just before you posted that. I was gonna increment variable x which I'm going to declare and whenever x is divisible by 3, store timeGetTime() and whenever another's message is sent, if the difference between the time stored and the current time is less than 3000, throw a message.
    Here's the checks I had on Goat, should cover most (if not all) of them. The latter part is to verify the same message isn't submitted 3 times in a row (PLS, ME NOOB BR, ME SWAP WIF U), even if they add spaces, alt codes or other bullshit at the end.

    Code:
    bool MMatchServer::OnChannelChat(struct MUID &uidChar, struct MUID &uidChannel, char *szMessage) {
        GoatObject *pGoatObj = GoatServer::getInstance()->getGoat(&uidChar);
        MMatchServer *pMMatchServer = MMatchServer::GetInstance();
        MMatchObject *pObject = pMMatchServer->GetObjectA(&uidChar);
        MMatchChannel *pChannel = pMMatchServer->FindChannel(uidChannel);
    
        if (pObject == NULL || pGoatObj == NULL || pChannel == NULL) {
            return false;
        }
    
        //GoatServer::checkTimeout(pGoatObj, pObject, NULL);
        
        if (pObject->m_AccountInfo.m_nPGrade == GOAT_PENALTY_CHAT || pObject->m_AccountInfo.m_nPGrade == GOAT_PENALTY_CHAT_AND_TAUNT) {
            Logging::writeObjectLog(pObject, "Has attempted to chat in channel [%u-%u] but his goat penalty is set to %i.", uidChannel.LowID, uidChannel.HighID, pObject->m_AccountInfo.m_nPGrade);
            GoatProtection::banHacker(pObject, "Penalty hacking.");
            return false;
        }
    
        if (pObject->m_nPlace != MMatchObject::CHANNEL) {
            Logging::writeObjectLog(pObject, "Has attempted to chat in channel [%u-%u] but MMatchPlace is set to %i.", uidChannel.LowID, uidChannel.HighID, pObject->m_nPlace);
            GoatProtection::banHacker(pObject, "Channel spamming.");
            return false;
        }
    
        if (pObject->m_ChannelInfo.m_uidChannel.HighID != uidChannel.HighID) {
            Logging::writeObjectLog(pObject, "Has attempted to channel chat in channel [%u-%u] while he is at channel [%u-%u].", uidChannel.LowID, uidChannel.HighID, pObject->m_ChannelInfo.m_uidChannel.LowID, pObject->m_ChannelInfo.m_uidChannel.HighID);
            GoatProtection::banHacker(pObject, "Channel spamming.");
            return false;
        }
            
        DWORD dwTime = GetTickCount();
            
        if (pGoatObj->m_dwLastChat > (dwTime - 500)) {
            Logging::writeObjectLog(pObject, "Has posted a channel message %u milliseconds after his previous!", (dwTime - pGoatObj->m_dwLastChat));
            pMMatchServer->DisconnectObject(uidChar); //Lucky guy, I'd be better off banning him.
            return false;
        }
    
        if (pGoatObj->m_dwLastChat != NULL && strncmp(pGoatObj->m_szLastChat, szMessage, strlen(pGoatObj->m_szLastChat)) == 0 && ++pGoatObj->m_nSpamCount >= 3) {
            Logging::writeObjectLog(pObject, "Has posted the same channel chat message three times in a row. Message: %s", szMessage);
            GoatServer::popupPlayer(pObject, "That looks like spam. Your connection to the gameserver will be terminated within 3 seconds.");
            pObject->disconnect(3);
            return false;
        }
    
        //Logging::writeChannelLog(pObject, pChannel, szMessage);
        strncpy_s(pGoatObj->m_szLastChat, szMessage, 128);
        pGoatObj->m_dwLastChat = dwTime;
        return true;
    }

  3. #33
    Account Upgraded | Title Enabled! Wish Q is offline
    MemberRank
    Jul 2012 Join Date
    LiveScoreLocation
    456Posts

    Re: Lobby Website Chat

    only sarcasm I'm using
    Last edited by Wish Q; 20-11-12 at 06:17 PM.

  4. #34
    Praise the Sun! Solaire is offline
    MemberRank
    Dec 2007 Join Date
    Undead BurgLocation
    2,862Posts

    Re: Lobby Website Chat

    Quote Originally Posted by Wish Q View Post
    that is why gunz is die
    It's people like you who lack English, common sense, knowledge, genitals and not to mention humanity that made GunZ die.

  5. #35
    Good Guy George qet123 is offline
    MemberRank
    Apr 2009 Join Date
    DesertLocation
    1,432Posts

    Re: Lobby Website Chat

    Quote Originally Posted by Joe9099 View Post
    Wish Q, you do know Wiz has been deving for probably longer than you have been alive. Stop with the spam shit, it's annoying me.
    As for this script, qet coded it, ofc theres gonna be errors <3 Joe
    Talking about errors? Gunz is the biggest error.
    I can't find any errors in my source, when I code something I code it without thinking about hackers becaue i don't understand a shit about sql and shit. Anyway it was my first coded shit connected with website and i excpect bugs, but you guys making it harder for me lol.

  6. #36
    Hi, I'm Omar! Vusion is offline
    MemberRank
    Jan 2011 Join Date
    HereLocation
    1,658Posts

    Re: Lobby Website Chat

    Quote Originally Posted by qet123 View Post
    Talking about errors? Gunz is the biggest error.
    I can't find any errors in my source, when I code something I code it without thinking about hackers becaue i don't understand a shit about sql and shit. Anyway it was my first coded shit connected with website and i excpect bugs, but you guys making it harder for me lol.
    This being the first thing you coded connected with website is irrelevant to the fact that you left SQLi open.

  7. #37
    Good Guy George qet123 is offline
    MemberRank
    Apr 2009 Join Date
    DesertLocation
    1,432Posts

    Re: Lobby Website Chat

    Quote Originally Posted by Vusion View Post
    This being the first thing you coded connected with website is irrelevant to the fact that you left SQLi open.
    Then how i can protect SQLI?

  8. #38
    RailGunZ Soon! megol is offline
    MemberRank
    Jun 2012 Join Date
    261Posts

    Re: Lobby Website Chat

    CSCommonE.lib(MMatchServer_Channel.obj) : error LNK2019: unresolved external symbol "public: bool __thiscall MMatchDBMgr::LobbyChat(char const *,char const *)" (?LobbyChat@MMatchDBMgr@@QAE_NPBD0@Z) referenced in function "protected: bool __thiscall MMatchServer::ChannelChat(struct MUID const &,struct MUID const &,char *)" (?ChannelChat@MMatchServer@@IAE_NABUMUID@@0PAD@Z)
    Runtime/theduel.exe : fatal error LNK1120: 1 unresolved externals

    Why?.

  9. #39
    Developer / Patch Finder Tankado is offline
    MemberRank
    Oct 2011 Join Date
    The NetherlandsLocation
    451Posts

    Re: Lobby Website Chat

    Megol, U build only gunz
    rebuild CSCommon / Gunz

  10. #40
    Praise the Sun! Solaire is offline
    MemberRank
    Dec 2007 Join Date
    Undead BurgLocation
    2,862Posts

    Re: Lobby Website Chat

    Quote Originally Posted by qet123 View Post
    Talking about errors? Gunz is the biggest error.
    The biggest error is working on something you call the biggest error. For real, if you like GunZ, admit it, if you hate it, you're in denial.

    And, as usual, a copy/pasted snippet from MSDN would suffice.
    SQL Injection

  11. #41
    Good Guy George qet123 is offline
    MemberRank
    Apr 2009 Join Date
    DesertLocation
    1,432Posts

    Re: Lobby Website Chat

    Quote Originally Posted by Wizkidje View Post
    The biggest error is working on something you call the biggest error. For real, if you like GunZ, admit it, if you hate it, you're in denial.

    And, as usual, a copy/pasted snippet from MSDN would suffice.
    SQL Injection
    I do like gunz.
    anyway i think it's time to read and learn

    http://forum.ragezone.com/f197/php-a...-script-69154/

  12. #42
    Mako is insane. ThePhailure772 is offline
    MemberRank
    Sep 2007 Join Date
    1,115Posts

    Re: Lobby Website Chat

    Quote Originally Posted by qet123 View Post
    I do like gunz.
    anyway i think it's time to read and learn

    http://forum.ragezone.com/f197/php-a...-script-69154/
    Another way is not be a dumbass and use prepared statements.



Page 3 of 3 FirstFirst 123

Advertisement