| 1635 | } |
| 1636 | |
| 1637 | void SyncGetItem(int x, int y, int idx, WORD ci, int iseed) |
| 1638 | { |
| 1639 | int i, ii; |
| 1640 | |
| 1641 | if (dItem[x][y]) { |
| 1642 | ii = dItem[x][y] - 1; |
| 1643 | if (item[ii].IDidx == idx |
| 1644 | && item[ii]._iSeed == iseed |
| 1645 | && item[ii]._iCreateInfo == ci) { |
| 1646 | FindGetItem(idx, ci, iseed); |
| 1647 | } else { |
| 1648 | ii = FindGetItem(idx, ci, iseed); |
| 1649 | } |
| 1650 | } else { |
| 1651 | ii = FindGetItem(idx, ci, iseed); |
| 1652 | } |
| 1653 | |
| 1654 | if (ii != -1) { |
| 1655 | dItem[item[ii]._ix][item[ii]._iy] = 0; |
| 1656 | i = 0; |
| 1657 | while (i < numitems) { |
| 1658 | if (itemactive[i] == ii) { |
| 1659 | DeleteItem(itemactive[i], i); |
| 1660 | FindGetItem(idx, ci, iseed); |
| 1661 | /// ASSERT: assert(FindGetItem(idx,ci,iseed) == -1); |
| 1662 | FindGetItem(idx, ci, iseed); /* todo: replace with above */ |
| 1663 | i = 0; |
| 1664 | } else { |
| 1665 | i++; |
| 1666 | } |
| 1667 | } |
| 1668 | /// ASSERT: assert(FindGetItem(idx, ci, iseed) == -1); |
| 1669 | FindGetItem(idx, ci, iseed); /* todo: replace with above */ |
| 1670 | } |
| 1671 | } |
| 1672 | |
| 1673 | BOOL CanPut(int x, int y) |
| 1674 | { |
no test coverage detected