Search Unity

  1. Looking for a job or to hire someone for a project? Check out the re-opened job forums.
    Dismiss Notice
  2. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

[RELEASED] Magica Cloth

Discussion in 'Assets and Asset Store' started by hoshos, Jan 22, 2020.

  1. ZeonIr

    ZeonIr

    Joined:
    Feb 23, 2014
    Posts:
    15
    ok i be back when you do make support thanks tho
     
  2. xDavidLeon

    xDavidLeon

    Joined:
    Jun 9, 2014
    Posts:
    121
    If you have any biped character with the Full Body Biped Ik and the Grounder IK, you should be able to see the feet iks work when on a ramp or stairs etc. If the character has Magica Bone Cloth elements, you should see them vibrate.
     
  3. trueh

    trueh

    Joined:
    Nov 14, 2013
    Posts:
    12
    Hi:

    I want a character to pull from a cloth. The cloth is holding from another object, then the character pulls from it to see what is behind it. The cloth has to fall to the floor. Is it possible to apply forces to the cloths made with Magica Cloth? The other option I have to do this effect is simulate with Houdini and try to use Alembic in Unity (which is something I have never tried)...
     
  4. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Thank you for the detailed information.
    I will test it here.
     
  5. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    The ability to grab and pull the cloth is currently under development.
    The work is a little late and it will take another month.
    However, there are no plans to tear the cloth.
    In addition, it is still possible to give force such as a blast to the cloth.
    Use the following API for this:
    * AddForce (..);

    https://magicasoft.jp/en/basecloth-2/
     
    trueh likes this.
  6. ChrisCoool

    ChrisCoool

    Joined:
    Jul 3, 2017
    Posts:
    13
    Hi, I have a question about Magica Bone Cloth configuration. To simplify my question, I use two chain of nodes and you can check the upload img1 & img2. The Bone Cloth component 1 takes the "Main Root" as its root and marks all tie nodes as invalid. While the Bone Cloth component 2 takes the "Tie Root" as its root. Is such configuration correct?

    I find out that when the Bone Cloth component 1 is enabled, the "Node3" sometimes appears in a very strange position (img3). Is this because Tie Nodes are nested in "Node3"?

    Any suggestions for this scenario? Thanks a lot!
     

    Attached Files:

  7. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    Unfortunately, BoneCloth cannot be parent-child.
    Currently, the only operation that can be performed is to use one BoneCloth and set the movement point as shown in the image.
    img1_B.jpg
     
  8. Acissathar

    Acissathar

    Joined:
    Jun 24, 2011
    Posts:
    595
    I was thinking about picking up Final IK during the sale, so if you find anything and can share it that would be awesome :)
     
    hoshos likes this.
  9. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Update: 1.8.5

    v1.8.5 has been released on the Asset Store!
    http://u3d.as/1Hzx

    A mode has been added to teleport while maintaining the simulation.
    It can be set from the World Influence panel.



    WorldInfluence2-2.jpg

    Release Note:
    Added: Added a mode to teleport while preserving the simulation.
    Added: Added Keep Teleport API.
    Improvement: Reduced vibration caused by collision detection.
    Improvement: Improved future prediction algorithms to reduce simulation vibrations.
    Fix: Fixed an issue where the mesh disappeared due to an error when using Global Collider.
    Fix: Fixed an issue that caused an error at runtime when copying / pasting component data in the editor.

    https://magicasoft.jp/en/release-note-2/
     
  10. ChrisCoool

    ChrisCoool

    Joined:
    Jul 3, 2017
    Posts:
    13
    Thanks for reply.
    Just curious, what problems will cause if BoneCloth is parent-child? If I want to make BoneCloth parent-child in a code way, is there any suggestion?
    Thanks!
     
  11. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    When BoneCloth has a parent-child structure, it is usually inconsistent unless calculations are performed in the order from parent to child.
    But in Magica Cloth, the Job System does everything in parallel.
    Therefore, it is not possible to form a parent-child structure.
    This cannot be easily fixed at design time.
    If you forcibly build a parent-child structure for the above reasons, multiple reads and writes to bones will occur, and various problems will occur in position and rotation depending on the processing order of threads.
     
  12. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Let me ask you one question about this issue.
    Are you using FinalIK's CharacterThirdPerson script to move the character in question?
    If not, is the character moved with FixedUpdate ()?
     
  13. xDavidLeon

    xDavidLeon

    Joined:
    Jun 9, 2014
    Posts:
    121
    Hi, it started happening again when upgrading from 1.8.4 to 1.8.5. I had to go back to 1.8.4 for the fix to work.

    I'm using a plugin called Kinematic Character Controller to move my character. Is a rigidbody based character controller, so it moves during the FixedUpdate. I think that if you move a rigidbody based character (FixedUpdate), use Final IK Grounder IK, and then use Bone Cloth, you should see the issue.
     
  14. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Thank you for your reply.
    This is a known issue that causes vibrations when moving a character with FixedUpdate.
    Many users have pointed out this problem, and we would like to fix it as soon as possible.
    However, it will be a little difficult work, so it will take a little longer.
    If possible, I would like to resolve it by the end of the year, so please wait for a while.
     
    NSokolovskyi likes this.
  15. daniel254973

    daniel254973

    Joined:
    Jun 9, 2016
    Posts:
    8
    Hello, I've found an issue related with MagicaBoneCloth.
    I have some characters that are prefab variants of a baseCharacter prefab. They contains a mesh prefab with MagicaBoneCloth component. When I do changes on my character variant, prefab variant is applied to the prefab base (and to itself, but this is ok, of course).

    The work around I've found is to press on MagicaBoneCloth Create button every time I edit the prefab variant.

    Image of one of my character variants https://imgur.com/a/R7XTvHW

    Any advice? Thanks!
     
  16. MrNani

    MrNani

    Joined:
    Jun 20, 2020
    Posts:
    3
    Hi, In some situation, I have to reset influence target in rumtime. But when I use MagicaMeshCloth.InfluenceTarget, it doesn't work. can someone give an example?
    Thanks!
    code.jpg result.png
     
  17. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    Thank you for reporting the bug!
    I was able to confirm the problem here as well.
    This seems to be a bug where cloth data is saved as a sub-asset on the parent prefab side when the prefab is nested.
    I will fix it, so please take a moment.
     
  18. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    Unfortunately, the Influence Target cannot be changed at runtime.
    This should be set to the [Hip] bone etc. in the case of this dress when designing with the editor.
    By the way, under what circumstances do you want to switch?
     
  19. MrNani

    MrNani

    Joined:
    Jun 20, 2020
    Posts:
    3
    Hello.
    In runtime,I need to clone a new character with MagicaCloth and use the Animation Retargeting to copy bone information,in this case,the Influence Target will be missing. so I want to reset it. Do you have some advice?
     
  20. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    I understand roughly.
    Will an API that replaces the InfluenceTarget solve this problem?
     
  21. MrNani

    MrNani

    Joined:
    Jun 20, 2020
    Posts:
    3
    OK, thanks for your advice!
     
  22. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    understood.
    I think it's possible, so I'll provide an API that allows you to change the Influence Target to runtime in the next version.
    However, I think that the update will probably be next year because my main job is busy this month and the work is not progressing easily.
     
  23. QbAnYtO

    QbAnYtO

    Joined:
    Dec 18, 2016
    Posts:
    135
    Can i use this on mesh’s that doesn’t have bone? Just strictly using the mesh/vertices as the “bones”? I have a character and her hair doesn’t have bones. It’s just a pony tail. Can I add MagicaCloth to JUST THE BONELESS HAIR to animated it moving while she runs?

    I ask because on your description, it says:


    • Implement BoneCloth driven by Bone (Transform) and MeshCloth driven by mesh
    • MeshCloth can also work with skinning mesh
     
  24. Acissathar

    Acissathar

    Joined:
    Jun 24, 2011
    Posts:
    595
    Yes, set it as a Mesh Cloth if you do. The screenshots and gifs I have earlier in the thread are all on meshes, such as skirts and hair, that do not have any bones in them.
     
    hoshos likes this.
  25. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Yes, it is possible to work with a mesh that does not contain bones.
    Please refer to the following two documents.

    <MeshCloth Start Guide>
    https://magicasoft.jp/en/magicaclothmeshclothstart-2/

    <Skirt by MeshCloth>
    https://magicasoft.jp/en/meshclothskirtguide-2/
     
  26. pha

    pha

    Joined:
    Oct 23, 2012
    Posts:
    20
    Just bought and install... got all of these errors.
     

    Attached Files:

  27. pha

    pha

    Joined:
    Oct 23, 2012
    Posts:
    20
    Never mind! Problem solved, I forgot to install Jobs and Burst.
     
    hoshos likes this.
  28. Monil

    Monil

    Joined:
    Apr 24, 2012
    Posts:
    94
  29. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    Unfortunately, we are currently unable to implement this feature.
    This is because some internal data structures need to be modified to implement this feature.
    However, we have received requests from several people to paint with vertex colors, so we would like to consider implementing it in the future.
     
    NSokolovskyi likes this.
  30. iileychen

    iileychen

    Joined:
    Oct 13, 2015
    Posts:
    73
    Hi, thanks for the great tool, our animator tested it for days and told us it is very good. But we have similar problem that is, we need runtime construction feature, since our game allow players to adjust/edit/cut their cloth at runtime. Hope you can support that, Thanks!!!
     
    hoshos likes this.
  31. Supergrubman

    Supergrubman

    Joined:
    Jan 2, 2014
    Posts:
    5
    Can you clarify what
    • No native plugin
    means?
     
  32. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    First, creating such a cloth-simulation requires high performance and is almost impossible to implement in Unity C #.
    It's too slow in C #.
    Therefore, until now, it was necessary to create a native plugin (DLL) for each platform and implement it outside Unity.
    However, the implementation in DLL is compatible with the execution terminal, and troubles such as crashes occur frequently.
    That's why Unity Burst Compiler + Job System was developed.
    By using this system, C # can be executed at high speed and in multiple threads.
    MagicaCloth is implemented by this Burst, eliminating the need for native plugins (DLLs).
     
    ObiOneStenobi likes this.
  33. wood333

    wood333

    Joined:
    May 9, 2015
    Posts:
    741
    We make our player characters with Reallusion's Character Creator. Can we use Magica Cloth?
     
  34. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    I haven't used Reallusion's Character Creator before, so I can't give a definite answer.
    However, if this tool is a type that creates characters externally, MagicaCloth is probably available.
    On the contrary, MagicaCloth cannot be used if it is a type that generates characters while Unity is running.
    This is because there is no function to generate data during execution.
     
    wood333 likes this.
  35. adamz

    adamz

    Joined:
    Jul 18, 2007
    Posts:
    1,056
    @hoshos Hi, just checking in and seeing how cloth grab is coming along :)
     
  36. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    The function to grab seems to take a little longer.
    I'm sorry to have kept you waiting.

    As a work policy, we give top priority to defect correction and implement the next most requested function.
    There were many bug reports in December, and most of them took time to fix this.
    This fix will be released as v1.8.6 early next year.

    And next year's work, there is a problem that MagicaCloth does not work well when animating characters with FixedUpdate, and there are many requests, so we plan to give priority to this work.
    Therefore, the function to grab is likely to be after that.
     
  37. bhavesh_unity3

    bhavesh_unity3

    Joined:
    Dec 29, 2020
    Posts:
    7
    Hi! Please help!

    I am looking for some answers. Please check below code snap and read comments of questions.

    Thanks




    Code (CSharp):
    1.     [SerializeField] MagicaRenderDeformer renderDeformer;
    2.     [SerializeField] MagicaVirtualDeformer virtualDeformer;
    3.     [SerializeField] MagicaMeshCloth meshCloth;
    4.  
    5. void Start() {
    6.         var skinRender = this.GetComponentInChildren<SkinnedMeshRenderer>();
    7.         renderDeformer = skinRender.gameObject.AddComponent<MagicaRenderDeformer>();
    8.         renderDeformer.CreateData();
    9.  
    10.         GameObject vdObject = new GameObject("virtualDeformer");
    11.         virtualDeformer=vdObject.gameObject.AddComponent<MagicaVirtualDeformer>();
    12.         vdObject.transform.SetParent(this.transform);
    13.         //How can i add magica renderDeformer object to Render Deformer List of virtualDeformer ?
    14.  
    15.  
    16.         GameObject mcObject = new GameObject("meshCloth");
    17.         meshCloth = mcObject.gameObject.AddComponent<MagicaMeshCloth>();
    18.         mcObject.transform.SetParent(this.transform);
    19.         //How can i add magica virtualDeformer object to Virtual Deformer of MagicaMeshCloth's MainSetup ?
    20.         //How can i load preset ?
    21.     }
     
  38. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    Unfortunately, MagicaCloth data cannot be generated at runtime.
    All data must be pre-created before execution.
    However, there are many requests for this project, so we plan to improve it.
    However, it will take a considerable amount of time because it needs to be reviewed from the design.
     
  39. daniel254973

    daniel254973

    Joined:
    Jun 9, 2016
    Posts:
    8
    Hello again,
    Is there any update about this? It's very hard to work around.

    Thank you and happy new year.
     
  40. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Update: 1.8.6

    v1.8.6 has been released on the Asset Store!
    http://u3d.as/1Hzx

    This time it's almost a bug FIX.
    It resolves global collider issues, TimeScale = 0 issues, prefabricated nesting issues, and more.

    Release Note:
    Added: Added API to switch Influence Target.
    Improvement: Turned off the Breast preset limit axis
    Improvement: Changed to perform mesh shaping process per vertex instead of per mesh when the number of meshes is small.
    Improvement: Improved the reduction algorithm of Virtual Deformer.
    Fix: Fixed a bug where the global collider would cause an error in some situations and the mesh would not be drawn.
    Fix: Fixed an issue where setting TimeScale = 0 would cause an error in some situations
    Fix: Fixed an issue where data would be saved in the wrong prefab if the prefab had a parent-child relationship
    Fix: Fixed an issue where particles would sway after teleporting when Keep Teleporting during rotation
    Fix: Fixed an issue where the simulation would not run on the second boot when ReloadDomain in Enter Play Mode Settings was turned off.

    https://magicasoft.jp/en/release-note-2/
     
    NSokolovskyi likes this.
  41. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    V1.8.6 was just released to resolve the prefab nesting issue.
    If you still have problems with this version, please report it.
    I will investigate.
     
  42. Hobodi

    Hobodi

    Joined:
    Dec 30, 2017
    Posts:
    54
    Hello Hoshos! Have you decided not to add standard colliders? Or are there still chances?
     
  43. daniel254973

    daniel254973

    Joined:
    Jun 9, 2016
    Posts:
    8
    Hello, I have tried it and it still happens. Prefab variant changes applied to root prefab.
    Hope you can find the issue.
    Thank you.
     
  44. djsaman

    djsaman

    Joined:
    Jul 13, 2012
    Posts:
    1
    Hello.
    My mesh vertex count bigger 65535.
    Possible disable limit and use bigger vertex count model?
     
  45. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    Excuse me, what are standard colliders?
    Is it a mesh collider or a Unity collider?
     
  46. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Sorry, v1.8.6 still has a bug with the prefab variant.
    This issue will be fixed in the next v1.8.7.
    Just in case, I sent the download link of v1.8.7.preview1 currently under development to your [InBox].
    I think this version fixes a problem with the variant.
    I would appreciate it if you could test it.
     
  47. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    330
    Hello.
    There is a plan, but the implementation time is undecided because the priority is low.
    However, cloth simulation of vertices over 65535 is quite heavy.
    Therefore, if possible, it is better to reduce the number of vertices with reduction software etc. to get better results.
     
  48. Hobodi

    Hobodi

    Joined:
    Dec 30, 2017
    Posts:
    54
    Unity standard colliders , for environments, self colliding and etc.
     
  49. Acissathar

    Acissathar

    Joined:
    Jun 24, 2011
    Posts:
    595
    If that ends up fixing it, would it be possible to get a copy of this as well? I somehow missed this and then thought it was a Unity issue haha
     
  50. athert

    athert

    Joined:
    Dec 31, 2012
    Posts:
    15
    Hello.
    Can you please help me with this issue? Im trying to create item clothing where i have prefab with just skinnedMeshRenderer that i later put on character if he equip specific item.

    upload_2021-1-5_23-33-27.png
    upload_2021-1-5_23-33-52.png

    As you can see on first screenshot, if i put prefab into level and adjust everything, deformers will tell me that everything is fine and saved. But if i look at prefab itself (or i will try to spawn this prefab later ingame), deformers will tell me that they have error in them so they will not work (see second screenshot).
    Is there any possible way to fix this or "hack" myself so it will work?

    Edit: I have cached all bones from character i originally created this item with deformers. Maybe if there will be option for me to just "send them" later when i spawn this prefab into deformers, it will work?
     
unityunity