-
-
Notifications
You must be signed in to change notification settings - Fork 991
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
support scenario files in [scenario]map_file #4803
Comments
I'd use extension rather than content to detect the format - if it's a .cfg, assume it's a scenario. If it's not a .cfg, assume it's a map. Your existing implementation (searching for the string |
Its efficient enough, its clearly not a botleneck here as both parsing the map and reading it from disk are much slower each. Furthermore, this is also how the editor detects the type when a map is loaded. I think it totally makes sense that the the map_file implementation detects it in the same way as the editor. |
Well, okay. I don't think it's a good method, but it does make sense to have consistency. |
* support scenario files in map_file Now a scenario generated by the scenario editor can be loaded just like a simple map file. fixes #4803
currently the scenarios generated by the scenario editor mare ment to be inclused ina scenario via {./map/ediro_scenario.cfg}, i think it migth make sense to support them via [scenario]map_file, so if a .cfg file is given in map_file, the code the currently reads map_file would just call scenario.appens(read_cfg(scenaro["map_file"])).
There are some things im unsure about yrt though:
The text was updated successfully, but these errors were encountered: