Changeset 105
- Timestamp:
- 11/19/08 13:36:24 (17 years ago)
- Location:
- trunk/src
- Files:
-
- 1 added
- 6 modified
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bindings/scripts/ScriptMgr.cpp
r82 r105 342 342 extern void AddSC_boss_malchezaar(); 343 343 extern void AddSC_boss_terestian_illhoof(); 344 extern void AddSC_netherspite_infernal();345 344 extern void AddSC_boss_moroes(); 346 345 extern void AddSC_bosses_opera(); … … 1532 1531 AddSC_boss_malchezaar(); 1533 1532 AddSC_boss_terestian_illhoof(); 1534 AddSC_netherspite_infernal();1535 1533 AddSC_boss_moroes(); 1536 1534 AddSC_bosses_opera(); -
trunk/src/bindings/scripts/scripts/item/item_scripts.cpp
r90 r105 63 63 return true; 64 64 } 65 } 66 67 /*##### 68 # item_arcane_charges 69 #####*/ 70 71 bool ItemUse_item_arcane_charges(Player *player, Item* _Item, SpellCastTargets const& targets) 72 { 73 // allow use in flight only 74 if( player->isInFlight() ) 75 return false; 76 77 // error 78 player->SendEquipError(EQUIP_ERR_CANT_DO_RIGHT_NOW,_Item,NULL); 79 return true; 65 80 } 66 81 … … 444 459 445 460 newscript = new Script; 461 newscript->Name="item_arcane_charges"; 462 newscript->pItemUse = ItemUse_item_arcane_charges; 463 m_scripts[nrscripts++] = newscript; 464 465 newscript = new Script; 446 466 newscript->Name="item_attuned_crystal_cores"; 447 467 newscript->pItemUse = ItemUse_item_attuned_crystal_cores; -
trunk/src/bindings/scripts/scripts/zone/gruuls_lair/boss_high_king_maulgar.cpp
r98 r105 26 26 27 27 //Sounds 28 #define SOUND_AGGRO 11367 //"Gronn are the real power in outland." 29 #define SOUND_ENRAGE 11368 //"You will not defeat the hand of Gruul!" 30 #define SOUND_OGRE_DEATH1 11369 //"You won't kill next one so easy!" 31 #define SOUND_OGRE_DEATH2 11370 //"Pah! Does not prove anything!" 32 #define SOUND_OGRE_DEATH3 11371 //"I'm not afraid of you." 33 #define SOUND_OGRE_DEATH4 11372 //"Good, now you fight me!" 34 #define SOUND_SLAY1 11373 //"You not so tough afterall!" 35 #define SOUND_SLAY2 11374 //"Aha ha ha ha!" 36 #define SOUND_SLAY3 11375 //"Mulgar is king!" 37 #define SOUND_DEATH 11376 //"Gruul ...will crush you..." 28 #define SOUND_AGGRO 11367 29 #define SOUND_ENRAGE 11368 30 #define SOUND_OGRE_DEATH1 11369 31 #define SOUND_OGRE_DEATH2 11370 32 #define SOUND_OGRE_DEATH3 11371 33 #define SOUND_OGRE_DEATH4 11372 34 #define SOUND_SLAY1 11373 35 #define SOUND_SLAY2 11374 36 #define SOUND_SLAY3 11375 37 #define SOUND_DEATH 11376 38 39 //Yells 40 #define SAY_AGGRO "Gronn are the real power in Outland!" 41 #define SAY_ENRAGE "You will not defeat the Hand of Gruul!" 42 #define SAY_OGRE_DEATH1 "You not kill next one so easy!" 43 #define SAY_OGRE_DEATH2 "Does not mean anything!" 44 #define SAY_OGRE_DEATH3 "I'm not afraid of you!" 45 #define SAY_OGRE_DEATH4 "Good, now you fight me!" 46 #define SAY_SLAY1 "You not so tough after all!" 47 #define SAY_SLAY2 "Ahahahaha!" 48 #define SAY_SLAY3 "Maulgar is king!" 49 #define SAY_DEATH "Gruul will... crush you!" 38 50 39 51 // High King Maulgar … … 41 53 #define SPELL_MIGHTY_BLOW 33230 42 54 #define SPELL_WHIRLWIND 33238 43 #define SPELL_BERSERKER_C 44 #define SPELL_ROAR 45 #define SPELL_FLURRY 55 #define SPELL_BERSERKER_C 26561 56 #define SPELL_ROAR 16508 57 #define SPELL_FLURRY 33232 46 58 47 59 // Olm the Summoner 48 60 #define SPELL_DARK_DECAY 33129 49 #define SPELL_DEATH_COIL 50 #define SPELL_SUMMON_WFH 61 #define SPELL_DEATH_COIL 33130 62 #define SPELL_SUMMON_WFH 33131 51 63 52 64 //Kiggler the Craed 53 #define SPELL_GREATER_POLYMORPH 3317354 #define SPELL_LIGHTNING_BOLT 3615255 #define SPELL_ARCANE_SHOCK 3317556 #define SPELL_ARCANE_EXPLOSION 3323765 #define SPELL_GREATER_POLYMORPH 33173 66 #define SPELL_LIGHTNING_BOLT 36152 67 #define SPELL_ARCANE_SHOCK 33175 68 #define SPELL_ARCANE_EXPLOSION 33237 57 69 58 70 //Blindeye the Seer 59 #define SPELL_GREATER_PW_SHIELD 3314760 #define SPELL_HEAL 3314461 #define SPELL_PRAYER_OH 71 #define SPELL_GREATER_PW_SHIELD 33147 72 #define SPELL_HEAL 33144 73 #define SPELL_PRAYER_OH 33152 62 74 63 75 //Krosh Firehand … … 83 95 uint32 Whirlwind_Timer; 84 96 uint32 Charging_Timer; 85 97 uint32 Roar_Timer; 86 98 87 99 bool Phase2; … … 120 132 void KilledUnit() 121 133 { 122 switch(rand()%2) 123 { 124 case 0: DoPlaySoundToSet(m_creature, SOUND_SLAY1); break; 125 case 1: DoPlaySoundToSet(m_creature, SOUND_SLAY2); break; 126 case 2: DoPlaySoundToSet(m_creature, SOUND_SLAY3); break; 134 switch(rand()%3) 135 { 136 case 0: 137 DoYell(SAY_SLAY1, LANG_UNIVERSAL, NULL); 138 DoPlaySoundToSet(m_creature, SOUND_SLAY1); 139 break; 140 case 1: 141 DoYell(SAY_SLAY2, LANG_UNIVERSAL, NULL); 142 DoPlaySoundToSet(m_creature, SOUND_SLAY2); 143 break; 144 case 2: 145 DoYell(SAY_SLAY3, LANG_UNIVERSAL, NULL); 146 DoPlaySoundToSet(m_creature, SOUND_SLAY3); 147 break; 127 148 } 128 149 } … … 131 152 { 132 153 DoPlaySoundToSet(m_creature, SOUND_DEATH); 133 154 DoYell(SAY_DEATH, LANG_UNIVERSAL, NULL); 155 134 156 if (pInstance) 135 157 { … … 145 167 void AddDeath() 146 168 { 147 switch(rand()%3) 148 { 149 case 0: DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH1);break; 150 case 1: DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH2);break; 151 case 2: DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH3);break; 152 case 3: DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH4);break; 153 } 169 switch(rand()%4) 170 { 171 case 0: 172 DoYell(SAY_OGRE_DEATH1, LANG_UNIVERSAL, NULL); 173 DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH1); 174 break; 175 case 1: 176 DoYell(SAY_OGRE_DEATH2, LANG_UNIVERSAL, NULL); 177 DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH2); 178 break; 179 case 2: 180 DoYell(SAY_OGRE_DEATH3, LANG_UNIVERSAL, NULL); 181 DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH3); 182 break; 183 case 3: 184 DoYell(SAY_OGRE_DEATH4, LANG_UNIVERSAL, NULL); 185 DoPlaySoundToSet(m_creature, SOUND_OGRE_DEATH4); 186 break; 187 } 154 188 } 155 189 … … 174 208 175 209 DoPlaySoundToSet(m_creature, SOUND_AGGRO); 176 210 DoYell(SAY_AGGRO, LANG_UNIVERSAL, NULL); 211 177 212 pInstance->SetData64(DATA_MAULGAREVENT_TANK, who->GetGUID()); 178 213 pInstance->SetData(DATA_MAULGAREVENT, IN_PROGRESS); … … 232 267 Phase2 = true; 233 268 DoPlaySoundToSet(m_creature, SOUND_ENRAGE); 234 DoCast(m_creature, SPELL_FLURRY); 235 236 m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0); 237 m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0); 269 DoYell(SAY_ENRAGE, LANG_UNIVERSAL, NULL); 270 DoCast(m_creature, SPELL_FLURRY); 271 272 m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0); 273 m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0); 238 274 } 239 275 -
trunk/src/bindings/scripts/scripts/zone/karazhan/boss_prince_malchezaar.cpp
r90 r105 23 23 24 24 #include "precompiled.h" 25 #include "def_karazhan.h" 25 26 26 27 #define SAY_AGGRO "Madness has brought you here to me. I shall be your undoing!" … … 162 163 struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI 163 164 { 164 boss_malchezaarAI(Creature *c) : ScriptedAI(c) {Reset();} 165 165 boss_malchezaarAI(Creature *c) : ScriptedAI(c) 166 { 167 pInstance = ((ScriptedInstance*)c->GetInstanceData()); 168 Reset(); 169 } 170 171 ScriptedInstance *pInstance; 166 172 uint32 EnfeebleTimer; 167 173 uint32 EnfeebleResetTimer; … … 205 211 AxesTargetSwitchTimer = 7500 + rand()%12500; 206 212 phase = 1; 213 214 if(pInstance) 215 { 216 GameObject* Door = GameObject::GetGameObject((*m_creature),pInstance->GetData64(DATA_GAMEOBJECT_NETHER_DOOR)); 217 if(Door) 218 { 219 Door->SetGoState(0); 220 } 221 } 207 222 } 208 223 … … 238 253 for(int i = 0; i < TOTAL_INFERNAL_POINTS; ++i) 239 254 positions.push_back(&InfernalPoints[i]); 255 256 if(pInstance) 257 { 258 GameObject* Door = GameObject::GetGameObject((*m_creature),pInstance->GetData64(DATA_GAMEOBJECT_NETHER_DOOR)); 259 if(Door) 260 { 261 Door->SetGoState(0); 262 } 263 } 240 264 } 241 265 … … 244 268 DoYell(SAY_AGGRO, LANG_UNIVERSAL, NULL); 245 269 DoPlaySoundToSet(m_creature, SOUND_AGGRO); 270 271 if(pInstance) 272 { 273 GameObject* Door = GameObject::GetGameObject((*m_creature),pInstance->GetData64(DATA_GAMEOBJECT_NETHER_DOOR)); 274 if(Door) 275 { 276 Door->SetGoState(1); 277 } 278 } 246 279 } 247 280 … … 628 661 } 629 662 630 void AddSC_ netherspite_infernal()663 void AddSC_boss_malchezaar() 631 664 { 632 665 Script *newscript; 666 newscript = new Script; 667 newscript->Name="boss_malchezaar"; 668 newscript->GetAI = GetAI_boss_malchezaar; 669 m_scripts[nrscripts++] = newscript; 670 633 671 newscript = new Script; 634 672 newscript->Name="netherspite_infernal"; … … 636 674 m_scripts[nrscripts++] = newscript; 637 675 } 638 639 void AddSC_boss_malchezaar()640 {641 Script *newscript;642 newscript = new Script;643 newscript->Name="boss_malchezaar";644 newscript->GetAI = GetAI_boss_malchezaar;645 m_scripts[nrscripts++] = newscript;646 } -
trunk/src/bindings/scripts/scripts/zone/magisters_terrace/boss_selin_fireheart.cpp
r90 r105 287 287 if( DrainManaTimer < diff ) 288 288 { 289 DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_DRAIN_MANA); 290 DrainManaTimer = 10000; 289 Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0); 290 if( target->getPowerType() == POWER_MANA) 291 { 292 DoCast(target, SPELL_DRAIN_MANA); 293 DrainManaTimer = 10000; 294 } 291 295 }else DrainManaTimer -= diff; 292 296 } … … 367 371 if(((boss_selin_fireheartAI*)Selin->AI())->CrystalGUID == m_creature->GetGUID()) 368 372 { 369 // Set this to false if we are the creature that Selin is draining so his AI flows properly373 Selin->RemoveAurasDueToSpell(SPELL_MANA_RAGE); 370 374 ((boss_selin_fireheartAI*)Selin->AI())->DrainingCrystal = false; 371 375 ((boss_selin_fireheartAI*)Selin->AI())->IsDraining = false; -
trunk/src/game/SpellEffects.cpp
r102 r105 1772 1772 { 1773 1773 // remove all harmful spells on you... 1774 if( // ignore positive and passive auras 1775 !iter->second->IsPositive() && !iter->second->IsPassive() && 1776 // only affect magic spells 1777 iter->second->GetSpellProto()->DmgClass == SPELL_DAMAGE_CLASS_MAGIC && 1778 // ignore immunity persistent spells 1779 !( iter->second->GetSpellProto()->AttributesEx & 0x10000 ) ) 1774 if(// only affect magic spells 1775 iter->second->GetSpellProto()->DmgClass == SPELL_DAMAGE_CLASS_MAGIC 1776 // ignore positive and passive auras 1777 && !iter->second->IsPositive() && !iter->second->IsPassive()) 1780 1778 { 1781 1779 m_caster->RemoveAurasDueToSpell(iter->second->GetSpellProto()->Id);