Jump to content

pyrothagorus

Community Newbie
  • Posts

    2
  • Joined

  • Last visited

Everything posted by pyrothagorus

  1. Thanks for your help. I've included the error message I was getting below for completeness, but I realise what I had done wrong. The template I used as the base was from the current live repo, which has edits that aren't in version 0.27.1 ("health_females_01" being renamed to "health_civilians_01"). <!DOCTYPE html> <meta charset="utf-8"> <title>Pyrogenesis Log</title> <style>body { background: #eee; color: black; font-family: sans-serif; } p { background: white; margin: 3px 0 3px 0; } .error { color: red; } .warning { color: blue; }</style> <h2>0 A.D. (0.27.1) Main log (warnings and errors only)</h2> <p class="error">ERROR: File 'simulation/data/technologies/health_civilians_01.json' does not exist</p> <p class="error">ERROR: JavaScript error: gui/reference/common/TemplateLoader.js line 114 data is undefined loadTechnologyTemplate@gui/reference/common/TemplateLoader.js:114:8 isPairTech@gui/reference/common/TemplateLoader.js:310:17 deriveProduction@gui/reference/common/TemplateLoader.js:173:14 deriveTemplateListsFromTemplate@gui/reference/common/TemplateLister.js:126:45 compileTemplateLists@gui/reference/common/TemplateLister.js:40:21 setActiveCiv@gui/reference/common/ReferencePage.js:26:51 selectTemplate@gui/reference/viewer/ViewerPage.js:38:9 init@gui/reference/viewer/viewer.js:18:9 showTemplateDetails@gui/session/selection_panels.js:1272:15 showTemplateFunc@gui/session/selection_panels.js:194:53</p> <p class="error">ERROR: GUI page 'page_viewer.xml': Failed to call init() function</p> Regarding the zip file, you're correct that the zip extract created an additional folder layer. But my point its that's the way most zip applications work, so the user workflow fails by default. As the mod.io zip files contain an mod.json plus a zip file, and then the zip file contains the same mod.json, I just think it's a bit confusing for someone first dipping their toes into modding.
  2. I've been enjoying playing 0AD recently, so I thought I'd try my hand at modding. I thought I'd start simple, and because I always find that I've not built enough houses, I thought I'd tweak the population bonus of the civic centre template. I've created a mod with the required mod.json and ./simulation/templates/template_structure_civic_civil_centre.xml. It works, in the sense that the population bonus is higher when I run the game with the mod. But it seems to break all the unit/structure right click info windows. Loads of error messages pop up in the game console when I right click on a unit icon in a build menu. I've seen some mention in the modding guide of having to save/reload, but that wasn't 100% clear. In any case I've opened/closed 0AD several times. Game version is 0.27.1, running on Linux Mint. How do I get the error messages outside of 0AD? I hoped there'd be some logs in ./local/share/0ad, but can't see anything in there. Grateful for any help. Also, on newbies starting modding, the user experience / guidance could probably do with some tweaking. My route into modding was to use the in-game mod.io downloader. I then tested the mod to see if it was working in the game. Then went into ./local/share/0ad/mods to edit it. I extracted the zip file and started playing around. No effect. I figured the game engine reads from the zip rather than folders by default, so I deleted the zip. And then the mod doesn't do anything any more. I finally realised that extracting the zip downloaded via mod.io doesn't generate the right folder structure. I think the below line from the tutorial is trying to get at this point, but it's not the clearest, particularly given the common definition of zip bomb: https://en.wikipedia.org/wiki/Zip_bomb. If you extract the mod so you can further work on it beware a properly packaged mod is a zip-bomb.
×
×
  • Create New...