Re: [crossfire] Resistance calculation

2008-05-19 Thread Nicolas Weeger
Hello.

 I would like to suggest a change to the resistance calculation to treat
 every additional protection and vulnerability relative to the current
 resistance.

 Currently, all positive resistances (protection) are accumulated, and
 the negative resistances (vulnerability) separately.

(split much)

IMO, the negative bonus that you can't overcome is part of the penalty for 
choosing a race/god.
If you could, from -30, reach 100, there would be really no point for the -30 
in the first place... There are, I think, enough items to have high 
resistances everywhere, so that -30 wouldn't matter much.


 I suggest to simplify the code and treat every protection or
 vulnerability the same by applying the accumulation formula above to
 both positive and negative resistance items.

Code complexity has nothing to do here :)
Code is at the service of features we want, not the other way around unless 
there is a really good reason - in this case none of those.


Nicolas
-- 
http://nicolas.weeger.org [Petit site d'images, de textes, de code, bref de 
l'aléatoire !]

___
crossfire mailing list
crossfire@metalforge.org
http://mailman.metalforge.org/mailman/listinfo/crossfire


Re: [crossfire] SVN commit access

2008-05-19 Thread Nicolas Weeger
 I have recently been getting quite a few patches into svn for the server
 source (look in trunk ChangeLog for Arvid Norlander), and have been
 considering trying to become a developer, gros, Ryo and Ragnor (iirc) have
 all indicated this may be a good idea on IRC. So here is the request:
 commit access to the server source in svn, mostly in order to: 1) Clean up
 source, fix messy/bad/old source
 2) Fix bugs (both security related and otherwise), memory leaks, valgrind
 errors. 2) Writing unit tests for server (has been requested by Ryo on IRC)

 I may have occasional bug fix for the gtk based clients too but my main
 interest is in the server source.

Support for SVN access - just don't make big breaking changes without 
discussion first :)

Nicolas
-- 
http://nicolas.weeger.org [Petit site d'images, de textes, de code, bref de 
l'aléatoire !]


signature.asc
Description: This is a digitally signed message part.
___
crossfire mailing list
crossfire@metalforge.org
http://mailman.metalforge.org/mailman/listinfo/crossfire


Re: [crossfire] Resistance calculation

2008-05-19 Thread Mark Wedel
Jochen Suckfüll wrote:

 * The damage factor from a vulnerability varies extremely, e.g. fire
 -10 doesn't hurt a newbie without fire protection (resistance 0) not
 much, but even breaks the fire immunity of a fireborn character.
 * Characters like the serpentman that start with cold -50 cannot get
 more than cold 50 even if they had a Cloak of Cold Immunity, since the
 maximum resistance cannot exceed 100-(accumulated vulnerability value).

  I believe those are intentional.

 * In general, even a little vulnerability hurts characters with a high
 resistance very much and renders the respective items almost unbearable.
 * Potions have to be treated separately, to overcome the penalty by the
 vulnerabilities.
 * The resistance cannot be less than -100, although there is no
 sane reason for this limit.

  That last point is probably more historical - I think at one point the 
resistance values where just in an 8 bit integer, limiting range to -127 to 
+127.  And it probably dates back to the days when discrete values didn't 
exist, 
but rather something with immune (+100), protected (+50) or vulnerable (-100), 
and no other values existed.

 
 
 I suggest to simplify the code and treat every protection or
 vulnerability the same by applying the accumulation formula above to
 both positive and negative resistance items.
 
 Advantages are:
 * An item with resist -100 effectively doubles the damage taken, no
 matter if there was any resistance at all. Immune characters remain
 immune, a character with resist 30 will end up with resist 60, resist
 -10 will become resist -120.
 * That's very intuitive, because the resistance on the item tells
 exactly how the resulting damage is changed.

  Not sure I totally agree.  It makes more intuitive sense to me that if I have 
a resist +50 item and a resist -50 item, they balance out to 0.

 * We could have spells that reduce a monster's resistance without
 removing immunities. That adds another tactic element.

  That's an interesting idea.  I'm not 100% sure that the change is needed for 
that


 * We can even have powerful items with resist -1000 (ten times the
 current damage!) to counter other very positive features, without
 breaking the balance or making the item unusable.

  I don't think anything actually prevents a resist -1000 item right now, but 
such an item is clearly useless or meaningless.

  Off topic, but given items big negatives to offset the big positives they 
have 
may be an overused way to slip good items in the game.  Players are smart 
enough 
to use the right items at the right time, so all the negatives do is prevent it 
from being a general object that one uses all the time to an object used at 
specific times.

 * In general there is a better control over the effects of resistance
 values on items.

  Hard to really see how all this plays out.  And at a larger level, this all 
comes down to real damage.

  If my character has 200 hp, -50 racial fire vulnerability, under current 
system best protection I could get might be resist fire 40 (suppose I have 
items 
to get my positive resistance to 90)

  If I'm hit with a spell that does 50 points of damage, resist fire 40 means I 
take 30 points of damage.  However, under revised scheme, character would take 
15 points of damage, and if didn't have that -50 penalty, would only take 10.

  10 vs 15 sounds like a lot, but at 200 hp, not a big deal.  10 vs 40 is a 
lot, 
and really makes that resistance a handicap, which is its intention.

  If the resistance formula is changed, I think a lot of the races/classes may 
need rebalancing.

  Also, I haven't finished rebalancing the spells for crossfire trunk, and that 
will affect things also.  I certainly won't finish that before I go on vacation.

 The current resistance calculation is implemented in
 common/living.c:fix_object(). I would volunteer to make the required
 changes to the trunk version (2.0) if there is a common agreement.

  What you may want to try is put your no formula in, but do it with #ifdef 
NEW_RESISTANCE or something.  That provides an easy way for people to 
expirement 
with it and see the impact.  One of the things I learned with combat 
rebalancing 
is that it was often to just try something out and see what impact it is, vs 
try 
to speculate how things will get affected.

___
crossfire mailing list
crossfire@metalforge.org
http://mailman.metalforge.org/mailman/listinfo/crossfire