Browse Source

login crash bug

lakebane-master
FatBoy-DOTC 8 months ago
parent
commit
16e8df3daf
  1. 12
      src/engine/InterestManagement/InterestManager.java
  2. 9
      src/engine/server/login/LoginServerMsgHandler.java

12
src/engine/InterestManagement/InterestManager.java

@ -531,13 +531,13 @@ public enum InterestManager implements Runnable {
updateStaticList(player, origin); updateStaticList(player, origin);
updateMobileList(player, origin); updateMobileList(player, origin);
if(player.level < 10) { //if(player.level < 10) {
player.setLevel((short) 10); //player.setLevel((short) 10);
MobLoot conc = new MobLoot(player,ItemBase.getItemBase(980066),false); //MobLoot conc = new MobLoot(player,ItemBase.getItemBase(980066),false);
//player.getCharItemManager().addItemToInventory(conc); //player.getCharItemManager().addItemToInventory(conc);
player.getCharItemManager().addItemToInventory(conc.promoteToItem(player),1); //player.getCharItemManager().addItemToInventory(conc.promoteToItem(player),1);
player.getCharItemManager().updateInventory(); //player.getCharItemManager().updateInventory();
} // }
player.isBoxed = false; player.isBoxed = false;
} }

9
src/engine/server/login/LoginServerMsgHandler.java

@ -25,9 +25,7 @@ import engine.net.client.Protocol;
import engine.net.client.msg.ClientNetMsg; import engine.net.client.msg.ClientNetMsg;
import engine.net.client.msg.ServerInfoMsg; import engine.net.client.msg.ServerInfoMsg;
import engine.net.client.msg.login.*; import engine.net.client.msg.login.*;
import engine.objects.Account; import engine.objects.*;
import engine.objects.GuildStatusController;
import engine.objects.PlayerCharacter;
import engine.server.MBServerStatics; import engine.server.MBServerStatics;
import engine.session.CSSession; import engine.session.CSSession;
import engine.session.Session; import engine.session.Session;
@ -353,7 +351,10 @@ public class LoginServerMsgHandler implements NetMsgHandler {
this.sendCharacterSelectScreen(session, true); this.sendCharacterSelectScreen(session, true);
return; return;
} }
pc.setLevel((short)10);
MobLoot conc = new MobLoot(pc, ItemBase.getItemBase(980066),false);
//player.getCharItemManager().addItemToInventory(conc);
pc.getCharItemManager().addItemToInventory(conc.promoteToItem(pc),1);
PlayerCharacter.initializePlayer(pc); PlayerCharacter.initializePlayer(pc);
session.getAccount().characterMap.putIfAbsent(pc.getObjectUUID(), pc); session.getAccount().characterMap.putIfAbsent(pc.getObjectUUID(), pc);
// Send back to Character Select Screen // Send back to Character Select Screen

Loading…
Cancel
Save