Search Unity

  1. Unity 2019.4 has been released.
    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
  3. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

[RELEASED] Magica Cloth

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

  1. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello.
    This is a Unity Editor setting.
    It has nothing to do with MagicaCloth.
    If you want to make the icons smaller, try moving the Gizmos [3D Icons] slider as shown in the image.
    icon-1.jpg
     
    Quang_Phan likes this.
  2. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Fixed a save error bug in prefab mode.
    Send the modified version of the package to your inbox.
    Thank you.
     
  3. Quang_Phan

    Quang_Phan

    Joined:
    Dec 28, 2016
    Posts:
    10
    Amazing man! Thank you very much!
     
  4. Acissathar

    Acissathar

    Joined:
    Jun 24, 2011
    Posts:
    540
    Hi,

    Would it possible to grab the patch too? I started running into this on one of my character's prefabs. I can send my invoice ID if needed.

    Thanks!
     
  5. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    You have sent an evaluation download link to your inbox.
    Thank you very much.
     
  6. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Update: 1.5.0

    v1.5.0 has been released on the Asset Store!
    http://u3d.as/1Hzx
    Added Delayed execution system!

    Delayed execution also runs the cloth simulation during rendering.
    This greatly improves performance.
    Just note that the result is one frame late.
    This delay is interpolated by making future predictions.

    delay-1.jpg

    profile-2.jpg

    Release Note:
    Feature: Added delayed execution mode.
    Improvement: Improved performance.(10% - 30%)
    Improvement: Displaying write time to mesh in profiler.
    Improvement: Render deformer normal / tangent recalculation can now select normal only or normal + tangent.
    Improvement: Scene view can be rotated by Alt + mouse drag while vertex painting.
    Fix: Fixed incorrect scale calculation when writing to bones.
    Fix: Fixed an issue where references to parent bones could be lost when referring to one bone multiple times.
    Fix: Fixed an issue where teleport might not work properly.
    Fix: Fixed an issue when selecting the wind component when the cloth monitor was hidden.
    Fix: Fixed an issue where data was not written correctly when editing in prefab mode.
    Fix: Modified to redraw the scene view when editing MeshSpring axes in the inspector.
    Note: The update mode [Once Per Frame] will be deprecated in the future.
     
    Micho_Dev, Quang_Phan and Acissathar like this.
  7. Quang_Phan

    Quang_Phan

    Joined:
    Dec 28, 2016
    Posts:
    10
    Great! For update to new version 1.5.0 do I need remove old version before update?
     
  8. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hi,
    Yes, it is safer to delete them.
     
    Quang_Phan likes this.
  9. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Update: 1.5.1

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

    API accessors for [Distance Disable] and [External Force] parameters have been added.
    Otherwise, bug FIX is the main.

    Release Note:
    Feature: Added API for accessing [Distance Disable] parameter.
    Feature: Added API for accessing [External Force] parameter.
    Improvement: Connection control between components has been strengthened.
    Fix: Fixed an issue where an error would occur if [Distance Disable] was turned On / Off during execution.
    Fix: Fixed an issue that caused an error when creating a cloth component with LateUpdate during delayed execution.
    Fix: Changed the delayed execution to be executed at PostLateUpdate instead of at the end of LateUpdate.
    Fix: Fixed an issue where inactive render deformers were being calculated.
    Fix: Fixed an issue where inactive render deformers were causing a memory leak.
    Fix: Fixed [RenderMeshVertexUsed] [VirtualMeshVertexUsed] values on cloth monitor to be correct.
     
  10. Acissathar

    Acissathar

    Joined:
    Jun 24, 2011
    Posts:
    540
    Just ran into this when re-activating a de-activated game object that has MagicaCloth in it.

    It threw up 16 errors in the log, but didn't seem to actually effect anything (cloth simulation kept going, game didn't crash, nor did editor pause).

    I am on Unity 2019.3.9, Entities is 0.8.0, and I do have unsafe code checked. Just wondering if this is a possible problem or something I need to handle before deactivating/activating:

    InvalidOperationException: The previously scheduled job PhysicsManagerTeamData:postProcessTeamDataJob writes to the NativeArray PostProcessTeamDataJob.teamData. You must call JobHandle.Complete() on the job PhysicsManagerTeamData:postProcessTeamDataJob, before you can read from the NativeArray safely.
    Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle.CheckReadAndThrowNoEarlyOut (Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle handle) (at <05f2ac9c8847426992765a22ef6d94ca>:0)
    Unity.Collections.NativeArray`1[T].CheckElementReadAccess (System.Int32 index) (at <05f2ac9c8847426992765a22ef6d94ca>:0)
    Unity.Collections.NativeArray`1[T].get_Item (System.Int32 index) (at <05f2ac9c8847426992765a22ef6d94ca>:0)
    MagicaCloth.FixedNativeList`1[T].get_Item (System.Int32 index) (at Assets/MagicaCloth/Core/Utility/NativeCollection/FixedNativeList.cs:158)
    MagicaCloth.ClampDistanceConstraint.RemoveTeam (System.Int32 teamId) (at Assets/MagicaCloth/Core/Physics/Constraint/ClampDistanceConstraint.cs:124)
    MagicaCloth.PhysicsManagerCompute.RemoveTeam (System.Int32 teamId) (at Assets/MagicaCloth/Core/Physics/Manager/PhysicsManagerCompute.cs:157)
    MagicaCloth.ClothSetup.ClothDispose (MagicaCloth.PhysicsTeam team) (at Assets/MagicaCloth/Core/Cloth/Common/ClothSetup.cs:371)
    MagicaCloth.BaseCloth.BaseClothDispose () (at Assets/MagicaCloth/Core/Cloth/Common/BaseCloth.cs:305)
    MagicaCloth.BaseCloth.OnDispose () (at Assets/MagicaCloth/Core/Cloth/Common/BaseCloth.cs:176)
    MagicaCloth.CoreComponent.OnDestroy () (at Assets/MagicaCloth/Core/Physics/CoreComponent/CoreComponent.cs:80)
     
  11. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello, Acissathar.

    I checked for errors.
    You're probably using the evaluation version v1.5.0.b4 you gave earlier.
    The current latest version is v1.5.1.
    This version also includes bug fixes around the controls.
    Please update from Asset Store to v1.5.1.
    If you still get the error please contact us.
     
  12. Acissathar

    Acissathar

    Joined:
    Jun 24, 2011
    Posts:
    540
    It was regular 1.5.0 for what it's worth, but after updating to 1.5.1 I haven't run into it again so seems good to me :)
     
    hoshos likes this.
  13. Imperatoss

    Imperatoss

    Joined:
    Mar 24, 2018
    Posts:
    45
    Hi,

    does anyone know how i can get rid of those?

    upload_2020-4-17_0-10-17.png
     
  14. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    This could be due to the mesh normals being flipped over.
    Perhaps the virtual mesh is too detailed.
    Try increasing the [Merge Vertex Distance] or [Merge Triangle Distance] in VirtualDeformer a little.

    https://magicasoft.jp/en/magicaclothmeshclothstart-2/

    It may stabilize the normals of the virtual mesh.
    Please take a backup before working.
     
    Imperatoss likes this.
  15. a340523052

    a340523052

    Joined:
    Jun 6, 2019
    Posts:
    7
    after deactive and active BodyAvatar the yellow hair look like this 208AB270-822A-432b-8B1B-42970A10E332.png
     
  16. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    Thank you for the bug report.
    I was able to confirm the problem here as well.
    I will fix it in the next version.
     
  17. a340523052

    a340523052

    Joined:
    Jun 6, 2019
    Posts:
    7
    I Control UnityChan to move forward,but her hair will vibrate
     
  18. a340523052

    a340523052

    Joined:
    Jun 6, 2019
    Posts:
    7
    another video
     
  19. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    What is specified in Update Mode of MagicaPhysicsManager?
     
  20. a340523052

    a340523052

    Joined:
    Jun 6, 2019
    Posts:
    7
    Unscaled Time
     
  21. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Thank you.
    There is no problem with the Unscaled Time setting.
    I would like to confirm. Is the [Reset After Teleport] checkbox of the World Influence parameter of the Cloth component checked?

    https://magicasoft.jp/en/paramater-world-influence-2/

    If this check is checked, the simulation will be reset when the main unit exceeds a certain speed.
    If it is ON, try setting it to OFF.
     
  22. Micho_Dev

    Micho_Dev

    Joined:
    Nov 5, 2019
    Posts:
    6
    HI, I'm trying to intergtate Game Creator(GC) with Magica Cloth.
    I created 2 action that Custom GC Action "Attach Avatar parts" and "Detach Avatar parts".
    Attach action is working but, detach action does'nt work.
    upload_2020-4-21_23-45-52.png
    so I tested by debug log. then I notice it returned on "if (avatarPartsList.Contains(parts) == false)"


    upload_2020-4-21_23-39-16.png
     
  23. Imperatoss

    Imperatoss

    Joined:
    Mar 24, 2018
    Posts:
    45
    Hi,

    i have a problem with the collider sticking through the cloth, i tried to change the settings but somehow it doesnt work.

    upload_2020-4-21_20-50-11.png

    Anyone an idea?

    If the movement of the collider is relative slow it doesnt stick through, but in normal animation speed it sticks through the cloth component : /
     
    Last edited: Apr 21, 2020
  24. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    There seems to be a problem with the usage of the API.
    The API for adding and deleting parts to Avatar is as follows.

    avatar_api-1.jpg

    AttachAvatarParts creates a clone of the passed part and attaches it.
    Please note that it is not the avatar part you passed.
    And the handle (int) to the part is returned.
    Use DetachAvatarParts (int partsId) to delete.
    partsId will be the handle returned by AttachAvatarParts ().
    Can you test this way?
     
  25. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    Unfortunately this issue is not yet completely resolved.
    The most stable method currently available is to fix some vertices.

    colision-issue-1.jpg

    In the case of the costume in the image, the vertices in the red range are fixed and the vertices in the green range are moved.
    This avoids excessive slip through.
    Also, additionally set ClampPosition / ClampRotation.
    ClampPosition can limit the movement range from the origin.

    https://magicasoft.jp/en/paramater-clamp-position-2/

    ClampRotation can limit the angle at which each vertex bends from the origin.

    https://magicasoft.jp/en/paramater-clamp-rotation-2/

    By setting either or both of these two, you can limit the range in which the vertex can move.
    * Please use MagicaCloth version 1.6.0 or higher.

    We are currently developing new constraints for this issue.
    We hope to solve this problem in the future.
     
    Imperatoss likes this.
  26. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Update: 1.6.0

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

    This time, the improvement of physics simulation is the main.
    Collision detection has priority over movement restriction.
    It also includes improvements in collision detection and accuracy in skin mesh weight calculations.
    The following movies are previews of these.
    Skirt collision detection is better than before.




    Release Note:
    Improvement: Improved the behavior of ClampPosition / ClampRotation. Collision detection has priority over movement restriction.
    Improvement: Improved collision determination processing.
    Improvement: Improved the rotation line generation algorithm.
    Improvement: Collider Gizmo is basically hidden when not selected.
    Improvement: Added a reset simulation button to the running inspector.
    Improvement: Improved the friction processing algorithm.
    Improvement: Enabled to specify the maximum number of connections in [Near Point] of Restore Distance.
    Improvement: Changed the Virtual Deformer weight calculation method to the average weight value of the referenced skinning mesh vertices.
    This greatly reduces the problem of unintended vertex deformation during animation.
    Improvement: Fixed vertices in VirtualDeformer were set to be completely excluded from the calculation in some situations.
    This greatly reduces the problem of unintended vertex deformation during animation.
    Improvement: Renamed Adjust Line to Rotation Interpolation.
    Improvement: Added FixedNonRotation flag to Rotation Interpolation.
    If this flag is set to ON, fixed particles will not rotate at all.
    Fix: Fixed an issue where Global Collider was not working properly.

     
    Ukounu, adamz and Acissathar like this.
  27. pigglet

    pigglet

    Joined:
    Aug 13, 2014
    Posts:
    111
    Hey! Is it possible to add a Magica Cloth during a runtime? I have a character generated on the fly from different pieces of mesh, can I also add MeshCloth&MeshSprings on runtime either?
     
  28. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    Unfortunately it is not possible to generate MagicaCloth data at runtime.
    This is not a technical issue.
    This is because there is a phase where the user specifies which particles will be moved and which particles will be pinned by vertex painting.
    This task cannot be automated.
    Therefore, we have no plans to implement it in the future.
     
    pigglet likes this.
  29. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    [Addition]
    However, there is a function to add / delete cloth parts generated in advance to the main body (Avatar).
    This makes it possible to switch costumes.

    https://magicasoft.jp/en/dress-up-start-2/
     
    pigglet likes this.
  30. pigglet

    pigglet

    Joined:
    Aug 13, 2014
    Posts:
    111
    Oh, so there is no way to define particles except manual painting directly in unity? Have you considered some other ways, like using black&white maps to define affected vertices? It could be a great UX improvement even for the current "non-runtime" model preparation. In my experience, I never succeed with tools required direct painting in unity, especially on complex models. But loading external maps prepared in other software was always a boost to a production pipeline.
    Anyway, the tool looks very promising! Thank you for your service!
     
    hoshos likes this.
  31. a340523052

    a340523052

    Joined:
    Jun 6, 2019
    Posts:
    7
    I add unitychan to a new scene and disable the animator,her body will vibrate
     
  32. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Thank you for your report.
    I also confirmed the phenomenon here.
    This may be due to a slight modification of the collision calculation in v1.6.0.
    However, please understand that problems are not fixed easily and take time.
    Because the vibration problem is always a problem with the physics engine.
    It is difficult to fix it perfectly, but we will try to reduce the vibration.
     
  33. Micho_Dev

    Micho_Dev

    Joined:
    Nov 5, 2019
    Posts:
    6
    Thank you for your advice!
    I succeeded in erasing the item with the parts ID stored in the variable. But if I set the Armature's collider to Global, it works on the parts that I instantiate in, but it's weird. What setting did I do wrong?

    upload_2020-4-23_1-25-51.png
     
  34. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    This may be a bug.
    Is MagicaCloth version 1.6.0?
    Also, did the Global Collider be built as an avatar part instead of being placed from the beginning?
     
  35. Micho_Dev

    Micho_Dev

    Joined:
    Nov 5, 2019
    Posts:
    6
    Yes, the version is 1.6.0.The avatar parts and global colliders are correctly assigned, but they seem to be quite broken.
    upload_2020-4-23_5-9-31.png
     
  36. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Thank you for your confirmation.
    How do you use Global Collider?
    For example, if you are just a skirt or hair collider, you don't need to check Global.
    Do you have any special reason?
     
  37. Micho_Dev

    Micho_Dev

    Joined:
    Nov 5, 2019
    Posts:
    6
    Oh, I thought it should be set Global when it's an avatar. It doesn't have to... Thank you.
    The skirt sometimes penetrates into the leg, but I think it will be okay if I set it up well. This is a really good Asset!
    upload_2020-4-23_6-10-40.png
     
  38. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Thank you for the verification.
    Let's investigate the cause of the problem when there is a global collider in the avatar part.
    For the time being, do not use the Global Collider.

    If your skirt bites your foot, check the following items.

    (1) Recreate Virtual Deformer
    The Virtual Deformer generation algorithm has changed in v1.6.0.
    If you are using MeshCloth and your data was created prior to v1.6.0, you may be able to improve it by recreating the new data.

    (2) Rotation Interpolation settings
    Rotatoin Interpolation parameter was added in v1.6.0, and you can specify rotation interpolation of particles.
    It may be improved by turning on / off the check in this.

    https://magicasoft.jp/en/paramater-adjust-line-2/

    Also, we haven't translated into English yet, but we are working on a guide for making skirts.
    Please refer to it if you like.

    BoneCloth Skirt
    https://magicasoft.jp/boneclothskirtguide/

    MeshCloth Skirt
    https://magicasoft.jp/meshclothskirtguide/
     
  39. Ukounu

    Ukounu

    Joined:
    Nov 2, 2019
    Posts:
    71
    Looks good, at least in the video. I kind of gave up on this asset in the past, due to all the skirt clipping issues. Will give it another try now.
     
  40. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Thank you.
    Cloth clipping issues are very difficult issues, but I would like to deal patiently.
     
  41. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Update: 1.6.1

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

    The friction process has been modified to reduce particle vibration.
    Fixed a problem that vertex painting could not be performed when there are two or more inspectors on the editor screen.


    Release Note:
    Improvement: Improved the friction processing algorithm. The problem of particles vibrating has been reduced.
    Fix: Fixed a problem that vertex painting could not be performed properly when there are two or more inspector windows in the editor.
    Fix: Fixed an issue that caused an error at the end of execution in the editor.

     
    Acissathar likes this.
  42. Ukounu

    Ukounu

    Joined:
    Nov 2, 2019
    Posts:
    71
    I experimented more with the newest version today. Unfortunately, every single issue that I mentioned earlier is still present.

    The biggest problem of the asset is clipping of clothes when characters actually move (as opposed to animation). Both promotion videos with Unity-chan and with that new dancing girl create an illusion that clothes can handle collisions with moving objects, but that happens only because both characters keep the same x/y/z position in the world without ever moving (all "movement" is done solely through animation clip). And when you attempt to actually move characters around the world, collision detection immediately fails and cloth begins to penetrate through colliders.

    The only way currently to deal with this is to set "world influence" parameter to 0, but that also disables all the effects of swaying clothes due to world movement, apparently.

    Making a realistic skirt is still impossible due to both "restore rotation" and "keep shape" making skirt to clip through colliders.

    Wind also forces clothes to penetrate through colliders - especially if your character moves towards wind (even if world influence is set to 0 and both "restore rotation" and "keep shape" are disabled).

    And without being able to use wind, "restore rotation", "keep shape", and "world influence", implementation of this asset for actual games will be very limited, I think.

    So, the full list of current issues is:
    1. World influence (any value above 0) overrides collisions and makes clothes to clip through colliders.
    2. Enabling "restore rotation" (any value above 0) overrides collisions and makes clothes to clip through colliders.
    3. Enabling "collision > keep shape" overrides collisions and makes clothes to clip through colliders.
    4. Wind (any value above 0) overrides collisions and makes clothes to clip through colliders.
     
    DragonSix likes this.
  43. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    Thank you for the detailed report.
    Actually, I have received the same problem from several people.
    I was a bit lacking in experiments on the effects of character movement.
    This issue is important, so I would like to stop doing other work for a while and work on it.
    However, since collision judgment is difficult, it may take 1-2 months.
    Please give me some time
    I would like to solve this problem somehow.
     
  44. a340523052

    a340523052

    Joined:
    Jun 6, 2019
    Posts:
    7
    upload_2020-4-29_15-53-5.png upload_2020-4-29_15-54-5.png upload_2020-4-29_15-52-34.png
    I use magica mesh cloth and the white side will through the black side,why?
     
  45. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    Thank you for contacting us.
    This is because MagicaCloth does not have self-collision, which may cause the cloths to slip out depending on the situation.
    If this happens, try the following settings.
    * See image

    (1) ClampDistance
    For long items such as coats, set MaxDistanceRatio to 1.0 so that it does not expand or contract too much.

    (2) ClampRotation
    Limit the cloth to a certain angle so that it is fluttered.
    Turn this feature on to keep the coat in its original position.

    (3) Restore Rotation
    Helps the cloth maintain its original posture.
    Similarly, turn this function on so that the coat retains its original posture.

    (4) TriangleBend
    Adjust the angle of the polygon so that the cloth keeps its original posture.
    Set it to a slightly larger value, around 0.7.

    (5) Restore Distance
    * This is important
    Turn on NearPoint so that the cloth gap is line-connected.
    It works by keeping a complex shape.
    It is good to adjust the connection of NearPoint while visually checking so that the gap is filled like the image.
    This requires a bit of trial and error.

    As mentioned in the above post, collision detection is currently unstable, and you may get caught up with the collider.
    In this case, for now, you can avoid it by lowering the Movement Ratio of World Influence to about 0.2.
    The collision detection is currently under repair.
    Thank you.

    coat-1.jpg coat-2.jpg coat-3.jpg
     
  46. NSokolovskyi

    NSokolovskyi

    Joined:
    Sep 1, 2017
    Posts:
    2
    Hello,
    Haven't used plugin since 1.3, now i am getting this errors, any workaround? I don't have enough skill to understand whats happening.
    Screenshot_1.jpg
    Cleaned up library and packages cache. Unity 2019.3.13f1, il2cpp, unsafe code, 1.6.1 magica.
     
  47. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    I tested it in the same environment and it worked.
    * Unity2019.3.13f1
    * IL2CPP + unsafe code
    * Burst 1.3.0 preview11
    * Jobs 0.2.9 preview5
    * HDRP 7.3.1

    I don't know the cause of the error.
    Just in case, can you ask for the next test?

    (1) Uninstall Burst, Jobs, Collections, Mathmatics package
    (2) Install Jobs package only

    With Unity 2019.3, Burst, Collections, Mathmatics will be installed automatically just by installing the Jobs package.
    This solves the problem of different package versions.
     
    NSokolovskyi likes this.
  48. a340523052

    a340523052

    Joined:
    Jun 6, 2019
    Posts:
    7
    How to use a same magica collider using dress up system? Like the avatar part body and hair,I want them use a same collider
     
  49. hoshos

    hoshos

    Joined:
    Mar 7, 2015
    Posts:
    142
    Hello,
    Unfortunately, it is currently not possible to set colliders that share the same avatar parts.
    You need to add a collider for each avatar part.
     
  50. NSokolovskyi

    NSokolovskyi

    Joined:
    Sep 1, 2017
    Posts:
    2
    Hey, did everything i can and you said, but the problem was in this script i found on the web:

    Code (CSharp):
    1. using UnityEngine;
    2. using System;
    3. using System.Reflection;
    4. using System.Text.RegularExpressions;
    5.  
    6. [AttributeUsage(AttributeTargets.Field, Inherited = true)]
    7. public class ReadOnlyAttribute : PropertyAttribute { }
    8.  
    9. #if UNITY_EDITOR
    10. [UnityEditor.CustomPropertyDrawer(typeof(ReadOnlyAttribute))]
    11. public class ReadOnlyAttributeDrawer : UnityEditor.PropertyDrawer
    12. {
    13.   public override void OnGUI(Rect rect, UnityEditor.SerializedProperty prop, GUIContent label)
    14.   {
    15.     bool wasEnabled = GUI.enabled;
    16.     GUI.enabled = false;
    17.     UnityEditor.EditorGUI.PropertyField(rect, prop);
    18.     GUI.enabled = wasEnabled;
    19.   }
    20. }
    21. #endif

    As everything worked fine in empty project i started deleting parts of my, so i found a problem.
    Have no idea why this causes errors and conflicts with your product, so i just deleted it.

    Thanks for respond, good luck
     
unityunity