New Content - Implemented Guzzlr tablet - May Item of the month

taltamir

Member
thank you for all the fixes. it is a lot smmother now.

with mafia r20143 when ascending with an incomplete guzzlr quest the following trackers are not reset to null:guzzlrQuestTier
guzzlrQuestLocation
guzzlrQuestBooze


Not too big a deal since
questGuzzlr
is correctly reset to unstarted so it can be used to ignore those trackers.

Even though it looks promising so far, I'd really need people to help me get data for 6 and 8 before going forward, because of how much of a wrench they throw in the whole logic.
If we can get a mafia tracker for number of fights done in a guzzlr zone (gotta take into account free fights). then I could add automatic spading for this to my guzzlr script.

... or I could just make my own tracker for now so we could get the data needed to construct a mafia tracker. I will try to get on it soon but at the moment i am doing a project on autoscend so it might be a few days
 
Last edited:

taltamir

Member
Had something weird happen.
The code
Code:
visit_url("inventory.php?tap=guzzlr", false);
run_choice(1);    //abandon quest
run_choice(5);    //exit menu


inexplicably produced
Code:
Encounter: Guzzlr Client Selection
Preference guzzlrQuestBooze changed from Guzzlr cocktail set to special personalized cocktail
Took choice 1412/1: Abandon Client
choice.php?whichchoice=1412&option=1&pwd
Encounter: Guzzlr Client Selection
Preference _guzzlrQuestAbandoned changed from false to true
Preference guzzlrQuestBooze changed from special personalized cocktail to 
Preference guzzlrQuestLocation changed from VYKEA to 
Preference guzzlrQuestTier changed from platinum to 
Preference questGuzzlr changed from started to unstarted
Preference guzzlrQuestTier changed from  to platinum
Preference _guzzlrPlatinumDeliveries changed from 1 to 2
Preference questGuzzlr changed from unstarted to started
Preference _guzzlrPlatinumDeliveries changed from 2 to 1
Took choice 1412/5: Don't take a client right now
choice.php?whichchoice=1412&option=5&pwd
as you can see, after I abandoned the quest it first correctly changed _guzzlrPlatinumDeliveries from 1 to 2 and questGuzzlr to unstarted. This is correct.

Then it inexplicably reverted both of those changes. resulting in incorrect state. IIRC it mentioned refreshing quests in gCLI (which did not get recorded in session log).
However it could not have really refreshed quests because you cannot navigate away from the guzzlr tablet so it could not have visited the quest log.

In particularly problematic is questGuzzlr saying started when it is in fact unstarted.
 
Last edited:

taltamir

Member
Shouldn't it be changed to 0?
Hmmm... actually it should have been changed from 0 to 1.
it is supposed to indicate how many deliveries you took today, not how many were completed or abandoned

Looking further back.
Code:
familiar Cat Burglar (44 lbs)> Taking a Platinum delivery
Preference lastEncounter changed from small hostile animal to Guzzlr Client Selection
Encounter: Guzzlr Client Selection
Took choice 1412/4: Platinum Tier
choice.php?whichchoice=1412&option=4&pwd
Preference guzzlrQuestLocation changed from The Fungal Nethers to VYKEA
Preference guzzlrQuestTier changed from gold to platinum
Preference _guzzlrPlatinumDeliveries changed from 0 to 1
Preference guzzlrQuestBooze changed from water purification pills to Guzzlr cocktail set
Preference questGuzzlr changed from unstarted to started
You acquire an item: Guzzlr cocktail set


mall.php?category=allitems&consumable_byme=0&weaponattribute=3&wearable_byme=0&nolimits=0&max_price=0&sortresultsby=price&justitems=0&x_cheapest=0&pudnuggler=%22cold+wad%22
mall.php?category=allitems&consumable_byme=0&weaponattribute=3&wearable_byme=0&nolimits=0&max_price=0&sortresultsby=price&justitems=0&x_cheapest=0&pudnuggler=%22miniature+boiler%22
mall.php?category=allitems&consumable_byme=0&weaponattribute=3&wearable_byme=0&nolimits=0&max_price=0&sortresultsby=price&justitems=0&x_cheapest=0&pudnuggler=%22robin%27s+egg%22
mall.php?category=allitems&consumable_byme=0&weaponattribute=3&wearable_byme=0&nolimits=0&max_price=0&sortresultsby=price&justitems=0&x_cheapest=0&pudnuggler=%22mangled+finger%22
mall.php?category=allitems&consumable_byme=0&weaponattribute=3&wearable_byme=0&nolimits=0&max_price=0&sortresultsby=price&justitems=0&x_cheapest=0&pudnuggler=%22Dish+of+Clarified+Butter%22
mall.php?category=allitems&consumable_byme=0&weaponattribute=3&wearable_byme=0&nolimits=0&max_price=0&sortresultsby=price&justitems=0&x_cheapest=0&pudnuggler=%22one-day+ticket+to+The+Glaciest%22
> The access item [one-day ticket to The Glaciest] is too expensive. abandoning delivery
Encounter: Guzzlr Client Selection
Preference guzzlrQuestBooze changed from Guzzlr cocktail set to special personalized cocktail
Took choice 1412/1: Abandon Client
choice.php?whichchoice=1412&option=1&pwd
Encounter: Guzzlr Client Selection
Preference _guzzlrQuestAbandoned changed from false to true
Preference guzzlrQuestBooze changed from special personalized cocktail to 
Preference guzzlrQuestLocation changed from VYKEA to 
Preference guzzlrQuestTier changed from platinum to 
Preference questGuzzlr changed from started to unstarted
Preference guzzlrQuestTier changed from  to platinum
Preference _guzzlrPlatinumDeliveries changed from 1 to 2
Preference questGuzzlr changed from unstarted to started
Preference _guzzlrPlatinumDeliveries changed from 2 to 1
Took choice 1412/5: Don't take a client right now
choice.php?whichchoice=1412&option=5&pwd
So to sum it up. taking platinum delivery did (showing only relevant bits):
Preference _guzzlrPlatinumDeliveries changed from 0 to 1
Preference questGuzzlr changed from unstarted to started

When I immediately abandoned this quest it did
Preference _guzzlrQuestAbandoned changed from false to true
Preference guzzlrQuestBooze changed from special personalized cocktail to
Preference guzzlrQuestLocation changed from VYKEA to
Preference guzzlrQuestTier changed from platinum to
Preference questGuzzlr changed from started to unstarted
Preference guzzlrQuestTier changed from to platinum
Preference _guzzlrPlatinumDeliveries changed from 1 to 2
Preference questGuzzlr changed from unstarted to started
Preference _guzzlrPlatinumDeliveries changed from 2 to 1

Hmmm... IIRC it did the failed quest refresh between these two lines
Preference _guzzlrPlatinumDeliveries changed from 1 to 2
Preference questGuzzlr changed from unstarted to started

but that does not explain
Preference guzzlrQuestTier changed from platinum to
Preference questGuzzlr changed from started to unstarted
Preference guzzlrQuestTier changed from to platinum

Why did it change quest tier back to platinum there?
Something is off

I think the issues are:
1. abandoning a delivery still increment the counter on how many you started today. So it gets +1 when started and +1 when abandoned.
2. the refresh quests attempt throws it off because it happens while still locked inside the guzzlr NC from which you cannot navigate away
 
Last edited:

taltamir

Member
Managed to get exact spot at which it tries to refresh the quest data

Code:
[COLOR=blue]The access item [one-day ticket to That 70s Volcano] is     too expensive. abandoning delivery[/COLOR]
Encounter: Guzzlr Client     Selection
Preference guzzlrQuestBooze changed from Guzzlr cocktail set     to special personalized cocktail
Submitting option 1 for choice 1412
Encounter:     Guzzlr Client Selection
Preference _guzzlrQuestAbandoned changed from     false to true
Preference guzzlrQuestBooze changed from special     personalized cocktail to
Preference guzzlrQuestLocation changed from     The Bubblin' Caldera to
Preference guzzlrQuestTier changed from     platinum to
Preference questGuzzlr changed from started to unstarted
Preference     guzzlrQuestTier changed from to platinum
Preference     _guzzlrPlatinumDeliveries changed from 1 to 2
Retrieving quest data...
Preference     questDoctorBag changed from started to step1
Preference questGuzzlr     changed from unstarted to started
Preference _guzzlrPlatinumDeliveries     changed from 2 to 1
Submitting option 5 for choice 1412
option 5 is the one used to exit the NC. so where it says retrieving quest data it is should be redirected towards the NC instead of actually retrieving the quest data. I think it is just seeing the older data
 

gausie

D̰͕̝͚̤̥̙̐̇̑͗̒e͍͔͎͈͔ͥ̉̔̅́̈l̠̪̜͓̲ͧ̍̈́͛v̻̾ͤe͗̃ͥ̐̊ͬp̔͒ͪ
Staff member
Well this was a dumb error, I missed a break in a switch case.

r20153
 

fredg1

Member
Shoes spading is done!!! Ready to be added to mafia.

So, there could be two ways of handling this:

We could simply get a "guzzlrFightsBarefoot" and "guzzlrFightsShoed" property, each simply tracking the amount of fights done without or with the shoes, respectively, letting people script themselves what it means in terms of progress.
Pros: If you already know how many fights that delivery will take, it's easy to know how far you are without having to learn anything about the in-game mechanics; just know how to count.
Cons: If you don't know how long quests take, it doesn't give you any idea as of how far you are into the quest.

OR, we could get a "questGuzzlrProgress" property: an integer going from 0 to 100, which literally tells the player the % of the progress they've done so far.
Pros: would be just like how KoL handles "it" (most likely), and all the logic would be done internally.
Cons: If you were to just look at that number by itself, without knowing how much it's incremented by fights, it's hard to turn it into roughly how many more fights it represents.

...We can also do both, I guess.


Not gonna clutter this post with the info of how it works before knowing if there's any interest in doing it the 2nd way; will be on watch for responses!
 

lostcalpolydude

Developer
Staff member
I would not expect guzzlrQuestProgress to be a percentage, I would expect it to just count up and be combined with the count of _guzzlrDeliveries (by a script, presumably) to know what the target is.

That seems like it gets weird with rollover involved though. But that also seems true of all the other methods of tracking.
 

fronobulax

Developer
Staff member
As a player who might yet script this myself I'm not sure I care. My decision to take a delivery, or not, will be based upon the expected bucks per adventure. That does vary with shoes, which tier and how many deliveries have been done, but moving between tiers changes it more than taking an additional delivery at a tier (when allowed). But my ignorance of the mechanics or my willingness to stop chasing GBucks and spend adventures on meat suggests I have no need for any of the variables. If I start a quest then I am going to finish it and don't know why I care that it is 40% done or there are three turns left. My decision to start it will almost certainly be based upon the Tier and how many I have already done and the new tracking variables don't seem to help that decision. So, given my limited understanding of the mechanics I'm not sure I need either tracking mechanic and if tht ever changed I could get by with whatever was implemented. A lot of help, I know.
 

fredg1

Member
I would not expect guzzlrQuestProgress to be a percentage, I would expect it to just count up and be combined with the count of _guzzlrDeliveries (by a script, presumably) to know what the target is.

That seems like it gets weird with rollover involved though. But that also seems true of all the other methods of tracking.

Could have the opposite of a percentage, i.e. a number that starts at 100, and when it reaches/goes below 0, that's when the quest is done.
Either way, it just... Is... how the game seemingly handles the storage of the quest progress (since there's rounding up involved, and it just wouldn't work if the target wasn't 100).

I would expect it to just count up and be combined with the count of _guzzlrDeliveries (by a script, presumably) to know what the target is.
That... that was exactly what the "Con" of that method was: you need _guzzlrDeliveries to know by how much the progress is incremented every fight. That's it, you need NOTHING else.
 
Last edited:

lostcalpolydude

Developer
Staff member
The problem with a percentage is deciding how to represent X/23, or X/37, or whatever the total progress is that is needed. I'm just making up numbers for that example though, because I have no idea what they would be.
 

fredg1

Member
You CAN totes get these anyway


I guess I'll just say how it works anyway, so that it's clearer

(considering 0=just started and 100<=completed)
The "value" of a fight, for each delivery, is:
Code:
max( 3 , 11 - delivery # you're on )
11 being "the kol number", I very much assume this is exactly how it's represented in their code, but it could very well instead be represented by a more convenient:
Code:
max( 3 , 10 - _guzzlrDeliveries )

For a fight with the shoes, it's literally just:
Code:
floor( 1.5 * "base value of a fight" )

... ... That's... That's it. You can get any other info you want with these two formulas, your progress and your _guzzlrDeliveries
How many fights are left vs. total (no shoes)? (remove the "100 - " and turn the first "ceil" into a "floor" if you want the "how many you did so far" instead)
Code:
ceil( ( 100 - questGuzzlrProgress ) / max( 3 , 10 - _guzzlrDeliveries ) )
out of
ceil( 100 / max( 3 , 10 - _guzzlrDeliveries ) )
What about with the shoes?
Code:
ceil( ( 100 - questGuzzlrProgress ) / floor( 1.5 * max( 3 , 10 - _guzzlrDeliveries ) ) )
out of
ceil( 100 / floor( 1.5 * max( 3 , 10 - _guzzlrDeliveries ) ) )
 

fredg1

Member
...bump?

Even if that wasn't enough to convince, tracking fights with + without shoes is still an option... (though if you do it that way, there'll be issues with rollover interaction, while, from what I seemed to gather, there won't be with the x/100 representation <_< )
 

taltamir

Member
Shoes spading is done!!! Ready to be added to mafia.
Thank you for doing that.
Also my apologies for not helping on that one even though I said I would. I got caught up in some IRL stuff and what free time I had I ended sinking into autoscend.
 

fronobulax

Developer
Staff member
...bump?

Even if that wasn't enough to convince, tracking fights with + without shoes is still an option... (though if you do it that way, there'll be issues with rollover interaction, while, from what I seemed to gather, there won't be with the x/100 representation <_< )

As a general rule I don't like percentages. The English describing percentages can get awkward and you have to have a convention about whether you store a float that is typically less than 1 or a number that is typically less than 100. Remembering to account for "100" in calculations is one more source of error. Coding a loop until done using a counter seems more intuitive to me than checking something against 1, or perhaps 100.

So if you are trying to choose between two things that are different but equivalent, avoid the percentage :)
 

fredg1

Member
As a general rule I don't like percentages. The English describing percentages can get awkward and you have to have a convention about whether you store a float that is typically less than 1 or a number that is typically less than 100. Remembering to account for "100" in calculations is one more source of error. Coding a loop until done using a counter seems more intuitive to me than checking something against 1, or perhaps 100.

So if you are trying to choose between two things that are different but equivalent, avoid the percentage :)

I may have not worded this well: "percentage" was just a way of "thinking about" what the numbers mean, but either way, these ARE the numbers: from zero to one-hundred (or the other way around, no way to know); you only, and MUST, store integers. There is no equivalent. If you are not comfortable with seeing a percentage out of them, then get rid of this completely imaginary % sign / implication that they could be seen as a fraction. They way things are set up, as suggested by spading, the numbers just... go... from zero to one-hundred. Only whole numbers here.
X/100 doesn't mean "x divided by 100", it means "x out of 100".

If you opt for the "tracking fights with + without shoes" option instead (the """equivalent"""), all it means is that every script will have to convert these numbers into a X/100 form by itself.
 
Last edited:

lostcalpolydude

Developer
Staff member
Talking about how it should be tracked before explaining anything about how it works led to a lot of wasted conversation. In that time, I drifted away from KoL a bit, which included ignoring this even though it was easy to code once you actually said anything about how it works. So in the future, it's probably worth explaining up front, so you don't need someone to decide they care about the feature two separate times (the first to ask you to explain, the second to write code).

Anyway, added guzzlrDeliveryProgress in 20223.
 
Top