Changeset 686
- Timestamp:
- 02/05/08 07:16:21 (7 months ago)
- Files:
-
- trunk/src/obj-make.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/src/obj-make.c
r683 r686 483 483 { 484 484 int tohit1 = randint(5) + m_bonus(5, level); 485 int tohit2 = m_bonus(10, level); 486 485 487 int todam1 = randint(5) + m_bonus(5, level); 486 487 int tohit2 = tohit1 + m_bonus(10, level); 488 int todam2 = todam2 + m_bonus(10, level); 489 490 491 if (power == -2) 492 { 493 o_ptr->to_h -= tohit2; 494 o_ptr->to_d -= todam2; 495 } 496 else if (power == -1) 497 { 498 o_ptr->to_h -= tohit1; 499 o_ptr->to_d -= todam1; 500 } 501 else if (power == 1) 502 { 503 o_ptr->to_h += tohit1; 504 o_ptr->to_d += todam1; 505 } 506 else if (power == 2) 507 { 508 o_ptr->to_h += tohit2; 509 o_ptr->to_d += todam2; 488 int todam2 = m_bonus(10, level); 489 490 switch (power) 491 { 492 case -2: 493 o_ptr->to_h -= tohit2; 494 o_ptr->to_d -= todam2; 495 496 case -1: 497 o_ptr->to_h -= tohit1; 498 o_ptr->to_d -= todam1; 499 break; 500 501 case 2: 502 o_ptr->to_h += tohit2; 503 o_ptr->to_d += todam2; 504 505 case 1: 506 o_ptr->to_h += tohit1; 507 o_ptr->to_d += todam1; 508 break; 510 509 } 511 510
