Jump to content

Props with meshes without textures and textures without meshes?


Recommended Posts

Hello!

I am making a tile-based game based on 0ad assets, and I'm having some trouble rendering some actors.

For example, structures/persians/stable.xml has a props/structures/persians/stable_horse_a.xml prop in the first group, but the first group in that file only has a mesh (skeletal/horse_persian.dae), and no textures. The mesh does have UV coordinates so I assume there's a texture that should be applied? What textures would be used here?

Also, the second group in stable_horse_a.xml has a bunch of variants in separate files, and quadraped/horse/stable/brown.xml for example has a base texture without a mesh. How does that work?

Thanks!

Link to post
Share on other sites

The game has a mechanism that allows to load models and apply textures later meaning that no .dae file contains any directly.

The variants add a randomized texture and/or props to the model.
As for the quadraped files, those are animations that a model is capable of doing and are defined in the .dae.

You can find every single texture in the following path: 

0.A.D -> binaries -> data -> mods -> puplic -> art -> textures

If you can't figure out which is which, go into the actors folder and read the .xml file you need as it contains the path to the texture of it.

  • Like 1
Link to post
Share on other sites
3 minutes ago, Panther said:

The game has a mechanism that allows to load models and apply textures later meaning that no .dae file contains any directly.

The variants add a randomized texture and/or props to the model.
As for the quadraped files, those are animations that a model is capable of doing and are defined in the .dae.

You can find every single texture in the following path: 


0.A.D -> binaries -> data -> mods -> puplic -> art -> textures

If you can't figure out which is which, go into the actors folder and read the .xml file you need as it contains the path to the texture of it.

Oh I see! I had the wrong mental model of how actors work. I thought each variant chosen in each group is supposed to be self contained and rendered separately. I was able to render a lot of structures that way (because they have both mesh and textures in the same variant), but not props.

This makes a lot more sense. Does that mean once all the variants are resolved for an actor, there should always be one mesh, one set of textures, and zero or more props that should be recursively rendered as their own actors, and attached to the parent actor mesh at the specified node?

Link to post
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.

×
×
  • Create New...