Page 1 of 1

Give details for warlock's mirror in its description

PostPosted: Friday, 27th May 2016, 15:53
by VeryAngryFelid
I found warlock's mirror on a character who sacrificed magic resistance to Ru and was wondering if it makes much sense to wear amulet of reflection to help with Hexes.
Currently even knowledge bots don't give details on how the artifact works so I suggest to change its in-game description.
Based on
  Code:
// 50% chance of blocking ench-type effects at 20 displayed sh
        const bool omnireflected
            = hit == AUTOMATIC_HIT
              && x_chance_in_y(player_shield_class(),
                               player_shield_class() + 40);

it can be something like this:
  Code:
The shield has 23% chance to reflect enchantments
for character with 12 SH
and
  Code:
The shield has 29% chance to reflect enchantments
when the character equips +5 amulet of reflection.

Edit. Or is it 46% and 58%?

Re: Give details for warlock's mirror in its description

PostPosted: Saturday, 28th May 2016, 23:27
by genericpseudonym
Actually it would be 38% and 46%, because for some reason the code's internal SH variable is 2x the SH value displayed to the player. So it would be a 24-in-64 or a 34-in-74 chance, respectively.

Re: Give details for warlock's mirror in its description

PostPosted: Sunday, 29th May 2016, 15:14
by VeryAngryFelid
Devs, is a patch welcome?

Re: Give details for warlock's mirror in its description

PostPosted: Sunday, 29th May 2016, 23:54
by lordfrikk
I'd say upload the patch and see what they think about it.

Re: Give details for warlock's mirror in its description

PostPosted: Monday, 30th May 2016, 01:56
by andreas
lordfrikk wrote:I'd say upload the patch and see what they think about it.


''No numbers in descriptions please.''

...just a guess.

e: added link

Re: Give details for warlock's mirror in its description

PostPosted: Monday, 30th May 2016, 02:09
by VeryAngryFelid

Re: Give details for warlock's mirror in its description

PostPosted: Monday, 30th May 2016, 03:41
by ydeve
andreas wrote:
lordfrikk wrote:I'd say upload the patch and see what they think about it.


''No numbers in descriptions please.''

...just a guess.

It would be really sad if that was the response, since this is exactly not the kind of "not useful" "informational overload" type of number they say they want to avoid.

Re: Give details for warlock's mirror in its description

PostPosted: Monday, 30th May 2016, 07:01
by sanka
Well, they opposed showing damage numbers, and I can't imagine more useful numbers to know than the damage you may receive.

Re: Give details for warlock's mirror in its description

PostPosted: Monday, 30th May 2016, 10:52
by Quazifuji
genericpseudonym wrote:Actually it would be 38% and 46%, because for some reason the code's internal SH variable is 2x the SH value displayed to the player. So it would be a 24-in-64 or a 34-in-74 chance, respectively.


Wasn't there a change a couple patches back that made each point of SH twice as effective in order to make enchantment levels on shields more meaningful? I assume that's why internal shield value is double what's displayed.

Re: Give details for warlock's mirror in its description

PostPosted: Monday, 30th May 2016, 17:01
by PleasingFungus
Quazifuji wrote:Wasn't there a change a couple patches back that made each point of SH twice as effective in order to make enchantment levels on shields more meaningful? I assume that's why internal shield value is double what's displayed.

Yep. It's technical debt, and someone who feels like they understand all the internal SH formulae should fix it.

Re: Give details for warlock's mirror in its description

PostPosted: Monday, 30th May 2016, 17:43
by PleasingFungus
Pushed a modified version of Sandman's patch. TY all!

Re: Give details for warlock's mirror in its description

PostPosted: Tuesday, 31st May 2016, 00:49
by dpeg
sanka wrote:Well, they opposed showing damage numbers, and I can't imagine more useful numbers to know than the damage you may receive.
In fact, that's one of not-so-many numbers that the game can provide without additional context. (Outgoing damage, for example, needs monster HP and some more numbers, so is a lot harder to make sensible.) But when you think about it, what would you display incoming damage: maximal value? Or also expected value?

Re: Give details for warlock's mirror in its description

PostPosted: Tuesday, 31st May 2016, 00:56
by neil
dpeg wrote:
sanka wrote:Well, they opposed showing damage numbers, and I can't imagine more useful numbers to know than the damage you may receive.
In fact, that's one of not-so-many numbers that the game can provide without additional context. (Outgoing damage, for example, needs monster HP and some more numbers, so is a lot harder to make sensible.) But when you think about it, what would you display incoming damage: maximal value? Or also expected value?


I think base damage (ignoring effects like might, multiple attacks, wielding weapons). That would parallel what we show for player weapons. For monsters with weapons we could show something like "Base damage: 25; Base weapon damage: 13" for an orc knight wielding a halberd. I wouldn't want to imply that the numbers are simply added together, though, or that it can't do more damage (slaying, weapon plusses, brands).

Calculating the actual maximum damage would a pain to get right and be very liable to get out of sync with the actual damage code, unless perhaps we make all the relevant functions use and return random_vars—and even then we'd need a flag to suppress hidden information.

Edits: bunches

Re: Give details for warlock's mirror in its description

PostPosted: Tuesday, 31st May 2016, 00:58
by HardboiledGargoyle
dpeg wrote:(Outgoing damage, for example, needs monster HP and some more numbers, so is a lot harder to make sensible.)
wut, why does it "need" monster HP? you just need to know which of your 2 weapons/spells/wands will do more damage, and by how much

Re: Give details for warlock's mirror in its description

PostPosted: Tuesday, 31st May 2016, 03:23
by VeryAngryFelid
neil wrote:I think base damage (ignoring effects like might, multiple attacks, wielding weapons). That would parallel what we show for player weapons. For monsters with weapons we could show something like "Base damage: 25; Base weapon damage: 13" for an orc knight wielding a halberd. I wouldn't want to imply that the numbers are simply added together, though, or that it can't do more damage (slaying, weapon plusses, brands).

Calculating the actual maximum damage would a pain to get right and be very liable to get out of sync with the actual damage code, unless perhaps we make all the relevant functions use and return random_vars—and even then we'd need a flag to suppress hidden information.


Can we start with displaying max damage for monster spells? I think they don't suffer from random factors, also avoiding melee monsters is easier than monsters with spells.

Re: Give details for warlock's mirror in its description

PostPosted: Tuesday, 31st May 2016, 03:35
by neil
VeryAngryFelid wrote:Can we start with displaying max damage for monster spells? I think they don't suffer from random factors, also avoiding melee monsters is easier than monsters with spells.


That's easy enough to implement for the usual case beam spells, but more difficult for things like freezing cloud, IOOD, etc. The program 'monster' (which the Gretell and Cheibriados use for their @?? and %?? queries) has code to calculate and guess monster spell damage, that often goes out of sync with the actual damage calculations, and I think is missing some spells. I'm hesitant to put that into the game proper because IMO it's worse if an in-game display goes out of sync with reality than if an IRC bot does so.

I wouldn't mind seeing things adjusted so that we can display that information without duplicating code with the actual damage calculations. Not sure about other devs, though.

Edit: edits

Re: Give details for warlock's mirror in its description

PostPosted: Tuesday, 31st May 2016, 08:19
by ion_frigate
A related issue: why do monster spells have so much looser damage distributions? A player with LCS does 10d22 damage at max power, and an ancient lich does something like 3d48. It seems like the 3dx distribution dates back to pre-DCSS Crawl, but for some reason it was tightened for players but not for monsters.

I understand that player/monster symmetry isn't a priority, but this one is really weird and spoilerish, and in fact punishes observant players who notice that spells like Iron Shot and LCS are pretty consistent in damage (e.g. they see that only the highest-AC monsters ever take no damage from them). Also weird: the fact that (player) Poison Arrow has a much looser damage distribution than other high-level conjurations.

Re: Give details for warlock's mirror in its description

PostPosted: Wednesday, 1st June 2016, 03:08
by Xion350
ion_frigate wrote:A related issue: why do monster spells have so much looser damage distributions? A player with LCS does 10d22 damage at max power, and an ancient lich does something like 3d48. It seems like the 3dx distribution dates back to pre-DCSS Crawl, but for some reason it was tightened for players but not for monsters.

I understand that player/monster symmetry isn't a priority, but this one is really weird and spoilerish, and in fact punishes observant players who notice that spells like Iron Shot and LCS are pretty consistent in damage (e.g. they see that only the highest-AC monsters ever take no damage from them). Also weird: the fact that (player) Poison Arrow has a much looser damage distribution than other high-level conjurations.



A player deals 10-220 damage VS an Lich's 3-144. Although it's inconsistent I can't say I'd enjoy being gibbed by a Lich.

Re: Give details for warlock's mirror in its description

PostPosted: Wednesday, 1st June 2016, 03:35
by HardboiledGargoyle
dpeg wrote: But when you think about it, what would you display incoming damage: maximal value? Or also expected value?
By the way, in answer to this, though you don't seem to be asking me, I would display the maximal post-EV post-SH pre-AC value for both incoming and outgoing damage, and also simply damage formulas to enforce a flat distribution from min (prob 0 but not necessarily) to max damage.
ion_frigate wrote: for some reason it was tightened for players but not for monsters
are you sure about that?

Re: Give details for warlock's mirror in its description

PostPosted: Wednesday, 1st June 2016, 23:48
by PleasingFungus
HardboiledGargoyle wrote:I would display the maximal post-EV post-SH pre-AC value for both incoming and outgoing damage, and also simply damage formulas to enforce a flat distribution from min (prob 0 but not necessarily) to max damage.

how are EV or SH relevant here?

also, why would a flat damage distribution be better than the current distributions?

Re: Give details for warlock's mirror in its description

PostPosted: Thursday, 2nd June 2016, 00:18
by HardboiledGargoyle
I just meant: assuming the attack doesn't miss
because with a flat damage distribution it's just 2 numbers that are easy to communicate (and they tell you everything)
if you just display them a certain way, then you naturally insinuate the context
for example if I see "Dam: 0-11" then I tend to think "any number between 0 and 11, inclusively, each equally likely"
(to-hit and EV rolls could similarly be simplified to the point that having the game actually calculate % for you would almost seem condescending)
that's a point in favor of flat distributions, so let me bounce the question back at you: what advantage do dX+dY+dZ distributions have over flat distributions?

Re: Give details for warlock's mirror in its description

PostPosted: Thursday, 2nd June 2016, 00:47
by Siegurt
HardboiledGargoyle wrote:I just meant: assuming the attack doesn't miss
because with a flat damage distribution it's just 2 numbers that are easy to communicate (and they tell you everything)
if you just display them a certain way, then you naturally insinuate the context
for example if I see "Dam: 0-11" then I tend to think "any number between 0 and 11, inclusively, each equally likely"
(to-hit and EV rolls could similarly be simplified to the point that having the game actually calculate % for you would almost seem condescending)
that's a point in favor of flat distributions, so let me bounce the question back at you: what advantage do dX+dY+dZ distributions have over flat distributions?

Less variance, if your damage range is say, 0-100, with a flat distribution the same monster can be anywhere from trivial to deadly in the average length of a crawl combat with equal likelihood. Whereas if you're distribution is 0-100, but there's a large bell curve, while you might see one or two unlikely results in a single combat, the monster will still have a much more predictable difficulty level.

For most people there's somewhere between "completely predictable" and "completely random" which feels like it's neither unfair nor boring.

Re: Give details for warlock's mirror in its description

PostPosted: Thursday, 2nd June 2016, 01:07
by HardboiledGargoyle
Flat distribution doesn’t mean that the minimum has to be 0. Instead of 3dX you could use X+1dX. It is different. It is not a bell, yet it is similar to a bell in practice (but you get fewer obscene outliers). Which is better? I don’t know, maybe the bell is better, but if it is, is it so damn good that the benefit it provides is so large that it is greater than the ability to concisely and precisely inform the player about damage numbers?