سلام ، آیا این بازدید اول شماست ؟ یا
logo_forum_header

تبلیغات
×
+
سفارش تبلیغات

نمایش نتایج: از 1 به 1 از 1
Like Tree1Likes
  • 1 Post By Mr_Mohammad

موضوع: اسکریپت Top5Killer

  1. #1

    شماره عضویت
    13
    تاریخ عضویت
    Oct 2014
    نوشته ها
    41
    نسل
    نسل مورد علاقه
    نژاد
    نژاد  مورد علاقه
    کلاس
     کلاس  مورد علاقه
    سورس
     سورس مورد علاقه
    پچ
    پچ مورد علاقه
    پسندیده : 58
    مورد پسند : 72 بار در 27 پست
    سیستم عامل و مرورگر:

    اسکریپت Top5Killer

    با سلام و خسته نباشی دوباره....

    این اسکریپت قابلیت نشون دادن نفرات که بیشترین کیل تو سرور گرفتن میده

    ترینتی 3.3.5


    کد PHP:
    #include "ScriptPCH.h"
    using namespace std;   
                   
            
    /*Basic Menu*/
    #define Menu_Whisp "|TInterface\\icons\\Achievement_WorldEvent_LittleHelper:20|t How Work Top Killers"
    #define Notification "This Server Team: Shoma Ebteda Bar Rooye Har Top Classi Ke Khastid Bezanid Agar Javab Nadad Yani Vojood Nadarad"
    #define M_Whisper "This Server Team: Shoma Ebteda Bar Rooye Har Top Classi Ke Khastid Bezanid Agar Javab Nadad Yani Vojood Nadarad"
    #define leave "Nevermind"
        /*Class E_Menu*/
    #define E_Warrior "|TInterface\\icons\\Ability_Warrior_WarCry:20|t View top 5 Warrior Killers"
    #define E_Paladin "|TInterface\\icons\\Ability_Paladin_ArtofWar:20|t View top 5 Paladin Killers"
    #define E_Hunter "|TInterface\\icons\\Ability_Hunter_AimedShot:20|t View top 5 Hunter Killers"
    #define E_Rogue "|TInterface\\icons\\Ability_Rogue_Ambush:20|t View top 5 Rogue Killers"
    #define E_Priest "|TInterface\\icons\\Ability_Racial_Cannibalize:20|t View top 5 Priest Killers"
    #define E_Shaman "|TInterface\\icons\\Ability_Shaman_Stormstrike:20|t View top 5 Shaman Killers"
    #define E_Mage "|TInterface\\icons\\ABILITY_MAGE_MOLTENARMOR:20|t View top 5 Mage Killers"
    #define E_Warlock "|TInterface\\icons\\Ability_Warlock_Haunt:20|t View top 5 Warlock Killers"
    #define E_Druid "|TInterface\\icons\\ABILITY_DRUID_DEMORALIZINGROAR:20|t View top 5 Druid Killers"
    #define E_Death_knight "|TInterface\\icons\\Spell_DeathKnight_BloodTap:20|t View top 5 Death knight Killers"
     /*Top 5 Message*/
    #define M_Warrior "Here is the top 5 Warrior Killers"
    #define M_Paladin "Here is the top 5 Paladin Killers"
    #define M_Hunter "Here is the top 5 Hunter Killers"
    #define M_Rogue "Here is the top 5 Rogue Killers"
    #define M_Priest "Here is the top 5 Priest Killers"
    #define M_Shaman "Here is the top 5 Shaman Killers"
    #define M_Mage "Here is the top 5 Mage Killers"
    #define M_Warlock "Here is the top 5 Warlock Killers"
    #define M_Druid "Here is the top 5 Druid Killers"
    #define M_Death_knight "Here is the top 5 Death knight Killers"
     
    class Top5_Killers : public CreatureScript
    {
    public:
            
    Top5_Killers() : CreatureScript("Top5_Killers") { }
     
            
    bool OnGossipHello(PlayerplayerCreaturecreature)
                    {
                    
    player->ADD_GOSSIP_ITEM(0Menu_WhispGOSSIP_SENDER_MAIN0);
                    
    player->ADD_GOSSIP_ITEM(1E_WarriorGOSSIP_SENDER_MAIN1);
                    
    player->ADD_GOSSIP_ITEM(1E_PaladinGOSSIP_SENDER_MAIN2);
                    
    player->ADD_GOSSIP_ITEM(1E_HunterGOSSIP_SENDER_MAIN3);
                    
    player->ADD_GOSSIP_ITEM(1E_RogueGOSSIP_SENDER_MAIN4);
                    
    player->ADD_GOSSIP_ITEM(1E_PriestGOSSIP_SENDER_MAIN5);
                    
    player->ADD_GOSSIP_ITEM(1E_ShamanGOSSIP_SENDER_MAIN6);
                    
    player->ADD_GOSSIP_ITEM(1E_MageGOSSIP_SENDER_MAIN7);
                    
    player->ADD_GOSSIP_ITEM(1E_WarlockGOSSIP_SENDER_MAIN8);
                    
    player->ADD_GOSSIP_ITEM(1E_DruidGOSSIP_SENDER_MAIN9);
                    
    player->ADD_GOSSIP_ITEM(1E_Death_knightGOSSIP_SENDER_MAIN10);
                    
    player->ADD_GOSSIP_ITEM(1leaveGOSSIP_SENDER_MAIN11);
                    
    player->SEND_GOSSIP_MENU(1creature->GetGUID());
                    return 
    true;
                    }
     
                    
    bool OnGossipSelect(PlayerplayerCreaturecreatureuint32 senderuint32 action)
            {
            if (
    sender == GOSSIP_SENDER_MAIN)
            {
                            
    player->PlayerTalkClass->ClearMenus();
                            switch(
    action)
                            {
                            case 
    12:
                            
    player->ADD_GOSSIP_ITEM(0Menu_WhispGOSSIP_SENDER_MAIN0);
                            
    player->ADD_GOSSIP_ITEM(1E_WarriorGOSSIP_SENDER_MAIN1);
                            
    player->ADD_GOSSIP_ITEM(1E_PaladinGOSSIP_SENDER_MAIN2);
                            
    player->ADD_GOSSIP_ITEM(1E_HunterGOSSIP_SENDER_MAIN3);
                            
    player->ADD_GOSSIP_ITEM(1E_RogueGOSSIP_SENDER_MAIN4);
                            
    player->ADD_GOSSIP_ITEM(1E_PriestGOSSIP_SENDER_MAIN5);
                            
    player->ADD_GOSSIP_ITEM(1E_ShamanGOSSIP_SENDER_MAIN6);
                            
    player->ADD_GOSSIP_ITEM(1E_MageGOSSIP_SENDER_MAIN7);
                            
    player->ADD_GOSSIP_ITEM(1E_WarlockGOSSIP_SENDER_MAIN8);
                            
    player->ADD_GOSSIP_ITEM(1E_DruidGOSSIP_SENDER_MAIN9);
                            
    player->ADD_GOSSIP_ITEM(1E_Death_knightGOSSIP_SENDER_MAIN10);
                            
    player->ADD_GOSSIP_ITEM(1leaveGOSSIP_SENDER_MAIN11);
                            
    player->SEND_GOSSIP_MENU(1creature->GetGUID());
                            break;
                           
                            case 
    11:
                            
    player->PlayerTalkClass->SendCloseGossip();
                            break;
                           
                            case 
    0:
                            
    player->GetSession()->SendNotification(Notification);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Whisper);
                            
    player->PlayerTalkClass->SendGossipMenu(12creature->GetGUID());
                            break;
                           
                            case 
    1//Warrior
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='1' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Warrior);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    2//Paladin
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='2' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Paladin);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    3//Hunter
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='3' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Hunter);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    4//Rogue
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='4' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Rogue);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    5//Priest
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='5' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Priest);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    6//Shaman
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='7' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Shaman);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    7//Mage
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='8' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Mage);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    8//warlock
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='9' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Warlock);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    9//Druid
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='11' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Druid);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                           
                            case 
    10//Death knight
                            
    {
                            
    QueryResult result CharacterDatabase.Query("SELECT name,totalKills FROM characters WHERE class='6' ORDER BY totalKills DESC LIMIT 5");
                        if(!
    result)
                              return 
    false;
     
                            
    Field fields NULL;
                            
    ChatHandler(player->GetSession()).PSendSysMessage(M_Death_knight);
                            do
                            {
                            
    fields result->Fetch();
                            
    string name fields[0].GetString();
                            
    uint32 totalKills fields[1].GetUInt32();
                            
    char msg[250];
                            
    snprintf(msg250"Name: %s, With Total Kills : %u"name.c_str(), totalKills);
                            
    ChatHandler(player->GetSession()).PSendSysMessage(msg);
                            }
                            while(
    result->NextRow());
                            
    player->SaveToDB();
                            
    player->PlayerTalkClass->SendCloseGossip();
                            }
                            break;
                            }
                    }
                return 
    true;
              }
            };
     
     
    void AddSC_Top5_Killers()
    {
        new 
    Top5_Killers();


    لذت ببرید...

    کاربر مقابل پست Mr_Mohammad عزیز را پسندیده است:

    Nightprince (10-29-2014)

    ubite likes this.
    مشکل ما اینه که میخوایم تو دنیایی مجازی کاربر برتر بشیم
    که اگه یه روز اینترنت نداشته باشیم فراموزش میشیم
    داداش گلم
    سعی کن تو دنیای واقعی ت برتر باشی
    نه اینجا که یه مشت بچه مچه شدن شاخ

  2. # ADS
    سیستم تبلیغات
    تاریخ عضویت
    01/01/2014
    نوشته ها
    پستی ندارد.
     

کلمات کلیدی این موضوع

مجوز های ارسال و ویرایش

  • شما نمیتوانید موضوع جدیدی ارسال کنید
  • شما امکان ارسال پاسخ را ندارید
  • شما نمیتوانید فایل پیوست کنید.
  • شما نمیتوانید پست های خود را ویرایش کنید
  •