Jump to content
  • 0

Weird Bug About Killing Spree System On Emu Pack


Question

Posted

So i implemented this simple system on emu ,works but not properly ,and there is nothing wrong with implementation nor values becuz i have no problem with other adaptions like custom cb,java buffer from L2J etc...

 

case 4

 

case 7

 

case 10

 

case 15

 

 

but guess how it goes 

 

it goes like omg... at 4 kills it goes to case 7 instead 4 ,at around 9 [yep 5 not 3] kills i think it goes to case 15 instead of 10 and from case 15 it goes to 25 instead of 20....

 

Anyone have idea of this cause?

This is the weirdest bug i ever found and i cant seem to fix it ,it doesnt giveme any info or warning ,error or whatever, its just goes like that ,retarded... ,there is nothing wrong with L2PcInstance or character ,all are implemented properly on pack 

10 answers to this question

Recommended Posts

  • 0
Posted

Just post the patch added, jesus...

public void increasPvpKills(L2PcInstance targetPlayer)
	{
		quakeSystem++;
		
		switch (quakeSystem) {
		case 4:
			 ExShowScreenMessage case4 = new ExShowScreenMessage("You reached 4 kills in a row", 10000);
	   		 sendPacket(case4);
	   		final CreatureSay cs100 = new CreatureSay(0, SystemChatChannelId.Chat_Hero, getName(),  "is Geting Started [4]");
	      	 Broadcast.toAllOnlinePlayers(cs100);
	      		 MagicSkillUse MS4 = new MagicSkillUse (this, this, 721, 1, 5, 0);
	      		sendPacket(MS4);
			 break;
		case 7:
	   		 ExShowScreenMessage case7 = new ExShowScreenMessage("You reached 4 kills in a row", 10000);
	   		 sendPacket(case7);
	   		final CreatureSay cs101 = new CreatureSay(0, SystemChatChannelId.Chat_Hero, getName(),  "is Geting Started [4]");
	      	 Broadcast.toAllOnlinePlayers(cs101);
	      		 MagicSkillUse MS7 = new MagicSkillUse (this, this, 721, 1, 5, 0);
	      		sendPacket(MS7);
	      		 break;
   	case 10:
   		ExShowScreenMessage case10 = new ExShowScreenMessage("You reached 10 kills in a row", 10000);
   		sendPacket(case10);
   		final CreatureSay cs3 = new CreatureSay(0, SystemChatChannelId.Chat_Hero, getName(),  "is on a Rampage [10]");
   		Broadcast.toAllOnlinePlayers(cs3);
   		MagicSkillUse MS10 = new MagicSkillUse (this, this, 721, 1, 5, 0);
   		addItem("Loot", 5574, 10, this, true);
   		addItem("Loot", 5572, 20, this, true);
   		addItem("Loot", 5570, 15, this, true);
   		addItem("Loot", 6622, 1, this, true);
   		setCurrentCp(getMaxCp());
   	    setCurrentHp(getMaxHp());
   	    setCurrentMp(getMaxMp());
   	    sendPacket(MS10);
   		break;
   	case 15:
   		ExShowScreenMessage case15 = new ExShowScreenMessage("You reached 15 kills in a row", 10000);
   		sendPacket(case15);
   		final CreatureSay cs4 = new CreatureSay(0, SystemChatChannelId.Chat_Hero, getName(),  "is on a Killing Spree [15]");
   		Broadcast.toAllOnlinePlayers(cs4);
   		MagicSkillUse MS15 = new MagicSkillUse (this, this, 721, 1, 5, 0);
   		addItem("Loot", 5574, 20, this, true);
   		addItem("Loot", 5572, 40, this, true);
   		addItem("Loot", 5570, 30, this, true);
   		addItem("Loot", 6622, 2, this, true);
   		setCurrentCp(getMaxCp());
   	    setCurrentHp(getMaxHp());
   	    setCurrentMp(getMaxMp());
   	    sendPacket(MS15);
   		break;
   	case 20:
   		ExShowScreenMessage case20 = new ExShowScreenMessage("You reached 20 kills in a row", 10000);
   		sendPacket(case20);
   		Announcements.getInstance().announceToAll("" + this.getName()+ " is on a Monster Kill!");
   		MagicSkillUse MS20 = new MagicSkillUse (this, this, 721, 1, 5, 0);
   		addItem("Loot", 5574, 30, this, true);
   		addItem("Loot", 5572, 50, this, true);
   		addItem("Loot", 5570, 40, this, true);
   		addItem("Loot", 3488, 1, this, true);
   		addItem("Loot", 6622, 4, this, true);
   		setCurrentCp(getMaxCp());
   	    setCurrentHp(getMaxHp());
   	    setCurrentMp(getMaxMp());
   	    sendPacket(MS20);
   		break;
   	case 25:
   		ExShowScreenMessage case25 = new ExShowScreenMessage("You reached 25 kills in a row", 10000);
   		sendPacket(case25);
   		Announcements.getInstance().announceToAll("" + this.getName()+ " is Unstoppable!");
   		MagicSkillUse MS25 = new MagicSkillUse (this, this, 721, 1, 5, 0);
   		addItem("Loot", 5574, 50, this, true);
   		addItem("Loot", 5572, 80, this, true);
   		addItem("Loot", 5570, 65, this, true);
   		addItem("Loot", 3488, 2, this, true);
   		addItem("Loot", 6622, 6, this, true);
   		setCurrentCp(getMaxCp());
   	    setCurrentHp(getMaxHp());
   	    setCurrentMp(getMaxMp());
   	    sendPacket(MS25);
   		break;
// Add karma to attacker and increase its PK counter
		setPvpKills(getPvpKills() + 1);
		quakeSystem++;
private int								_questNpcObject						= 0;

	/** Bitmask used to keep track of one-time/newbie quest rewards */
	private int								_newbie;
	private int quakeSystem = 0;
setPvpFlag(0); // Clear the pvp flag
		quakeSystem = 0;

this is the implementation, better? :) i didnt told this because u were suppose to know how quake system works ;p

 

PS: even if i remove text/magicskill and only rewards are working ,its remain the same...it skips cases

  • 0
Posted

Ofc we know how this code works but if u don't show what u did we can't guess what's wrong, lol.

Yep I don't see the problem there, is this the full switch?

  • 0
Posted (edited)

its the same untill 100

 

it ends something like



case 100:
   		ExShowScreenMessage case100 = new ExShowScreenMessage("You reached 100 kills in a row, you're fucking awesome!", 10000);
   		sendPacket(case100);
   		final CreatureSay cs15 = new CreatureSay(0, SystemChatChannelId.Chat_Hero, getName(),  "is on a SYSTEM OVERLOAD, SYS SY SYY SS LO D OADD LOO ADD! bffvrffbfr!!!!!!!! [100]");
   		Broadcast.toAllOnlinePlayers(cs15);
   		MagicSkillUse MS100 = new MagicSkillUse (this, this, 721, 1, 5, 0);
   		addItem("Loot", 5574, 2400, this, true);
   		addItem("Loot", 5572, 3600, this, true);
   		addItem("Loot", 5570, 3000, this, true);
   		addItem("Loot", 3488, 120, this, true);
   		addItem("Loot", 4355, 60, this, true);
   		addItem("Loot", 6622, 360, this, true);
   		addItem("Loot", 9627, 60, this, true);
   		setCurrentCp(getMaxCp());
   	    setCurrentHp(getMaxHp());
   	    setCurrentMp(getMaxMp());
   	    sendPacket(MS100);
   	    break;
   		 default:
   			 ;
   }  
		if (isInFunEvent())
			return;

		if (!Config.ALT_PVP_POINTS_SAMEIP && getClient() != null && targetPlayer.getClient() != null && getClient().getHostAddress().equals(targetPlayer.getClient().getHostAddress()))
			return;
		
		if (!Config.ALT_PVP_POINTS_SAMEHWID && getClient() != null && targetPlayer.getClient() != null && getClient().getHWID() != null && getClient().getHWID().equals(targetPlayer.getClient().getHWID()))
			return;
		
		// Add karma to attacker and increase its PK counter
		setPvpKills(getPvpKills() + 1);
		quakeSystem++;
		// Send a Server->Client UserInfo packet to attacker with its Karma and PK Counter
		sendPacket(new UserInfo(this));
	}

Its implemented properly and pack works also just fine ,i tested my self most of bugs ,works much better than l2j yet this simple quake system wont work xD

Edited by Karasu
  • 0
Posted (edited)

I see this quakeSystem++; 2 times.

 

its 2 times as it was suppose to be i guess, 1 at switch and 1 for increase pvp kills......

 

but il remove it from pvp and test it again

Edited by Karasu
  • 0
Posted

i tested my self most of bugs ,works much better than l2j yet this simple quake system wont work xD

Who cares O.o

 

//ontopic

Do what devlin said and remove this, useless.

 

default:
   			 ;
  • 0
Posted

yes works now LOL!

 

cant believe i only had to do this ,i never thinked about this becuz it was the same implementation on l2j yet it was working properly! PS: Credits or Beer ,take your pick xD

  • 0
Posted (edited)

If you have in l2jserver the variable being increased 2 times, it won't work properly. It's not about the pack, lol.

Locked.

Edited by ^Wyatt
Guest
This topic is now closed to further replies.
  • Posts

    • You should buy it then I’ll make a discount  
    • Hi everyone,   In 2014, I completely stepped away from developing L2 servers and doing L2J-related work. Since then, I’ve only opened this server about once a year and helped a few servers and individuals for free. I haven’t taken on any paid L2J work since then.   LINEAGE2.GOLD is a project that has reached about Season 6. The first season launched at the end of 2020 and was a fully rebuilt Gold-style server on the Classic client (protocol 110). It featured many custom systems and enhancements. After several seasons, I decided to abandon the Mobius-based project and move to Lucera, as my goal was to get as close as possible to Interlude PTS behavior while still staying on the L2J platform.   The current project was once again completely rebuilt, this time on the Essence client (protocol 306), and is based on Lucera. Because of that, acquiring a license from Deazer is required.   My Lucera extender includes, but is not limited to: Formulas.java Basic anti-bot detection, which proved quite effective, we caught most Adrenaline users using relatively simple server-side logic, logged them, and took staff action. Simple admin account lookup commands based on IP, HWID, and similar identifiers. In-game Captcha via https://lineage2.gold/code, protected by Cloudflare, including admin commands for blacklisting based on aggression levels and whitelisting. Additional admin tools such as Auto-Play status checks, Enchanted Hero Weapon live sync, force add/remove clans from castle sieges, item listeners for live item monitoring, and more. A fully rewritten Auto-Play system with support for ExAutoPlaySetting, while still using the Auto-Play UI wheel, featuring: Debuff Efficiency Party Leader Assist Respectful Hunting Healer AI Target Mode Range Mode Summoner buff support Dwarf mechanics Reworked EffectDispelEffects to restore buffs after Cancellation. Raid Bomb item support. Reworked CronZoneSwitcher. Prime Time Raid Respawn Service. Community Board features such as Top rankings and RB/Epic status. Custom systems for Noblesse, Subclasses, support-class rewards, and much more.   Depending on the deal, the project can include: The lineage2.gold domain The website built on the Laravel PHP framework The server’s Discord Client Interface source Server files and extender source The server database (excluding private data such as emails and passwords)   I’m primarily looking for a serious team to continue the project, as it would be a shame to see this work abandoned. This is not cheap. You can DM me with offers. If you’re wondering why I’m doing this: I’ve felt a clear lack of appreciation from the L2 community, and I’m not interested in doing charity work for people who don’t deserve it. I’m simply not someone who tolerates BS. Server Info: https://lineage2.gold/info Server for test: https://lineage2.gold/download Over 110 videos YouTube playlist: https://www.youtube.com/watch?v=HO7BZaxUv2U&list=PLD9WZ0Nj-zstZaYeWxAxTKbX7ia2M_DUu&index=113
  • 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..

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 Disabled AdBlock