Alex Mann wrote:
> I am trying to add dodging and parrying of attacks into my fight code. Atm i
> am doing it like this:
>
> // Top of hit code //
> else
> damage(ch, victim, 0, w_type);
> } else {
>
> /* Now we check to we wether the victim parries or dodges.*/
> if (IS_NPC(victim)){
> dodge = (number(1, 40)+ (GET_LEVEL(victim)/2));
> faildodge = (number(1, 20));
> }
> else{
> dodge = (number(1, 20)+ (GET_DEX(victim) + (GET_LEVEL(victim)/2)));
> faildodge = (GET_DEX(ch) + (GET_STR(ch) + number(1,20)));
> }
IS_NPC (mob)
dodge = (1 - 20) + (10/2) = (6 - 25)
faildodge = (1 - 20)
good chance to dodge
using a level 10 warrior with standard high str/dex
else (player)
dodge = (1 - 20) + 14 + (10/2) = (20 - 40)
faildodge = 14 + 15 + (1 - 20) = (29 - 49)
probably a less than 50% chance to dodge.
--
+---------------------------------------------------------------+
| FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
| Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
+---------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/04/01 PST