How Weapon Stats are Calculated

Got a question about Dragon Court? We have the answers! Ask here.

How Weapon Stats are Calculated

Postby Cheshire » November 2nd, 2008, 6:50 pm

To begin, I would like to refer to this old post by LordXod, originally posted on 01/25/03. Following that is an extra analysis provided by me.

Disclaimer - this is kind of convoluted and contains some math. If you aren't interested in this sort of thing, stop reading before it is too late :p

First of all, the quality of a weapon drop is not dependant on your level.

How drop quality is calculated:

The notation [0..3] means a random number in the range 0-3 (it could be 0,1,2, or 3).

skew(50) works as follows:
Start with a value of 0. Select a random number between 0 and 99. If it is less than 50, then add 1 to the value and try again by selecting another random number. If it is equal to or greater than 50, quit. Notice that this is an unbounded value. There is no upper limit on weapon power, just a statistical probability that it won't get too high. For instance, the probability of getting a skew value of 8 or greater is 1/256.

A number is calculated as follows:
7 + [0..3] + [0..3] + skew(50)

This number is applied to each of the items base stats as follows (base stats are listed at the end of this post):
If the stat is >= 0: stat = (stat * number) / 10
If the stat is < 0: stat = (stat *10) / number

Notice that the lowest an item can be is 70% of its base stats. As I indicated above there is no upper limit on an item because of the skew function.

For example, if you find a +115a+46s gladius, then the number calculated was 23.

Adding special abilities to an item:

The following special abilities can be added to an item:
"Curse", "Glows", "Flames", "Bless", "Lucky", "Disease", "Blind", "Panic", "Blast", "Enchant"

This is calculated as follows:
Get the weapon power: 3 * base attack + 2 * base defense + base skill. Assign this to a temporary power value.

Roll a random number in the range 0 - 2047. If it is less than the weapon power, randomly select one of the special abilites described above. If the special ability is already on the weapon, remove it (this is why you can find things like matchlocks with no blast), otherwise add it.

Subtract the random number rolled above from the current temporary power value. Go back to rolling a random number as described in the previous paragraph to see if an additional special ability will be added to the weapon. This continues until the random number rolled is higher than the current temporary power value.

Notice that the more powerful weapons are more likely to have special abilities on them.

Base item stats:

Every item in the game has a base starting level described in the following table (the columns are read as item | attack | defense | skill |where you use the item, two columns for right + left) | item default abilities):

(This is everything defined in the game - not all of these are available)

Knife|2|0|-1|right
Hatchet|4|0|-1|right
Short Sword|5|0|0|right
Long Sword|7|0|0|right
Spear|9|0|1|right
Broad Sword|11|0|1|right
Battle Axe|13|0|1|right|left
Pike|15|0|2|right|left
Silver Pike|30|0|2|right
Sling|4|0|4|right
Short Bow|8|0|6|right|left
Long Bow|12|0|8|right|left
Spike Helm|3|5|-2|head
Main Gauche|2|2|1|left
Clothes|0|2|0|body
Leather Jacket|0|4|0|body
Brigandine|0|6|-1|body
Chain Suit|0|8|-2|body
Scale Suit|0|10|-2|body
Buckler|0|2|-1|left
Targe|0|4|-1|left
Shield|0|6|-2|left
Spike Shield|3|5|-3|left
Sandals|0|0|3|feet
Shoes|0|2|5|feet
Boots|0|4|7|feet
Leather Cap|0|2|-1|head
Pot Helm|0|4|-2|head
Chain Coif|0|6|-3|head;
Steel Sword|15|0|-3|right
Bill Hook|17|0|5|right|left
Sword Breaker|6|6|3|left
Shakrum|13|0|7|right
Recurve Bow|16|0|9|right|left
Half Plate|0|12|-6|body
Full Plate|0|15|-9|body
Steel Buckler|0|5|-1|left
Roman Helm|0|7|-3|head
Doc Martins|4|6|5|feet
Mercury Sandals|0|0|20|feet
Rusty Dagger|3|0|-1|right|decay
Throwing Knife|5|0|5|right
Silver Throwing Knife|10|0|10|right|panic
Staff|5|0|3|right|left
War Tusk|7|6|-3|left
Elf Bow|21|0|10|right|left
Silver Elf Bow|42|0|10|right|left|blast
Mithril Mail|0|13|-2|body
Dwarf Axe|13|2|5|right|lucky
Unicorn Horn|17|0|8|right|bless
Cross Bow|20|0|20|right|left
Miners Cap|0|12|-5|head|glows
Goblin Pick|18|0|0|right
Weird Knife|12|8|12
Silver Weird Knife|25|8|12|left|disease
Goblin Shield|0|13|-5|left
War Boots|7|8|10|feet
Goblin Pike|22|0|5|right
Magic Staff|15|10|12|right|left|bless|lucky
Silver Staff|30|10|12|right|bless|lucky
Magic Robes|0|10|3|head|bless|lucky
Goblin Mithril|0|15|-5
Flaming Sword|15|0|5|right|flames
Goblin Plate|0|18|-5|bless
Terror Rod|17|0|8|right|glows|panic
Rams Horn|7|13|-8|left
Giant Maul|45|0|-20|right|left
Silver Giant Maul|90|0|-20|right
Rat Tail Whip|25|6|25|right|disease
Silver Tail Whip|50|12|50|right|disease
Dragon Shield|0|25|18|left
Great Pike|54|0|15|right|left
Mystic Staff|25|25|25|right|left|bless|lucky
Mystic Robes|0|25|12|body|bless|lucky
Great Bow|50|0|35|right|left
Serpent Scale|0|20|25|left
Sea Slippers|0|10|100|feet
Silver Sea Slippers|0|20|200|feet
Gladius|50|0|20|right
Silver Gladius|100|0|20|right|blind
Great Targe|0|35|10|left
Snake Scale Suit|0|50|-15|body
Matchlock Rifle|80|0|80|right|left|blast
Foul Axe|30|0|15|right|disease
Asaura|0|20|12|feet
Nunchaku|25|0|30|right
Shuriken|30|0|50|left
Spirit Katana|50|0|80|right|panic
Masamune|60|0|40|right
Silver Masamune|120|0|40|right|panic
Koutetsu|10|60|-20|body


============================================

Now that you know how weapon stats are calculated technically, let me break it down into plainer terms. Weapon stats are random BUT follows a positive skewed normal distribution. I made several Dragon Scale Jackets and wrote down every stat made, this was the distribution:

Code: Select all
Tier   Stat   Amount
-----------------------
0.7   56   57
0.8   64   140
0.9   72   201
1.0   80   371
1.1   88   338
1.2   96   314
1.3   104   230
1.4   112   114
1.5   120   56
1.6   128   26
1.7   136   19
1.8   144   5
1.9   152   4
2.0   160   2
2.1   168   0
2.2   176   1
2.3   184   0
2.4   192   0
2.5   200   0



The "base" code of a DSJ in the code is 80, but the mean of the distribution was 90.026 which is closer to a 88d DSJ. The standard deviation (std) was 19.60317358. This means that ~68% of all Dragon Scale Jackets will fall in the range of +/- 1 std, ~95% will fall between +/-2 std and ~99% will fall between +/- 3 std.

If you need more concrete numbers:
  • 68% of all DSJs will be between 72d and 112d
  • 95% of all DSJs will be between 56d and 128d
  • 99% of all DSJs will be between 56d and 144d
(The reason 56d is used twice is because of the lower-limit cut off on weapon stats)

This means that a mere 1% of all DSJs will be greater than a 144d.

Why am I using DSJ or what is the importance of using DSJs? Because ALL weapons in DC have their stats calculated in the SAME exact way. Taking my experiment and putting it into universal numbers:
  • 68.27% will be between 0.9 tier and 1.4 tier
  • 95.45% will be between 0.7 tier and 1.6 tier
  • 99.994% will be between 0.7 tier and 1.8 tier
  • 0.006% will be higher than a 1.8 tier

So you have 3 in 500 chance of getting a 1.9 tier or higher (6/1000). Keep in mind that a 1.9 tier has higher chances than a 2.0 tier which has higher chances of a 2.1 tier, etc.

Good luck at finding that new high stat ;)
Image
*DC Name: Cheshire3 (send all mail & packages there)*

(Personal List Records)
Fame: #6 - 30k (2/22/09)
Skill: #4 - 23k (12/12/08)
Rank: #6 (6/16/07)
Guild: #6 (2/15/10)
Cheshire
RP Councillor
 
Posts: 1596
Joined: August 3rd, 2005, 11:22 pm
Location: There! *points*

Return to Hall of Answers

Who is online

Users browsing this forum: No registered users and 15 guests

cron