| 191 | } |
| 192 | |
| 193 | static void scroll_world(world_map screen, int xdiff, int ydiff) { |
| 194 | const auto visitor = overloads { |
| 195 | [xdiff, ydiff](df::viewscreen_choose_start_sitest* s) {scroll_world_internal(s, xdiff, ydiff);}, |
| 196 | [xdiff, ydiff](df::viewscreen_worldst* s) {scroll_world_internal(s, xdiff, ydiff);}, |
| 197 | [xdiff, ydiff](df::viewscreen_new_regionst* s) {scroll_world_internal(s, xdiff, ydiff);}, |
| 198 | }; |
| 199 | std::visit(visitor, screen); |
| 200 | } |
| 201 | |
| 202 | DFhackCExport command_result plugin_onupdate(color_ostream &out) { |
| 203 | // Apply a cooldown to any potential edgescrolls |
no test coverage detected