Results 1 to 28 of 28

Thread: Milkshape ms3d importer/exporter for 3ds Max and Gmax

  1. #1
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Milkshape ms3d importer/exporter for 3ds Max and Gmax

    In between tearing our hair out over animation problems with offset horse
    meshes, Bwian and I have been working on an importer/exporter of
    Milkshape .ms3d files into 3ds Max and Gmax. All the OBVIOUS bugs seem
    to be gone now so consider this an alpha release. You can find the script
    and some other files here:

    http://www.twcenter.net/forums/downl...o=file&id=1718

    The zip file contains the MaxScript ms3dimportexport_ver1_0.ms,
    a readme.txt file, and two files needed by Gmax users but not by
    3ds Max users. The script can be placed in your scripts subdirectory
    or any place convenient to your workflow. Click the Max Script menu item,
    then Run Script, then mouse to the directory containing
    ms3dimportexport.ms and double click to run it. It will display a simple
    rollout with import and export buttons.

    Importing will bring in all the mesh data, bones, bone assignments and
    vertex weighting, along with the bounding sphere and group names,
    types, and flags needed to reconstruct a mesh file. Details are covered
    in the Technical bits below.

    Animations can be done with the Python animation utility animmerge and
    then imported the same way as a regular model. After modification,
    the animated model can be exported and the new animations extracted
    to a cas file with the animextract utility.

    Regular units, mounts, and siege engines are supported as are their
    animated versions except for siege engines (the animation utilities
    don't support animating siege engines).

    Please report any bugs you find here or send a PM. I don't have a copy
    of 3ds Max so if problems come up in the part of the code that writes
    the binary .ms3d file, we'll have to work together on that.
    (Gmax can't write files.)


    Acknowledgements:

    Bwian for getting me started with Gmax and sending a link to Vercingetorix's script.

    Vercingetorix for writing the wonderful script in the first place.

    Aymar de Bois Mauri for explaining that "groups" in 3ds Max can only be made by making multiple meshes,
    a conceptual roadblock for me coming from Milkshape.

    GrumpyOldMan for sending along the listener data grabbing utility: GmaxSLGRAB.exe (discussed below).


    Technical Bits for Gmax Users:
    ------------------------------

    Spoiler Alert, click show to read: 
    (1) The export procedure for Gmax:

    Among the many runtime features turned off in Gmax, the ability to write
    ASCII or binary files is one of the most frustrating things to lose. The
    procedure I've seen other authors do for Gmax is export to the listener
    window and then cut and paste into a text file. Fortunately,
    GrumpyOldMan heard my pain and found a utility that does this for you.
    This has been included in the zip file and is called GMaxSLGRAB.exe. Once
    you have exported to the listener double click this file. It displays a small
    Window with one big button with "grab" as the label. Click the
    "grab" button and it copies the data from the listener and prompts
    you for a filename to save it to. Note that it supplies an .xml filter but
    my recommendation is to explicitely type a .txt extension for your filename
    to override this. It will warn you if you are going to overwrite an existing
    file and it displays "done" after writing the file.

    Now your data is out but in a useless made up format of mine. Now you
    run the supplied Python utility ascii2ms3dconverter.py by either double
    clicking it or right clicking and selecting open. It pops up a filechooser
    and you select the text file you just made and it reads the data and
    converts it to binary .ms3d format. Only slightly more complicated
    than the 3ds Max way.

    (2) Exporting big models clobbers the listener window, here's a workaround:

    Cut and paste the following into a file and name it clearlistener.mcr.

    macroScript clearListener
    category:"Helpers and Gizmos"
    internalcategory:"Helpers and Gizmos"
    tooltip:"Clear Listener"
    ButtonText:"Clear Listener"
    Icon:#("Helpers",1)
    (
    on execute do clearlistener()
    )


    Place it in your ui\macroscripts directory. In Gmax click the customize menu
    item and then select customize user interface. In the dialog that pops up
    click the toolbars tab and scroll down until you see clearlistener, click and
    drag it to your main toolbar. Then click the save button to update your
    configuration. Now when the listener gets filled up by an export and won't
    allow you to type in it, you can hit this button to clear it.



    Technical Bits for All Users:
    -----------------------------

    Spoiler Alert, click show to read: 
    (1) Where's the data stored?

    In Milkshape the group name, type, and flag are stored in the group
    comments and the bounding sphere data is stored in the model comment.
    In 3ds Max and Gmax the name of a given mesh is the group name and
    the group type and flag are stored in user defined properties. To see them
    select the mesh with the Select Objects dialog, then under the edit menu
    item select Object Properties, then select the User Defined tab to see
    the group name and flag. The bounding sphere is stored in the root bone:
    bone_pelvis for humanoids, bone_H_Saddle for horses, bone_camel_root
    for camels, bone_E_platform for elephants, and USUALLY bone_body for
    siege engines. The bounding sphere is stored as ASCII floats joined by
    % signs. (Oddity of Gmax, maybe of 3ds Max, you can store strings with
    spaces in User Properties and see them there, but only the first whole
    word comes back out, hence the need to make strings with no spaces.)

    When dealing with animated files, the .cas header, hierarchy, and footer
    strings are stored in the first three joint comments in Milkshape.
    In 3ds Max and Gmax they are stored in the root bone as well and you
    can see them in User Properties. They also are ASCII format numbers
    joined by percent signs. Underscores would have looked better but
    texture paths for siege engines have underscores so I couldn't use
    them because I tokenize the string based on the chosen delimeter.
    Naturally for siege engines, the three texture paths are stored here,
    it's just that their keywords are: animheader, animhierarchy, and
    animfooter. This may change if I get animation utilities to work with
    siege engines.


    (2) Known Deficiencies:

    The script works on unanimated regular units converted by GrumpyOldMan's
    converter and unanimated mounts and siege engines converted by my
    Python converter. It also works for animated regular units and mounts.
    It WON'T work for animated siege engines because I store the three
    texture paths for siege engines in the joints comments but I also
    store the .cas file animation headers, hierarchy, and footers in the joints comments. Haven't worked through this conflict yet.

    Not a deficiency of this script but if people are going to start using the
    Python animation utilities (version 1_1 uploaded June 18, 2007) there are
    three known bugs.
    1 - on line 1092 in the animextract function there's this extraneous entry
    float_vec3.fromfile( fidcas, 7 )
    I can't fathom how it got there, it wasn't there when I tested everything.
    Just comment it out with a pound sign like
    # float_vec3.fromfile( fidcas, 7 )

    2 - Converttxttocas doesn't convert the degrees back to radians. Oops,
    it's fixed just have to post an updated copy.

    3 - I didn't check for uppercase extensions so some cas files that look like
    name.CAS
    don't get exported to. Bwian found this one in the exportskeleton function. Also fixed just not released.


    (3) Modifier Stack:

    The export only works if the skin is at the top of the modifier stack for
    each mesh in the model. You can do this manually by clicking and holding
    the modifier and moving it. A "feature" of Gmax at least is that if you do
    this to the skin modifier to move it to the top of the stack it loses all
    its information about bone assignments and weighting. On the other hand,
    if you manually move all other modifiers below the skin modifier, the
    information is retained and the export works. I've duplicated this procedure
    in the script so that if the skin modifier is NOT at the top of the stack,
    I make full copies of all the modifiers above the skin modifier, delete
    the originals so that the skin modifier is at the top, and then recreate
    the other modifiers, in order, below the skin modifier. The script will
    stop and ask if you want it to do this procedure or to terminate.


    (4) Trying to reconstruct the basepose on exporting an animated model:

    Having used Milkshape first I expected animated files to look the same way
    in Gmax, that is, be in the basepose and only change to animations when
    you hit the animate button. Bwian explained this isn't the way it works,
    animations are just done differently between the two. If I simply exported
    the same way I did a regular model I get the vertex positions of whatever
    frame happens to be displayed at the time. If you opened this is Milkshape
    you'd see the bones in the basepose and a distorted mesh. The animations
    are perfectly good and you can run animextract to make a perfectly good
    .cas file but this is still unsightly.

    So to get an approximation to the basepose mesh I followed this procedure.
    For each vertex get its primary bone assignment. In that bone's coordinate
    system get the vertex position, i.e., relative to the pivot point. Now get
    the relative bone positions all the way up the hierarchy to the root bone
    and add them up. This SHOULD be the vertex position in world or object
    or whatever the outside coordinate system is. (bone_pelvis is hard coded
    to be at (0, 0, 0) since its position got overridden by the animation data.)
    For armored_sergeants this was good to about a percent, too large to be
    round-off error but too small to detect in Milkshape. So the warning is:
    don't reimport a previously exported animated model, it's akin to making
    a xerox of a xerox. Again, this is just for aesthetics, you only want the
    animation data from an exported animated model, you never backconvert
    these to meshes.


    (5) Bone Assignments:

    Mesh files always have two bone assignments, a primary and a secondary,
    even if the vertex weighting on the secondary is zero. Gmax ignores an
    assignment with a zero weight so to preserve these two bones I weight
    the secondary one with 0.00001 and the primary with 0.99999. This
    satisfies Gmax to keep two assignments but on conversion back to
    Milkshape format it rounds back to 100 percent on the primary and
    0 percent on the secondary and everybody's happy. Custom made models
    in Milkshape frequently have only a single bone assignment so the
    secondary Id is -1. To be safe and ensure that there are always two
    bone assignments I arbitrarily made the secondary assignment to the
    root bone with a weight of 0.00001.

  2. #2

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    During testing, we also ran this thing with custom skeletons, and it worked with those too. IT was possible to get animations and meshes through from MS3D to Max using hte SMD file format...but you got a messy end result with no comments, groups or other useful stuff. I also had a few issues with animations and meshes afterwards.

    This script was able to move the models intact, with all the uspporting data still present, the groups as seperate objects, and all the stuff needed to rebuild a solid model once you get back to MS3D. VERY important!
    Careless Orc Costs Lives!

  3. #3
    CeltiberoRamiroI Member Monkwarrior's Avatar
    Join Date
    Apr 2004
    Location
    Salduie/Caesaraugusta/ Sarakusta/Saragossa
    Posts
    828

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Each time I try to export a model as ms3d I get this error message:



    In this case I had a single shield on the skeleton (I'm starting some kind of library) and I wanted to attach on this model a part from a RTW model (the central part of the shield, I don't know the name in English). Once attached, I try to export it as ms3d with this result.

    I get the same message in a direct conversion:
    - Firstly ms3d to max (no problem)
    - Secondly, the same max (with no modification) to ms3d (error message).

    Am I doing anything wrong?

  4. #4
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @Monkwarrior,

    I don't think you're doing anything wrong, just found a
    failure mode in the script. From where it failed it looks like
    it didn't form the bonename_array and now its trying to find
    the root bone with an undefined name. Is the last line in the
    listener something like:
    "number of bones in the model: 0"

    Anyway, I'll PM you an e-mail, easiest thing is to attach the
    original .ms3d file and I'll duplicate the error. Then I can turn
    on some debugging information to see what's going on.

  5. #5
    Warhammer: Total War Team Member Alletun's Avatar
    Join Date
    Mar 2007
    Posts
    121

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Wow this is great! gonna test it out immediately

  6. #6
    Warhammer: Total War Team Member Alletun's Avatar
    Join Date
    Mar 2007
    Posts
    121

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    ok this is what i got so far:

    1) tried importing an unedited dismounted latinkon. worked like a charm :)

    2) tried importing the custom model / skeleton of a stone troll for warhammer:tw. got this error:


    All joinst were zero-jointed etc.

  7. #7

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    We had some early problems impotring some of my custom models, but we got that sorted out. Hopefully KE can see what has caused this ...he knows his stuff
    Careless Orc Costs Lives!

  8. #8
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Hi Alletun,

    From the error I can tell it's dying on a comment section,
    either group comments or model comment. Since the
    count method is undefined it didn't read anything and
    strbuf is empty. Can't really tell more without looking at the
    ms3d file. I'll PM a pair of e-mail addresses, send to both since
    Bwian has had problems sending me e-mail; this will double the
    chance of getting through.

    I did mention this was an alpha release.

  9. #9
    Warhammer: Total War Team Member Alletun's Avatar
    Join Date
    Mar 2007
    Posts
    121

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Oki mail has been send to both adresses.

  10. #10
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Got it at work. No fix needed, go to the model comment.
    You have two non-printing characters after the / sign.
    (Well they print, to me they look like y's with umlauts.)
    Delete those two characters and the troll imports fine.

    But there's another problem, your rig has rotations in it.
    Hit the zero joints to make only position offsets. Then
    it imports/exports ok, otherwise most of the bones kick out
    of the screen.

  11. #11
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @Monkwarrior,

    Received your e-mails both at work at home so no
    problems there. I can't reproduce your error because Gmax
    is frozen at 3ds Max release 4.0 so the later .max files won't
    import. However, I do understand what you are trying to do.
    The best thing seems to be to add two new buttons,
    importgeometryonly and exportgeometryonly. I think the
    merge operation might be destroying the information in the skin
    modifier and that's why the script is failing to get the bone
    information after new vertices and faces are added in the merge.
    This is not a big deal, I'll copy the code and simply delete the
    bone and weighting part. Ideally, you get a .ms3d file
    out with only geometry data, no bone data, group comments
    that only have the group type and flag, and weighting data that
    just has -1's meaning no bones assigned.

    As regards library files: this is a great idea, I've been thinking
    about this the last few weeks. I am trying to work out a Max
    Script library where you can run a script and bring in various
    models based on CA or your own models.

    Right now it requires wiring up some buttons yourself in the interface
    so I'd like to spend a few more days to see if something better
    suggests itself.

    I'll try to get the geometry only import and export functions working
    tomorrow. I think it is better to do it this way than try to make the
    user have to wrap himself around getting bones and other things
    in the right configuration just to get the exporter to do what one wants.

    This will be a good test, many thanks for trying the script!

    Regards,
    KE

  12. #12
    CeltiberoRamiroI Member Monkwarrior's Avatar
    Join Date
    Apr 2004
    Location
    Salduie/Caesaraugusta/ Sarakusta/Saragossa
    Posts
    828

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Glad to see that my test is useful.

    The merge option of max is really very useful with regard to the creation of libraries of weapons, shields or accessories.

    In case you don't know how it works:






    You have the possibility to pick only one or several elements of the merged model and to link the elements to the bones with the same name as in the original model.

    I don't know if the importer of ms3d might work in the same way. Although probably the problem is that all the elements in M2TW models need a skin modifier, whereas the cas models have elements without it and directly assigned to a single bone.

    Another interesting feature is that the import/export buttons appear in the right menu, as it happens with the cas import/export script. In that way you save a lot of time.

    I hope this helps you to make a perfect tool.

  13. #13
    feed me! Member Ashdnazg's Avatar
    Join Date
    Dec 2006
    Location
    Haifa, Israel
    Posts
    54

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    In the script I worked on I created an actual sphere to store the bounding sphere values (with value boxes in the UI to update it), so you can see its size and place better. (best to make it invisible after importing, since it isn't needed usually).
    a.k.a Lord hokomoko @ the Lordz Modding Collective

  14. #14
    Warhammer: Total War Team Member Alletun's Avatar
    Join Date
    Mar 2007
    Posts
    121

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @KE
    thanks i'll try that out

  15. #15
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @Alletun,
    Ok, let me know if anything else crops up. Off topic but I
    finally got a chance to print out a color copy of the Tome
    of Knowledge at work. If no more bugs show up, maybe I
    can make my first model over the Thanksgiving weekend.

    @Ashdnazg
    That's a great idea! I'll take it out of the UserProps and
    just make an initially hidden sphere with a spinner control for
    the radius on the rollout to remind the user the boundingsphere
    is around.

    @Monkwarrior
    Thanks, I'll try the merge operation and then export as
    geometry only just to make sure it still works. Ran across this
    in the documentation a few days ago. You can open the script
    in the Script editor, choose File -> Evaluate All, and then select
    all the text of the script in the script editor and drag it to a
    toolbar and it makes a button. Now you don't have to mouse around
    directories to run the script.

  16. #16
    CeltiberoRamiroI Member Monkwarrior's Avatar
    Join Date
    Apr 2004
    Location
    Salduie/Caesaraugusta/ Sarakusta/Saragossa
    Posts
    828

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @KE

    That method works for the script. It saves a lot of time, thanks.
    (I should have found it by myself )

    I've sent to your e-mail address the report of the tests with the new version. Unfortunately the export geometry option doesn't work, or at least I'm not able to make it work (you will see that success is possible, but I don't know how ). I can successfully import the full geometry of a ms3d file, but not export any object of a "normal" (unmodified) ms3d file imported to max.

    I've just remarked the origin a new error I found after sending you the message (I was trying to reproduce the successful attempt), but I must re-check it this night (10 a.m. now in Spain, and I'm at work )

    Edit: I've remarked another difference from the RTW models.
    In M2TW all the objects have a skin modifier, and that means that all of them require vertex weighting. In RTW models the objects linked to a single bond had not the skin modifier, and they were assigned easily in the "hierarchy" window (not sure if it is called in that way). Could it be automatically changed with the script? The system will be to add a skin modifier and assign 1 (100%) to all the vertex for the bone the object is assign. I'm not sure if I explain myself in English .
    Last edited by Monkwarrior; 11-22-2007 at 09:06.

  17. #17
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @Monkwarrior
    Did not get an e-mail at home. Because of the Thanksgiving holiday
    I won't be at work until Monday. If you could, try sending to the home
    e-mail again, it worked before. I went through the export geometry only
    code again and realized I was trying to read uv information. This would
    probably break on your merged model. I'll remove everything except for
    vertices, faces, and grouptype and groupflag. If the geometry doesn't
    have a grouptype or groupflag, I'll put in UNASSIGNED as the string for both
    so it will be obvious when looking at it in the group comments in Milkshape.
    The groupname will just be the name of the geometry object as you see it
    in 3ds Max like head_01 or kite simple_64 etc.

    I don't think I understand the issue about RTW models. Are these the
    .cas files in models_strat like spy.cas, northern_ambassador.cas?
    The file version looks to be 3.20 and the headers start off like what
    is in Verc's script (though his seems to support 3.12 up to 3.18 from his
    comments). The data looks like one big mesh for the ambassador and a
    little mesh for documents. As far as I can tell from a hex editor these
    match really close to the CAS_IE importer. Tried running to see what
    the script would do but didn't even get a rollout. I don't see any issue
    with putting a skin on these meshes and assigning bones, just need a
    converter to go back and forth between a mesh-style .cas and .ms3d.
    At least there aren't any granny bytes in .cas meshes.

  18. #18
    CeltiberoRamiroI Member Monkwarrior's Avatar
    Join Date
    Apr 2004
    Location
    Salduie/Caesaraugusta/ Sarakusta/Saragossa
    Posts
    828

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Message sent to the other address.

    I'm having some problems because when I get an error in the export attempts, the script doesn't work properly unless I reset 3ds max.

    I will try to explain you my point of weighting or direct assignation with images.


    In this model, we can see the links between objects and bones (schematic view, is called in 3ds max, the button marked in red).
    As you can see, only one object (body_400) is not linked to any bone, but weighted through a skin modifier. All the others (falkata, as an example) have no skin modifier, but are linked to one bone.
    This is very easily done with the tool marked in red in the schematic view window.

    If I want to export this model to M2TW, apart from the differences between bones, each object should have a skin modifier and the vertex should be weighted to that bone (in the case of falkata, the pelvis bone) with 100%.
    I wonder if all those manipulations can be made automatically with the script.

    Perhaps there are some differences in the possible assignations from RTW to M2TW. For example, shields are linked to left hand in RTW, but to left elbow (if I'm not wrong) in M2TW. Perhaps the exporter should ask the modeller which bone must be linked to each object (or type of object, using the comments?).
    Last edited by Monkwarrior; 11-23-2007 at 01:01.

  19. #19
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    (1) Having to reset: Following Verc's script I take a snapshot of each of the
    meshes and work with the snapshot to pull out information. I then delete the
    snapshot afterwards. If the script fails, the snapshot doesn't get deleted.
    If you look in the Select By Name dialog you'll find a duplicated entry.
    For instance, if you had 3 heads: head_01, head_02 and head_03, after an
    error you would see head_04, that's the snapshot. It doesn't have a skin
    modifier so the script fails again and you have to reset to get a good set
    of meshes and skin modifiers.

    (2) Totally misunderstood the question. Gmax doesn't have that button but
    I THINK I'm understanding what you are saying. Let me back up and take
    Milkshape and Max out of the question. Mesh files always have two bone
    assignments. (CA left room for four but the other two aren't used in M2TW.)
    For most vertices the secondary weight is 0.0 so its like a single bone
    assignment but the placeholder is there.

    Let's put Milkshape in. GOM's converter and mine put the two bone assignments
    into the .ms3d file. The primary goes into the vertex section and the
    secondary bone assignment is done at the bottom in the weighting section.
    The weights are in the bottom section in percents. Mostly 100 as a byte
    for the primary and 0 as a byte for the secondary weight. For the few that
    have real weighting it might be 75 and 25 and so on.

    Now put 3ds Max in. I bring over the data and use a skin modifier to assign
    with because Verc's script did it that way and I found the documentation
    for how that is done. If I make two bone assignments with weights of
    1.0 and 0.0 Gmax ignores the zero weight and I lose the mesh data.
    So I do 0.99999 for the primary weight and 0.00001 for the secondary and
    Gmax remembers this and I can pull the data back out on export and
    everyting is 1 to 1.

    That was background. I think the question is there are two ways of assigning
    vertices to a bone in Max. I did not know this. The older way, I'm guessing,
    is what you've called a direct assignment. This means one bone only, no
    weighting. The newer way is with a skin modifier and this allows weighting.
    Sort of like Milkshape 1.7 versus 1.8. I think the answer is, if you do
    assignments for all meshes in your model using skin modifiers, but do it
    as 0.99999 for bone_Rhand for weapons and 0.00001 to its parent
    bone_Relbow, then the model should export fine to .ms3d. From there,
    since it has two bone assignments even though the conversion to bytes
    will make the weights 100 and 0, it should convert back to a mesh just
    fine.

    Large shields are assigned to bone_Lelbow. If there are bucklers or targets
    in the game those might be assigned to bone_Lhand since that's how they
    would be wielded for real. Haven't really looked at that.

    I think this means I don't have to look at .cas mesh files anymore. Pity,
    really, the format is straightforward and would be easy to convert.

  20. #20
    CeltiberoRamiroI Member Monkwarrior's Avatar
    Join Date
    Apr 2004
    Location
    Salduie/Caesaraugusta/ Sarakusta/Saragossa
    Posts
    828

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @KE

    (1) Yes I've seen the creation of a snapshot, but the question is not only the error with the same model, but if you open a new scene and try to import a new ms3d file, you get also an error. I think it is important to remark the need to a reset in case of getting an error using the script. If not the users will think the importer doesn't work.

    (2) Yes, that's the question. I didn't know that M2TW models are using always the assignation to two bones.

    If you need more information about 3ds max, don't hesitate to ask me (even if I'm not an expert, I'm simply a user that tries to make everything as easy as possible )

  21. #21

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    KE, the 'comments' section of Milkshape models, where's that shown in 3dsmax? Don't we still need Milkshape to do the comments and such?

  22. #22
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    @SigniferOne
    I use the mesh name as the group name, the grouptype and groupflag
    are in the UserProps of each mesh in the model. You can select a mesh
    then edit->object properties and then click the "user defined" tab to see
    them. They're in a key/value format like
    grouptype = Arms
    groupflag = 0
    Boundingsphere is done the same way only it's stored in the UserProps
    of the root bone. Weird thing is UserProps won't let you retrieve the full
    string if there are spaces in it so the bounding sphere is stored with
    percent signs like
    boundingsphere = 0.345%0.112%0.005%1.711%/

  23. #23

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    is there a tutorial on using this correctly somewhere?

    the reason I ask is I just create a box in 3dsmax and try to export it using the script to ms3d. it exports but nothing shows up in milkshape. Any explanation for this?

    thanks

  24. #24
    Member Member KnightErrant's Avatar
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    458

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Hi etcetera,

    No, no real user's manual for this. The converter is very
    specific to game files so just making a box will kill it; it would
    look for a skeleton and UserProps in the root bone, etc. and not
    finding those will most likely crash and produce nothing. You can
    watch it's demise be hitting F11 and bringing up the Max Script listener.

    I'd try going the other way: Download GrumpyOldMan's converter from
    here:
    http://www.twcenter.net/forums/downl...o=file&id=1276

    It's tried and true and every modeller uses it. Find a .mesh file for a unit
    you want to convert and turn it into a .ms3d file in Milkshape's binary
    format. Then import it into Gmax or Max with the converter. You
    should see a real game unit that you can modify and then export out again
    because all the data will be defined like uv's, assignments, UserProp stuff
    like boundingsphere data etc.

    Regards,

    KE

  25. #25

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    ah, thanks KnightErrant.

    I'm only going to use it for fully modelled characters with skeleton and everything so then this tool is perfect.

  26. #26

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    hello all .
    this is my 3d model in max.
    i can't export it in to milkshape .
    please some one do it for me if possible .
    i dont know what is the problem .
    this is my file
    www.sourenagames.com/characterforMB.rar
    thankyou

  27. #27

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    I cannot download the file as it says I need to log in. When I log in, it says my information is invalid; it is not actually lol

  28. #28
    Annoyingly awesome Member Booger Flick Champion, Run Sam Run Champion, Speed Cards Champion rickinator9's Avatar
    Join Date
    Dec 2011
    Posts
    957

    Default Re: Milkshape ms3d importer/exporter for 3ds Max and Gmax

    Quote Originally Posted by AnnieOverAgain View Post
    I cannot download the file as it says I need to log in. When I log in, it says my information is invalid; it is not actually lol
    The file is hosted on another forum. https://mega.co.nz/#!GwJ0HLoR!ksT5v8...ocL8OLFXfi9DZg is a download link for it without having to create another account.
    rickinator9 is either a cleverly "hidden in plain sight by jumping on the random bandwagon" scum or the ever-increasing in popularity "What the is going on?" townie. Either way I want to lynch him. - White Eyes

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Single Sign On provided by vBSSO