Scripts/Gilneas:

* added more sparring datas
* fixed Quests "Sacrifices" and "By Blood and Ash"
* added missing reward spells for quest "The Last Stand"
* killed some duplicate spawns
* added emote states to Tobias Mistmantle and Lord Darius Crowley
* gave the interior rebels a SAI script to look for enemies if not on combat
This commit is contained in:
Ovalord
2018-01-13 18:41:20 +01:00
parent dd2ab26731
commit 06aeeb59bd
3 changed files with 302 additions and 2 deletions

View File

@@ -4674,6 +4674,46 @@ class spell_gen_gilneas_prison_periodic_dummy : public SpellScriptLoader
}
};
enum Sacrifices
{
CREDIT_ROUND_UP_WORGEN = 35582,
SPELL_THROW_TORCH = 67063
};
class spell_gen_throw_torch : public SpellScriptLoader
{
public:
spell_gen_throw_torch() : SpellScriptLoader("spell_gen_throw_torch") { }
class spell_gen_throw_torch_SpellScript : public SpellScript
{
PrepareSpellScript(spell_gen_throw_torch_SpellScript);
bool Validate(SpellInfo const* /*spellInfo*/) override
{
return ValidateSpellInfo( { SPELL_THROW_TORCH });
}
void HandleEffect()
{
if (Player* player = GetCaster()->ToPlayer())
if (GetHitUnit() && !GetHitUnit()->HasAura(SPELL_THROW_TORCH))
player->KilledMonsterCredit(CREDIT_ROUND_UP_WORGEN);
}
void Register()
{
BeforeHit += SpellHitFn(spell_gen_throw_torch_SpellScript::HandleEffect);
}
};
SpellScript* GetSpellScript() const
{
return new spell_gen_throw_torch_SpellScript();
}
};
void AddSC_generic_spell_scripts()
{
new spell_gen_absorb0_hitlimit1();
@@ -4780,4 +4820,5 @@ void AddSC_generic_spell_scripts()
new spell_gen_projectile_goods();
new spell_gen_vengeance();
new spell_gen_gilneas_prison_periodic_dummy();
new spell_gen_throw_torch();
}