v4 bugfixes (66b0fe2)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Magnate
    Angband Devteam member
    • May 2007
    • 5110

    v4 bugfixes (66b0fe2)

    Ok, tonight I've pushed a bunch of changes to v4 to tidy up some recent bugs:

    - archery should no longer be useless. The problem was (as well as the erroneous treatment of prowess described by Derakon) that p_ptr->ammo_mult was being divided by 100! This is now fixed, so archery should now be non-useless. It may well be that x4 launchers are too powerful though. This is by no means a final word on archery, just a quick interim fix to make it vaguely playable again.

    - melee critical chance now decays by 5% per extra die, so no infinite loops for uber-warriors with 100% ... please note that this renders the average damage calculation slightly too high, but it shouldn't be too far out - and if any mathmos want to code up the new accurate formula for average damage, please do!

    - melee critical chance is halved across the board, because people were reporting way too many criticals (so ~40% of hits being crits halfway through the game should now be ~20%, and so on) ... yes this might be too savage, but better to define both extremes first than inch along

    - randart weapons should now never have -1 balance or heft. Doh! Sorry about that.

    - slays ought to work more consistently now - there was a bug which meant that any slay less than +101% was ignored (though higher slays worked). There may well be other remaining slay bugs, so please do watch very carefully to check that the best applicable slay on your equipment is being applied ...

    - fizzix's pathfinding changes, so that PASS_WALL monsters (and presumably KILL_WALL ones too) will revert to normal pathing when blocked by permarock (instead of waiting around stupidly)


    There appears to be a problem with the autobuilders tonight, so I'll post an update when it's actually ready for download. In the meantime, it's available to anyone self-building.

    EDIT: the problem seems to be with the gitpoller rather than the builders, because forced builds work fine. Win and OSX versions now available from the normal place.

    I'm sorry there's been no real progress on the archery front - I can't speak for the rest of the devteam (though I know everyone is still busy with RL), but I've had a shocking few weeks and am now ill (but not, unfortunately, ill enough to stay off work and hack). Please bear with us a while longer.
    Last edited by Magnate; February 22, 2012, 22:41.
    "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles
  • jevansau
    Adept
    • Jan 2009
    • 200

    #2
    Thanks for the fixes - they certainly make this more playable - not sure about the archery though. Might just be the display, but actual damage didn't seem very high either. Details from latest char dump:
    Shoot (+783,+219)
    b) a Journeyman's Long Bow of Lothlórien (x4) (+192,+219) <+3..>
    Bought from a store.

    +3 dexterity.
    +1 shooting power.
    Cannot be harmed by acid, electricity, fire, cold.
    Prevents paralysis. Grants telepathy.

    n) 26 Hunter's Arrows of Flame (1d4) (+72,+10) <+78..>
    Dropped by a Mature black dragon at 3250 feet (level 65).

    Branded with flames (x1.51), frost (x1.78).
    Cannot be harmed by fire, cold.
    Can be destroyed by acid.

    Combat info:
    Hits targets up to 140 feet away.
    Average damage/round: 1.9 vs. normal creatures, 59.8 vs. creatures
    made of stone, 5.4 vs. creatures made of stone, 0 vs. creatures
    hurt by light, 9.7 vs. animals, 0 vs. evil creatures, 20.1 vs.
    undead, 3.9 vs. demons, 10.7 vs. orcs, 3.9 vs. trolls, 10.7 vs.
    giants, 398.5 vs. dragons, 5.5 vs. creatures not resistant to
    acid, 4.1 vs. creatures not resistant to electricity, 4.9 vs.
    creatures not resistant to fire, 5.4 vs. creatures not resistant
    to cold, 4.5 vs. creatures not resistant to poison.
    35% chance of breaking upon contact.

    Comment

    • CunningGabe
      Swordsman
      • Feb 2008
      • 250

      #3
      The arrow damage display seems totally borked -- with regular arrows and a Long Bow of Slaying, I get this long list of strange damages, including 0.1 damage vs. normal creatures, 58 vs. creatures made of stone, etc. It seems like the damage display is going through every slay type, even though my bow doesn't have any slays.

      Another, unrelated bug: I'm wielding an acid-branded axe, and the monster memory is correctly noting when a monster is not immune to acid. However, it seems to be failing to note when a monster _is_ immune.

      Comment

      • Magnate
        Angband Devteam member
        • May 2007
        • 5110

        #4
        Originally posted by CunningGabe
        The arrow damage display seems totally borked -- with regular arrows and a Long Bow of Slaying, I get this long list of strange damages, including 0.1 damage vs. normal creatures, 58 vs. creatures made of stone, etc. It seems like the damage display is going through every slay type, even though my bow doesn't have any slays.
        Yes, sorry, I forgot to mention this one ... hmmm, actually I think I did mention it in a previous v4 thread. Anyway, something is wrong with the *listing* of slays for missiles, though I don't think that actually affects the damage calculation. I am working on this (the listing function currently looks for slays on all equipment, which it should not do for missiles).
        Another, unrelated bug: I'm wielding an acid-branded axe, and the monster memory is correctly noting when a monster is not immune to acid. However, it seems to be failing to note when a monster _is_ immune.
        Do you mean that it uses the brand verb when you hit it ("you melt the foo", or whatever it is)? If so, please pop up a savefile - running it through a debugger is so much easier than trying to reproduce it.

        Or do you mean simply that the monster memory isn't showing the acid immunity, but the brand is correctly not being applied? That's a good catch.
        "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

        Comment

        • CunningGabe
          Swordsman
          • Feb 2008
          • 250

          #5
          Originally posted by Magnate
          Do you mean that it uses the brand verb when you hit it ("you melt the foo", or whatever it is)? If so, please pop up a savefile - running it through a debugger is so much easier than trying to reproduce it.

          Or do you mean simply that the monster memory isn't showing the acid immunity, but the brand is correctly not being applied? That's a good catch.
          I mean the latter -- monster memory doesn't note the immunity. I don't remember whether it used the brand verb or not; I'll take a look when I get home.

          Comment

          • CunningGabe
            Swordsman
            • Feb 2008
            • 250

            #6
            The branding verb looks to be applied consistently. The monster memory is being a little strange. My monster memory updated correctly when I fought water hounds, but not when I fought a gelatinous cube, both of which are immune to acid. I've looked into the problem briefly, and I think the monster recall code is working fine, so it's probably a problem with actually learning the flag.

            Comment

            • Magnate
              Angband Devteam member
              • May 2007
              • 5110

              #7
              Originally posted by CunningGabe
              The branding verb looks to be applied consistently. The monster memory is being a little strange. My monster memory updated correctly when I fought water hounds, but not when I fought a gelatinous cube, both of which are immune to acid. I've looked into the problem briefly, and I think the monster recall code is working fine, so it's probably a problem with actually learning the flag.
              Ah! Got it! The monster memory is only updated when the flag is learned, not if it's already known. I think that's what's happening. Good catch. I'll try to fix that.
              "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

              Comment

              • Magnate
                Angband Devteam member
                • May 2007
                • 5110

                #8
                Originally posted by Magnate
                Ah! Got it! The monster memory is only updated when the flag is learned, not if it's already known. I think that's what's happening. Good catch. I'll try to fix that.
                Hmm, no, that isn't the problem. What's happening is that the lore is only being updated when the monster isn't immune. It needs to be updated when the monster is immune too. Dammit.
                "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

                Comment

                • Magnate
                  Angband Devteam member
                  • May 2007
                  • 5110

                  #9
                  Fixed it (a20bccb).
                  "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

                  Comment

                  • jevansau
                    Adept
                    • Jan 2009
                    • 200

                    #10
                    I've noticed that past a point of prowess/finesse, the damage display becomes meaningless still (although no crashes which is great). For example at +943/+884, damage is showing as 10644.4 for normal creatures. Testing showed it is clearly not doing anything like this amount of damage.

                    If someone would like to tell me the method of working out damage, I'll come up with an algorithm for displaying the damage.

                    Comment

                    • Magnate
                      Angband Devteam member
                      • May 2007
                      • 5110

                      #11
                      Originally posted by jevansau
                      I've noticed that past a point of prowess/finesse, the damage display becomes meaningless still (although no crashes which is great). For example at +943/+884, damage is showing as 10644.4 for normal creatures. Testing showed it is clearly not doing anything like this amount of damage.

                      If someone would like to tell me the method of working out damage, I'll come up with an algorithm for displaying the damage.
                      Hmmm. Part of the problem is that you aren't supposed to end up with anything like that amount of +fin/prow - could you post a dump?

                      Don't forget that that's damage per *round*, not per blow. But 2000 damage per blow is still ridiculous.

                      The damage is simply:

                      1. XdY diceroll
                      2. Multiplied by "mult" (which is derived from your prowess score and your weapon's preference for prowess, which we call heft, plus any slay or brand mult)
                      3. Check for crit chance (which is fin^2 plus prow^2 all / 5000 and capped at 99%).
                      4. If the check fails, stop - that's the total damage.
                      5. Add 1dY if successful, multiply chance by 0.95 and go back to 3

                      It's the x0.95 that messes things up - there's a nice mathematical equation to calculate the crit damage if chance is constant, but it isn't.
                      "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

                      Comment

                      • jevansau
                        Adept
                        • Jan 2009
                        • 200

                        #12
                        Thanks for that - I actually got impatient yesterday and grabbed a clone of the source, and did some testing with a spreadsheet.
                        Formula for extra critical dice is:
                        dice = c + (.95c)c + (.95c)^2c +(.95c)^3c ...
                        where c is the critical chance. Because of the .99 cap, a total of 14 terms gives a very close approximation.
                        Tops out at about 5.2 dice average at 99%.

                        Dump attached.
                        Attached Files

                        Comment

                        • Derakon
                          Prophet
                          • Dec 2009
                          • 9022

                          #13
                          That is one beastly weapon you have there. 5d10 damage and an acid brand! I kinda feel like the Disruption affix should make the weapon be heavily prowess-oriented -- having a 35-pound weapon that's 70/30 balance/heft seems wrong.

                          You're getting 335 finesse from race/class/level, 348 from equipment, and 260 from DEX. The original intent was that you get about a third from race/class/level, a third from equipment, and a third from DEX, so things are slightly out of whack here, but it wouldn't seem like they're excessively so.

                          Your crit chance should be ((.7 * 943)^2 + (.3 * 743)^2) / 5000 + 1 = 98%. So we didn't actually hit the crit cap. It would take 14 successful crits before your chance of getting an extra crit would be below 50%. If we brought your non-DEX finesse mods down to 260 to match DEX (and didn't change the prowess mods) then you'd be at ((.7 * 780) + (.3 * 743)^2) / 5000 + 1 = 70%. That's still pretty high; it'd take 7 successful crits before the chance for another drops below 50%.

                          So it sounds like weapon and class mods may need a bit of a nerf, but more importantly that .95x multiplier needs to be brought down. At .8x the two cases outlined above become 4 and 2 iterations, respectively, before the chance for further crits drops below half.

                          Comment

                          • jevansau
                            Adept
                            • Jan 2009
                            • 200

                            #14
                            I did see one with 6d10 and a 6.64 slay multiplier for undead. Too heavy though and 10/90.

                            The calculation I gave seems about right when I look at number of turns to kill compared to health of monster.

                            Comment

                            • Derakon
                              Prophet
                              • Dec 2009
                              • 9022

                              #15
                              Alternate solution: increase the divisor further (to 7500 or 10000, say) and cap max crit chance at 50% (or whatever), then do away with the .95x multiplier altogether. That would, per Magnate's post, also make it easier to calculate expected damage from crits.

                              Comment

                              Working...
                              😀
                              😂
                              🥰
                              😘
                              🤢
                              😎
                              😞
                              😡
                              👍
                              👎