| 152 | } |
| 153 | |
| 154 | map_marker *map_feature_marker::parse(const string &s, const string &) |
| 155 | { |
| 156 | if (!starts_with(s, "feat:")) |
| 157 | return nullptr; |
| 158 | string raw = s; |
| 159 | strip_tag(raw, "feat:", true); |
| 160 | |
| 161 | const dungeon_feature_type ft = dungeon_feature_by_name(raw); |
| 162 | if (ft == DNGN_UNSEEN) |
| 163 | { |
| 164 | throw bad_map_marker_f("Bad feature marker: %s (unknown feature '%s')", |
| 165 | s.c_str(), raw.c_str()); |
| 166 | } |
| 167 | return new map_feature_marker(coord_def(0, 0), ft); |
| 168 | } |
| 169 | |
| 170 | string map_feature_marker::debug_describe() const |
| 171 | { |
nothing calls this directly
no test coverage detected