| 665 | } |
| 666 | |
| 667 | void DoUnVision(int nXPos, int nYPos, int nRadius) |
| 668 | { |
| 669 | int i, j, x1, y1, x2, y2; |
| 670 | |
| 671 | nRadius++; |
| 672 | y1 = nYPos - nRadius; |
| 673 | y2 = nYPos + nRadius; |
| 674 | x1 = nXPos - nRadius; |
| 675 | x2 = nXPos + nRadius; |
| 676 | |
| 677 | if (y1 < 0) { |
| 678 | y1 = 0; |
| 679 | } |
| 680 | if (y2 > MAXDUNY) { |
| 681 | y2 = MAXDUNY; |
| 682 | } |
| 683 | if (x1 < 0) { |
| 684 | x1 = 0; |
| 685 | } |
| 686 | if (x2 > MAXDUNX) { |
| 687 | x2 = MAXDUNX; |
| 688 | } |
| 689 | |
| 690 | for (i = x1; i < x2; i++) { |
| 691 | for (j = y1; j < y2; j++) { |
| 692 | dFlags[i][j] &= ~(BFLAG_VISIBLE | BFLAG_LIT); |
| 693 | } |
| 694 | } |
| 695 | } |
| 696 | |
| 697 | void DoVision(int nXPos, int nYPos, int nRadius, BOOL doautomap, BOOL visible) |
| 698 | { |
no outgoing calls
no test coverage detected