Index: java/net/sf/l2j/gameserver/clientpackets/RequestSocialAction.java =================================================================== --- java/net/sf/l2j/gameserver/clientpackets/RequestSocialAction.java (revision 1240) +++ java/net/sf/l2j/gameserver/clientpackets/RequestSocialAction.java (working copy) @@ -21,6 +21,7 @@ import java.util.logging.Logger; import net.sf.l2j.Config; +import net.sf.l2j.gameserver.ThreadPoolManager; import net.sf.l2j.gameserver.ai.CtrlIntention; import net.sf.l2j.gameserver.model.actor.instance.L2PcInstance; import net.sf.l2j.gameserver.network.SystemMessageId; @@ -71,7 +72,7 @@ return; } - if ( activeChar.getPrivateStoreType()==0 && + if ( activeChar.getPrivateStoreType()==0 && !activeChar.getIsSocial()&& activeChar.getActiveRequester()==null && !activeChar.isAlikeDead() && (!activeChar.isAllSkillsDisabled() || activeChar.isInDuel()) && @@ -80,11 +81,26 @@ if (Config.DEBUG) _log.fine("Social Action:" + _actionId); SocialAction atk = new SocialAction(activeChar.getObjectId(), _actionId); - activeChar.broadcastPacket(atk); + // Schedule a social task to wait for the animation to finish + ThreadPoolManager.getInstance().scheduleGeneral(new SocialTask(this), 2600); + activeChar.setIsParalyzed(true); + activeChar.setIsSocial(true); } } - + class SocialTask implements Runnable + { + L2PcInstance _player; + SocialTask(RequestSocialAction action) + { + _player = getClient().getActiveChar(); + } + public void run() + { + _player.setIsSocial(false); + _player.setIsParalyzed(false); + } + } /* (non-Javadoc) * @see net.sf.l2j.gameserver.clientpackets.ClientBasePacket#getType() */ Index: java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java =================================================================== --- java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (revision 1273) +++ java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (working copy) @@ -657,6 +657,7 @@ _reference = reference; _sendMessage = sendMessage; } + @SuppressWarnings("synthetic-access") public void run() { try @@ -10034,6 +10073,7 @@ } private FastMap ReuseTimeStamps = new FastMap().setShared(true); + private boolean _isSocial = false; /** * Simple class containing all neccessary information to maintain @@ -10138,4 +10178,19 @@ { _forceBuff = fb; } + /** + * Set _isSocial to given value + */ + public void setIsSocial(boolean state) + { + _isSocial = state; + } + + /** + * @return _isSocial + */ + public boolean getIsSocial() + { + return _isSocial; + } }