Jump to content

Ironmaiden2012

Members
  • Posts

    3
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

1 Follower

About Ironmaiden2012

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Ironmaiden2012's Achievements

Newbie

Newbie (1/16)

  • Week One Done Rare
  • One Month Later Rare
  • One Year In Rare

Recent Badges

0

Reputation

  1. Wtb faction server interlude, info and price please, thank you.
  2. Hello, can you help me with a problem? I need to stop attacking the character for a while when clicking to walk. I tried two ways. At first he does not attack until you finish walking, that's bad for archer, in the second he stops attacking and not attacking more, you can tell me why? I'm trying to make a server with high status, please help me in this. What area will the forum for these questions, I am newbie in the forum. Sorry my english and thanks for reading. (Check One) Index: head-src/com/l2jfrozen/gameserver/model/L2Character.java =================================================================== --- head-src/com/l2jfrozen/gameserver/model/L2Character.java (revisão 65) +++ head-src/com/l2jfrozen/gameserver/model/L2Character.java (cópia de trabalho) @@ -932,7 +932,13 @@ if(target == null) return; - + + if(isMoving()) + { + sendPacket(ActionFailed.STATIC_PACKET); + return; + } + if(isAlikeDead()) { // If L2PcInstance is dead or the target is dead, the action is stoped (Check Two) Index: head-src/com/l2jfrozen/gameserver/model/L2Character.java =================================================================== --- head-src/com/l2jfrozen/gameserver/model/L2Character.java (revisão 65) +++ head-src/com/l2jfrozen/gameserver/model/L2Character.java (cópia de trabalho) @@ -219,6 +219,10 @@ private boolean _blocked; private boolean _meditated; + + /**MY Variables*/ + private boolean moved = false; + /** * Zone system<br> * x^2 or x*x @@ -932,7 +936,13 @@ if(target == null) return; - + + if(getMoved()) + { + sendPacket(ActionFailed.STATIC_PACKET); + return; + } + if(isAlikeDead()) { // If L2PcInstance is dead or the target is dead, the action is stoped @@ -9589,4 +9599,14 @@ { return _isBuffProtected; } + + public void setMoved(boolean x) + { + moved = x; + } + + public boolean getMoved() + { + return moved; + } } Index: head-src/com/l2jfrozen/gameserver/network/clientpackets/MoveBackwardToLocation.java =================================================================== --- head-src/com/l2jfrozen/gameserver/network/clientpackets/MoveBackwardToLocation.java (revisão 65) +++ head-src/com/l2jfrozen/gameserver/network/clientpackets/MoveBackwardToLocation.java (cópia de trabalho) @@ -24,6 +24,7 @@ import com.l2jfrozen.gameserver.network.serverpackets.ActionFailed; import com.l2jfrozen.gameserver.network.serverpackets.StopMove; import com.l2jfrozen.gameserver.thread.TaskPriority; +import com.l2jfrozen.gameserver.thread.ThreadPoolManager; import com.l2jfrozen.gameserver.util.IllegalPlayerAction; import com.l2jfrozen.gameserver.util.Util; @@ -115,22 +116,49 @@ // Can't move if character is confused, or trying to move a huge distance if (activeChar.isOutOfControl() || dx * dx + dy * dy > 98010000) // 9900*9900 { activeChar.sendPacket(ActionFailed.STATIC_PACKET); return; } + + + if (activeChar.isInCombat()) + { + activeChar.setMoved(true); + ThreadPoolManager.getInstance().scheduleGeneral(new protection(activeChar), 2000);//2 sec + } + + activeChar.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new L2CharPosition(_targetX, _targetY, _targetZ, 0)); } } @Override public String getType() { return "[C] 01 MoveBackwardToLoc"; } + + class protection implements Runnable + { + L2PcInstance activeChar; + public protection(L2PcInstance player) + { + activeChar = player; + } + @Override + public void run() + { + activeChar.setMoved(false); + } + } + }
×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock