Tüm Sürümler İçin Renkli Notice Ekleme Farklı Sistem

'Kaynak Kod Paylaşımları' forumunda Knightİmperia tarafından 23 Mart 2018 tarihinde açılan konu

  1. Knightİmperia

    Knightİmperia New Member

    GameServer Komut Kullanımı

    /clan

    /ally

    /captain

    /party

    [HIDE]ChatHandler.cpp

    { "clan", &CGameServerDlg::HandleClanCommand, "Sends a server-wide chat notice." },
    { "ally", &CGameServerDlg::HandleAllyCommand, "Sends a server-wide chat notice." },
    { "captain", &CGameServerDlg::HandleCapCommand, "Sends a server-wide chat notice." },
    { "party", &CGameServerDlg::HandlePartCommand, "Sends a server-wide chat notice." },

    ChatHandler.cpp de HandleNoticeCommand aratın hemen Altına Ekleyin

    COMMAND_HANDLER(CGameServerDlg::HandleClanCommand)
    {
    if (vargs.empty())
    return true;


    SendNoticeClan(args);
    return true;
    }


    COMMAND_HANDLER(CGameServerDlg::HandleAllyCommand)
    {
    if (vargs.empty())
    return true;


    SendNoticeAlly(args);
    return true;
    }


    COMMAND_HANDLER(CGameServerDlg::HandleCapCommand)
    {
    if (vargs.empty())
    return true;


    SendNoticeCommand(args);
    return true;
    }


    COMMAND_HANDLER(CGameServerDlg::HandlePartCommand)
    {
    if (vargs.empty())
    return true;


    SendNoticePart(args);
    return true;
    }


    GameServerDlg.h Ekleyin

    INLINE void SendNoticeClan(const char *msg, uint8 byNation = Nation::ALL)
    {
    SendChat<KNIGHTS_CHAT>(msg, byNation, true);
    }


    INLINE void SendNoticeAlly(const char *msg, uint8 byNation = Nation::ALL)
    {
    SendChat<ALLIANCE_CHAT>(msg, byNation, true);
    }


    INLINE void SendNoticeCommand(const char *msg, uint8 byNation = Nation::ALL)
    {
    SendChat<COMMAND_CHAT>(msg, byNation, true);
    }


    INLINE void SendNoticePart(const char *msg, uint8 byNation = Nation::ALL)
    {
    SendChat<PARTY_CHAT>(msg, byNation, true);
    }

    Son Olarak User.h Ekleyiniz

    void SendChat(uint8 chattype, std::string msg, std::string Sender = "");





    [/HIDE]
     
  2. kimbulenox

    kimbulenox New Member

    teşekkürler
     
  3. symbol54

    symbol54 Member

    teşekkürler
     
  4. danny

    danny New Member

    +++++++++++
     
  5. ArdreamPower

    ArdreamPower New Member

    asdsdsdsdsdsdsdsd
     
  6. GkhnSkry

    GkhnSkry New Member

    Teşekkürler
     
  7. lizozim

    lizozim New Member

    +++++++++++++
     
  8. lozzytr

    lozzytr New Member

    teşekkürler
     
  9. saol-man

    saol-man New Member

    saolllllllllllllllllll!!!!!
     

Bu Sayfayı Paylaş