About the game
News
Sign in
Register
Top Players
Forum
15:24
4674
 online
Authorization required
You are not logged in
   Forums-->Queries and help-->

AuthorPlease confirm the way that damages are rounded : )
Hello : ),

when using the physical damage (on succesful hit) calculation formulae ,
found in Forum FAQs

("Forums-->Queries and help-->F.A.Q. Read before posting your question"
Post #24 Arctic 2008-06-07 23:21:22 )

especially when mutual faction resistance bonus applies in pvp,
we often end up with non-integer numbers
could you please confirm the way damages are rounded ?

for instance, we could have one of the 3 sample methods below or even something else :

Method 1) damages are rounded according to decimal part of number
decimal part of number >= 0.5 : damages rounded up
decimal part of number < 0.5 : damages rounded down / floored

Method 2) damages always rounded up

Method 3) damages always rounded down / floored but cant be inferior to 1


Do we need some example ? (neednt? dont read further ; )

Lets imagine a duel opposing two level 1 knights, who both have 1 attack and 0 defence.
They both trained their knight faction skill to level 1 (bonus +1 defence to troops).
They battle with their farmers only, for fun.
Both sides have only a single farmers stack (both stacks same strentgh).
All attacks and defences bonuses are equivalent thus cancel each other.
As a result of that, we end up with a simpler formulae (only for this example !)
damage dealt = number of farmers * 0.97
where 0.97 is modifier for the reduction of damages because of the 3% resistance against knights)

With the above methods 1 and 2,
2 farmers hitting two others with their forks would still do 2 damages,
as if there was not the 3% knight skill resistance bonus
(2*0.97=1.94 and when you round up 1.94 damages you get 2 damages).

With method 1, you can notice a damage drop only when there are like 17 farmers or more
(when keeping same parameters with no attack bonus).

With method 2 - i didnt check - but its like
you need like 100 farmers to notice any difference.

With method 3, 2 farmers would hit 1 instead of 2 because of 3% the knight resistance bonus.

Thank You for reading : )
this is a very deep thought...i think your method 1 is right, i don't see how it will make a difference in battle though since it's just 1 damage...
Thank you for your reply
It can sound fun but 1 damage is evrything in a battle, its the diference between death and survival, especially with farmers haveing only 4 hp (there are many other units with low hp).
in our example :
Method 1&2 the 2 farmers kill the others in 4 hits (8 hitpoints total)
Method 3 the 2 farmers will need to hit 8 times to kill the others,
(if the heroes dont help them off course)
Method 3 will always make a difference when farmers are protected with resistance against other knight (faction bonus) while for other methods the effect wont be noticeable with under certain amount of troops and attack bonuses.
This topic is long since last update and considered obsolete for further discussions.

Back to topics list
2008-2024, online games LordsWM