Randarts and power

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Nick
    Vanilla maintainer
    • Apr 2007
    • 9647

    Randarts and power

    First, some context.

    Randarts have a long history in Angband. Since about 3.2, they have principally been a labour of love for Magnate, who spent a lot of time and effort refining the randart generation to the point where everyone seems to be pretty happy with it in 4.0.5.

    So I'm about to break them. Here are my reasons:
    1. Objects used to only be allowed to have one value (the "pval") which could be used as a bonus to stats, speed, stealth, etc. This changed first to allowing three such values ("multiple pvals"), and now to the ability to have as many as there are such modifiers. But the randart code still behaves as if it's the one pval era, which seems an unnecessary restriction.
    2. Randarts work by calculating a power value for all the standard artifacts, then for each one generating a replacement of similar power. This power calculation can in fact be done for any object; it is also used for determining shop prices. Now there is also a monster power calculation, and these two depend on each other. This power calculation code is quite intricate, and has had some strange fudge factors put in to make all the final answers look sensible. This is all very well, but it means the power calculations are very sensitive to changes in the object or monster list. I would like to make it so that changes to objects and monsters can be made without having to retune power.
    3. More generally, a big part of my aim in restructuring the Angband code was to make it easier to modify sensibly. My insistence on making 4.0.0 gameplay identical to 3.5.1 meant much of the power and randart code had to remain as it was, but now that restriction has been lifted I would like to finish the restructure job for these areas.


    So long story short, the nightlies are going to have randarts and object prices which will (to put it kindly) require some balancing for a while. Please play them and give feedback about how the balance is going (note that there is also a bug thread for the nightlies here).
    One for the Dark Lord on his dark throne
    In the Land of Mordor where the Shadows lie.
  • Estie
    Veteran
    • Apr 2008
    • 2347

    #2
    I would be happy to play, but are these changes already in effect ?

    Can you give a rough idea of how artifact power depends on monster power and what those fudge factors look like ?

    As for shop pricing, giving that there are items I always buy (free action gloves) and ones I never buy (defender weapon), I dont see how changing prices could possibly be unbalancing, unless it is for consumables - but why would those depend on power calculations.

    Edit: it seems to be in effect alreday, I created a randart file and there is artifact with +3 str and +5 stealth, indicating multiple pvals.
    Last edited by Estie; November 6, 2016, 11:02.

    Comment

    • Nick
      Vanilla maintainer
      • Apr 2007
      • 9647

      #3
      Originally posted by Estie
      Can you give a rough idea of how artifact power depends on monster power and what those fudge factors look like ?
      Well, power of an artifact includes a power value for its slays and brands. This is worked out by working out the best slay/brand multiplier against each monster, and then calculating an average multiplier against all monsters weighted by the monster power.

      Fudge factors - there are many. One example is when calculating the max damage a monster can deal with a melee blow, the current code multiplies that damage by 4/3 if it is a blow that can stun, or by 7/5 if it is a blow that can cut, to give an idea how relatively dangerous that blow is. This seems kind of reasonable, but is also basically just an arbitrary guess, and then there are dozens of these guesses.

      I'm not sure exactly what the best way forward is - we may well end up with something quite similar to now, but I'll be thinking about it and I'm happy to hear suggestions.

      Originally posted by Estie
      As for shop pricing, giving that there are items I always buy (free action gloves) and ones I never buy (defender weapon), I dont see how changing prices could possibly be unbalancing, unless it is for consumables - but why would those depend on power calculations.
      When these power calculations first started, there was, for example, a big drop in the shop price for Boots of Speed. I don't think there will be huge price changes this time, but there may be some; and certainly randarts will be different in ways I can't really predict.

      Originally posted by Estie
      Edit: it seems to be in effect already, I created a randart file and there is artifact with +3 str and +5 stealth, indicating multiple pvals.
      Yes, the first changes are in the latest nightlies. There will probably be more randart changes as I clean up the code and see what I break
      One for the Dark Lord on his dark throne
      In the Land of Mordor where the Shadows lie.

      Comment

      • Pete Mack
        Prophet
        • Apr 2007
        • 6883

        #4
        Stunning is way more dangerous than cuts or poison. Stunning and confusion are by far the most dangerous side effects (especially with lanterns of seeing in the game.)

        Comment

        • Magnate
          Angband Devteam member
          • May 2007
          • 5110

          #5
          Good luck my friend. I am lurking and interested - it is a long-held ambition to get rid of all the fudge factors. If there's anything I can do etc.
          "Been away so long I hardly knew the place, gee it's good to be back home" - The Beatles

          Comment

          • Nomad
            Knight
            • Sep 2010
            • 958

            #6
            Originally posted by Nick
            Fudge factors - there are many. One example is when calculating the max damage a monster can deal with a melee blow, the current code multiplies that damage by 4/3 if it is a blow that can stun, or by 7/5 if it is a blow that can cut, to give an idea how relatively dangerous that blow is. This seems kind of reasonable, but is also basically just an arbitrary guess, and then there are dozens of these guesses.

            I'm not sure exactly what the best way forward is - we may well end up with something quite similar to now, but I'll be thinking about it and I'm happy to hear suggestions.
            This is probably more reorganising the problem than solving it, but how about moving all the arbitrary multipliers/fudge factors out to an edit file? List all the flags in an edit file and assign them each a numerical "power level"/value corresponding to their relative usefulness/importance (huge can of worms in itself, I know). Then the actual hard-coded power calculation can be clean and simple and just look up how many "points" each trait is worth from the file and plug that number in as a multiplier. Plus it will be easy to make tweaks to the edit file both to balance things after game changes and for individual players who disagree with the existing rankings.

            (As for the huge can of worms that is deciding how much individual traits are worth relative to each other in the first place, the only thing I can suggest is getting the community to all list their personal rankings and averaging the results. Which I'm sure will probably devolve into a length derailing argument about some minor point within the first handful of posts, but oh, well. )

            Comment

            • Nick
              Vanilla maintainer
              • Apr 2007
              • 9647

              #7
              Originally posted by Nomad
              This is probably more reorganising the problem than solving it, but how about moving all the arbitrary multipliers/fudge factors out to an edit file? List all the flags in an edit file and assign them each a numerical "power level"/value corresponding to their relative usefulness/importance (huge can of worms in itself, I know). Then the actual hard-coded power calculation can be clean and simple and just look up how many "points" each trait is worth from the file and plug that number in as a multiplier. Plus it will be easy to make tweaks to the edit file both to balance things after game changes and for individual players who disagree with the existing rankings.
              Funnily enough, I just had that very thought this morning

              A start has already been made on this with constants.txt, but yes, that is the correct thing to do.

              Originally posted by Nomad
              (As for the huge can of worms that is deciding how much individual traits are worth relative to each other in the first place, the only thing I can suggest is getting the community to all list their personal rankings and averaging the results. Which I'm sure will probably devolve into a length derailing argument about some minor point within the first handful of posts, but oh, well. )
              Well, once they're all in edit files I can just throw my hands up and say "Fix it yourself"
              One for the Dark Lord on his dark throne
              In the Land of Mordor where the Shadows lie.

              Comment

              • fizzix
                Prophet
                • Aug 2009
                • 3025

                #8
                Originally posted by Nick
                Well, once they're all in edit files I can just throw my hands up and say "Fix it yourself"
                What we really need is a good metric for these things. How valuable is slay evil, how about slay undead? slay orc on an early weapon isn't bad, but on a late game weapon is completely worthless. How do we calculate the power of that?

                Since these things do depend on the monster list, I don't see any way of getting around the coupling problem. I think this is the natural way to go.

                I'm not sure how to go about calculating these metrics in any sort of self-consistent way. This even moreso for "utility" things like speed, damage, telepathy. What's the relative weighting of +3 damage vs. slay troll?

                Comment

                • Pete Mack
                  Prophet
                  • Apr 2007
                  • 6883

                  #9
                  If you really want to know, do a fit based on dlevel statistics in the ladder. But in general, acid brand +slay evil is super powerful, while cold brand and slay animal is not

                  Comment

                  • fizzix
                    Prophet
                    • Aug 2009
                    • 3025

                    #10
                    Originally posted by Pete Mack
                    If you really want to know, do a fit based on dlevel statistics in the ladder. But in general, acid brand +slay evil is super powerful, while cold brand and slay animal is not
                    Sample size will be nowhere near enough, and furthermore, it won't necessarily scale across versions. For a long time, trident of pain + branding acid ring was a very common combo. That's out of the picture now.

                    Comment

                    • Derakon
                      Prophet
                      • Dec 2009
                      • 9022

                      #11
                      Originally posted by fizzix
                      What we really need is a good metric for these things. How valuable is slay evil, how about slay undead? slay orc on an early weapon isn't bad, but on a late game weapon is completely worthless. How do we calculate the power of that?
                      Part of the problem we run into is that powers are tightly inter-related across pieces of equipment. This is most obvious with stuff like off-weapon brands, where the power of the brand depends on the dice of the weapon you use in the endgame -- which might be determined by the fact that you have the brand in the first place! So for example, an 8d8 randart dagger with weak to-dam and no powers might be an amazingly useful item just because you happened to find a ring with an off-weapon Slay Evil on it.

                      That particular kind of situation I believe is specifically coded for, but only really because it's the most obvious of these kinds of dependencies across items. The value of a specific item always depends on what it brings to the table relative to what you're already using. In particular, many abilities suffer from diminishing returns. Your fifth source of Free Action isn't very valuable, but your first is incredibly important -- and if FA is rare in your randart set, then the value of a randart with FA is correspondingly higher. The same goes for all the other resists and protections.

                      This is a very tricky problem to solve with a "greedy" randart generator (that does not consider the entire set of randarts when calculating power for a specific randart). And it is of course further complicated by the fact that the average player does not find all randarts in a given session. There might be an incredibly powerful and pretty common randart that's skewing the power rankings for every other randart in the game -- that still doesn't mean you'll find it.

                      Honestly I don't know what the right solution to this is. I think the current randarts are usually pretty good. I'd rather err on the side of making them weaker rather than stronger, though, for three reasons. First, people playing randarts generally have more experience with the game. Second, we want to make the game harder anyway. And third, all it really takes to blow the game wide open is the player finding a single really great artifact. I'm not saying the player should never find good artifacts, just that they shouldn't be routinely finding e.g. Deathwreaker-caliber artifacts.

                      (Frankly I think the Rings of Power are all too common right now; I remember only rarely finding them back in the 2.8.x days)

                      Comment

                      • Estie
                        Veteran
                        • Apr 2008
                        • 2347

                        #12
                        Randarts currently are weaker than standarts - in a randart game, I am using more ego items. While there are spikes where the set creates some very powerfull endgame toon, on average a randart game often feels like a "no artifact" game. It is easiest to see this for - but not limited to - melee weapons; the standart set guarantees a few who are on par or better than the top end egos, but many (I would think: more than half) of randart sets have nothing that tops egos. This is not a very interesting situation, so if you want to make the game harder by lowering item power, I would suggest nerfing the egos instead.

                        The value of the affixes changes with class, game stage, monster population and what not, and this is a good thing. So assigning them a value that is correct under all circumstances is impossible; however, I dont see why this would be necessary. There is no need to get the shop price just right, or make rand-Ringil exactly as desirable as original Ringil. You just need to get it close enough so the game doesnt feel distorted.

                        As for difficulty in general, what about introducing difficulty levells. Currently you can pick between a normal game, with or without connected stairs, and 2-stage ironman, but ironman is not only more difficult, it is a completely different game. What I envision is to make some values variable, like for example the amount of inventory slots, the capacity of the quiver, the power and/or frequency of items and any other things people can think of (and maintainers can program . The idea is to change gameplay as little as possible, but provide more of a challenge for people who play the game for that reason.

                        I dont know how much work that would be - probably a lot - but with that in mind, it might be good to completely change the randart generation, from mirroring the existing standarts, to a scheme where you enter a few parameters like amount, minvalue, maxvalue and then just let the game roll a set with those parameters. It would then be easy to modify the overall quality, be it for different birth options or just for balancing the basic game, by adjusting those parameters.

                        Comment

                        • Derakon
                          Prophet
                          • Dec 2009
                          • 9022

                          #13
                          Originally posted by Estie
                          I would suggest nerfing the egos instead.
                          Nerf the egos, check.

                          Integrating portions of constants.txt into the difficulty options is an interesting idea that I wholeheartedly support.

                          Comment

                          • fizzix
                            Prophet
                            • Aug 2009
                            • 3025

                            #14
                            Originally posted by Derakon
                            Nerf the egos, check.

                            Integrating portions of constants.txt into the difficulty options is an interesting idea that I wholeheartedly support.
                            It's a good point. Right now we allow for very granular modification of stuff, like going into the edit files and changing individual allocations. Really it'd be useful to have some broader knobs to tweak. Turn up wands, turn down ammo, turn up monster density, reduce artifact generation chance, etc.

                            Comment

                            • Nomad
                              Knight
                              • Sep 2010
                              • 958

                              #15
                              Originally posted by Derakon
                              Nerf the egos, check.
                              This goes pretty much hand in hand with something else I'd like to see now we have rune-based ID, more randomisation of egos. There are a bunch of no-brainer progressions in the egos where you trade up from, say, single resist armour to Resistance to Elvenkind and each one is so self-evidently better than the last there's no element of choice involved. IMO it's much more interesting to have a bunch of mid-level egos with a random selection of traits so you might end up deciding between armour with rCold/rFire/rPois versus armour with rAcid/rElec/rNexus instead of the mindless upgrade from Resistance to Elvenkind.

                              Same for the ego weapons; they're a little more varied, but there's still not a lot of choice and comparison involved in going from Slay to *Slay* to Holy Avenger to another, slightly better Holy Avenger. I'd rather see more mid-level egos where you sometimes get lucky with the mix of properties in place of top-end egos where you always get lucky because they've got a broad set of guaranteed properties.

                              Comment

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