Mafia is indicating -100 ML right now, and with 5 bladders, extra_ml is equal to 0. It is 28 with -72 ML. Why would you need to add 200 ML?so that the script takes negative amounts of ML into account
Mafia is indicating -100 ML right now, and with 5 bladders, extra_ml is equal to 0. It is 28 with -72 ML. Why would you need to add 200 ML?so that the script takes negative amounts of ML into account
Does this happen with the non relay version of the script?
Mafia is indicating -100 ML right now, and with 5 bladders, extra_ml is equal to 0. It is 28 with -72 ML. Why would you need to add 200 ML?
Ah right, I didn't see the case where the total ML is negative.-55%100 is -55, not 45.
boolean semirare = ( get_counters("Fortune Cookie",0,0) != "" ) ;
if( slime_damage() >= my_maxhp() || ( semirare && have_effect( $effect[Coated in Slime]) > 0 && slime_damage( (have_effect( $effect[Coated in Slime])-1) ) < my_maxhp() ) )
if ( turns < 1 ) return 0;
adventure( 1 , $location[The Slime Tube] );
boolean combat = !( get_property("lastEncounter").contains_text("Engulfed") || get_property("lastEncounter").contains_text("Showdown") ) ;
Entering function print
<font color="blue">Adventure 7 out of 10</font>
Function print returned: void
[NORMAL] <- void
[NORMAL] <- true
Eval: visit_url()
Param #1: to_url()
Param #1: "The Slime Tube"
[NORMAL] <- "The Slime Tube"
Entering function to_url
Function to_url returned: adventure.php?snarfblat=203
[NORMAL] <- "adventure.php?snarfblat=203"
Entering function visit_url
class net.sourceforge.kolmafia.request.RelayRequest
Connecting to adventure.php...
Requesting: http://www2.kingdomofloathing.com/adventure.php?snarfblat=203
4 request properties
Field: Cookie = [PHPSESSID=9q7p5dvrf1kpno07gk1or5uob4]
Field: Content-Length = [13]
Field: User-Agent = [KoLmafia v14.1]
Field: Content-Type = [application/x-www-form-urlencoded]
Retrieving server reply...
Retrieved: http://www2.kingdomofloathing.com/adventure.php?snarfblat=203
11 header fields
Field: null = [HTTP/1.1 302 Found]
Field: Date = [Wed, 21 Jul 2010 05:04:16 GMT]
Field: Content-Length = [0]
Field: Expires = [Thu, 19 Nov 1981 08:52:00 GMT]
Field: Location = [fight.php?ireallymeanit=1279688656]
Field: Connection = [close]
Field: Content-Type = [text/html; charset=UTF-8]
Field: Server = [Apache/2.2.3 (CentOS)]
Field: X-Powered-By = [PHP/5.1.6]
Field: Cache-Control = [no-store, no-cache, must-revalidate, post-check=0, pre-check=0]
Field: Pragma = [no-cache]
Function visit_url returned:
Set:
[NORMAL] <- ""
if
Test: contains_text()
Param #1: page_text
[NORMAL] <- ""
Param #2: "Combat"
[NORMAL] <- "Combat"
Entering function contains_text
Function contains_text returned: false
[NORMAL] <- false
else
Eval: false
Set: false
[NORMAL] <- false
[NORMAL] <- true
Eval: run_adv()
Param #1: page_text
[NORMAL] <- ""
Entering function run_adv
if
Test: ( page_text == "" )
Operator: ==
Operand 1: page_text
[NORMAL] <- ""
Operand 2:
[NORMAL] <- ""
<- true
[NORMAL] <- true
Param #1: "Fight.php returned a blank response!"
[NORMAL] <- "Fight.php returned a blank response!"
Entering function abort
Fight.php returned a blank response!
Function abort returned: void
[EXIT] <- void
[EXIT] <- void
Function run_adv returned:
Set:
[EXIT] <- void
[EXIT] <- void
[EXIT] <- void
Function run_tube returned: void
[EXIT] <- void
[EXIT] <- void
[6671] The Slime Tube
> debug off
adventure( 1 , $location[The Slime Tube] );
adv_to_use = adv_to_use - 1;
if ( adventure( 1 , $location[The Slime Tube] ) )
adv_to_use = adv_to_use - 1;
Regarding my fix to not get killed when getting semirares, adv1() should be used instead of adventure(), so the fix would be:
- To make sure the counterScript will trigger before adventuring to reslime, use this instead of visit_url(to_url($location[The Slime Tube])):
PHP:adventure( 1 , $location[The Slime Tube] ); boolean combat = !( get_property("lastEncounter").contains_text("Engulfed") || get_property("lastEncounter").contains_text("Showdown") ) ;
adv1($location[slime tube], -1, "");
boolean combat = !( get_property("lastEncounter").contains_text("Engulfed") || get_property("lastEncounter").contains_text("Showdown") ) ;
Maybe adventure() should be captured in some way so that the error doesn't stop the script (assuming it doesn't happen on every adventure of course). Try replacing
at the end byPHP:adventure( 1 , $location[The Slime Tube] ); adv_to_use = adv_to_use - 1;
PHP:if ( adventure( 1 , $location[The Slime Tube] ) ) adv_to_use = adv_to_use - 1;
page_text = visit_url( to_url( $location[The Slime Tube] ) );
I'm not really sure what a HTTP redirect means... I'm guessing it means that it's not Mafia's fault?
I'm not really sure what a HTTP redirect means... I'm guessing it means that it's not Mafia's fault?
Or the script should use adv1() instead of run_adv(),
I haven't seen a good workaround.
page_text = visit_url( to_url( $location[The Slime Tube] ) );
if( page_text.contains_text( "Combat" ) ) combat = true;
else combat = false;
page_text = run_adv( page_text );
adv1($location[slime tube], -1, "");
boolean combat = !( get_property("lastEncounter").contains_text("Engulfed") || get_property("lastEncounter").contains_text("Showdown") ) ;
set_property("choiceAdventure326","0");