Jump to content

[SHARE] Delvl When PK


Recommended Posts

oh, no flame please its my first share i am new to Java ^^

 

 

 

ok, open l2pcinstance and Import

import net.sf.l2j.gameserver.Announcements;

 

Than now find those lines and add the code

 

// Add karma to attacker and increase its PK counter

setPkKills(getPkKills() + 1);

setKarma(getKarma() + newKarma);

 

ok now add the code :

 

     

       // Delvl Player When they PK Another Player

       getStat().removeExpAndSp((getExp() - Experience.LEVEL[getStat().getLevel() - 1]), 0);

broadcastKarma();

Announcements.getInstance().announceToAll("" + this.getName()+ " Has been Delvld for PKing!");

sendMessage("You Have Been Delvld for Wrong Actions! You are now level " +getLevel()+ " !");

 

IF someone Pk's now a player he gets Delevled by one level, 78 to 77 to 76 and and and

Might be interesting for a Server Where pk is not allowed like a RPG server whatever

 

Script work on all Chronicles just adapt it for your version/Project

 

IMG : http://img580.imageshack.us/i/shot00026x.jpg/

 

Credits: Me

 

 

Link to comment
Share on other sites

Well i think first of all it should have a config.And secondly i would find it extremly usefull if it was related with zones for example if the pk was on farm areas he would be deleveled....

Link to comment
Share on other sites

Well i think first of all it should have a config.And secondly i would find it extremly usefull if it was related with zones for example if the pk was on farm areas he would be deleveled....

 

just add like :

 

 

+ if (isInsideZone(ZONE_Farm))

+ {

+            getStat().removeExpAndSp((getExp() - Experience.LEVEL[getStat().getLevel() - 1]), 0);

+    broadcastKarma();

+    Announcements.getInstance().announceToAll("" + this.getName()+ " Has been Delvld for PKing!");

+    sendMessage("You Have Been Delvld for Wrong Actions! You are now level " +getLevel()+ " !");

+ }

+

than make your Farm zone and done, it should work than

edit: Correct me if i am wrong havent tested it

Link to comment
Share on other sites

the idea isn't bad ;D But you could make something like this :

getInventory().destroyItemByItemId("Adena", 57, 100000000, player, null);

and delete the announce ;)

thanks and heh been thinking about the same whit deleting items.

i'm myself bored and annoyed by those Pkers in lvling/farm zones :D

Link to comment
Share on other sites

  • 2 years later...

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