| 4644 | } |
| 4645 | |
| 4646 | staticfn void |
| 4647 | sel_set_door(coordxy dx, coordxy dy, genericptr_t arg) |
| 4648 | { |
| 4649 | coordxy typ = *(coordxy *) arg; |
| 4650 | coordxy x = dx, y = dy; |
| 4651 | |
| 4652 | if (!IS_DOOR(levl[x][y].typ) && levl[x][y].typ != SDOOR) |
| 4653 | levl[x][y].typ = (typ & D_SECRET) ? SDOOR : DOOR; |
| 4654 | if (typ & D_SECRET) { |
| 4655 | typ &= ~D_SECRET; |
| 4656 | if (typ < D_CLOSED) |
| 4657 | typ = D_CLOSED; |
| 4658 | } |
| 4659 | set_door_orientation(x, y); /* set/clear levl[x][y].horizontal */ |
| 4660 | levl[x][y].doormask = typ; |
| 4661 | SpLev_Map[x][y] = 1; |
| 4662 | } |
| 4663 | |
| 4664 | DISABLE_WARNING_UNREACHABLE_CODE |
| 4665 |
no test coverage detected