Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*Duel Reset info.
- -------------------------------------------------------------------------------------
- /* Made by SymbolixDEV
- Script for: On Duel End Reset Hp , Cooldowns , cast stop , attack stop etc..
- Working on 19.3.2014 REV
- Compile Success
- Working : Test and work 100%
- What is good on this script ?
- izgubi = losser
- pobeditel = winner
- _________________________
- pobeditel->CastStop(); - Stop Cast on Duel End and give Evade
- pobeditel->Attackstop(); - Stop Attack on duel end !
- pobeditel->SetHealth(Losser->GetMaxHealth()); - set winner health to max
- pobeditel->RemoveAurasByType(SPELL_AURA_PERIODIC_DAMAGE); - Remove Auras on Duel End
- pobeditel->RemoveAllSpellCooldown(); - Remove All Cooldowns on Duel End Again
- NOT CHANSE FOR DIE PEOPLE WITH THIS DUEL SCRIPT
- http://github.com/SymbolixDEV
- Thanks !
- --------------------------------------------------------------------------------------
- */
- // SymbolxiDEV Start !
- // Please all remove my credits don't remove Credits !
- //Thanks SYMBOLIXDEV !
- #include "ScriptPCH.h"
- #include "Map.h"
- /*Buffs - Start*/
- #define BUFF_MARK_OF_THE_WILD 48469
- #define BUFF_BLESSING_OF_WISDOM 48938
- #define BUFF_BLESSING_OF_KINGS 25898
- #define BUFF_BLESSING_OF_SANCTUARY 25899
- #define BUFF_BLESSING_OF_MIGHT 48932
- #define BUFF_POWER_WORD_FORTITUDE 48161
- /*Buff - End*/
- class Reset_OnDuelEnd : public PlayerScript
- {
- public:
- Reset_OnDuelEnd() : PlayerScript("Reset_OnDuelEnd") {}
- void OnDuelStart(Player * pobeditel, Player * izgubi)
- {
- if (pobeditel->getPowerType() == POWER_ENERGY)
- pobeditel->SetPower(POWER_ENERGY, pobeditel->GetMaxPower(POWER_ENERGY));
- if (pobeditel->getPowerType() == POWER_RAGE)
- pobeditel->SetPower(POWER_RAGE, 0);
- }
- void OnDuelEnd(Player *pobeditel, Player *izgubi/*, Player *pet* SymbolixDEV */, DuelCompleteType type)
- {
- //Set Max Healt [START] //
- pobeditel->SetHealth(pobeditel->GetMaxHealth());
- izgubi->SetHealth(izgubi->GetMaxHealth());
- if ( pobeditel->getPowerType() == POWER_MANA )
- pobeditel->SetPower(POWER_MANA, pobeditel->GetMaxPower(POWER_MANA));
- if ( izgubi->getPowerType() == POWER_MANA )
- izgubi->SetPower(POWER_MANA, izgubi->GetMaxPower(POWER_MANA));
- //Set Max Healt [END]
- // Cast And Attack Stop [Start] //
- pobeditel->CastStop();
- izgubi->CastStop();
- pobeditel->AttackStop();
- izgubi->AttackStop();
- // Cast And Attack Stop [END]
- //Remove Cooldowns [START]
- pobeditel->RemoveAllSpellCooldown();
- izgubi->RemoveAllSpellCooldown();
- //Remove Cooldowns [END}
- //Combat Stop [START]
- pobeditel->CombatStop();
- izgubi->CombatStop();
- //Combat Stop [END]
- //Start Remove Auras and etc
- //aura
- pobeditel->RemoveAura(15007);
- izgubi->RemoveAura(15007);
- //buffs
- pobeditel->CastSpell(pobeditel, BUFF_POWER_WORD_FORTITUDE, false);
- izgubi->CastSpell(pobeditel, BUFF_POWER_WORD_FORTITUDE, false);
- pobeditel->CastSpell(pobeditel, BUFF_BLESSING_OF_KINGS, false);
- izgubi->CastSpell(pobeditel, BUFF_BLESSING_OF_KINGS, false);
- izgubi->CastSpell(izgubi, 31719, true);
- //add badge
- pobeditel->AddItem(45624, 3);
- //winer - give +7000 money / looser -7000
- izgubi->ModifyMoney(-7000);
- pobeditel->ModifyMoney(+7000);
- // Winner 650 honor Reward
- pobeditel->ModifyHonorPoints(650);
- pobeditel->CastSpell(pobeditel, 11543, 1);
- pobeditel->PlayDirectSound(11530, pobeditel);
- izgubi->DurabilityRepairAll(false, 0, false);
- pobeditel->DurabilityRepairAll(false, 0, false);
- pobeditel->RemoveAurasByType(SPELL_AURA_PERIODIC_DAMAGE);
- izgubi->RemoveAurasByType(SPELL_AURA_PERIODIC_DAMAGE);
- // Debuffs
- pobeditel->RemoveAura(57723);
- pobeditel->RemoveAura(57724);
- pobeditel->RemoveAura(25771);
- pobeditel->RemoveAura(41425);
- pobeditel->RemoveAura(61987);
- pobeditel->RemoveAura(66233);
- pobeditel->RemoveAura(11196);
- pobeditel->RemoveAura(47986);
- izgubi->RemoveAura(57723);
- izgubi->RemoveAura(57724);
- izgubi->RemoveAura(25771);
- izgubi->RemoveAura(41425);
- izgubi->RemoveAura(61987);
- izgubi->RemoveAura(66233);
- izgubi->RemoveAura(11196);
- izgubi->RemoveAura(47986);
- }
- };
- void AddSC_Reset()
- {
- new Reset_OnDuelEnd;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement