| 905 | } |
| 906 | |
| 907 | inline bool RemoveBlockEventInline(int32_t x, int32_t y, int32_t z, df::block_square_event * which) |
| 908 | { |
| 909 | df::map_block *block = Maps::getBlock(x, y, z); |
| 910 | if (!block) |
| 911 | return false; |
| 912 | int idx = linear_index(block->block_events, which); |
| 913 | if (idx >= 0) |
| 914 | { |
| 915 | delete which; |
| 916 | vector_erase_at(block->block_events, idx); |
| 917 | return true; |
| 918 | } |
| 919 | else |
| 920 | return false; |
| 921 | } |
| 922 | inline bool Maps::RemoveBlockEvent(int32_t x, int32_t y, int32_t z, df::block_square_event * which) |
| 923 | { |
| 924 | return RemoveBlockEventInline(x, y, z, which); |
no test coverage detected