Jump to content
  • 0

[HELP] Custom killing spree system l2j server [/HELP]


Question

Posted

Hello, i got the source code for the custom killing spree system from Cobra which was for l2j free and i converted it for l2j server. The  only problem is the following: I configured it so that when someone had 30 pvp kills in a row, a "You are on a killing spree" message would show up on his screen and an announcement would be published on the global chat. Here is the thing. I inserted a code so that when you have 30 pvp kills in a row not only would a message appear but you'd also get hero status and on death this hero status would disappear but i failed. I compiled and i went ingame to test it ,everything worked fine except that when i was getting 30 pvp kills i could see the hero glow but others could not, they could only see it after a restart of their client. And also, when i was on death my hero glow would not disappear if i didnt restart my client. Here is the code in the file L2PcInstance:

+private int impro = 0;
    public void increasePvpKills()
    {
    	 + impro++;
    	            
    	           +switch(impro){
               
    	         
    	      +case 30:
    	        + ExShowScreenMessage case30 = new ExShowScreenMessage("You reached 30 killing spree!", 10000);
    	         +sendPacket(case30);
    	         +Announcements.getInstance().announceToAll("Player  " + getName() + " Is On a Killing Spree Someone Stop Him");
    	         +setHero(true);   	        
    	        + break;
    	             + default:
    	              + ;
    	           + }

 

 

// Check if the player is dead
        if (isDead())
        {
        	+impro = 0;
        	+setHero(false);
        	abortCast();

 

Anyone got an idead of how to fix this? Thanks!

4 answers to this question

Recommended Posts

  • 0
Posted

is this the code for sending the users data to the server? or is there anything else like sendPacket(setHero); ? i tried to build a new method that would connect with isHero but didnt work out

  • 0
Posted

broadcastUserInfo() send player informations both for player (CharInfo packet) and for his knownlist (broadcast UserInfo). Both problems you said can be linked to a miss of that method. In the end of setHero() method, just add that line :

broadcastUserInfo();

 

If it works I'm glad, if it doesn't, drop that line and search anywhere else. I got no other idea.

 

Btw the switch for one case isn't easy to read (I know you made it like that because Cobra code was using it), just use following if you got only one case :

if (impro == 30)
{
    	         sendPacket(new ExShowScreenMessage("You reached 30 killing spree!", 10000));
    	         Announcements.getInstance().announceToAll("Player  " + getName() + " Is On a Killing Spree Someone Stop Him");
    	         setHero(true);
}

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Posts

    • Download Lobby u need island for lobby Download Crow Island  
    • Website: https://l2elixir.org/ Discord: https://discord.gg/5ydPHvhbxs    
    • L2-LORENA x100 MID RATE   Interlude Nostalgia Meets Modern Gameplay   OFFICIAL OPENING:  April 4 (Saturday)  19:00 UTC+1 ⸻  MAIN INFORMATION  Adena: x5  Drop: x10  Spoil: x10  Raid Boss: x10  Seal Stones: x2  Quests: x10 ⸻  FEATURES  GM Shop up to B-Grade  Full Buffer  Premium System (x2 bonuses)  AutoFarm – FREE for everyone ⸻  SERVER CONCEPT  Classic Interlude nostalgia  Enhanced with modern interface & mechanics  Balanced PvP & PvE gameplay  Active development & custom features ⸻  WHY JOIN L2-LORENA?  No Pay-to-Win  Smooth gameplay & stable server  Competitive PvP environment  Friendly & active community ⸻  JOIN US NOW L2-LORENA 100X <<< LINK Discord: https://discord.gg/TYZ88Tgx4b  Facebook: https://www.facebook.com/share/18kwbkaYZY/?mibextid=wwXIfr   L2-LORENA Link << Discord: https://discord.gg/TYZ88Tgx4b  Facebook: https://www.facebook.com/share/18kwbkaYZY/?mibextid=wwXIfr
    • https://web.archive.org/web/20260306183214/https://maxcheaters.com/topic/241828-l2j-l2damage/page/3/ https://l2topzone.com/forum/l2-server-support-problems/9/l2damage-stopped/30514 Also we will try to push longer seasons ever ! (1135-100)/9 = 115 online
    • ONE SIDE – AND EVERYTHING BREAKS ▪ Looks like a simple case: Florida DL, back side, barcode – “clean and minimal”. ▪ In reality, these are exactly the tasks that fail most often. – data provided as plain text – request only for the back side – focus on the barcode (PDF417) ▪ And here’s the key point: ▪ A barcode is not just a “picture on the back”. It’s compressed logic of the entire document. ▪ If it doesn’t match the front, format, and data structure – the system flags it instantly. ▪ Many create a “similar-looking” code. But systems don’t read “similar” – they read by specification. ▪ In cases like this, it’s not about design. It’s about correct data assembly and how it behaves inside the format. ▪ Today only – 15% off for verification cases. ▪ Want it to pass, not just look right? Describe your case – we’ll show where even clean files break. › TG: @mustang_service ( https:// t.me/ mustang_service ) › Channel: Mustang Service ( https:// t.me/ +JPpJCETg-xM1NjNl ) #editing #photoshop #documents #verification #case
  • Topics

×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..