daily pastebin goal
50%
SHARE
TWEET

Untitled

a guest May 16th, 2018 85 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. enum
  3. {
  4.     //Quete
  5.     QUEST_GARDES_DU_CORPS       = 5821,
  6.    
  7.     //Donneur de quete
  8.      NPC_CORK_GIZELTON           = 11625,
  9.    
  10.     //Mob, Qu'un seul type pour le moment pour les test
  11.     NPC_MOB_1                   = 4632
  12. };
  13.  
  14. struct MANGOS_DLL_DECL npc_cork_gizeltonAI : public npc_escortAI
  15. {
  16.     npc_cork_gizeltonAI(Creature* pCreature) : npc_escortAI(pCreature) { Reset(); }
  17.    
  18.     void WaypointReached(uint32 WP)
  19.     {
  20.         switch (WP)
  21.         {
  22.             case 11:
  23.                 m_creature->SummonCreature(NPC_MOB_1, -1025.51f, 1181.81f, 89.00f, 3.98f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  24.                 m_creature->SummonCreature(NPC_MOB_1, -1025.51f, 1181.81f, 89.00f, 3.98f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  25.                 m_creature->SummonCreature(NPC_MOB_1, -1025.51f, 1181.81f, 89.00f, 3.98f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  26.                 m_creature->SummonCreature(NPC_MOB_1, -1025.51f, 1181.81f, 89.00f, 3.98f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  27.                 break;
  28.                
  29.             case 21:
  30.                 m_creature->SummonCreature(NPC_MOB_1, -1282.13f, 1228.26f, 108.00f, 3.74f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  31.                 m_creature->SummonCreature(NPC_MOB_1, -1282.13f, 1228.26f, 108.00f, 3.74f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  32.                 m_creature->SummonCreature(NPC_MOB_1, -1282.13f, 1228.26f, 108.00f, 3.74f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  33.                 m_creature->SummonCreature(NPC_MOB_1, -1282.13f, 1228.26f, 108.00f, 3.74f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  34.                 break;
  35.  
  36.             case 31:
  37.                 m_creature->SummonCreature(NPC_MOB_1, -1446.66f, 1189.42f, 111.00f, 3.77f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  38.                 m_creature->SummonCreature(NPC_MOB_1, -1446.66f, 1189.42f, 111.00f, 3.77f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  39.                 m_creature->SummonCreature(NPC_MOB_1, -1446.66f, 1189.42f, 111.00f, 3.77f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  40.                 m_creature->SummonCreature(NPC_MOB_1, -1446.66f, 1189.42f, 111.00f, 3.77f, TEMPSUMMON_CORPSE_TIMED_DESPAWN, 10000);
  41.                 break;
  42.             case 48:
  43.                 if (Player* pPlayer = GetPlayerForEscort())
  44.                     pPlayer->GroupEventHappens(QUEST_GARDES_DU_CORPS, m_creature);
  45.                 break;
  46.         }
  47.     }
  48.    
  49.         void Reset()
  50.     {
  51.         if (!HasEscortState(STATE_ESCORT_ESCORTING))
  52.             m_creature->SetStandState(UNIT_STAND_STATE_DEAD);
  53.     }
  54.  
  55.     void Aggro(Unit* who)
  56.     {
  57.     }
  58.  
  59.     void JustSummoned(Creature* summoned)
  60.     {
  61.         summoned->AI()->AttackStart(m_creature);
  62.     }
  63. };
  64.  
  65. CreatureAI* GetAI_npc_cork_gizelton(Creature* pCreature)
  66. {
  67.     return new npc_cork_gizeltonAI(pCreature);
  68. }
  69.  
  70. bool QuestAccept_npc_cork_gizelton(Player* pPlayer, Creature* pCreature, const Quest* pQuest)
  71. {
  72.     if (pQuest->GetQuestId() == QUEST_GARDES_DU_CORPS)
  73.     {
  74.         pCreature->SetStandState(UNIT_STAND_STATE_STAND);
  75.        
  76.         if (pPlayer->GetTeam() == ALLIANCE)
  77.             pCreature->setFaction(FACTION_ESCORT_A_PASSIVE);
  78.  
  79.         if (pPlayer->GetTeam() == HORDE)
  80.             pCreature->setFaction(FACTION_ESCORT_H_PASSIVE);
  81.  
  82.         if (npc_cork_gizeltonAI* pEscortAI = dynamic_cast<npc_cork_gizeltonAI*>(pCreature->AI()))
  83.             pEscortAI->Start(false, pPlayer, pQuest);
  84.     }
  85.     return true;
  86. }
  87.  
  88. void AddSC_Desolace()
  89. {
  90.     pNewScript = new Script;
  91.     pNewScript->Name = "npc_cork_gizelton";
  92.     pNewScript->GetAI = &GetAI_npc_cork_gizelton;
  93.     pNewScript->pQuestAcceptNPC = &QuestAccept_npc_cork_gizelton;
  94.     pNewScript->RegisterSelf();
  95. }
  96.  
  97.  
  98. //////////////////////
  99. //////////////////////
  100. //////////////////////
  101.  
  102.  
  103. INSERT INTO `script_waypoint` (`entry`, `pointid`, `location_x`, `location_y`, `location_z`, `waittime`, `point_comment`)
  104. VALUES
  105. ('139347','0','-847.221','1188.78','99','0',''),
  106. ('139347','1','-847.221','1188.78','99','0',''),
  107. ('139347','2','-857.324','1187.98','99','0',''),
  108. ('139347','3','-869.854','1186.48','98','0',''),
  109. ('139347','4','-883.781','1185.01','97','0',''),
  110. ('139347','5','-904.03','1183.5','95','0',''),
  111. ('139347','6','-935.499','1182.24','91','0',''),
  112. ('139347','7','-958.267','1182.92','89','0',''),
  113. ('139347','8','-974.384','1182.91','89','0',''),
  114. ('139347','9','-995.034','1177.64','89','0',''),
  115. ('139347','10','-1009.27','1177.46','89','0',''),
  116. ('139347','11','-1025.51','1181.81','89','0',''),
  117. ('139347','12','-1056.65','1186.35','89','0',''),
  118. ('139347','13','-1084.96','1184.87','89','0',''),
  119. ('139347','14','-1098.32','1187.53','89','0',''),
  120. ('139347','15','-1112.01','1190.48','89','0',''),
  121. ('139347','16','-1153.93','1192.36','92','0',''),
  122. ('139347','17','-1170.62','1195.64','94','0',''),
  123. ('139347','18','-1195.94','1208.73','98','0',''),
  124. ('139347','19','-1206.27','1209.18','100','0',''),
  125. ('139347','20','-1227.62','1205.96','103','0',''),
  126. ('139347','21','-1282.13','1228.26','108','0',''),
  127. ('139347','22','-1306.17','1233.9','109','0',''),
  128. ('139347','23','-1317.72','1233.58','110','0',''),
  129. ('139347','24','-1343.73','1228.03','111','0',''),
  130. ('139347','25','-1373.84','1218.94','111','0',''),
  131. ('139347','26','-1412.23','1205.42','111','0',''),
  132. ('139347','27','-1417.17','1202.14','111','0',''),
  133. ('139347','28','-1446.66','1189.42','111','0',''),
  134. ('139347','29','-1467.95','1185.75','110','0',''),
  135. ('139347','30','-1485.08','1188.79','107','0',''),
  136. ('139347','31','-1492.79','1191.12','105','0',''),
  137. ('139347','32','-1505.44','1200.36','100','0',''),
  138. ('139347','33','-1514.29','1213.33','94','0',''),
  139. ('139347','34','-1521.29','1232.28','87','0',''),
  140. ('139347','35','-1523.64','1246.41','82','0',''),
  141. ('139347','36','-1521.45','1259.16','77','0',''),
  142. ('139347','37','-1517.39','1273.3','71','0',''),
  143. ('139347','38','-1513.56','1304.56','63','0',''),
  144. ('139347','39','-1512.08','1325.5','60','0',''),
  145. ('139347','40','-1502.82','1346.56','58','0',''),
  146. ('139347','41','-1488.55','1384.94','58','0',''),
  147. ('139347','42','-1485.31','1407.55','58','0',''),
  148. ('139347','43','-1487.64','1438.56','58','0',''),
  149. ('139347','44','-1490.62','1459.35','58','0',''),
  150. ('139347','45','-1476.09','1496.85','58','0',''),
  151. ('139347','46','-1457.39','1511.91','59','0',''),
  152. ('139347','47','-1446.92','1514.49','59','0',''),
  153. ('139347','48','-1426.87','1508.7','59','0',''),
  154. ('139347','49','-1410.16','1499.86','59','0','');
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top