Closed damagefilter closed 12 years ago
I think I implemented this one. I had a quick look and can't see where you mean to move it. The other login based methods have the EntityPlayer already made. Perhaps we could just remove the hook and let plugins kick in onPlayerConnect. We could even have a method denyLogin(String) or something to make it easier.
WWOL
The hook needs to be moved to the head of the method, before the player instance is created. That is needed to allow plugins to set the world the player can spawn in before the entity is created. It also requires some refactoring in the method that calls this whole thing.
See current LOGINCHECK changes in CanaryMod
Ah sorry, in the same method, silly me. If it's not too urgent I could probably do this over the weekend (2 days away for me).
WWOL
I added a world name and dimension to LoginChecks hook and changed it a little bit in the implementation (can't push to GitHub though). I didn't move it to the top of the method yet. Any reason why you wanted to do that?
WWOL
Yes, because of the World. It was my intention to to create the new player instance with the correct world and dimension already set. It will also require some changes in the method that calls the login handler. I'll do it once you pushed though.
I'll need to bug shadow for push access to github first. If I understand you correctly then I think what I have done allows you to set a world and dim without moving code. I didn't test it though.
WWOL
Fixed, closed.
Move the login check hook inside the login method further up and include a world name string in the hook object. This way we can set a cutom world and ItemInWorldManager before the player is fully registered to the server. Makes working with multiworld easier.