Jump to content

Strange issue with Docks when making a new Civ; not recognizing Civ specific ships?


Jackerino
 Share

Recommended Posts

I'm working on a mod that adds new Civs based on various fantasy races and every other structure and building and training setup has worked so far.  However, I have ran into an issue with making new Docks for my Civilization.

Specifically, the issue I ran into was I made the Dock structure itself, which functions correctly and gets all of the Upgrades the way it's supposed to.  However, despite having a functional ship_fishing.xml in the correct location with the correct labels, and with the dock.xml having everything labelled correctly, the fisherman boat doesn't show up on the menu for the docks.  I'm honestly at a loss for what the issue is.

Everything is set up correctly as far as I know, with most of it being direct copy/pastes of the Mauryan structure and unit templates before I started adding changes, with the Civ tags changed to be the correct label so that they are labelled under the correct Civilization.  Even more bafflingly, in the information tab of the docks, it shows that it can train fisherman boats, yet it doesn't actually show up on the UI, for some strange reason.

Any help or information would be greatly appreciated.  Can't really make any naval ships until I figure out what's causing this issue.  Worst case scenario, this Civ won't be able to have a Navy, which would be unfortunate.

(Shown below is screenshots of the evidence + the attached offending .xml's)

Screenshot 2025-10-04 023557.png

Screenshot 2025-10-04 023612.png

dock.xml ship_fishing.xml

Screenshot 2025-10-04 025030.png

Edited by Jackerino
clarification stuff
Link to comment
Share on other sites

33 minutes ago, Jackerino said:

I'm working on a mod that adds new Civs based on various fantasy races and every other structure and building and training setup has worked so far.  However, I have ran into an issue with making new Docks for my Civilization.

Specifically, the issue I ran into was I made the Dock structure itself, which functions correctly and gets all of the Upgrades the way it's supposed to.  However, despite having a functional ship_fishing.xml in the correct location with the correct labels, and with the dock.xml having everything labelled correctly, the fisherman boat doesn't show up on the menu for the docks.  I'm honestly at a loss for what the issue is.

Everything is set up correctly as far as I know, with most of it being direct copy/pastes of the Mauryan structure and unit templates before I started adding changes, with the Civ tags changed to be the correct label so that they are labelled under the correct Civilization.  Even more bafflingly, in the information tab of the docks, it shows that it can train fisherman boats, yet it doesn't actually show up on the UI, for some strange reason.

Any help or information would be greatly appreciated.  Can't really make any naval ships until I figure out what's causing this issue.  Worst case scenario, this Civ won't be able to have a Navy, which would be unfortunate.

(Shown below is screenshots of the evidence + the attached offending .xml's)

Screenshot 2025-10-04 023557.png

Screenshot 2025-10-04 023612.png

dock.xml 452 B · 0 downloads ship_fishing.xml 474 B · 0 downloads

Screenshot 2025-10-04 025030.png

 

You must first make a template and see how patent templates work.

 

Then make sure your unit exists as a base unit, for example a new ship needs 2 new files to work.

A parent ( class)  and civ unit specific template.

 

<Trainer>

    <BatchTimeModifier>0.8</BatchTimeModifier>

    <Entities datatype="tokens">

      units/{civ}/ship_fishing

      units/{civ}/ship_merchant

      units/{civ}/ship_scout

      units/{civ}/ship_arrow

      units/{civ}/ship_ram

      units/{civ}/ship_fire

      units/{civ}/ship_siege

    </Entities>

  </Trainer>

You need this is parent template or in specific template.

https://gitea.wildfiregames.com/0ad/0ad/src/branch/main/binaries/data/mods/public/simulation/templates/template_structure_military_dock.xml

 

Edited by Classic-Burger
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...