numl0ckas Posted July 2, 2013 Share Posted July 2, 2013 Hello, how change spawn after death then use To Village? Using: aCis, Thanks! Link to comment Share on other sites More sharing options...
0 An4rchy Posted July 2, 2013 Share Posted July 2, 2013 Index: java/net/l2jalpha/gameserver/network/clientpackets/RequestRestartPoint.java =================================================================== --- java/net/l2jalpha/gameserver/network/clientpackets/RequestRestartPoint.java (revision 26) +++ java/net/l2jalpha/gameserver/network/clientpackets/RequestRestartPoint.java (working copy) @@ -18,7 +18,6 @@ */ package net.l2jalpha.gameserver.network.clientpackets; -import net.l2jalpha.gameserver.ThreadPoolManager; import net.l2jalpha.gameserver.datatables.sql.MapRegionTable; import net.l2jalpha.gameserver.instancemanager.CastleManager; import net.l2jalpha.gameserver.instancemanager.ClanHallManager; @@ -176,8 +175,13 @@ _log.warning("Living player ["+activeChar.getName()+"] called RestartPointPacket! Ban this player!"); return; } + + activeChar.teleToLocation(0, 0, 0, true); + activeChar.doRevive(); + activeChar.setCurrentHpMp(activeChar.getMaxHp(), activeChar.getMaxMp()); + activeChar.setCurrentCp(activeChar.getMaxCp()); - Castle castle = CastleManager.getInstance().getCastle(activeChar.getX(), activeChar.getY(), activeChar.getZ()); + /*Castle castle = CastleManager.getInstance().getCastle(activeChar.getX(), activeChar.getY(), activeChar.getZ()); if (castle != null && castle.getSiege().getIsInProgress()) { if (activeChar.getClan() != null && castle.getSiege().checkIsAttacker(activeChar.getClan())) @@ -191,7 +195,7 @@ } } - ThreadPoolManager.getInstance().scheduleGeneral(new DeathTask(activeChar), 1); + ThreadPoolManager.getInstance().scheduleGeneral(new DeathTask(activeChar), 1);*/ } Where 0, 0, 0 add your x, y, z coords. WARNING: That will modify the respawn location even if player is in siege etc. Link to comment Share on other sites More sharing options...
0 numl0ckas Posted July 2, 2013 Author Share Posted July 2, 2013 if (!activeChar.isDead()) { _log.warning("Living player [" + activeChar.getName() + "] called RequestRestartPoint packet."); return; } Castle castle = CastleManager.getInstance().getCastle(activeChar.getX(), activeChar.getY(), activeChar.getZ()); if (castle != null && castle.getSiege().getIsInProgress()) { if (activeChar.getClan() != null && castle.getSiege().checkIsAttacker(activeChar.getClan())) { // Schedule respawn delay for attacker ThreadPoolManager.getInstance().scheduleGeneral(new DeathTask(activeChar), Siege.getAttackerRespawnDelay()); if (Siege.getAttackerRespawnDelay() > 0) activeChar.sendMessage("You will be teleported in " + Siege.getAttackerRespawnDelay() / 1000 + " seconds."); return; } } // run immediately (no need to schedule) new DeathTask(activeChar).run(); } } how adapt? because i get errors Link to comment Share on other sites More sharing options...
0 SweeTs Posted July 2, 2013 Share Posted July 2, 2013 An4rchy ? :o If you mean custom spawn point when you click 'To Village', here it is. ### Eclipse Workspace Patch 1.0 #P aCis_gameserver Index: java/net/sf/l2j/gameserver/network/clientpackets/RequestRestartPoint.java =================================================================== --- java/net/sf/l2j/gameserver/network/clientpackets/RequestRestartPoint.java (revision 8) +++ java/net/sf/l2j/gameserver/network/clientpackets/RequestRestartPoint.java (working copy) @@ -138,7 +138,7 @@ break; default: - loc = MapRegionTable.getInstance().getTeleToLocation(activeChar, MapRegionTable.TeleportWhereType.Town); + loc = new Location(45786,49070 ,-3095); // x,y,z your coords break; } Link to comment Share on other sites More sharing options...
0 numl0ckas Posted July 2, 2013 Author Share Posted July 2, 2013 thanks! Link to comment Share on other sites More sharing options...
0 FighterBoss Posted July 2, 2013 Share Posted July 2, 2013 thanks! I suppose you don't have any more questions about it,locked. If you need to ask something more pm me to unlock it. Link to comment Share on other sites More sharing options...
Question
numl0ckas
Hello, how change spawn after death then use To Village? Using: aCis, Thanks!
Link to comment
Share on other sites
5 answers to this question
Recommended Posts