Jump to content
  • 0

Pvp/pk Circle Acis Problem


Tachi

Question

who can help me to import pvp/pk circle  on 1 private project ..source acis

 

video with code done but not mine :(

 

 

this is code

### Eclipse Workspace Patch 1.0
#P L2jFrozen_GameServer_tests
Index: head-src/com/l2jfrozen/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- head-src/com/l2jfrozen/gameserver/model/actor/instance/L2PcInstance.java	(revision 488)
+++ head-src/com/l2jfrozen/gameserver/model/actor/instance/L2PcInstance.java	(working copy)
@@ -5845,6 +5845,7 @@
 		}
 
 		setPvpFlag(0); // Clear the pvp flag
+		setTeam(0);
 
 		// Unsummon Cubics
 		if(_cubics.size() > 0)
@@ -6698,6 +6699,7 @@
 		}
 
 		//Update the character's title color if they reached any of the 5 PK levels.
+		setTeam(2);
 		updatePkColor(getPkKills());
 		broadcastUserInfo();
 
Index: head-src/com/l2jfrozen/gameserver/model/L2Character.java
===================================================================
--- head-src/com/l2jfrozen/gameserver/model/L2Character.java	(revision 488)
+++ head-src/com/l2jfrozen/gameserver/model/L2Character.java	(working copy)
@@ -189,6 +189,7 @@
 	private double _hpUpdateDecCheck = .0;
 	private double _hpUpdateInterval = .0;
 	private boolean _champion = false;
+	private int _team = 0;
 	/** Table of Calculators containing all used calculator */
 	private Calculator[] _calculators;
 
@@ -8161,6 +8162,7 @@
 	{
 		_pvpFlagLasts = time;
 	}
+	
 
 	public long getPvpFlagLasts()
 	{
@@ -8170,10 +8172,24 @@
 	public void startPvPFlag()
 	{
 		updatePvPFlag(1);
+		setTeam(1);
 
 		_PvPRegTask = ThreadPoolManager.getInstance().scheduleGeneralAtFixedRate(new PvPFlag(), 1000, 1000);
 	}
 
+	/**
+	 * @param i
+	 */
+	public void setTeam(int team)
+	{
+		_team = team;
+	}
+
+	public int getTeam()
+	{
+		return _team;
+	}
+
 	public void stopPvpRegTask()
 	{
 		if(_PvPRegTask != null)
@@ -8185,7 +8201,7 @@
 	public void stopPvPFlag()
 	{
 		stopPvpRegTask();
-
+		setTeam(0);
 		updatePvPFlag(0);
 
 		_PvPRegTask = null;

Link to comment
Share on other sites

Recommended Posts

Guest
This topic is now closed to further replies.


×
×
  • Create New...