Jump to content

[Share] agorase Skill me ta PvP soy


pirama

Recommended Posts

ayto edw to npc einai ena npc opoy poylaei skill kai perni ta PvP soy

einai ftiagmeno gia aCis pack logo ton skill

 

shot00000r.jpg

 

shot00001op.jpg

 

Download

 

create on  net.sf.l2j.gameserver.model.actor.instance       L2PVPSkillManagerInstance.java
=====================================================================================

package net.sf.l2j.gameserver.model.actor.instance;

import net.sf.l2j.gameserver.datatables.SkillTable;
import net.sf.l2j.gameserver.network.serverpackets.NpcHtmlMessage;
import net.sf.l2j.gameserver.templates.chars.L2NpcTemplate;

public class L2PVPSkillManagerInstance extends L2NpcInstance
{
public L2PVPSkillManagerInstance(int objectId, L2NpcTemplate template)
{
	super(objectId, template);
}

@Override
public void onBypassFeedback(L2PcInstance player, String command)
{
	int skillId1 = 7100; // Focus Passive Custom skill
	int skillId1Level = 6; // lvl 6
	int skillId1PvpCount = 200; // perni 200 PvP
	int skillId2 = 7101; // Haste Passive Custom Skill
	int skillId2Level = 6; // lvl 6
	int skillId2PvpCount = 200; // perni 200 pvp
	int skillId3 = 7102; // Acume Passive Custom Skill
	int skillId3Level = 3; // lvl 3
	int skillId3PvpCount = 200; // perni 200 PvP
	int skillId4 = 7103; // Max Cp,Hp,Mp Passive Custom skill
	int skillId4Level = 3; // lvl 3
	int skillId4PvpCount = 200; // perni 200 PvP
	int skillId5 = 7104; // Wild Magic
	int skillId5Level = 3; // lvl 3
	int skillId5PvpCount = 200; // perni 200 PvP
	final String[] subCommand = command.split("_");

	if (player == null )  return;

	if (player.getPvpKills() == 0)
	{
		player.sendMessage("You cannot use this npc without PvP.");
		return;
	}

	if (command.startsWith("skill1"))
	{
		if (player.getPvpKills() >= skillId1PvpCount)
		{
			player.setPvpKills(player.getPvpKills() - skillId1PvpCount);
			player.addSkill(SkillTable.getInstance().getInfo(skillId1, skillId1Level), true);
			player.broadcastUserInfo();
		}
		else
			player.sendMessage("Not enough PvPs.");
	}
	else if (command.startsWith("skill2"))
	{
		if (player.getPvpKills() >= skillId2PvpCount)
		{
			player.setPvpKills(player.getPvpKills() - skillId2PvpCount);
			player.addSkill(SkillTable.getInstance().getInfo(skillId2, skillId2Level), true);
			player.broadcastUserInfo();
		}
		else
			player.sendMessage("Not enough PvPs.");
	}
	else if (command.startsWith("skill3"))
	{
		if (player.getPvpKills() >= skillId3PvpCount)
		{
			player.setPvpKills(player.getPvpKills() - skillId3PvpCount);
			player.addSkill(SkillTable.getInstance().getInfo(skillId3, skillId3Level), true);
			player.broadcastUserInfo();
		}
		else
			player.sendMessage("Not enough PvPs.");
	}
	else if (command.startsWith("skill4"))
	{
		if (player.getPvpKills() >= skillId4PvpCount)
		{
			player.setPvpKills(player.getPvpKills() - skillId4PvpCount);
			player.addSkill(SkillTable.getInstance().getInfo(skillId4, skillId4Level), true);
			player.broadcastUserInfo();
		}
		else
			player.sendMessage("Not enough PvPs.");
	}
	else if (command.startsWith("skill5"))
	{
		if (player.getPvpKills() >= skillId5PvpCount)
		{
			player.setPvpKills(player.getPvpKills() - skillId5PvpCount);
			player.addSkill(SkillTable.getInstance().getInfo(skillId5, skillId5Level), true);
			player.broadcastUserInfo();
		}
		else
			player.sendMessage("Not enough PvPs.");
	}

	else if(command.startsWith("Chat"))
	{
		if(subCommand[1].isEmpty() || subCommand[1] == null) return;
		NpcHtmlMessage html = new NpcHtmlMessage(getObjectId());
		html.setFile("data/html/default/"+subCommand[1]);
		html.replace("%objectId%", String.valueOf(getObjectId()));
		player.sendPacket(html);
	}
}
}

create html    on data/html/default               101.htm
===============================================================================

<html>
<head>
	<title>PvP Shop Manager</title>
</head>
<body>
<tr>
<center><img src="L2UI_CH3.inventory_outline_over" width=0.1 height=20></center>
</tr>
<center><img src="sek.gui001" width=258 height=64.2></center>
<br>
<center><font color="LEVEL">Hello strainger </font></center>
<tr>
<br>
<center><img src="L2UI_CH3.inventory_outline_over" width=100 height=3></center>
</tr>
<br>
<br>
<tr><td></td></tr>
<center><button value="Skill List" action="bypass -h npc_%objectId%_Chat_104-1.htm" width=88 height=15 back="l2ui.SystemWindowButton" fore="l2ui.SystemWindowButton_click"></td>
<tr><td></td></tr>
<br>
<br>
<tr>
<center><img src="L2UI_CH3.inventory_outline_over" width=100 height=3></center>
</tr>
<tr>
<center><img src="L2UI_CH3.inventory_outline_over" width=0.1 height=10></center>
</tr>
<center><font color="fcd209">Lineage II Pirama</font></center>
<br>
<center><img src="sek.ui03" width=210 height=50></center>
<center><font color="fcd209"></font></center>
</body>
</html>

create html     101-1.htm
===============================================================================

<html><title>PvP Shop Manager</title>
<body>
<br>
<br>
<center><font color="LEVEL">You Need 200 PvP For 1 Passive Skill</font></center><br><br>
<tr><td></td></tr>
<tr>
<center><img src="L2UI_CH3.inventory_outline_over" width=100 height=3></center>
</tr>
<br>
<center><button value="Focus" action="bypass -h npc_%objectId%_skill1" width=88 height=15 back="l2ui.SystemWindowButton" fore="l2ui.SystemWindowButton_click"></td>
<tr><td></td></tr>
<br>
<tr><td></td></tr>
<center><button value="Haste" action="bypass -h npc_%objectId%_skill2" width=88 height=15 back="l2ui.SystemWindowButton" fore="l2ui.SystemWindowButton_click"></td>
<tr><td></td></tr>
<br>
<tr><td></td></tr>
<center><button value="Acumen" action="bypass -h npc_%objectId%_skill3" width=88 height=15 back="l2ui.SystemWindowButton" fore="l2ui.SystemWindowButton_click"></td>
<tr><td></td></tr>
<br>
<tr><td></td></tr>
<center><button value="Wild Magic" action="bypass -h npc_%objectId%_skill5" width=88 height=15 back="l2ui.SystemWindowButton" fore="l2ui.SystemWindowButton_click"></td>
<tr><td></td></tr>
<br>
<tr><td></td></tr>
<center><button value="Cp/Hp/Mp" action="bypass -h npc_%objectId%_skill4" width=88 height=15 back="l2ui.SystemWindowButton" fore="l2ui.SystemWindowButton_click"></td>
<tr><td></td></tr>
<tr>
<br>
<center><img src="L2UI_CH3.inventory_outline_over" width=100 height=3></center>
</tr>
<br>
<br>
<br>
<tr><td></td></tr>
<center><button value="Return" action="bypass -h npc_%objectId%_Chat _104.htm" width=88 height=15 back="l2ui.SystemWindowButton" fore="l2ui.SystemWindowButton_click"></td>
<tr><td></td></tr>
</body></html>

create sql file
=========================================================================

INSERT INTO `npc` VALUES ('101','31324','Trader','1','Skill Trade','1','NPC.a_casino_FDarkElf','8.00','23.00','70','female','L2PVPSkillManager','40','3862','1493','11.85','2.78','40','43','30','21','20','10','0','0','1314','470','780','382','278','333','0','0','55','132','0','7','0');

ayta edw ta bazete sto system sto arxio    skillgpr
=========================================================================

7100	1	2	0	-1	0	0.00000000	0			icon.skill1077	0	0	0	0	-1	-1
7100	2	2	0	-1	0	0.00000000	0			icon.skill1077	0	0	0	0	-1	-1
7100	3	2	0	-1	0	0.00000000	0			icon.skill1077	0	0	0	0	-1	-1
7100	4	2	0	-1	0	0.00000000	0			icon.skill1077	0	0	0	0	-1	-1
7100	5	2	0	-1	0	0.00000000	0			icon.skill1077	0	0	0	0	-1	-1
7100	6	2	0	-1	0	0.00000000	0			icon.skill1077	0	0	0	0	-1	-1
7101	6	2	0	-1	0	0.00000000	0			icon.skill1086	0	0	0	0	-1	-1
7101	1	2	0	-1	0	0.00000000	0			icon.skill1086	0	0	0	0	-1	-1
7101	2	2	0	-1	0	0.00000000	0			icon.skill1086	0	0	0	0	-1	-1
7101	3	2	0	-1	0	0.00000000	0			icon.skill1086	0	0	0	0	-1	-1
7101	4	2	0	-1	0	0.00000000	0			icon.skill1086	0	0	0	0	-1	-1
7101	5	2	0	-1	0	0.00000000	0			icon.skill1086	0	0	0	0	-1	-1
7101	6	2	0	-1	0	0.00000000	0			icon.skill1086	0	0	0	0	-1	-1
7102	1	2	0	-1	0	0.00000000	0			icon.skill1085	0	0	0	0	-1	-1
7102	2	2	0	-1	0	0.00000000	0			icon.skill1085	0	0	0	0	-1	-1
7102	3	2	0	-1	0	0.00000000	0			icon.skill1085	0	0	0	0	-1	-1
7103	1	2	0	-1	0	2.50000000	0			icon.skill1363	0	0	0	0	-1	-1
7103	2	2	0	-1	0	2.50000000	0			icon.skill1363	0	0	0	0	-1	-1
7103	3	2	0	-1	0	2.50000000	0			icon.skill1363	0	0	0	0	-1	-1
7104	1	2	0	-1	0	4.00000000	0			icon.skill1303	0	0	0	0	-1	-1
7104	2	2	0	-1	0	4.00000000	0			icon.skill1303	0	0	0	0	-1	-1
7104	3	2	0	-1	0	4.00000000	0			icon.skill1303	0	0	0	0	-1	-1


ayta edw ta bazete sto system sto arxio  skillname-e
==========================================================================
7100	1	a,Focus\0	a,Effect 6.\0	a,none\0	a,none\0
7100	2	a,Focus\0	a,Effect 6.\0	a,none\0	a,none\0
7100	3	a,Focus\0	a,Effect 6.\0	a,none\0	a,none\0
7100	4	a,Focus\0	a,Effect 6.\0	a,none\0	a,none\0
7100	5	a,Focus\0	a,Effect 6.\0	a,none\0	a,none\0
7100	6	a,Focus\0	a,Effect 6.\0	a,none\0	a,none\0
7101	1	a,Haste\0	a,Effect 6.\0	a,none\0	a,none\0
7101	2	a,Haste\0	a,Effect 6.\0	a,none\0	a,none\0
7101	3	a,Haste\0	a,Effect 6.\0	a,none\0	a,none\0
7101	4	a,Haste\0	a,Effect 6.\0	a,none\0	a,none\0
7101	5	a,Haste\0	a,Effect 6.\0	a,none\0	a,none\0
7101	6	a,Haste\0	a,Effect 6.\0	a,none\0	a,none\0
7102	1	a,Acumen\0	a,Effect 3.\0	a,none\0	a,none\0
7102	2	a,Acumen\0	a,Effect 3.\0	a,none\0	a,none\0
7102	3	a,Acumen\0	a,Effect 3.\0	a,none\0	a,none\0
7103	1	a,Max/Cp/Hp/Mp\0	a,Effect 3.\0	a,none\0	a,none\0
7103	2	a,Max/Cp/Hp/Mp\0	a,Effect 3.\0	a,none\0	a,none\0
7103	3	a,Max/Cp/Hp/Mp\0	a,Effect 3.\0	a,none\0	a,none\0
7104	1	a,Wild Magic\0	a,Effect 3.\0	a,none\0	a,none\0
7104	2	a,Wild Magic\0	a,Effect 3.\0	a,none\0	a,none\0
7104	3	a,Wild Magic\0	a,Effect 3.\0	a,none\0	a,none\0


Server\gameserver\data\xml\skills           7100-7110.xml
===========================================================================

<?xml version='1.0' encoding='utf-8'?>
<list>
<skill id="7100" levels="6" name="Focus">
	<table name="#rCrit"> 86.7 82.2 77.8 73.3 68.9 64.5 </table>
	<table name="#magicLvl"> 46 49 52 55 58 61 </table>
	<set name="target" val="TARGET_SELF" />
	<set name="skillType" val="BUFF" />
	<set name="operateType" val="OP_PASSIVE" />
	<set name="magicLvl" val="#magicLvl" />
	<for>
		<add order="0x40" stat="rCrit" val="#rCrit" />
	</for>
</skill>
<skill id="7101" levels="6" name="Haste">
	<table name="#pAtkSpd"> 1.08 1.07 1.07 1.07 1.06 1.06 </table>
	<table name="#magicLvl"> 46 49 52 55 58 61 </table>
	<set name="target" val="TARGET_SELF" />
	<set name="skillType" val="BUFF" />
	<set name="operateType" val="OP_PASSIVE" />
	<set name="magicLvl" val="#magicLvl" />
	<for>
		<mul order="0x30" stat="pAtkSpd" val="#pAtkSpd" />
	</for>
</skill>
<skill id="7102" levels="3" name="Acumen">
	<table name="#pvpBonus"> 1 1.05 1.05 </table>
	<table name="#magicLvl"> 64 64 70 </table>
	<set name="target" val="TARGET_SELF" />
	<set name="skillType" val="BUFF" />
	<set name="operateType" val="OP_PASSIVE" />
	<set name="magicLvl" val="#magicLvl" />
	<for>
		<mul order="0x30" stat="mAtkSpd" val="1.15" />
		<mul order="0x30" stat="pvpPhysDmg" val="#pvpBonus" />
		<mul order="0x30" stat="pvpPhysSkillsDmg" val="#pvpBonus" />
		<mul order="0x30" stat="pvpMagicalDmg" val="#pvpBonus" />
	</for>
</skill>
<skill id="7103" levels="3" name="Max/Cp/Hp/Mp">
	<table name="#pvpBonus"> 1 1.05 1.05 </table>
	<table name="#magicLvl"> 64 64 70 </table>
	<set name="target" val="TARGET_SELF" />
	<set name="skillType" val="BUFF" />
	<set name="operateType" val="OP_PASSIVE" />
	<set name="magicLvl" val="#magicLvl" />
	<for>
		<mul order="0x30" stat="maxMp" val="1.3" />
		<mul order="0x30" stat="maxHp" val="1.3" />
		<mul order="0x30" stat="maxCp" val="1.3" />
		<mul order="0x30" stat="pvpPhysDmg" val="#pvpBonus" />
		<mul order="0x30" stat="pvpPhysSkillsDmg" val="#pvpBonus" />
		<mul order="0x30" stat="pvpMagicalDmg" val="#pvpBonus" />
	</for>
</skill>
<skill id="7104" levels="3" name="Wild Magic">
	<table name="#pvpBonus"> 1 1.05 1.05 </table>
	<table name="#magicLvl"> 64 64 70 </table>
	<set name="target" val="TARGET_SELF" />
	<set name="skillType" val="BUFF" />
	<set name="operateType" val="OP_PASSIVE" />
	<set name="magicLvl" val="#magicLvl" />
	<for>
		<mul order="0x30" stat="mCritRate" val="2" />
		<mul order="0x30" stat="pvpPhysDmg" val="#pvpBonus" />
		<mul order="0x30" stat="pvpPhysSkillsDmg" val="#pvpBonus" />
		<mul order="0x30" stat="pvpMagicalDmg" val="#pvpBonus" />
	</for>
</skill>
</list>

 

Credits: valanths1990  ( gia ton code )

Credits: Me ( gia ta ypolipa :P )

 

 

Link to comment
Share on other sites

θα μπορούσες να κάνεις .patch..έτσι είναι πολυ ακατάστατο..

 

thanks anyway

nai tha mporoysa ( an iksera :P ) an kataferw na mathw tha kanw update :)

(kapios na to delete an to di ekana katalathos diplo post )

Link to comment
Share on other sites

poly kali doulia palikaria mpravo sas epitelous vlepoune ta matia mou kt new : )

se eyxaristoyme :)

θα μπορούσες να κάνεις .patch..έτσι είναι πολυ ακατάστατο..

 

thanks anyway

nai tha mporoysa ( an iksera :P ) an kataferw na mathw tha kanw update :)

Link to comment
Share on other sites

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...