Forum > Serverside Modding
[QUESTION] How to get new players to start in phase 2?
(1/1)
frommeboys:
So, I want new players to start in the gadgetzan arena, however I don't want to completely change gadgetzan for when players go back there after leveling. I have the mobs all there in phase 2, but I don't know how to get the players to start in a phase other than one. I looked around player.cpp, and it might be there, but I dont know the exact syntax for the phase, or I think it could be posible using playercreateinfo_cast_spell with a spell that changes phase, but I didnt see one when I looked. Any help is appreciated.
Adspartan:
Assuming you're using Trinitycore 3.3.5 (idk about the other extensions):
Just create a PlayerScript and override this function to set the player to the phase you want :
--- Code: ---virtual void OnLogin(Player* /*player*/, bool /*firstLogin*/) { } --- End code --- (in ScriptMgr.h)
frommeboys:
I've done some core edits before, but I havent written any scripts as of yet. Are you suggesting I create a new funtions that looks something like OnLogin(Player* /*player*/, bool /*firstLogin*/, uint32 /*phase#*/) ?
Or are you suggesting that I call the current OnLogin and do stuffs with it?
Navigation
[0] Message Index
|