How can I substitute if (player->GetLevel() == #) to automatically sense each level up.
[CODE]
/************************************
-
AnimationOnLevel *
-
*
-
Edit By DemonicRealms *
-
*
-
RealityNetGaming *
*/
class AnimationOnLevel : public PlayerScript
{
public:
AnimationOnLevel() : PlayerScript(“AnimationOnLevel”) { }
void OnLevelChanged(Player* player, unit8 oldLevel)
{
if (player->GetLevel() == 2)
player->CastSpell(player, 127933);
if (player->GetLevel() == 3)
player->CastSpell(player, 127933);
}
};
void AddSC_AnimationOnLevel()
{
new AnimationOnLevel;
}[/CODE]