Page 1 of 3 123 LastLast
Results 1 to 20 of 54

Thread: What's wrong with my unit? (Finally solved!)

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Icon14 What's wrong with my unit? (Finally solved!)

    I tried to create Castle Militia out of the Town Militia unit. First I loaded the Swordsmen Militia in to Milkshape and removed everything except the Sword. Then I exported it as an .obj file.

    Then I opened up all four Town Militia meshes, deleted the spear, imported the sword .obj and saved it and converted it back to a .mesh file.

    Everything looks good with the model, except when I start the game the men are just standing there with their hands out like a cross. Just like in they do in Milkshape. When they move they float around like ghosts. And some parts where invisible, depending on what angle I was viewing them from.

    I added this to the EDU:

    type Castle Militia
    dictionary Castle_Militia ; Castle Militia
    category infantry
    class light
    voice_type Light
    banner faction main_infantry
    banner holy crusade
    soldier Castle_Militia, 60, 0, 0.25
    attributes sea_faring, hide_forest, can_withdraw, free_upkeep_unit
    formation 1.2, 1.2, 2.4, 2.4, 5, square
    stat_health 1, 0
    stat_pri 5, 2, no, 0, 0, melee, melee_blade, piercing, sword, 0, 0.35
    ;stat_pri_ex 0, 0, 0
    stat_pri_attr no
    stat_sec 0, 0, no, 0, 0, no, melee_simple, blunt, none, 0, 0.35
    ;stat_sec_ex 0, 0, 0
    stat_sec_attr no
    stat_pri_armour 0, 9, 5, flesh
    ;stat_armour_ex 0, 4, 5, 0, 1, 6, 6, flesh
    stat_sec_armour 0, 0, flesh
    stat_heat 2
    stat_ground 1, -2, 3, 2
    stat_mental 3, normal, trained
    stat_charge_dist 30
    stat_fire_delay -2500
    stat_food 60, 300
    stat_cost 1, 290, 125, 75, 60, 290, 4, 70
    armour_ug_levels 0, 1, 2
    armour_ug_models Castle_Militia
    ownership england
    ;unit_info 5, 0, 7

    And this to the modeldb:

    14 castle_militia
    1 4
    61 unit_models/_Units/EN_Peasant_Padded/castle_militia_lod0.mesh 121
    61 unit_models/_Units/EN_Peasant_Padded/castle_militia_lod1.mesh 900
    61 unit_models/_Units/EN_Peasant_Padded/castle_militia_lod2.mesh 2500
    61 unit_models/_Units/EN_Peasant_Padded/castle_militia_lod3.mesh 6400
    1
    7 england
    79 unit_models/_Units/EN_Peasant_Padded/textures/EN_Peasant_Padded_england.texture
    78 unit_models/_Units/EN_Peasant_Padded/textures/EN_Peasant_Padded_normal.texture
    49 unit_sprites/england_Dummy_EN_Spearmen_sprite.spr
    1
    7 england
    68 unit_models/AttachmentSets/Final European Light_england_diff.texture
    68 unit_models/AttachmentSets/Final European Light_england_norm.texture 0
    1
    4 None
    14 MTW2_Swordsman 0
    2
    18 MTW2_Sword_Primary
    14 fs_test_shield 0
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002

    I tried switching '49 unit_sprites/england_Dummy_EN_Spearmen_sprite.spr' with '49 unit_sprites/england_Armored_Swordsmen_sprite.spr ' but it was still the same.

    I am totally new to all this, so there is probably an easy explanation I have not yet discovered that some of you might know. I hope
    Last edited by zowrath; August 12, 2007 at 07:36 AM.

  2. #2

    Default Re: What's wrong with my unit?

    did you delete the skeleton, too when you deleted everything from the sword militia except for the sword...I made that mistake sometimes with my holites and it was leading to the same result.
    Prof's Mods (Attila Mods)
    Creator of Polemarchia: Total War
    Under the patronace of Epistolary Richard
    <- Now with Attila screens

  3. #3

    Default Re: What's wrong with my unit?

    Quote Originally Posted by Prof View Post
    did you delete the skeleton, too when you deleted everything from the sword militia except for the sword...I made that mistake sometimes with my holites and it was leading to the same result.
    I think I did, I am not quite sure how to do that but the only one thing left in the obj is the sword. Have a look here at the attachment here.
    Last edited by zowrath; August 28, 2007 at 11:37 AM.

  4. #4
    Csatádi's Avatar Senator
    Join Date
    Sep 2005
    Location
    Budapest, Hungary, EU
    Posts
    1,153

    Default Re: What's wrong with my unit?

    Quote Originally Posted by Prof View Post
    did you delete the skeleton, too when you deleted everything from the sword militia except for the sword...I made that mistake sometimes with my holites and it was leading to the same result.
    How can I delete the skeleton?

  5. #5

    Default Re: What's wrong with my unit?

    Quote Originally Posted by Csatádi View Post
    How can I delete the skeleton?
    If you have the "jesus" syndrome, did you use Milkshape to merge any files or did you use GOM's tool? Because the JS appeared for me when I used Milkshape. When I used GOM's tool to merge it went just fine.

  6. #6
    Csatádi's Avatar Senator
    Join Date
    Sep 2005
    Location
    Budapest, Hungary, EU
    Posts
    1,153

    Default Re: What's wrong with my unit? (Finally solved!)

    Prof said how to delete skeleton. Big thanks, Prof.
    My question is only:

    How can I assign weapons to joints? (I detailed this in this thread)

    The process as detailed in this thread doesn't work in that way.

  7. #7
    STReetSamurai's Avatar Miles
    Join Date
    Jul 2007
    Location
    Paktika Province
    Posts
    312

    Default Re: What's wrong with my unit?

    Haha, your units broken.

    think about it.

  8. #8

    Default Re: What's wrong with my unit?

    Quote Originally Posted by STReetSamurai View Post
    Haha, your units broken.

    think about it.
    Read the whole post my friend. The sword is just a sword, it is supposed to be that. But the other unit which I did not post here is a whole unit just missing one weapon. It is when I import the weapon the unit stop functioning as it should. As far as I can tell. So if any other people have any better ideas, I am all ears.

  9. #9
    Alletun's Avatar Artifex
    Join Date
    Jan 2007
    Location
    Denmark
    Posts
    584

    Default Re: What's wrong with my unit?

    click your imported sword in milkshape, then click "comment" (in the Groups tab). it should say something like:
    Sword
    Sword_01
    0

    if not, write it. Sword_01 is the name on your sword group.

    Then after you've done that select your sword (by clicking the group and then the select button) and click over to the Joints tab. Find the bone called weapon01 or something (3rd from the bottom) then click the Assign button. now you've assigned your sword to the hand and you've told the game how to handle it. it should now work

    REMEMBER: all faces on a model must be assigned to a bone or you'll get the jesus syndrom AND all groups must have a comment.
    Last edited by Alletun; August 10, 2007 at 02:24 AM.
    Unit makers Tome of Knowledge:
    http://www.twcenter.net/forums/showthread.php?t=127787
    Warhammer: Total war modeller. Orc & Goblins (GREENSKINS!) creator
    http://forums.totalwar.org/vb/showthread.php?t=90663&page=2
    Third Age: Total war. Modeling and Skinning. Working on Isengard.

  10. #10

    Icon7 Re: What's wrong with my unit?

    Quote Originally Posted by Alletun View Post
    REMEMBER: all faces on a model must be assigned to a bone or you'll get the jesus syndrom AND all groups must have a comment.

    Jesus syndrome, haha, I laughed so hard I almost fell off my chair. My colleagues wondered if I lost it. But yeah, that's what it looks like.

    So basicly when I removed the spear from the Town Militia, saved, imported the Sword, saved, all assignments where lost and I have to attach them again? I will have a go after I return from work. Thank you so much for your information. It is nice, because I am just learning how to do this. It is fun!

  11. #11
    Alletun's Avatar Artifex
    Join Date
    Jan 2007
    Location
    Denmark
    Posts
    584

    Default Re: What's wrong with my unit?

    Go to the joints tab and click "draw vertices with bone color". you'll probably see that your sword is gray while the rest looks like a colorblind person went crazy with a brush. after you've assigned your sword to the weapon bone your sword should be .. blue i think, can't remember.

    also did you use milkshape's merge function of GoM's merge function? you must use GoM's because milkshape will load everything twice (so there are two skeletons, instead of only one)
    Unit makers Tome of Knowledge:
    http://www.twcenter.net/forums/showthread.php?t=127787
    Warhammer: Total war modeller. Orc & Goblins (GREENSKINS!) creator
    http://forums.totalwar.org/vb/showthread.php?t=90663&page=2
    Third Age: Total war. Modeling and Skinning. Working on Isengard.

  12. #12

    Default Re: What's wrong with my unit?

    Ok, returned from work and did as described and now it works. Although the texture of the sword looks pretty weird. Grey with black spots in various sizes on it. Is that a texture related issue only? Maybe I can't use the peasant texture for it?

  13. #13
    Alletun's Avatar Artifex
    Join Date
    Jan 2007
    Location
    Denmark
    Posts
    584

    Default Re: What's wrong with my unit?

    most probably thats a problem with the UV map. the unit that you took the sword from has a different attachmentSet texture than your new unit. what you do is:
    in milkshape Set the texture for "Attachments" to be whatever it says in your modelDB file.
    eg:
    1
    6 france
    67 unit_models/AttachmentSets/Final European Light_france_diff.texture
    67 unit_models/AttachmentSets/Final European Light_france_norm.texture 0

    convert Final European Light_france_diff.texture to a dds file and put it in milkshape (go to materials tab and click the top of the <none> buttons).

    then you select all faces in your sword and go to Window->Texture Coordinate Editor, in the new window you select the sword from the dropdown menu. the UV-map that now appear can be moved around. find a sword you like and place it over it.
    your sword will now look as it should.
    Last edited by Alletun; August 10, 2007 at 08:58 AM.
    Unit makers Tome of Knowledge:
    http://www.twcenter.net/forums/showthread.php?t=127787
    Warhammer: Total war modeller. Orc & Goblins (GREENSKINS!) creator
    http://forums.totalwar.org/vb/showthread.php?t=90663&page=2
    Third Age: Total war. Modeling and Skinning. Working on Isengard.

  14. #14

    Icon7 Re: What's wrong with my unit?

    Holy cow m8, it all works You are the best. You know, this small thread in itself is a tutorial for many!

    If I want to change the armor itself, I recon I open that dds in the top <none> button under Figure and edit there? Just my guess.

    I will attach the file here, if you want to have a look. But I think I got it all covered now for this unit.

    One thing I wonder though, why are there 4 lod's? Is it for diversity of the soldiers? And that's why I need to change all of them? Can I just change one, and rename the rest 1,2,3 and so on?

    Thank you for all help, so far. I might come running to you more though, hehe.
    Last edited by zowrath; August 28, 2007 at 11:37 AM.

  15. #15
    Alletun's Avatar Artifex
    Join Date
    Jan 2007
    Location
    Denmark
    Posts
    584

    Default Re: What's wrong with my unit?

    As far as i know, LoD stands for Level of Detail. Lod0 is the model that is displayed ingame when you are very close to the unit. it has the most faces and looks the best, while lod3 is displayed just before the game goes over to sprites (2d thingys) and has considerably fewer faces. This is good if you have a slower computer. it's not required that you use different LoDs, in fact you can just write, in modelDB:
    16 hungarian_nobles
    1 4
    60 unit_models/_Units/LB_Plain_Fancy/hungarian_nobles_lod0.mesh 121
    60 unit_models/_Units/LB_Plain_Fancy/hungarian_nobles_lod0.mesh 900
    60 unit_models/_Units/LB_Plain_Fancy/hungarian_nobles_lod0.mesh 2500
    60 unit_models/_Units/LB_Plain_Fancy/hungarian_nobles_lod0.mesh 6400

    or just

    16 hungarian_nobles
    1 4
    60 unit_models/_Units/LB_Plain_Fancy/hungarian_nobles_lod0.mesh 6400

    and it uses the same model at all distances. (the number to the right of the line is the distance at which the model shows.)
    Unit makers Tome of Knowledge:
    http://www.twcenter.net/forums/showthread.php?t=127787
    Warhammer: Total war modeller. Orc & Goblins (GREENSKINS!) creator
    http://forums.totalwar.org/vb/showthread.php?t=90663&page=2
    Third Age: Total war. Modeling and Skinning. Working on Isengard.

  16. #16

    Default Re: What's wrong with my unit?

    Ok. Again, thank you for all the help you have provided. I have learned more in this thread alone than i have in countless hours of browsing the web

  17. #17
    Csatádi's Avatar Senator
    Join Date
    Sep 2005
    Location
    Budapest, Hungary, EU
    Posts
    1,153

    Default Re: What's wrong with my unit? (Finally solved!)

    Looks cool!
    Could you send me the mesh files?
    This would be only the first step of the remodelling process but I would be able to insert it in the mod for testing purposes.

  18. #18
    joedreck's Avatar Artifex
    Join Date
    Jan 2007
    Location
    Frankfurt am Main
    Posts
    2,009

    Default Re: What's wrong with my unit? (Finally solved!)

    how can i change the horse models? i would like to give the christus knights the barded horses.
    Edictum mod adds new edicts to Rome II. http://www.twcenter.net / YouTube: Edictum Mod / Click here for Edictum Mod on steam
    Vote Brain Slug for president.

  19. #19
    Alletun's Avatar Artifex
    Join Date
    Jan 2007
    Location
    Denmark
    Posts
    584

    Default Re: What's wrong with my unit? (Finally solved!)

    look in the EDU under "mount" in the units entry
    Unit makers Tome of Knowledge:
    http://www.twcenter.net/forums/showthread.php?t=127787
    Warhammer: Total war modeller. Orc & Goblins (GREENSKINS!) creator
    http://forums.totalwar.org/vb/showthread.php?t=90663&page=2
    Third Age: Total war. Modeling and Skinning. Working on Isengard.

  20. #20
    joedreck's Avatar Artifex
    Join Date
    Jan 2007
    Location
    Frankfurt am Main
    Posts
    2,009

    Default Re: What's wrong with my unit? (Finally solved!)

    i've got it. my idea is to make for the hre teutonic units their own barded horse.
    how can i make it? is it the same like a new unit? i make all and the system have an error in the edu. here are the importent things:

    EDU
    type Komtur Knights
    dictionary Komtur_Knights ; Komtur Knights
    category cavalry
    class heavy
    voice_type Heavy
    banner faction grudenc
    soldier Komtur_Knights, 24, 0, 1
    mount komtur horse

    battle_modeldb

    18 mount_komtur_horse
    1.12 3
    60 unit_models/Mounts/Komtur_Horse/mount_komtur_horse_lod0.mesh 121
    60 unit_models/Mounts/Komtur_Horse/mount_komtur_horse_lod1.mesh 1225
    60 unit_models/Mounts/Komtur_Horse/mount_komtur_horse_lod2.mesh 10000
    1
    3 hre
    65 unit_models/Mounts/komtur_horse/textures/komtur_horse_hre.texture
    68 unit_models/Mounts/Barded_Horse/textures/Barded_Horse_normal.texture
    46 unit_sprites/hre_Mount_Barded_Horse_sprite.spr
    1
    5 Horse
    14 fs_heavy_horse 0
    0 0 -1 0 0 0 0 0 0
    System.log
    22:28:42.576 [script.err] [error] Script Error in mods/retrofit/data/export_descr_unit.txt, at line 15321, column 18
    Unrecognised mount type 'komtur horse'.
    Edictum mod adds new edicts to Rome II. http://www.twcenter.net / YouTube: Edictum Mod / Click here for Edictum Mod on steam
    Vote Brain Slug for president.

Page 1 of 3 123 LastLast

Posting Permissions

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