| 48 | } |
| 49 | |
| 50 | Maybe<pair<String, String>> parseAssetSource(String const& source) { |
| 51 | if (!File::isDirectory(source)) |
| 52 | return {}; |
| 53 | |
| 54 | String sourcePath = source.trimEnd("/\\"); |
| 55 | String sourceName = sourcePath.splitAny("/\\").last(); |
| 56 | |
| 57 | return make_pair(sourceName, sourcePath); |
| 58 | } |
| 59 | |
| 60 | String tilesetExportDir(String const& sourcePath, String const& sourceName) { |
| 61 | return StringList{sourcePath, AssetsTilesetDirectory, sourceName}.join("/"); |
no test coverage detected