This commit is contained in:
Gabriele C 2015-12-18 17:11:33 +01:00
commit 7614b263b0
3 changed files with 14 additions and 4 deletions

View File

@ -90,6 +90,14 @@
<include>plugin.yml</include>
</includes>
</resource>
<resource>
<targetPath>.</targetPath>
<filtering>true</filtering>
<directory>src/main/resources/</directory>
<includes>
<include>email.html</include>
</includes>
</resource>
<resource>
<targetPath>.</targetPath>
<filtering>false</filtering>

View File

@ -229,7 +229,7 @@ public class AuthMePlayerListener implements Listener {
if (auth != null && !auth.getRealName().equals("Player") && !auth.getRealName().equals(event.getName())) {
event.setLoginResult(AsyncPlayerPreLoginEvent.Result.KICK_OTHER);
event.setKickMessage("You should join using username: " + ChatColor.AQUA + auth.getRealName() +
ChatColor.RESET + "\nnot :" + ChatColor.RED + event.getName()); // TODO: write a better message
ChatColor.RESET + "\nnot: " + ChatColor.RED + event.getName()); // TODO: write a better message
return;
}
@ -288,7 +288,7 @@ public class AuthMePlayerListener implements Listener {
pl.kickPlayer(m.retrieveSingle(MessageKey.KICK_FOR_VIP));
event.allow();
} else {
ConsoleLogger.info("The player " + event.getPlayer().getName() + " tryed to join, but the server was full");
ConsoleLogger.info("The player " + event.getPlayer().getName() + " tried to join, but the server was full");
event.setKickMessage(m.retrieveSingle(MessageKey.KICK_FULL_SERVER));
event.setResult(PlayerLoginEvent.Result.KICK_FULL);
}

View File

@ -141,8 +141,10 @@ public class AsyncRegister {
return;
}
if (!Settings.forceRegLogin) {
PlayerCache.getInstance().addPlayer(auth);
database.setLogged(name);
//PlayerCache.getInstance().addPlayer(auth);
//database.setLogged(name);
// TODO: check this...
plugin.getManagement().performLogin(player, "dontneed", true);
}
plugin.otherAccounts.addPlayer(player.getUniqueId());
ProcessSyncPasswordRegister sync = new ProcessSyncPasswordRegister(player, plugin);