Results 1 to 9 of 9

Thread: poolSkill preference is never updated

  1. #1

    Default poolSkill preference is never updated

    Code:
    > prefref poolskill
    
    Name Value Default Scope
    poolSkill 0 0 user
    
    > poolskill
    
    Pool Skill is estimated at : 15.
    5 from equipment, 0 from having 0 inebriety, 0 hustling training and 10 learning from 25 sharks.
    
    > prefref poolskill
    
    Name Value Default Scope
    poolSkill 0 0 user
    Visiting the quest log doesn't update it either.
    I'd prefer not to write the code needed to parse the value out of the poolskill command by wrapping it in a cli_execute_output() call just so I can use it in a choiceAdventureScript to handle the Welcome To Our ool Table NC.

    Thanks.

  2. #2
    Developer fronobulax's Avatar
    Join Date
    Feb 2009
    Location
    Central Virginia, USA
    Posts
    4,674

    Default

    I'm going to say not a bug, working as expected. The preference, in spite of the name, is actually the contribution to pool skill from training. So it only changes after Welcome To Our ool Table is encountered. A somewhat superficial look at the code says to me that the preference is being incremented. That said, I did not look to see whether it is reset by Ascension.

    The poolskill command returns an estimate of pool skill and the estimate is derived from equipment, training, a semirare bonus and an equipment bonus. The preference poolskill is just the training portion of that total.

    My sense is that you can do what you want with the commands that are available now that we both know that the poolskill preference is merely one component of what the poolskill command returns.

    If you need another command or function, perhaps a FR?

  3. #3
    Senior Member ckb's Avatar
    Join Date
    Mar 2006
    Posts
    972

    Default

    poolskill is weird and Mafia's support of it is mostly an evolution of not totally understanding it then adding to it as spading happened I think.
    Here is what I use:

    PHP Code:
    int PoolSkill() {
        
    int ps to_int(get_property("poolSkill"));
        
    ps += min(10,to_int(2.0*square_root(to_float(get_property("poolSharkCount")))));
        if (
    my_inebriety()>=10) {
            
    ps += 30-(2*my_inebriety());
        } else {
            
    ps += my_inebriety();
        }
        if (
    have_equipped($item[pool cue])) { ps += 3; }
        if (
    have_effect($effect[Chalky Hand])>0) { ps += 3; }
        return 
    ps;


  4. #4
    Developer fronobulax's Avatar
    Join Date
    Feb 2009
    Location
    Central Virginia, USA
    Posts
    4,674

    Default

    poolskill is weird and Mafia's support of it is mostly an evolution of not totally understanding it then adding to it as spading happened I think.
    Originally Posted by ckb View Post
    Your editorial comment makes me wonder if I failed to make my point :-)

    The preference poolSkill does exactly one thing - count the increase in Pool Skill that results from Welcome To Our ool Table.

    The calculation of "effective" pool skill that mafia makes is similar to yours. It is probably the same but I have no interest, at the moment, in proving it.

    I will note that the core of mafia's pool support dates to 2014 so I am not sure your model of spading driven evolution applies, unless you are referring to pre-2014 work.
    Well, thank you.
    Originally Posted by Veracity View Post

  5. #5
    Senior Member zarqon's Avatar
    Join Date
    Nov 2007
    Location
    Seoul, Korea
    Posts
    3,776

    Default

    @ckb: BatMan RE's calculations are mostly the same as yours, except it uses floor() instead of to_int() and uses the Pool Skill modifier rather than hardcoded values:

    PHP Code:
    int poolishness min(10,floor(2*square_root(to_float(get_property("poolSharkCount"))))) + (min(my_inebriety(),10) - 
                   
    max(0,my_inebriety() - 10)*2) + to_int(numeric_modifier("Pool Skill")) + to_int(get_property("poolSkill")); 
    Sig by JakAtk
    My scripts: Prefref Plus | Skillref Plus | One-Click Woss | Om****est (??) | Psychose-a-Matic | RandBot
    Combat suite: Best Between Battle | Mercenary Mood | SmartStasis | BatMan | BatMan RE
    For script authors: ASH Wiki | ZLib | BatBrain | CLI Links | Drag-n-Drop Inventories | CanAdv | Script Registry | Map Manager
    If you appreciate my work, help me become BAT KING OF THE WORLD! Thanks to all donators!

  6. #6
    Senior Member ckb's Avatar
    Join Date
    Mar 2006
    Posts
    972

    Default

    Your editorial comment makes me wonder if I failed to make my point :-)

    The preference poolSkill does exactly one thing - count the increase in Pool Skill that results from Welcome To Our ool Table.

    The calculation of "effective" pool skill that mafia makes is similar to yours. It is probably the same but I have no interest, at the moment, in proving it.

    I will note that the core of mafia's pool support dates to 2014 so I am not sure your model of spading driven evolution applies, unless you are referring to pre-2014 work.
    Originally Posted by fronobulax View Post
    I am also not sure about all that 2014 work... I remember poolskill being a thing that took some time to totally flush out, but I'm old and my remembering things from 6 years ago might have a wide band of tolerance :-)

  7. #7

    Default

    I'm going to say not a bug, working as expected. The preference, in spite of the name, is actually the contribution to pool skill from training. So it only changes after Welcome To Our ool Table is encountered. A somewhat superficial look at the code says to me that the preference is being incremented. That said, I did not look to see whether it is reset by Ascension.

    The poolskill command returns an estimate of pool skill and the estimate is derived from equipment, training, a semirare bonus and an equipment bonus. The preference poolskill is just the training portion of that total.

    My sense is that you can do what you want with the commands that are available now that we both know that the poolskill preference is merely one component of what the poolskill command returns.

    If you need another command or function, perhaps a FR?
    Originally Posted by fronobulax View Post
    In that case I'd close this as not a bug. I've written a quick function to parse the return value from the poolskill cli command. While it'd be nice to have an actual ASH command that returns it as an int (I could say this about a number of cli commands actually) it's not important enough to bother.

    Thanks frono.

  8. #8

    Default

    The feature requested here isn't possible. The Quest Log shows permanent skill from the semirare plus skill from this ascension from training in the noncombat.

    If you get some semirares outside of KoLmafia, then poolSharkCount will be wrong, and the total calculation will be wrong as a result. Otherwise, everything should be working. I can't think of any feature for attempting to fix tracking when stuff is done outside of KoLmafia either.

  9. #9
    Senior Member
    Join Date
    Oct 2017
    Posts
    550

    Default

    The feature requested here isn't possible. The Quest Log shows permanent skill from the semirare plus skill from this ascension from training in the noncombat.If you get some semirares outside of KoLmafia, then poolSharkCount will be wrong, and the total calculation will be wrong as a result. Otherwise, everything should be working. I can't think of any feature for attempting to fix tracking when stuff is done outside of KoLmafia either.
    Originally Posted by lostcalpolydude View Post
    You could calculate it under the assumption that any not-in-mafia events were only in the past and that currently only mafia is used.keep track of temp poolskill gained in run via the NCcalculate poolskill from equipped itemstake the value from questlog, subtract the above 2 values, and you get the permanent poolskill.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •