Results 1 to 10 of 10

Thread: Help needed: variantmeshdefinitions problem with my custom unit.

  1. #1

    Default Help needed: variantmeshdefinitions problem with my custom unit.

    Somebody's eyes better than mine?

    Can anyone help me out?






    My code looks like this

    <VARIANT_MESH>
    <SLOT name="base" >
    <VARIANT_MESH>
    <SLOT name="skin" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/skin/egyptian_skin.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="facial_hair" />
    <SLOT name="props" />
    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/armour/african_skirts.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="cloaks" />
    <SLOT name="greaves" />
    <SLOT name="shield" attach_point="weapon_03" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/shield/egyptian_shields.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_1" attach_point="weapon_01" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/weapons/short_spears.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_2" />
    <SLOT name="weapon_3" />
    <SLOT name="weapon_4" />
    </VARIANT_MESH>
    </SLOT>
    </VARIANT_MESH>




    Halp :'(

  2. #2
    Maximus183's Avatar Senator
    Join Date
    Oct 2008
    Location
    Magna Scandinavia
    Posts
    1,002

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    It's this part:

    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/armour/african_skirts.VariantMeshDefinition" />
    </SLOT>

    Under your reference for the helmets slot, you forgot to add </SLOT> which basically means that anything underneath the "helmets" > bit is considered one big reference, aka it wont work. It should look like this:

    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    ​</SLOT>
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/armour/african_skirts.VariantMeshDefinition" />
    </SLOT>

  3. #3

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    Quote Originally Posted by Maximus183 View Post
    It's this part:

    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/armour/african_skirts.VariantMeshDefinition" />
    </SLOT>

    Under your reference for the helmets slot, you forgot to add </SLOT> which basically means that anything underneath the "helmets" > bit is considered one big reference, aka it wont work. It should look like this:

    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    ​</SLOT>
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/armour/african_skirts.VariantMeshDefinition" />
    </SLOT>
    Thank you maximus! My eyesight is terrible :o MODDING IS HARD.

  4. #4

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    Quote Originally Posted by Maximus183 View Post
    It's this part:

    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/armour/african_skirts.VariantMeshDefinition" />
    </SLOT>

    Under your reference for the helmets slot, you forgot to add </SLOT> which basically means that anything underneath the "helmets" > bit is considered one big reference, aka it wont work. It should look like this:

    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    ​</SLOT>
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/armour/african_skirts.VariantMeshDefinition" />
    </SLOT>

    One more thing. The african tunic skirts show up but the african skirts do not. D: Why is this O' modly one?

  5. #5

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    D'oh I think i found it... man/armour/african_skirts
    Ithink it's meant to be tunics. I am sorry i am a bad coder and a total noob at this, but i want to get more efficient. Making an egyptian unit pack :3

  6. #6

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    OK! finally they're working but then HUGE DISSAPOINTMENT. Turns out CA hasn't modelled the bottom half of an egyptian torso. FFFFFFFFFFFFFFFFFFFFFFFFFFFFFUUUUUUUUUuuuuuuuuuuuuuuuuuuuuu

  7. #7

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    OK NEW QUESTION. How do I make a new full egpyptian skins variantmeshdefinition to have, say... the whiter looking african lower torso. Would it fit? Theoretically would I have to package a copy of the egyptian variantmeshdefinitions into my mod with the same directory (eg skins) rename it something different with more mesh components referenced such as africanlower torso or whatever it's called.. AND WOULD IT WORK?

  8. #8

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    Oh no i've gone crosseyed..

  9. #9
    Maximus183's Avatar Senator
    Join Date
    Oct 2008
    Location
    Magna Scandinavia
    Posts
    1,002

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    To my knowledge, there is no full body egyptian skin. The onle ones you could look at for that would be the barb_eastern (or something like that) in the skins category. There's different version of those I think that have either parts of- or the full body modelled.

  10. #10
    Dude with the Food's Avatar Campidoctor
    Join Date
    Oct 2012
    Location
    Round the Corner.
    Posts
    1,800

    Default Re: Help needed: variantmeshdefinitions problem with my custom unit.

    I've ended up with both of your problems and I think I can give the head's up about something else you might otherwise run into.

    This is with the changes to your original in this thread.
    Spoiler Alert, click show to read: 
    <VARIANT_MESH>
    <SLOT name="base" >
    <VARIANT_MESH>
    <SLOT name="skin" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/skin/egyptian_skin.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="facial_hair" />
    <SLOT name="props" />
    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_skirts.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="cloaks" />
    <SLOT name="greaves" />
    <SLOT name="shield" attach_point="weapon_03" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/shield/egyptian_shields.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_1" attach_point="weapon_01" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/weapons/short_spears.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_2" />
    <SLOT name="weapon_3" />
    <SLOT name="weapon_4" />
    </VARIANT_MESH>
    </SLOT>
    </VARIANT_MESH>


    This is what it will possible end up like.
    Spoiler Alert, click show to read: 
    <VARIANT_MESH>
    <SLOT name="base" >
    <VARIANT_MESH>
    <SLOT name="skin" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/skin/egyptian_skin.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/skin/"whatever full torso you use".VariantMeshDefinition" />

    </SLOT>
    <SLOT name="facial_hair" />
    <SLOT name="props" />
    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_skirts.VariantMeshDefinition" />

    </SLOT>
    <SLOT name="cloaks" />
    <SLOT name="greaves" />
    <SLOT name="shield" attach_point="weapon_03" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/shield/egyptian_shields.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_1" attach_point="weapon_01" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/weapons/short_spears.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_2" />
    <SLOT name="weapon_3" />
    <SLOT name="weapon_4" />
    </VARIANT_MESH>
    </SLOT>
    </VARIANT_MESH>


    However, this will mean half the men get full bodies and half get the skirts. So a quarter will have full bodies and tunics and another quarter will have the missing bodies and skirts.

    This is what you'll need if you want to mix skirts and tunics.
    Spoiler Alert, click show to read: 
    <VARIANT_MESH>
    <SLOT name="base" >
    <VARIANT_MESH>

    <SLOT name="skin" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/skin/egyptian_skin.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="facial_hair" />
    <SLOT name="props" />
    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_tunic_skirts.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="cloaks" />
    <SLOT name="greaves" />
    <SLOT name="shield" attach_point="weapon_03" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/shield/egyptian_shields.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_1" attach_point="weapon_01" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/weapons/short_spears.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_2" />
    <SLOT name="weapon_3" />
    <SLOT name="weapon_4" />
    </VARIANT_MESH>
    <VARIANT_MESH>

    <SLOT name="skin" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/skin/"whatever full torso you use".VariantMeshDefinition" />
    </SLOT>
    <SLOT name="facial_hair" />
    <SLOT name="props" />
    <SLOT name="helmets" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/helmets/egyptian_headresses.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="clothing" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/tunics/african_skirts.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="cloaks" />
    <SLOT name="greaves" />
    <SLOT name="shield" attach_point="weapon_03" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/shield/egyptian_shields.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_1" attach_point="weapon_01" >
    <VARIANT_MESH_REFERENCE definition="VariantMeshes/_VariantModels/man/weapons/short_spears.VariantMeshDefinition" />
    </SLOT>
    <SLOT name="weapon_2" />
    <SLOT name="weapon_3" />
    <SLOT name="weapon_4" />
    </VARIANT_MESH>
    </SLOT>

    </VARIANT_MESH>


    I've bolded all the bits of importance.
    Spoiler Alert, click show to read: 
    I am me. You are not me. You are you. If I was you, I wouldn't be me.
    If you were me, I'd be sad.But I wouldn't then be me because you'd be me so you wouldn't be me because I wasn't me because you were me but you couldn't be because I'd be a different me. I'd rather be any kind of bird (apart from a goose) than be you because to be you I'd have to not be me which I couldn't do unless someone else was me but then they would be you aswell so there would still be no me. They would be you because I was you so to restore balance you would have to be me and them meaning all three of us would become one continously the same. That would be very bad.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •