Menu

#483 Patch: doc/Developers/types/type_13.dox - clarify "chance to break" (food) semantics

None
feedback-needed
None
5
1 day ago
4 days ago
Rick Tanner
No

The "chance to break" row for ARROW (type 13) was technically correct but under-specified, which contributed to a downstream documentation error (player-facing guides relabeled this field "durability" and inverted its meaning, treating a higher %-chance-to-break as a higher survival chance).

This patch, without changing the original meaning, adds:

  • The break-chance roll also applies when a projectile simply runs out of flight range (not only on impact with a wall/monster).
  • An explicit note that this value is the inverse of "durability" (higher = more fragile), and that an artifact's own value is ADDED to the base projectile's value rather than replacing it.
  • A pointer clarifying that for ARROW (type 13), "chance to break" is the only relevant interpretation of <food> - the "changing", "splitting", and "is used up" rows describe unrelated uses of <food> for other object types.</food></food>

Crossfire version: crossfire-crossfire-server (current main/HEAD as of 2026-06-12).

Generated with: diff -u (run from the crossfire-crossfire-server top-level directory, per doc/Developers/programming_guide.md path conventions).

Also attached is the patched types_13.dox for comparison

$ patch -p1 --dry-run < type_13_dox_durability_clarification.patch
checking file doc/Developers/types/type_13.dox

$ patch -p1 < type_13_dox_durability_clarification.patch
patching file doc/Developers/types/type_13.dox

2 Attachments

Discussion

  • Kevin Zheng

    Kevin Zheng - 4 days ago
    • status: open --> feedback-needed
    • assigned_to: Kevin Zheng
    • Group: -->
     
  • Kevin Zheng

    Kevin Zheng - 4 days ago

    Per the README in that directory:

    Files in this directory were generated by utils/gridarta-types-convert so don't modify them else your changes will be lost next time they are generated!

    Please submit a patch against the gridarta types file instead. Then this can be automatically re-generated.

     

    Last edit: Kevin Zheng 4 days ago
  • Rick Tanner

    Rick Tanner - 1 day ago

    New patch is attached

    $ patch -p1 --dry-run < gridarta_types_xml_durability_clarification.patch
    checking file src/crossfire/src/main/resources/resource/conf/types.xml

    $ patch -p1 < gridarta_types_xml_durability_clarification.patch
    patching file src/crossfire/src/main/resources/resource/conf/types.xml

    $ git diff
    diff --git a/src/crossfire/src/main/resources/resource/conf/types.xml b/src/crossfire/src/main/resources/resource/conf/types.xml
    index e6ae9cde4..0a454155c 100644
    --- a/src/crossfire/src/main/resources/resource/conf/types.xml
    +++ b/src/crossfire/src/main/resources/resource/conf/types.xml
    @@ -4941,9 +4941,15 @@

    <attribute arch="food" editor="chance to break" type="int" min="0" max="100">
    The <chance to break> defines the breaking probability when
    - this projectile hits an obstacle, e.g. wall or monster. The value is
    + this projectile hits an obstacle, e.g. wall or monster, or simply
    + comes to rest after exhausting its flight range. The value is
    the %-chance to break, ranging from 0 (never breaking) to 100
    (breaking at first shot).
    +
    + Note: this is the inverse of "durability" - a higher value makes
    + the projectile more fragile, not less. An artifact's own
    + <chance to break> value (if any) is added to the base
    + projectile's value, not used as a replacement.
    </attribute>
    <attribute arch="magic" editor="magic bonus" type="int">
    Magic bonus increases chance to hit and damage a little bit.</attribute>

     

Log in to post a comment.

Auth0 Logo