it won't work,lol.check the way he created the method he calls.
baggos,there's no reason to make your life harder by doing all these(which doesn't work btw) stuff for something simple.
check below,for such a code you need just a simple check in the place that pvps are increased,nothing else.
### Eclipse Workspace Patch 1.0
#P gameserver
Index: java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java
===================================================================
--- java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (revision 42)
+++ java/net/sf/l2j/gameserver/model/actor/instance/L2PcInstance.java (working copy)
@@ -4811,6 +4811,18 @@
// Add karma to attacker and increase its PK counter
setPvpKills(getPvpKills() + 1);
+ if (getPvpKills() == 100)
+ {
+ if (!isMageClass())
+ {
+ addItem("PvP Reward", Config.REWARD_FIGHTER_ID, Config.REWARD_FIGHTER_COUNT, this, true);
+ sendMessage("You've been rewarded with a fighter tattoo");
+ }
+ else
+ {
+ addItem("PvP Reward", Config.REWARD_MAGE_ID, Config.REWARD_MAGE_COUNT, this, true);
+ sendMessage("You've been rewarded with a mage tatoo");
+ }
+ }
+
PvpPkColorSystem.getInstance().checkPvpColors(this);
// Send a Server->Client UserInfo packet to attacker with its Karma and PK Counter
Index: java/net/sf/l2j/Config.java
===================================================================
--- java/net/sf/l2j/Config.java (revision 41)
+++ java/net/sf/l2j/Config.java (working copy)
@@ -422,6 +422,11 @@
/** Buffs */
public static boolean STORE_SKILL_COOLTIME;
public static byte BUFFS_MAX_AMOUNT;
+
+ public static int REWARD_FIGHTER_ID;
+ public static int REWARD_FIGHTER_COUNT;
+ public static int REWARD_MAGE_ID;
+ public static int REWARD_MAGE_COUNT;
//--------------------------------------------------
// Server
@@ -1134,6 +1139,10 @@
BUFFS_MAX_AMOUNT = Byte.parseByte(players.getProperty("MaxBuffsAmount","20"));
STORE_SKILL_COOLTIME = Boolean.parseBoolean(players.getProperty("StoreSkillCooltime", "true"));
+ REWARD_FIGHTER_ID = Integer.parseInt(players.getProperty("RewardFighterID","1"));
+ REWARD_FIGHTER_COUNT = Integer.parseInt(players.getProperty("RewardFightCount","2"));
+ REWARD_MAGE_ID = Integer.parseInt(players.getProperty("RewardMageId","3"));
+ REWARD_MAGE_COUNT = Integer.parseInt(players.getProperty("RewardMageCount","4"));
}
catch (Exception e)
{
Index: config/players.properties
===================================================================
--- config/players.properties (revision 41)
+++ config/players.properties (working copy)
@@ -310,4 +310,10 @@
MaxBuffsAmount = 20
# Store buffs/debuffs on user logout?
-StoreSkillCooltime = True
\ No newline at end of file
+StoreSkillCooltime = True
+
+#Class Based pvp reward at 100 pvps
+RewardFighterID = 1
+RewardFighterCount = 2
+RewardMageID = 3
+RewardMageCount = 4
\ No newline at end of file