Bug - Not A Bug FightRequest assuming winning fights?

Darzil

Developer
I was planning to just remove Abyssal Battle Plans once General Seal was defeated. FightRequest.php looked the best place. However, running away (before I added the check for winning) decremented my Abyssal Battle Plans, showing that fight was only over, rather than won.

That's fine for Baron von Ratsworth location marking, but questionable for blackPuddingsDefeated, lastWuTangDefeated and triggering WumpusManager.reset.

Am I missing something or should all these check for a win ?

from FightRequest.php
Code:
			if ( monster.equalsIgnoreCase( "Black Pudding" ) )
			{
				Preferences.increment( "blackPuddingsDefeated", 1 );
			}
			else if ( monster.equalsIgnoreCase( "Wu Tang the Betrayer" ) )
			{
				Preferences.setInteger( "lastWuTangDefeated", KoLCharacter.getAscensions() );
			}
			else if ( monster.equalsIgnoreCase( "Baron Von Ratsworth" ) )
			{
				TavernRequest.addTavernLocation( '6' );
			}
			else if ( monster.equalsIgnoreCase( "Wumpus" ) )
			{
				WumpusManager.reset();
			}
			else if ( monster.equalsIgnoreCase( "general seal" ) )
			{
				if ( responseText.contains( "won some kind of medal" ) )
				{
					ResultProcessor.removeItem( ItemPool.ABYSSAL_BATTLE_PLANS );
				}
			}
			else if ( monster.equalsIgnoreCase( "drunk pygmy" ) )
			{
				if ( responseText.contains( "notices the Bowl of Scorpions" ) )
				{
					ResultProcessor.removeItem( ItemPool.BOWL_OF_SCORPIONS );
				}
			}
 
Last edited:
Code:
boolean won = responseText.indexOf( "<!--WINWINWIN-->" ) != -1;
And all of that block is inside of
Code:
if ( won )
It looks like the issue you saw is that the battle plans were removed as soon as they were used, because they are marked usable instead of reusable in items.txt.
 
Back
Top