Proposal: change Poison formula


Although the central place for design discussion is ##crawl-dev on freenode, some may find it helpful to discuss requests and suggestions here first.

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Wednesday, 6th March 2013, 05:50

Proposal: change Poison formula

Not nearly balanced, but here is an idea on how poison could work

Poison = min(abs(1d(Poison Magic / 3 +1) - 1d(Poison Magic / 3 +1)), Spell Level)

Basically the target is damaged by the difference between two die rolls. It is heavily biased toward low poison damage.

Let's assume: Poison Magic = 3 * Spell Level
Poison = abs(1d(Spell Level +1) - 1d(Spell Level +1)
  Code:
Lv1: 0-1 poison, avg 0.50
Lv2: 0-2 poison, avg 0.89
Lv3: 0-3 poison, avg 1.25
Lv4: 0-4 poison, avg 1.60
Lv5: 0-5 poison, avg 1.94
Lv6: 0-6 poison, avg 2.29
Lv7: 0-7 poison, avg 2.63
Lv8: 0-8 poison, avg 2.96
Lv9: 0-9 poison, avg 3.30

A chart representation for the 9 spell levels:

X    1d1 1d2 1d3 1d4 1d5 1d6 1d7 1d8 1d9 1d10
1d1    0   1   2   3   4   5   6   7   8   9
1d2    1   0   1   2   3   4   5   6   7   8
1d3    2   1   0   1   2   3   4   5   6   7
1d4    3   2   1   0   1   2   3   4   5   6
1d5    4   3   2   1   0   1   2   3   4   5
1d6    5   4   3   2   1   0   1   2   3   4
1d7    6   5   4   3   2   1   0   1   2   3
1d8    7   6   5   4   3   2   1   0   1   2
1d9    8   7   6   5   4   3   2   1   0   1
1d10   9   8   7   6   5   4   3   2   1   0


At Poison magic / 3 < Spell level, the spell level cap becomes useless (the poison just becomes a weaker version).

If Poison magic / 3 > Spell level, the poison becomes a more powerful version of that spell

Let's assume: Poison Magic = 27
Poison = min(abs(1d(10) - 1d(10)), Spell Level)
  Code:
Lv1: 0-1 poison, avg 0.90
Lv2: 0-2 poison, avg 1.62
Lv3: 0-3 poison, avg 2.18
Lv4: 0-4 poison, avg 2.60
Lv5: 0-5 poison, avg 2.90
Lv6: 0-6 poison, avg 3.10
Lv7: 0-7 poison, avg 3.22
Lv8: 0-8 poison, avg 3.28
Lv9: 0-9 poison, avg 3.30

A chart representation of a lvl 5 spell with 27 poison magic:

X    1d1 1d2 1d3 1d4 1d5 1d6 1d7 1d8 1d9 1d10
1d1    0   1   2   3   4   5   5   5   5   5
1d2    1   0   1   2   3   4   5   5   5   5
1d3    2   1   0   1   2   3   4   5   5   5
1d4    3   2   1   0   1   2   3   4   5   5
1d5    4   3   2   1   0   1   2   3   4   5
1d6    5   4   3   2   1   0   1   2   3   4
1d7    5   5   4   3   2   1   0   1   2   3
1d8    5   5   5   4   3   2   1   0   1   2
1d9    5   5   5   5   4   3   2   1   0   1
1d10   5   5   5   5   5   4   3   2   1   0
Last edited by Fergy on Wednesday, 6th March 2013, 20:29, edited 3 times in total.

Ziggurat Zagger

Posts: 11111

Joined: Friday, 8th February 2013, 12:00

Post Wednesday, 6th March 2013, 07:44

Re: Poison Magic

As far as I know poison duration is based on spell power, poison damage is basically a constant. If we increase poison damage, we should make poison duration a constant and poison magic effectively will become another direct damage magic. We have already many direct damage schools.

Slime Squisher

Posts: 375

Joined: Sunday, 15th January 2012, 16:59

Post Wednesday, 6th March 2013, 12:35

Re: Poison Magic

Here is an idea how poison could work: as it does now

Ziggurat Zagger

Posts: 3163

Joined: Friday, 6th January 2012, 18:45

Post Wednesday, 6th March 2013, 14:32

Re: Poison Magic

Poison works very well on the things it affects.

Cocytus Succeeder

Posts: 2297

Joined: Saturday, 14th April 2012, 21:35

Post Wednesday, 6th March 2013, 14:37

Re: Poison Magic

The first step to proposing a change in mechanic: state why you think the current state is bad and what your way will do better.

For this message the author Psieye has received thanks: 2
some12fat2move, Sporkman

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Wednesday, 6th March 2013, 18:47

Re: Poison Magic

Psieye wrote:The first step to proposing a change in mechanic: state why you think the current state is bad and what your way will do better.

The current system relies heavily on failure chance to reduce the overall damage of the spell. This system has a smaller failure chance, but also has a lower median damage.

Before I make a comparison, I should state that the spell level of the poison is independent of the actual spell level (A level 6 poison spell could use the lvl 9 chart). The 'poison magic / 3' part of the suggestion isn't necessary. It is only one of many possible ways of adjusting spell power.

The main part of the suggestion is to change poison from the sum of dice rolls to the difference between dice rolls.
Curent: aDb
New: abs( 1Dc - 1Dc)

My information comes from the wiki: http://crawl.chaosforge.org/Poison#Poison_Types

Regular Poison:
  Code:
Current: 25% chance of 1 poison (5% if the attack does less than 2 points of damage).
New: Lvl 0.5 poison: 50% chance of dealing Lvl 1 poison, (80% chance of failure if the attack did less than 2 points of damage).

PSN   0   1  Avg
Cur 75% 25% 0.25
New 75% 25% 0.25

There would not be any difference with this poison level.  This is only to show that this level can be replicated.

Medium Poison:
  Code:
Current: 33% chance of 1d3 poison (7% if the attack did less than 2 points of damage)
New: Lvl 1.4 poison: 60% chance of lvl 1 poison, 40% chance of lvl 2 poison (80% chance of failure if the attack did less than 2 points of damage)

PSN   0   1   2   3  Avg
Cur 67% 11% 11% 11% 0.66
New 43% 48% 18%  0% 0.66

Strong Poison
  Code:
Current: 33% chance of 2D5+1 poison (7% if the attack did less than 2 points of damage)
New: Lvl 6.1 poison: 90% chance of lvl 6 poison, 10% chance of lvl 7 (80% chance of failure if the attack did less than 2 points of damage)

PSN   0   1   2   3   4   5   6   7   8   9  10  11  Avg
Cur 67%  0%  0%  1%  3%  4%  5%  7%  5%  4%  3%  1% 2.33
New 14% 24% 20% 16% 12%  8%  4% ~0%  0%  0%  0%  0% 2.32

Spiny Worm Poison
  Code:
Current:1D4+1 poison
New: Lvl 9.6 poison: 40% chance of lvl 9 poison, 60% chance of lvl 10

PSN   0   1   2   3   4   5   6   7   8   9  10 Avg
Cur  0%  0% 25% 25% 25% 25%  0%  0%  0%  0%  0% 3.5
New  9% 17% 15% 14% 12% 10%  8%  6%  5%  3%  1% 3.5
Last edited by Fergy on Wednesday, 6th March 2013, 20:00, edited 1 time in total.

Tartarus Sorceror

Posts: 1888

Joined: Saturday, 9th July 2011, 20:57

Post Wednesday, 6th March 2013, 18:53

Re: Poison Magic

Fergy wrote:The current system relies heavily on failure chance to reduce the overall damage of the spell.


What's wrong with that, though?

Vestibule Violator

Posts: 1567

Joined: Friday, 21st January 2011, 22:56

Post Wednesday, 6th March 2013, 19:14

Re: Poison Magic

I don't even know what you are talking about. Doesn't poison stack up to do more and more damage?

Ziggurat Zagger

Posts: 3163

Joined: Friday, 6th January 2012, 18:45

Post Wednesday, 6th March 2013, 19:48

Re: Poison Magic

Fergy wrote:Regular Poison:
  Code:
Current: 25% chance of 1 damage (5% if the attack does less than 2 points of damage).

You are mixing your terminology. The wiki page says that regular poison has a 25% chance of applying 1 level of poison. This is not damage. Damage is based on total poison level acquired and is defined later on.

Edit: Also, those poison types are only descriptors of monster attacks. They have nothing to do with player attacks or spells, and so have no connection to Poison Magic skill.

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Wednesday, 6th March 2013, 20:08

Re: Poison Magic

BlackSheep wrote:
Fergy wrote:Regular Poison:
  Code:
Current: 25% chance of 1 damage (5% if the attack does less than 2 points of damage).

You are mixing your terminology. The wiki page says that regular poison has a 25% chance of applying 1 level of poison. This is not damage. Damage is based on total poison level acquired and is defined later on.


I meant poison, as in the commutative amount of poison that later becomes damage. Hopefully I fixed this in my posts.

Ziggurat Zagger

Posts: 3163

Joined: Friday, 6th January 2012, 18:45

Post Wednesday, 6th March 2013, 20:21

Re: Poison Magic

Sorry, I edited my post and you may have missed it. The poison types you referenced are monster attack types. They have nothing to do with player attacks or spells.

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Wednesday, 6th March 2013, 21:03

Re: Poison Magic

BlackSheep wrote:Sorry, I edited my post and you may have missed it. The poison types you referenced are monster attack types. They have nothing to do with player attacks or spells.


That's fine. The scope of this suggestion is limited to changing the formula for how poison in accumulated. The formula will work for both monster attacks and player attacks. I changed the topic title to be less confusing.

My first post introduces the formula (and unfortunately it goes on a confusing tangent...). The 2nd post provides examples of how this formula relates to the current system (all being monster attacks).

For a player example, the venom brand would be translated into 1.7 poison lvl (38% 0 poison, 46% 1 poison, 16% 2 poison). I will translate other formulas into this system when I can find an accurate source for how the current formula works (wiki is lacking in this).

Ziggurat Zagger

Posts: 3163

Joined: Friday, 6th January 2012, 18:45

Post Wednesday, 6th March 2013, 21:15

Re: Poison

This may only seem like an obvious question to me, but, if you don't know how the current formula works, why are you seeking to devise a replacement?

Lair Larrikin

Posts: 20

Joined: Sunday, 18th December 2011, 08:44

Post Thursday, 7th March 2013, 04:21

Re: Poison Magic

Fergy wrote:I will translate other formulas into this system when I can find an accurate source for how the current formula works (wiki is lacking in this).


I would suggest looking at the source code of crawl rather than the wiki if you want an accurate source.

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Friday, 8th March 2013, 18:43

Re: Poison

BlackSheep wrote:This may only seem like an obvious question to me, but, if you don't know how the current formula works, why are you seeking to devise a replacement?

Rule 47: Every newb must make at least 1 suggestion on something they know nothing about before reaching post count 10.

I jest. I'll split up your question into several:

Do I know how the spell system generally works? - Somewhat
Do I know how poison magic affects spell power? - Yes
Do I know how spell power affects poison spells? - Generally no
Do I know how poison accumulation works? - Yes
Do I know how poison damage works? - Yes

Was my first post suggesting something I know nothing about? Generally yes. I'm sorry, I was thinking out loud.

Was my second post suggesting something I know nothing about? Generally no. It's true that I don't know how it works in every situation, but this is mostly irrelevant. I see how the current system works in a limited set. I see what I don't like about it. I make a suggestion that addresses what I don't like. I do not need to know how the system works in every circumstance, because that formula would work in nearly every circumstance I can foresee. (It's just a different way of rolling dice. Adjusting the number of sides will make it fit...)

Another formula that might address what I don't like: 1d(1d(a+1)) - 1

_____________________________________________________________
Time to think out loud again! (I haven't run any calcs, it's merely an idea)

This system would also allow for an interesting change in the Poison Resistance formula (If so desired).

rPois+: Reduces poison accumulation by 1 (min 0)
rPois++: Reduces poison accumulation by 2 (min 0)
rPois+++: Reduces poison accumulation by 3 (min 0)
rPois-: Increases poison accumulation by 1
rPois-- & rPois---: Same as rPois, except harder to get rid of.

(These resistances would have to have other attributes that address direct poison damage, and other things)

Since the proposed formula is heavily weighted toward low numbers, a small amount of rPois would significantly reduce the amount of poison taken from poison. rPois would grant immunity to low level poison, but still allow them to become poisoned on lucky rolls from higher level poison. 100% poison immunity could only be acquired as a racial attribute (such as undead).

Dungeon Master

Posts: 1531

Joined: Saturday, 5th March 2011, 06:29

Post Friday, 8th March 2013, 18:49

Re: Poison

Fergy wrote:Since the proposed formula is heavily weighted toward low numbers, a small amount of rPois would significantly reduce the amount of poison taken from poison. rPois would grant immunity to low level poison, but still allow them to become poisoned on lucky rolls from higher level poison. 100% poison immunity could only be acquired as a racial attribute (such as undead).


Have you played trunk lately? rPois was changed to no longer be 100% effective anyway.

It's not entirely clear whether you're talking about player getting poisoned or monsters getting poisoned.

And finally, you still haven't satisfactorily answered the glaring question: why is there anything wrong with the current formula?

Ziggurat Zagger

Posts: 3163

Joined: Friday, 6th January 2012, 18:45

Post Friday, 8th March 2013, 19:08

Re: Poison

Also, does your proposed system ignore spell power? Would the staff of poison/olgreb no longer have an effect? Robe of the Archmagi? What about Int stat?

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Friday, 8th March 2013, 21:00

Re: Poison

BlackSheep wrote:Would the staff of poison/olgreb no longer have an effect?


Current:
Chance to Activate on a Hit: Evocations×6.66% + Poison Magic×3.33% (100% likely at 15 Evocations)
Chance to Poison: Poison Magic×12.5%, with a separate 50% chance if that fails; even poison-resistantanimals and plants can be poisoned if an additional Poison Magic×6.25% chance is successful.


Off the Cuff Proposal: (I'll have to think about it more, but this is one possible alternative)
Chance to Activate on a Hit: Evocations×6.66% + Poison Magic×3.33% (100% likely at 15 Evocations)
Poison Level = 1 + Poison Magic / 10

The poison amount starts at lvl 1 poison (0.5 avg poison per activation), and maxes out at lvl 3.7 poison ( 1.5 avg poison per activation). At 7 Poison Magic & 11.5 Evocation, the staff would be equal to the venom brand.

At max power:
0 poison: 22%
1 poison: 34%
2 poison: 15%
3 poison: 6%


BlackSheep wrote:Also, does your proposed system ignore spell power?

No. When I find exactly how poison spells work with respect to spell power I will post my thoughts on them

As another tangent: The current spell power formula stinks. Using a reduction formula on a parabolic formula to achieve semi-linearity, could be better done my using a semi-linear function to begin with. (I think the same thing about the stabbing formula)

That is, the spell power formula should be of the form: 1 / ((1/a) + (1/b)) , or something else that does the same thing.

For those that don't recognize this formula, its the solution to: If it takes "A" 5 hours to paint a house, and "B" 3 hours to paint a house, how long would it take them to paint the house if they work together?

Tartarus Sorceror

Posts: 1888

Joined: Saturday, 9th July 2011, 20:57

Post Friday, 8th March 2013, 21:20

Re: Poison

Fergy wrote:As another tangent: The current spell power formula stinks. Using a reduction formula on a parabolic formula to achieve semi-linearity, could be better done my using a semi-linear function to begin with. (I think the same thing about the stabbing formula)


but since players don't actually have to calculate spell power on the fly by hand what does it matter what formula is used if the end result is what's desired

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Friday, 8th March 2013, 21:23

Re: Poison

mumra wrote:It's not entirely clear whether you're talking about player getting poisoned or monsters getting poisoned.

My understanding is poison accumulation for both player and monsters work the same way. The difference is monsters have a different poison damage formula with respect to the poison accumulated.

If I am wrong on this, please correct me. If I am correct in my understanding, then I am suggesting a change to both.

As for the Poison Resistance tangent, If that was implemented, monsters wouldn't take extra damage for being vulnerable to poison (Instead, the monster would gain more poison accumulation per poisoning, which would result in more damage)

mumra wrote:And finally, you still haven't satisfactorily answered the glaring question: why is there anything wrong with the current formula?

There is nothing wrong with the current formula per se. However, I consider relying on an outright fail chance (without a way to reduce the fail chance) for the pupose of reducing avg damage to be bad game design. I would much rather use a formula with a lower avg damage that still has a wide variable range (such as the one I proposed).

Furthermore, I prefer to have all formulas of a particular damage type to have a similar formula style.

In essence, its a suggestion of style.

Tartarus Sorceror

Posts: 1888

Joined: Saturday, 9th July 2011, 20:57

Post Friday, 8th March 2013, 21:25

Re: Poison

Fergy wrote:There is nothing wrong with the current formula per se.


then why the hell would anybody bother changing it
User avatar

Dungeon Master

Posts: 4031

Joined: Thursday, 16th December 2010, 20:37

Location: France

Post Friday, 8th March 2013, 21:30

Re: Poison

Fergy wrote:Using a reduction formula on a parabolic formula to achieve semi-linearity

What parabolic formula are you referring to?

Your proposal is overly complicated and I'm not sure what you're actually trying to achieve. Maybe you should simplify it to "give a decimal to poison level and makes its result deterministic instead of random". I don't think the result would be noticeable, average damage over time would be the same and the little random variations aren't significant. Assuming we keep the interface and don't display the exact number, It would just create some uncertainty about the exact poison level (since 1.0 is a bit different than 1.9) which wouldn't be very significant nor interesting.

Before diving into numbers and formulae, you should explain more clearly what you are trying to change and why.
<+Grunt> You dereference an invalid pointer! Ouch! That really hurt! The game dies...
User avatar

Barkeep

Posts: 4435

Joined: Tuesday, 11th January 2011, 12:28

Post Friday, 8th March 2013, 21:39

Re: Poison

Fergy wrote:As another tangent: The current spell power formula stinks.


That's a pretty strong statement. Got any reasoning to back that up? From what I understand, people have actually put some thought into spell power.

It's totally fine to be a newcomer to game design, but saying coming out and saying you don't really totally understand the systems at work and then saying part of it stinks isn't going to encourage a super productive discussion.
I am not a very good player. My mouth is a foul pit of LIES. KNOW THIS.

Snake Sneak

Posts: 106

Joined: Friday, 1st March 2013, 20:24

Post Saturday, 9th March 2013, 04:43

Re: Poison

nicolae wrote:
Fergy wrote:There is nothing wrong with the current formula per se.


then why the hell would anybody bother changing it

To make everything standardized and intuitively easy to understand. I realize that the way I explained it is anything but... Attempt # 2.

Purpose:
- Make all poison accumulation spells/attacks/etc. use the same basic method of determining poisoned amount.

Proposed method:
- Roll two dice, take the big number and subtract the smaller number
- The number of sides on the dice can be directly inferred by the poison level (sides = poison lvl +1).
- The max poison can be directly inferred by the poison level.
- If a poison level has a decimal (Foo.XX), it means XX% of the time, roll dice with 1 more side.

  Code:
Poison lvl 0: 0 - 0 poison
X | 1
--+-----------------------------------
1 | 0

Rolled number: Probability of rolling number
0: 1/1 = 100%
Average: 0.0


Poison lvl 1: 0 - 1 poison
X | 1 2
--+-----------------------------------
1 | 0 1
2 | 1 0

Rolled number: Probability of rolling number
0: 2/4 = 50%
1: 2/4 = 50%
Average: 0.5


Poison lvl 2: 0 - 2 poison
X | 1 2 3
--+-----------------------------------
1 | 0 1 2
2 | 1 0 1
3 | 2 1 0

Rolled number: Probability of rolling number
0: 3/9 = 33.3%
1: 4/9 = 44.4%
2: 2/9 = 22.2%
Average: 0.89


Poison lvl 3: 0 - 3 poison
X | 1 2 3 4
--+-----------------------------------
1 | 0 1 2 3
2 | 1 0 1 2
3 | 2 1 0 1
4 | 3 2 1 0

Rolled number: Probability of rolling number
0: 4/16 = 25.0%
1: 6/16 = 37.5%
2: 4/16 = 25.0%
3: 2/16 = 12.5%
Average: 1.25


Poison lvl 4: 0 - 4 poison
X | 1 2 3 4 5
--+-----------------------------------
1 | 0 1 2 3 4
2 | 1 0 1 2 3
3 | 2 1 0 1 2
4 | 3 2 1 0 1
5 | 4 3 2 1 0

Rolled number: Probability of rolling number
0: 5/25 = 20.0%
1: 8/25 = 32.0%
2: 6/25 = 24.0%
3: 4/25 = 16.0%
5: 2/25 =  8.0%
Average: 1.60


Poison lvl 5: 0 - 5 poison
X | 1 2 3 4 5 6
--+-----------------------------------
1 | 0 1 2 3 4 5
2 | 1 0 1 2 3 4
3 | 2 1 0 1 2 3
4 | 3 2 1 0 1 2
5 | 4 3 2 1 0 1
6 | 5 4 3 2 1 0

Rolled number: Probability of rolling number
0:  6/36 = 16.7%
1: 10/36 = 27.8%
2:  8/36 = 22.2%
3:  6/36 = 16.7%
5:  4/36 = 11.1%
6:  2/36 =  5.6%
Average: 1.94

etc.


edit: Made redundant information under code to reduce length

Tartarus Sorceror

Posts: 1888

Joined: Saturday, 9th July 2011, 20:57

Post Saturday, 9th March 2013, 11:53

Re: Poison

Fergy wrote:To make everything standardized and intuitively easy to understand. I realize that the way I explained it is anything but... Attempt # 2.


It's already intuitively easy to understand. I hit a monster and it might get poisoned and then it takes poison damage.

Return to Game Design Discussion

Who is online

Users browsing this forum: No registered users and 171 guests

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.