Jump to content
  • 0

About Flagged Heal


L2Reon
 Share

Question

4 answers to this question

Recommended Posts

  • 0

post here your requestMagicSkillUse.java from your clientPackets

Here the code my friend.but i want all type of heals. not only of soultakers.and from bishops.

/*
* 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 2, 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, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*
* http://www.gnu.org/copyleft/gpl.html
*/
package com.l2jfrozen.gameserver.network.clientpackets;

import java.util.logging.Logger;

import com.l2jfrozen.Config;
import com.l2jfrozen.gameserver.datatables.SkillTable;
import com.l2jfrozen.gameserver.model.L2Skill;
import com.l2jfrozen.gameserver.model.L2Skill.SkillType;
import com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance;
import com.l2jfrozen.gameserver.network.serverpackets.ActionFailed;

/**
* This class ...
*
* @version $Revision: 1.7.2.1.2.3 $ $Date: 2005/03/27 15:29:30 $
*/
public final class RequestMagicSkillUse extends L2GameClientPacket
{
private static Logger _log = Logger.getLogger(RequestMagicSkillUse.class.getName());

private int _magicId;
private boolean _ctrlPressed;
private boolean _shiftPressed;

@Override
protected void readImpl()
{
	_magicId      = readD();              // Identifier of the used skill
	_ctrlPressed  = readD() != 0;         // True if it's a ForceAttack : Ctrl pressed
	_shiftPressed = readC() != 0;         // True if Shift pressed
}

@Override
protected void runImpl()
{
	// Get the current L2PcInstance of the player
	L2PcInstance activeChar = getClient().getActiveChar();

	if (activeChar == null)
		return;

	// Get the level of the used skill
	int level = activeChar.getSkillLevel(_magicId);
	if (level <= 0)
	{
		activeChar.sendPacket(ActionFailed.STATIC_PACKET);
		return;
	}

	if(activeChar.isOutOfControl())
	{
		activeChar.sendPacket(ActionFailed.STATIC_PACKET);
		return;
	}

	// Get the L2Skill template corresponding to the skillID received from the client
	L2Skill skill = SkillTable.getInstance().getInfo(_magicId, level);

	// Check the validity of the skill
	if (skill != null)
	{

		// _log.fine(" [FINE] 	skill:"+skill.getName() + " level:"+skill.getLevel() + " passive:"+skill.isPassive());
		// _log.fine(" [FINE] 	range:"+skill.getCastRange()+" targettype:"+skill.getTargetType()+" optype:"+skill.getOperateType()+" power:"+skill.getPower());
		// _log.fine(" [FINE] 	reusedelay:"+skill.getReuseDelay()+" hittime:"+skill.getHitTime());
		// _log.fine(" [FINE] 	currentState:"+activeChar.getCurrentState());	//for debug

		// If Alternate rule Karma punishment is set to true, forbid skill Return to player with Karma
		if (skill.getSkillType() == SkillType.RECALL && !Config.ALT_GAME_KARMA_PLAYER_CAN_TELEPORT && activeChar.getKarma() > 0)
			return;

		// players mounted on pets cannot use any toggle skills
		if (skill.isToggle() && activeChar.isMounted())
			return;
		// activeChar.stopMove();

		//final L2Object target = activeChar.getTarget();
		//if(target!=null && target instanceof L2Character)
		//	activeChar.sendPacket(new ValidateLocation((L2Character)target));

		activeChar.useMagic(skill, _ctrlPressed, _shiftPressed);
	}
	else
	{
		activeChar.sendPacket(ActionFailed.STATIC_PACKET);
		_log.severe(" [ERROR] [WARNING]No skill found with id " + _magicId + " and level " + level + " !!");
	}
}

@Override
public String getType()
{
	return "[C] 2F RequestMagicSkillUse";
}
}

Link to comment
Share on other sites

  • 0

Post the issue on their forums, it will be useful for their community rather than you only getting the fix.

 

Any coder/higer rank locks the thread, it's not a "bug reports" section.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share



  • Posts

    • Dear friends, We promised you an Interlude server towards the end of the year, now we are here to deliver.  The entire L2mid team is proud to present you, a returning legend! L2Mid Interlude Dynamic Rates X25 A traditional Interlude server most fitting for the upcoming Christmas Season!   Grand Opening: 26th December 2021  Website: https://l2mid.com   Let’s send off this year in a fitting way, by playing on the top Interlude mid-rate server!  You can seat tight and expect in the near future, when we will announce more information about other upcoming projects with whom we will be collaborating.       Merry Christmas, and may all your Christmases be white!     May the true spirit of Christmas shine in your heart and light your path.         Dynamic Rates x25 is a classic game with simplified development and with maximum approximation to massive PVP battles. Сlassic, but simplistic gameplay maintains a constant competition in all its manifestations. Here you will not achieve everything in just one day and you will not quietly develop because your competitors will disturb you all time. Dynamic Rates Experience and Skill Points from Monsters: 1-61 Level - x25   Dynamic Rates Experience and Skill Points from Monsters: 61-76 LEVEL - X15   Dynamic Rates Experience and Skill Points from Monsters: 76-80 LEVEL - X5 ADENA x15   SEAL STONES x10   DROP x15   SPOIL x15   MANOR x1   Raid Boss Experience, Skill Points and Drop x7   Epic Boss Experience, Skill Points and Drop x1   Quest Item Drop x3   Quest Item Reward x2   Daily Quest Every 24 hours
    • Moved to request help board.
    • Hello, @DumanisT regarding the rules your topic must include prices.
    • UPDATER / LAUNCHER code update: - fixed assert error when Game was running in the background / files were in use. PATCH BUILDER code update: - added auto-save path for input / output folders.
  • Topics

×
×
  • 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 Disbaled AdBlock