Jump to content

Recommended Posts

Posted

Zone name: Chaotic Zone

 

Information:

1:players can attack,use any skills (offensive or deffensive) without holding CTRL

2:you can directly pvp/pk someone

3:random spawn inside that zone after clicking "to village" button..

4:default zone is primeval island

5:players with karma don't drop inside chaotic zone

=========================

admin aio buffer

-set a character into an aio buffer in-game

-full aio buffer skill (can be modified)

-no 3rd party programs just like the 1 that has been shared here in mxc

-just an admin command,1 click aio buffer right away

send a pm and give me your offer.. price is negotiable..

 

to all haters ==== /care :)

 

EDIT: i shared a chaotic zone here in mxc, but that was a different one, and read the infos very carefully and try to understand what's the difference and try to compare it,from this proposal to that zone i already shared. ciao :P

 

 

 

Posted

@shawshaw

this? :s

 

Index: java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java	(revision 4967)
+++ java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java	(working copy)
@@ -613,6 +625,11 @@
	/** The Clan Identifier of the L2PcInstance */
	private int _clanId;

+	//Chaotic Zone
+	private static int[] _x = {11551, 10999, 10401, 9472, 6918, 9780};
+    private static int[] _y = {-24264, -23576, -24030, -23369, -23188, -22286};
+    private static int[] _z = {-3644, -3651, -3660, -3703, -3653, -3699};
+	
	/** The Clan object of the L2PcInstance */
	private L2Clan _clan;

@@ -2000,6 +2131,13 @@
			ExSetCompassZoneCode cz = new ExSetCompassZoneCode(ExSetCompassZoneCode.SIEGEWARZONE2);
			sendPacket(cz);
		}
+		else if (isInsideZone(ZONE_CHAOTIC))
+		{
+			if (_lastCompassZone == ExSetCompassZoneCode.CHAOTICZONE) return;
+			_lastCompassZone = ExSetCompassZoneCode.CHAOTICZONE;
+			ExSetCompassZoneCode cz = new ExSetCompassZoneCode(ExSetCompassZoneCode.CHAOTICZONE);
+			sendPacket(cz);
+		}
		else if (isInsideZone(ZONE_PVP))
		{
			if (_lastCompassZone == ExSetCompassZoneCode.PVPZONE) return;
@@ -5349,6 +5593,36 @@
						Announcements.getInstance().announceToAll(msg);
				}
			}
+			if (isInsideZone(ZONE_CHAOTIC))
+			{
+				{
+					sendMessage("Get ready! You will be revive in 5 seconds!");
+					ThreadPoolManager.getInstance().scheduleGeneral(new Runnable()
+					{
+						public void run()
+						{
+							int r = Rnd.get(3);
+							teleToLocation(_x[r] , _y[r], _z[r]);
+							doRevive();
+						}
+					}, 5000);
+				}
+			}

			broadcastStatusUpdate();
			// Clear resurrect xp calculation

Index: java/com/l2jserver/gameserver/network/serverpackets/Die.java
===================================================================
--- java/com/l2jserver/gameserver/network/serverpackets/Die.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/serverpackets/Die.java	(working copy)
@@ -62,10 +63,13 @@

		}
		_charObjId = cha.getObjectId();
	_canTeleport = !((cha instanceof L2PcInstance && TvTEvent.isStarted() && TvTEvent.isPlayerParticipant(_charObjId)) || cha.isPendingRevive());
		if (cha instanceof L2Attackable)
			_sweepable = ((L2Attackable)cha).isSweepActive();

+		if(cha instanceof L2PcInstance && ((L2PcInstance)cha).getWorldRegion().containsZone(42490))
+            _canTeleport = false;
+		
	}
Index: java/com/l2jserver/gameserver/network/SystemMessageId.java
===================================================================
--- java/com/l2jserver/gameserver/network/SystemMessageId.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/SystemMessageId.java	(working copy)
@@ -14693,6 +14693,25 @@
	public static final SystemMessageId THOMAS_D_TURKEY_DISAPPEARED;

	/**
+	 * ID: 6510<br>
+	 * Message: Chaotic Zone
+	 */
+	public static final SystemMessageId CHAOTIC_ZONE;
+	
+	
+	/**
	 * Array containing all SystemMessageIds<br>
	 * Important: Always initialize with a length of the highest SystemMessageId + 1!!!
	 */
@@ -17116,7 +17135,9 @@
		THOMAS_D_TURKEY_APPEARED = new SystemMessageId(6503);
		THOMAS_D_TURKEY_DEFETED = new SystemMessageId(6504);
		THOMAS_D_TURKEY_DISAPPEARED = new SystemMessageId(6505);
-		
+		CHAOTIC_ZONE = new SystemMessageId(6510);
		buildFastLookupTable();
	}
Index: java/com/l2jserver/gameserver/network/serverpackets/ExSetCompassZoneCode.java
===================================================================
--- java/com/l2jserver/gameserver/network/serverpackets/ExSetCompassZoneCode.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/serverpackets/ExSetCompassZoneCode.java	(working copy)
@@ -23,12 +23,13 @@
	private static final String _S__FE_32_EXSETCOMPASSZONECODE = "[s] FE:33 ExSetCompassZoneCode";

	public static final int ALTEREDZONE = 0x08;
public static final int SIEGEWARZONE1 = 0x0A; 
	public static final int SIEGEWARZONE2 = 0x0B;
	public static final int PEACEZONE = 0x0C;
	public static final int SEVENSIGNSZONE = 0x0D;
	public static final int PVPZONE = 0x0E;
	public static final int GENERALZONE = 0x0F;
+	public static final int CHAOTICZONE = 0x09;

	private int _zoneType;
Index: java/com/l2jserver/gameserver/model/zone/type/L2ChaoticZone.java
===================================================================
--- java/com/l2jserver/gameserver/model/zone/type/L2ChaoticZone.java	(revision 0)
+++ java/com/l2jserver/gameserver/model/zone/type/L2ChaoticZone.java	(revision 0)
@@ -0,0 +1,82 @@
+/*
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 3 of the License, or (at your option) any later
+ * version.
+ * 
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ * 
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package com.l2jserver.gameserver.model.zone.type;
+
+import com.l2jserver.gameserver.datatables.SkillTable;
+import com.l2jserver.gameserver.model.actor.L2Character;
+import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
+import com.l2jserver.gameserver.model.zone.L2SpawnZone;
+
+
+/**
+ * Diffrent Version of Chaotic Zone
+ *
+ * @author  Jeff 
+ */
+public class L2ChaoticZone extends L2SpawnZone
+{	
+	public L2ChaoticZone(int id)
+	{
+		super(42490);
+	}
+	
+	@Override
+	protected void onEnter(L2Character character)
+	{
+		character.setInsideZone(L2Character.ZONE_CHAOTIC, true);
+		character.setInsideZone(L2Character.ZONE_NOSUMMONFRIEND, true);
+		character.setInsideZone(L2Character.ZONE_NOSTORE, true);
+		character.setInsideZone(L2Character.ZONE_NOBOOKMARK, true);
+		character.setInsideZone(L2Character.ZONE_NOITEMDROP, true);
+		
+	       if (character instanceof L2PcInstance)
+	       {
+	           ((L2PcInstance) character).setPvpFlag(1);
+	           ((L2PcInstance) character).sendMessage("You entered a Chaotic Zone");
+	           ((L2PcInstance) character).broadcastUserInfo();
+	       }
+	}
+	
+	@Override
+	protected void onExit(L2Character character)
+	{
+		character.setInsideZone(L2Character.ZONE_CHAOTIC, false);
+		character.setInsideZone(L2Character.ZONE_NOSUMMONFRIEND, false);
+		character.setInsideZone(L2Character.ZONE_NOSTORE, false);
+		character.setInsideZone(L2Character.ZONE_NOBOOKMARK, false);
+		character.setInsideZone(L2Character.ZONE_NOITEMDROP, false);
+		
+		if (character instanceof L2PcInstance)
+		{
+			((L2PcInstance) character).sendMessage("You left a Chaotic Zone");
+			((L2PcInstance) character).setPvpFlag(0);
+			((L2PcInstance) character).broadcastUserInfo();
+		}
+	}
+	
+	@Override
+	public void onDieInside(L2Character character)
+	{
+	       if (character instanceof L2PcInstance)
+	       {
+	       }
+	}
+	
+	@Override
+	public void onReviveInside(L2Character character)
+	{
+        SkillTable.getInstance().getInfo(1323, 1).getEffects(character, character);
+	}
+}
\ No newline at end of file
Index: java/com/l2jserver/gameserver/network/clientpackets/Logout.java
===================================================================
--- java/com/l2jserver/gameserver/network/clientpackets/Logout.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/clientpackets/Logout.java	(working copy)
@@ -83,6 +85,14 @@
			return;
		}

+		//Chaotic Zone
+		if (player.isInsideZone(player.ZONE_CHAOTIC))
+		{
+					player.sendMessage("You cannot log out while you are inside Chaotic Zone.");
+					sendPacket(RestartResponse.valueOf(false));
+					return;
+		}
+		
		// Prevent player from logging out if they are a festival participant
		// and it is in progress, otherwise notify party members that the player
		// is not longer a participant.
Index: java/com/l2jserver/gameserver/network/clientpackets/RequestRestart.java
===================================================================
--- java/com/l2jserver/gameserver/network/clientpackets/RequestRestart.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/clientpackets/RequestRestart.java	(working copy)
@@ -87,6 +88,15 @@
			return;
		}

+		//Chaotic Zone
+		if (player.isInsideZone(player.ZONE_CHAOTIC))
+		{
+			player.sendMessage("You cannot restart while you are inside Chaotic Zone.");
+			sendPacket(RestartResponse.valueOf(false));
+			return;
+		}
+		
+		
		// Prevent player from restarting if they are a festival participant
		// and it is in progress, otherwise notify party members that the player
		// is not longer a participant.

Index: java/com/l2jserver/gameserver/model/actor/L2Character.java
===================================================================
--- java/com/l2jserver/gameserver/model/actor/L2Character.java	(revision 4967)
+++ java/com/l2jserver/gameserver/model/actor/L2Character.java	(working copy)
@@ -205,8 +205,10 @@
	public static final byte ZONE_ALTERED = 19;
	public static final byte ZONE_NOBOOKMARK = 20;
	public static final byte ZONE_NOITEMDROP = 21;
+	public static final byte ZONE_CHAOTIC = 22;

-	private final byte[] _zones = new byte[22];
+	private final byte[] _zones = new byte[23];

 

Index: dist/game/data/scripts/handlers/voicedcommandhandlers/Home.java
===================================================================
--- dist/game/data/scripts/handlers/voicedcommandhandlers/Home.java	(revision 0)
+++ dist/game/data/scripts/handlers/voicedcommandhandlers/Home.java	(revision 0)
@@ -0,0 +1,106 @@
+/*
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 3 of the License, or (at your option) any later
+ * version.
+ * 
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ * 
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package handlers.voicedcommandhandlers;
+
+import com.l2jserver.Config;
+import com.l2jserver.gameserver.datatables.MapRegionTable;
+import com.l2jserver.gameserver.handler.IVoicedCommandHandler;
+import com.l2jserver.gameserver.model.Location;
+import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
+import com.l2jserver.gameserver.network.serverpackets.ActionFailed;
+import com.l2jserver.gameserver.taskmanager.AttackStanceTaskManager;
+
+
+/**
+ * ===Jeff===
+ *
+ */
+public class Home implements IVoicedCommandHandler
+{
+    private static final String[] VOICED_COMMANDS = { "home" };
+    public boolean useVoicedCommand(String command, L2PcInstance activeChar, String target)
+    {    
+        if (command.equalsIgnoreCase("home"))
+        {
+        	if(activeChar.isDead())
+        	{
+                activeChar.sendMessage("You cannot use this feature if you're dead.");
+               return false;
+             }
+             if(activeChar.isInOlympiadMode())
+              {
+              activeChar.sendMessage("You cannot use this feature during olympiad.");
+             return false;
+           }
+           if(activeChar.isInJail())
+             {
+              activeChar.sendMessage("You cannot use this command while you are in Jail.");
+             return false;
+           }
+           if(activeChar.isInDuel())
+            {
+             activeChar.sendMessage("You cannot use this feature during Duel.");
+            return false;
+          }
+          if(activeChar.isFestivalParticipant())
+           {
+            activeChar.sendMessage("You cannot use this feature during a Festival.");
+           return false;
+          }
+          if(activeChar.inObserverMode())
+           {
+            activeChar.sendMessage("You cannot use this feature during Observer Mode.");
+           return false;
+          }
+           if(activeChar.getInventory().getItemByItemId(57) == null)
+           {
+              activeChar.sendMessage("You don't have enough adena to use command .home");
+             return false;
+           }  
+   		if(AttackStanceTaskManager.getInstance().getAttackStanceTask(activeChar) && !(activeChar.isGM() && Config.GM_RESTART_FIGHTING))
+   		{
+   			if (Config.DEBUG) _log.fine("Player " + activeChar.getName() + " tried to logout while fighting inside chaotic zone");
+   			
+   			activeChar.sendMessage("You cannot go home while fighting!"); 
+   			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+   			return false;
+   		}
+           if(activeChar instanceof L2PcInstance && ((L2PcInstance)activeChar).getWorldRegion().containsZone(42490))
+       	{
+              activeChar.sendMessage("You will be send to nearest town!"); 
+              activeChar.getInventory().destroyItemByItemId("root", 57, 500, activeChar, activeChar.getTarget());
+              activeChar.broadcastUserInfo();
+              Location loc = MapRegionTable.getInstance().getTeleToLocation(activeChar, MapRegionTable.TeleportWhereType.Town);
+              activeChar.setInstanceId(0);
+              activeChar.teleToLocation(loc, true);
+              activeChar.doRevive();
+        }
+       	else 
+       	{
+       		activeChar.sendMessage("Command .home can only be used inside Chaotic Zone");
+       	}
+        }
+       return true;
+    }
+    public static int teleToLocation()
+	{
+		return teleToLocation();
+	}
+    public String[] getVoicedCommandList()
+    {
+        return VOICED_COMMANDS;
+    }
+
+}
\ No newline at end of file
Index: dist/game/data/scripts/handlers/MasterHandler.java
===================================================================
--- dist/game/data/scripts/handlers/MasterHandler.java	(revision 8427)
+++ dist/game/data/scripts/handlers/MasterHandler.java	(working copy)
@@ -240,12 +251,20 @@
import handlers.voicedcommandhandlers.TvTVoicedInfo;
+import handlers.voicedcommandhandlers.Home;
import handlers.voicedcommandhandlers.Wedding;
import handlers.voicedcommandhandlers.stats;

import java.util.logging.Logger;
@@ -535,7 +565,16 @@

	private static void loadVoicedHandlers()
	{
		VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new stats());
+		VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new Home());
                if (Config.L2JMOD_ALLOW_WEDDING)
			VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new Wedding());
		if (Config.BANKING_SYSTEM_ENABLED)

 

shared on mxc :s

Posted

@shawshaw

this? :s

 

Index: java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java	(revision 4967)
+++ java/com/l2jserver/gameserver/model/actor/instance/L2PcInstance.java	(working copy)
@@ -613,6 +625,11 @@
	/** The Clan Identifier of the L2PcInstance */
	private int _clanId;

+	//Chaotic Zone
+	private static int[] _x = {11551, 10999, 10401, 9472, 6918, 9780};
+    private static int[] _y = {-24264, -23576, -24030, -23369, -23188, -22286};
+    private static int[] _z = {-3644, -3651, -3660, -3703, -3653, -3699};
+	
	/** The Clan object of the L2PcInstance */
	private L2Clan _clan;

@@ -2000,6 +2131,13 @@
			ExSetCompassZoneCode cz = new ExSetCompassZoneCode(ExSetCompassZoneCode.SIEGEWARZONE2);
			sendPacket(cz);
		}
+		else if (isInsideZone(ZONE_CHAOTIC))
+		{
+			if (_lastCompassZone == ExSetCompassZoneCode.CHAOTICZONE) return;
+			_lastCompassZone = ExSetCompassZoneCode.CHAOTICZONE;
+			ExSetCompassZoneCode cz = new ExSetCompassZoneCode(ExSetCompassZoneCode.CHAOTICZONE);
+			sendPacket(cz);
+		}
		else if (isInsideZone(ZONE_PVP))
		{
			if (_lastCompassZone == ExSetCompassZoneCode.PVPZONE) return;
@@ -5349,6 +5593,36 @@
						Announcements.getInstance().announceToAll(msg);
				}
			}
+			if (isInsideZone(ZONE_CHAOTIC))
+			{
+				{
+					sendMessage("Get ready! You will be revive in 5 seconds!");
+					ThreadPoolManager.getInstance().scheduleGeneral(new Runnable()
+					{
+						public void run()
+						{
+							int r = Rnd.get(3);
+							teleToLocation(_x[r] , _y[r], _z[r]);
+							doRevive();
+						}
+					}, 5000);
+				}
+			}

			broadcastStatusUpdate();
			// Clear resurrect xp calculation

Index: java/com/l2jserver/gameserver/network/serverpackets/Die.java
===================================================================
--- java/com/l2jserver/gameserver/network/serverpackets/Die.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/serverpackets/Die.java	(working copy)
@@ -62,10 +63,13 @@

		}
		_charObjId = cha.getObjectId();
	_canTeleport = !((cha instanceof L2PcInstance && TvTEvent.isStarted() && TvTEvent.isPlayerParticipant(_charObjId)) || cha.isPendingRevive());
		if (cha instanceof L2Attackable)
			_sweepable = ((L2Attackable)cha).isSweepActive();

+		if(cha instanceof L2PcInstance && ((L2PcInstance)cha).getWorldRegion().containsZone(42490))
+            _canTeleport = false;
+		
	}
Index: java/com/l2jserver/gameserver/network/SystemMessageId.java
===================================================================
--- java/com/l2jserver/gameserver/network/SystemMessageId.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/SystemMessageId.java	(working copy)
@@ -14693,6 +14693,25 @@
	public static final SystemMessageId THOMAS_D_TURKEY_DISAPPEARED;

	/**
+	 * ID: 6510<br>
+	 * Message: Chaotic Zone
+	 */
+	public static final SystemMessageId CHAOTIC_ZONE;
+	
+	
+	/**
	 * Array containing all SystemMessageIds<br>
	 * Important: Always initialize with a length of the highest SystemMessageId + 1!!!
	 */
@@ -17116,7 +17135,9 @@
		THOMAS_D_TURKEY_APPEARED = new SystemMessageId(6503);
		THOMAS_D_TURKEY_DEFETED = new SystemMessageId(6504);
		THOMAS_D_TURKEY_DISAPPEARED = new SystemMessageId(6505);
-		
+		CHAOTIC_ZONE = new SystemMessageId(6510);
		buildFastLookupTable();
	}
Index: java/com/l2jserver/gameserver/network/serverpackets/ExSetCompassZoneCode.java
===================================================================
--- java/com/l2jserver/gameserver/network/serverpackets/ExSetCompassZoneCode.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/serverpackets/ExSetCompassZoneCode.java	(working copy)
@@ -23,12 +23,13 @@
	private static final String _S__FE_32_EXSETCOMPASSZONECODE = "[s] FE:33 ExSetCompassZoneCode";

	public static final int ALTEREDZONE = 0x08;
public static final int SIEGEWARZONE1 = 0x0A; 
	public static final int SIEGEWARZONE2 = 0x0B;
	public static final int PEACEZONE = 0x0C;
	public static final int SEVENSIGNSZONE = 0x0D;
	public static final int PVPZONE = 0x0E;
	public static final int GENERALZONE = 0x0F;
+	public static final int CHAOTICZONE = 0x09;

	private int _zoneType;
Index: java/com/l2jserver/gameserver/model/zone/type/L2ChaoticZone.java
===================================================================
--- java/com/l2jserver/gameserver/model/zone/type/L2ChaoticZone.java	(revision 0)
+++ java/com/l2jserver/gameserver/model/zone/type/L2ChaoticZone.java	(revision 0)
@@ -0,0 +1,82 @@
+/*
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 3 of the License, or (at your option) any later
+ * version.
+ * 
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ * 
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package com.l2jserver.gameserver.model.zone.type;
+
+import com.l2jserver.gameserver.datatables.SkillTable;
+import com.l2jserver.gameserver.model.actor.L2Character;
+import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
+import com.l2jserver.gameserver.model.zone.L2SpawnZone;
+
+
+/**
+ * Diffrent Version of Chaotic Zone
+ *
+ * @author  Jeff 
+ */
+public class L2ChaoticZone extends L2SpawnZone
+{	
+	public L2ChaoticZone(int id)
+	{
+		super(42490);
+	}
+	
+	@Override
+	protected void onEnter(L2Character character)
+	{
+		character.setInsideZone(L2Character.ZONE_CHAOTIC, true);
+		character.setInsideZone(L2Character.ZONE_NOSUMMONFRIEND, true);
+		character.setInsideZone(L2Character.ZONE_NOSTORE, true);
+		character.setInsideZone(L2Character.ZONE_NOBOOKMARK, true);
+		character.setInsideZone(L2Character.ZONE_NOITEMDROP, true);
+		
+	       if (character instanceof L2PcInstance)
+	       {
+	           ((L2PcInstance) character).setPvpFlag(1);
+	           ((L2PcInstance) character).sendMessage("You entered a Chaotic Zone");
+	           ((L2PcInstance) character).broadcastUserInfo();
+	       }
+	}
+	
+	@Override
+	protected void onExit(L2Character character)
+	{
+		character.setInsideZone(L2Character.ZONE_CHAOTIC, false);
+		character.setInsideZone(L2Character.ZONE_NOSUMMONFRIEND, false);
+		character.setInsideZone(L2Character.ZONE_NOSTORE, false);
+		character.setInsideZone(L2Character.ZONE_NOBOOKMARK, false);
+		character.setInsideZone(L2Character.ZONE_NOITEMDROP, false);
+		
+		if (character instanceof L2PcInstance)
+		{
+			((L2PcInstance) character).sendMessage("You left a Chaotic Zone");
+			((L2PcInstance) character).setPvpFlag(0);
+			((L2PcInstance) character).broadcastUserInfo();
+		}
+	}
+	
+	@Override
+	public void onDieInside(L2Character character)
+	{
+	       if (character instanceof L2PcInstance)
+	       {
+	       }
+	}
+	
+	@Override
+	public void onReviveInside(L2Character character)
+	{
+        SkillTable.getInstance().getInfo(1323, 1).getEffects(character, character);
+	}
+}
\ No newline at end of file
Index: java/com/l2jserver/gameserver/network/clientpackets/Logout.java
===================================================================
--- java/com/l2jserver/gameserver/network/clientpackets/Logout.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/clientpackets/Logout.java	(working copy)
@@ -83,6 +85,14 @@
			return;
		}

+		//Chaotic Zone
+		if (player.isInsideZone(player.ZONE_CHAOTIC))
+		{
+					player.sendMessage("You cannot log out while you are inside Chaotic Zone.");
+					sendPacket(RestartResponse.valueOf(false));
+					return;
+		}
+		
		// Prevent player from logging out if they are a festival participant
		// and it is in progress, otherwise notify party members that the player
		// is not longer a participant.
Index: java/com/l2jserver/gameserver/network/clientpackets/RequestRestart.java
===================================================================
--- java/com/l2jserver/gameserver/network/clientpackets/RequestRestart.java	(revision 4967)
+++ java/com/l2jserver/gameserver/network/clientpackets/RequestRestart.java	(working copy)
@@ -87,6 +88,15 @@
			return;
		}

+		//Chaotic Zone
+		if (player.isInsideZone(player.ZONE_CHAOTIC))
+		{
+			player.sendMessage("You cannot restart while you are inside Chaotic Zone.");
+			sendPacket(RestartResponse.valueOf(false));
+			return;
+		}
+		
+		
		// Prevent player from restarting if they are a festival participant
		// and it is in progress, otherwise notify party members that the player
		// is not longer a participant.

Index: java/com/l2jserver/gameserver/model/actor/L2Character.java
===================================================================
--- java/com/l2jserver/gameserver/model/actor/L2Character.java	(revision 4967)
+++ java/com/l2jserver/gameserver/model/actor/L2Character.java	(working copy)
@@ -205,8 +205,10 @@
	public static final byte ZONE_ALTERED = 19;
	public static final byte ZONE_NOBOOKMARK = 20;
	public static final byte ZONE_NOITEMDROP = 21;
+	public static final byte ZONE_CHAOTIC = 22;

-	private final byte[] _zones = new byte[22];
+	private final byte[] _zones = new byte[23];

 

Index: dist/game/data/scripts/handlers/voicedcommandhandlers/Home.java
===================================================================
--- dist/game/data/scripts/handlers/voicedcommandhandlers/Home.java	(revision 0)
+++ dist/game/data/scripts/handlers/voicedcommandhandlers/Home.java	(revision 0)
@@ -0,0 +1,106 @@
+/*
+ * This program is free software: you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by the Free Software
+ * Foundation, either version 3 of the License, or (at your option) any later
+ * version.
+ * 
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ * 
+ * You should have received a copy of the GNU General Public License along with
+ * this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package handlers.voicedcommandhandlers;
+
+import com.l2jserver.Config;
+import com.l2jserver.gameserver.datatables.MapRegionTable;
+import com.l2jserver.gameserver.handler.IVoicedCommandHandler;
+import com.l2jserver.gameserver.model.Location;
+import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
+import com.l2jserver.gameserver.network.serverpackets.ActionFailed;
+import com.l2jserver.gameserver.taskmanager.AttackStanceTaskManager;
+
+
+/**
+ * ===Jeff===
+ *
+ */
+public class Home implements IVoicedCommandHandler
+{
+    private static final String[] VOICED_COMMANDS = { "home" };
+    public boolean useVoicedCommand(String command, L2PcInstance activeChar, String target)
+    {    
+        if (command.equalsIgnoreCase("home"))
+        {
+        	if(activeChar.isDead())
+        	{
+                activeChar.sendMessage("You cannot use this feature if you're dead.");
+               return false;
+             }
+             if(activeChar.isInOlympiadMode())
+              {
+              activeChar.sendMessage("You cannot use this feature during olympiad.");
+             return false;
+           }
+           if(activeChar.isInJail())
+             {
+              activeChar.sendMessage("You cannot use this command while you are in Jail.");
+             return false;
+           }
+           if(activeChar.isInDuel())
+            {
+             activeChar.sendMessage("You cannot use this feature during Duel.");
+            return false;
+          }
+          if(activeChar.isFestivalParticipant())
+           {
+            activeChar.sendMessage("You cannot use this feature during a Festival.");
+           return false;
+          }
+          if(activeChar.inObserverMode())
+           {
+            activeChar.sendMessage("You cannot use this feature during Observer Mode.");
+           return false;
+          }
+           if(activeChar.getInventory().getItemByItemId(57) == null)
+           {
+              activeChar.sendMessage("You don't have enough adena to use command .home");
+             return false;
+           }  
+   		if(AttackStanceTaskManager.getInstance().getAttackStanceTask(activeChar) && !(activeChar.isGM() && Config.GM_RESTART_FIGHTING))
+   		{
+   			if (Config.DEBUG) _log.fine("Player " + activeChar.getName() + " tried to logout while fighting inside chaotic zone");
+   			
+   			activeChar.sendMessage("You cannot go home while fighting!"); 
+   			activeChar.sendPacket(ActionFailed.STATIC_PACKET);
+   			return false;
+   		}
+           if(activeChar instanceof L2PcInstance && ((L2PcInstance)activeChar).getWorldRegion().containsZone(42490))
+       	{
+              activeChar.sendMessage("You will be send to nearest town!"); 
+              activeChar.getInventory().destroyItemByItemId("root", 57, 500, activeChar, activeChar.getTarget());
+              activeChar.broadcastUserInfo();
+              Location loc = MapRegionTable.getInstance().getTeleToLocation(activeChar, MapRegionTable.TeleportWhereType.Town);
+              activeChar.setInstanceId(0);
+              activeChar.teleToLocation(loc, true);
+              activeChar.doRevive();
+        }
+       	else 
+       	{
+       		activeChar.sendMessage("Command .home can only be used inside Chaotic Zone");
+       	}
+        }
+       return true;
+    }
+    public static int teleToLocation()
+	{
+		return teleToLocation();
+	}
+    public String[] getVoicedCommandList()
+    {
+        return VOICED_COMMANDS;
+    }
+
+}
\ No newline at end of file
Index: dist/game/data/scripts/handlers/MasterHandler.java
===================================================================
--- dist/game/data/scripts/handlers/MasterHandler.java	(revision 8427)
+++ dist/game/data/scripts/handlers/MasterHandler.java	(working copy)
@@ -240,12 +251,20 @@
import handlers.voicedcommandhandlers.TvTVoicedInfo;
+import handlers.voicedcommandhandlers.Home;
import handlers.voicedcommandhandlers.Wedding;
import handlers.voicedcommandhandlers.stats;

import java.util.logging.Logger;
@@ -535,7 +565,16 @@

	private static void loadVoicedHandlers()
	{
		VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new stats());
+		VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new Home());
                if (Config.L2JMOD_ALLOW_WEDDING)
			VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new Wedding());
		if (Config.BANKING_SYSTEM_ENABLED)

 

shared on mxc :s

 

did you guys even noticed who made that? i made that one, and it's not the original chaotic zone, as the title says on that share "Chaotic Zone Different version".. that share will only make players auto flag and auto revive plus random spawn, what i am trying to sell is the popular,old school,original chaotic zone,actually this zone can be seen in lots of l2off private server, but never been shared.

Posted

@wyatt hey meng, use your arrogance to your enemies, not to me, because i did nothing to you,and i don't have against with you, if you have problem with this post, then you have the right to stfu and stop spamming.. make your own script and share it nigga... Ohh and one last thing, make your own chaotic zone,then share it to someone,so the world would not look so stupid if someone "EVER" buy this script.. ohh yeahh, never did much work with it, just messing up some pussy inside l2pcinstance... and ,l,

Posted

@shawshaw

Take it easy man, my last post in your thread, leave in peace.

 

you pissed me off nigga.. There's a lot more stupid post compare to mine for you to react , and you came here just like dropping a damn nuclear bomb from US to PHIL.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...