andy5995 81 Posted Monday at 14:45 Report Share Posted Monday at 14:45 (edited) When I reported on IRC that my skirmish maps weren't working, @Stan`gave me a link to this script https://code.wildfiregames.com/P232 I've attached the python script it to this post. python3 <scriptname> <version> <path> The correct version to use is "7". For the path, I used "." (single dot) while in the directory containing my custom skirmish maps. After that, you may have to edit your xml. I still get errors such as the following when opening most maps into Atlas Quote ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: CCacheLoader failed to find archived or source file for: "simulation/templates/gaia/flora_tree_cretan_date_palm_tall.xml" ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: CCacheLoader failed to find archived or source file for: "simulation/templates/gaia/flora_tree_cretan_date_palm_tall.xml" ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: CCacheLoader failed to find archived or source file for: "simulation/templates/gaia/flora_tree_cretan_date_palm_tall.xml" ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: CCacheLoader failed to find archived or source file for: "simulation/templates/gaia/flora_tree_cretan_date_palm_tall.xml" ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' ERROR: Failed to load entity template 'gaia/flora_tree_cretan_date_palm_tall' GAME STARTED, ALL INIT COMPLETE 0ad-map-upgrade-20210222-01.py Edited Monday at 14:46 by andy5995 2 1 Quote Link to post Share on other sites
wowgetoffyourcellphone 6.394 Posted Monday at 16:30 Report Share Posted Monday at 16:30 1 hour ago, andy5995 said: gaia/flora_tree_cretan_date_palm_tall With these errors you can just use Notepad++ or your favorite text editor and do a ctrl-H replace all gaia/tree/cretan_date_palm_tall 1 Quote Link to post Share on other sites
andy5995 81 Posted Monday at 18:06 Author Report Share Posted Monday at 18:06 Thanks. I also want to give it some thought and see if it could be done with something like find . -name '*' -print -exec sed -i 's/gaia\/tree\/cretan_date_palm_tall/replacement-text/g' {} \; to fix all the files at once. I'll take a closer look later. Quote Link to post Share on other sites
Nescio 1.514 Posted Monday at 18:20 Report Share Posted Monday at 18:20 (edited) 21 hours ago, andy5995 said: Thanks. I also want to give it some thought and see if it could be done with something like find . -name '*' -print -exec sed -i 's/gaia\/tree\/cretan_date_palm_tall/replacement-text/g' {} \; to fix all the files at once. I'll take a closer look later. You should have a look at the patches that broke your maps, they have sed scripts to fix things: https://code.wildfiregames.com/D1009 https://code.wildfiregames.com/D1010 https://code.wildfiregames.com/D2234 https://code.wildfiregames.com/D2254 https://code.wildfiregames.com/D2774 https://code.wildfiregames.com/D3012 https://code.wildfiregames.com/D3097 Furthermore, you need to replace {civ}_* with {civ}/* (for structures and units). https://code.wildfiregames.com/P225 was used for that, though that script does more than you need, so it's probably better to write a sed script for that (there are only 13 civs). [EDIT] Here you go: Spoiler find binaries/data/mods/public/maps/ \( -name '*.js' -o -name '*.json' -o -name '*.xml' \) -print0 | xargs -0 sed -i \ -e 's,structures/athen_,structures/athen/,g' \ -e 's,structures/brit_,structures/brit/,g' \ -e 's,structures/cart_,structures/cart/,g' \ -e 's,structures/gaul_,structures/gaul/,g' \ -e 's,structures/iber_,structures/iber/,g' \ -e 's,structures/kush_,structures/kush/,g' \ -e 's,structures/mace_,structures/mace/,g' \ -e 's,structures/maur_,structures/maur/,g' \ -e 's,structures/pers_,structures/pers/,g' \ -e 's,structures/ptol_,structures/ptol/,g' \ -e 's,structures/rome_,structures/rome/,g' \ -e 's,structures/sele_,structures/sele/,g' \ -e 's,structures/spart_,structures/spart/,g' \ -e 's,units/athen_,units/athen/,g' \ -e 's,units/brit_,units/brit/,g' \ -e 's,units/cart_,units/cart/,g' \ -e 's,units/gaul_,units/gaul/,g' \ -e 's,units/iber_,units/iber/,g' \ -e 's,units/kush_,units/kush/,g' \ -e 's,units/mace_,units/mace/,g' \ -e 's,units/maur_,units/maur/,g' \ -e 's,units/pers_,units/pers/,g' \ -e 's,units/ptol_,units/ptol/,g' \ -e 's,units/rome_,units/rome/,g' \ -e 's,units/sele_,units/sele/,g' \ -e 's,units/spart_,units/spart/,g' And insert any other civs your mod has. [EDIT] There are probably some other things I forgot. Edited Tuesday at 16:06 by Nescio forgot D2234, D3012, D3097 1 Quote Link to post Share on other sites
Grapjas 60 Posted Monday at 21:14 Report Share Posted Monday at 21:14 (edited) If people need a little more guidance on how to convert their maps from a23 to a24 on windows: click start, type "cmd" type "python3" inside the command prompt and hit enter, it will open the microsoft app store directing you to the python app. Download and install that. Go to the directory where your skirmish map is. Put the file @andy5995 provided in there. Click the directory bar Spoiler Type cmd and hit enter Spoiler copy the following line and paste it inside the command prompt (including the dot at the end): python3 0ad-map-upgrade-20210222-01.py 7 . Done. Now you can open up your map again. Edited Tuesday at 01:38 by Grapjas 3 Quote Link to post Share on other sites
andy5995 81 Posted Tuesday at 14:25 Author Report Share Posted Tuesday at 14:25 19 hours ago, Nescio said: You should have a look at the patches that broke your maps, they have sed scripts to fix things: https://code.wildfiregames.com/D1009 https://code.wildfiregames.com/D1010 https://code.wildfiregames.com/D2254 https://code.wildfiregames.com/D2774 https://code.wildfiregames.com/D3012 Furthermore, you need to replace {civ}_* with {civ}/* (for structures and units). https://code.wildfiregames.com/P225 was used for that, though that script does more than you need, so it's probably better to write a sed script for that (there are only 13 civs). [EDIT] There are probably some other things I forgot. I ran all of these scripts. So far the only things I've noticed are a missing bench ERROR: Failed to load entity template 'other/bench' ERROR: CCacheLoader failed to find archived or source file for: "simulation/templates/other/bench.xml" (which I couldn't figure out how to fix) And the civs can't be changed from the game setup menu. When I uncheck the player name and civ from within Atlas, changes to the civ name are not saved. Quote Link to post Share on other sites
Grapjas 60 Posted Tuesday at 15:56 Report Share Posted Tuesday at 15:56 1 hour ago, andy5995 said: And the civs can't be changed from the game setup menu. When I uncheck the player name and civ from within Atlas, changes to the civ name are not saved. I noticed this too. I simply deleted them in the xml file and then you can change settings again @ game setup. Same story for teams, cant be changed either unless deleted in xml. "PlayerData": [ { }, { }, { }, { }, { }, { }, { }, { } ], 1 Quote Link to post Share on other sites
Nescio 1.514 Posted Tuesday at 16:05 Report Share Posted Tuesday at 16:05 1 hour ago, andy5995 said: I ran all of these scripts. So far the only things I've noticed are a missing bench ERROR: Failed to load entity template 'other/bench' ERROR: CCacheLoader failed to find archived or source file for: "simulation/templates/other/bench.xml" (which I couldn't figure out how to fix) That was D3097. I've now updated the previous post. 1 hour ago, andy5995 said: And the civs can't be changed from the game setup menu. When I uncheck the player name and civ from within Atlas, changes to the civ name are not saved. I'm not sure what you mean. 1 Quote Link to post Share on other sites
Stan` 7.017 Posted Tuesday at 16:07 Report Share Posted Tuesday at 16:07 2 minutes ago, Nescio said: And the civs can't be changed from the game setup menu. When I uncheck the player name and civ from within Atlas, changes to the civ name are not saved. Yeah I noticed that. Changing them work though unnasigning them doesn't. Quote Link to post Share on other sites
Grapjas 60 Posted Tuesday at 16:12 Report Share Posted Tuesday at 16:12 7 minutes ago, Nescio said: I'm not sure what you mean. If a civ has been set for a player inside Atlas you cannot change them ingame at the gamesetup. As if it were a scenario map even though it's a skirmish map. 1 Quote Link to post Share on other sites
wowgetoffyourcellphone 6.394 Posted Tuesday at 16:42 Report Share Posted Tuesday at 16:42 27 minutes ago, Grapjas said: If a civ has been set for a player inside Atlas you cannot change them ingame at the gamesetup. As if it were a scenario map even though it's a skirmish map. Not only that, but in Atlas you can uncheck the civs and save the map, but Atlas bugs and assigns default civs anyway. Quite annoying. 45 minutes ago, Grapjas said: noticed this too. I simply deleted them in the xml file and then you can change settings again @ game setup. Same story for teams, cant be changed either unless deleted in xml Yeah, I've had to do this as well. 2 Quote Link to post Share on other sites
andy5995 81 Posted Tuesday at 17:25 Author Report Share Posted Tuesday at 17:25 40 minutes ago, wowgetoffyourcellphone said: Not only that, but in Atlas you can uncheck the civs and save the map, but Atlas bugs and assigns default civs anyway. Quite annoying. Yeah, I've had to do this as well. I've noticed too that when editing the xml directly and removing the civ names, everything is fine. Then I open it in Atlas, make no changes, and click save. The civ names return. 2 Quote Link to post Share on other sites
Stan` 7.017 Posted Tuesday at 20:08 Report Share Posted Tuesday at 20:08 Not sure there is a ticket for it. Should be somewhat easy to debug and patch if someone has the time Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.