Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

[Released] Mesh Destruction "Piecemaker"

Discussion in 'Assets and Asset Store' started by Marrrk, May 29, 2011.

  1. ProjectOne

    ProjectOne

    Joined:
    Aug 9, 2010
    Posts:
    442
    Hi, does Piecemaker work fine with Unity 4?
    Thanks
     
  2. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    i use piecemaker quite a lot and found it works pretty fine under unity 4 but you do get a lot of warning messages about deprecated functions etc, not a problem (for now) but a bit irritating
     
  3. ProjectOne

    ProjectOne

    Joined:
    Aug 9, 2010
    Posts:
    442
    Thanks Lazygunn
     
  4. Zozo2099

    Zozo2099

    Joined:
    Jul 15, 2012
    Posts:
    478
    Please can someone tell me if it is fully compatible with Unity 4? thanks
     
  5. Adam-Buckner

    Adam-Buckner

    Joined:
    Jun 27, 2007
    Posts:
    5,664
    Zozo2099: I'd go with this:

     
  6. Zozo2099

    Zozo2099

    Joined:
    Jul 15, 2012
    Posts:
    478
    Thank you !
     
  7. Eyeshock

    Eyeshock

    Joined:
    Sep 7, 2012
    Posts:
    60
    Nevermind. Thanks!
     
    Last edited: Jan 11, 2013
  8. Gekigengar

    Gekigengar

    Joined:
    Jan 20, 2013
    Posts:
    705
    I am working with unity 4,

    and I bought piece maker yesterday, (Through Paypal, Asset Store)

    I tried this on the 3rd test scene,

    and it does not work as well as the Web Browser Version,

    Example Cases :

    when you cut a cylinder horizontally, BOTH of the pieces fly upwards for a very high distance, most objects fly away at a very high velocity, which is very unrealistic. (does not happen on the Web Browser Version).

    Sometimes it does not cut the objects with the slicer bullet, even though the sound effect applies,

    IT IS NOT as smooth as the Web Browser Version, sometimes the slicer LAGS/DELAYED, before cutting the object,

    It is very hard to slice things on air (Sometimes does not cut), compared to the web browser version...

    And i paid $30 for this, i felt ripped off,
    and to think there is another mesh slicer script in the store.

    Is there any way i could get the older version?

    anyways, are there any examples on how to slice with complex mesh?

    Such as meshes which were grouped.
     
    Last edited: Jan 20, 2013
  9. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    Ive never even used the slicing aspect of this, so i found it great value, i always saw the slicing as an afterthought
     
  10. Goat45

    Goat45

    Joined:
    Feb 3, 2013
    Posts:
    3
    Hi,

    I bought Piecemaker last week and I need some help with a small piece of code in unity.

    I use javascript in combination with piecemaker and I can't get it to work.

    The only thing I want is when I click leftmouse button, my object gets destroyed (break into pieces).

    I tried to place this code on the object that needs to be destroyed.

    Code (csharp):
    1.  
    2. function Update () {
    3.     // Did the user press fire?
    4.     if (Input.GetButton ("Fire1")) {
    5.             gameObject.TakeDamage(5f,transform.position,transform.position,gameObject);
    6.             gameObject.Destruct();
    7.         }
    8. }
    9.  
    Most time i get the error "method not found".

    Can someone please put me on the right track?

    Tnx..
     
  11. Adam-Buckner

    Adam-Buckner

    Joined:
    Jun 27, 2007
    Posts:
    5,664
    Can you paste the exact error from your console here?
     
  12. Goat45

    Goat45

    Joined:
    Feb 3, 2013
    Posts:
    3
    Tnx for your reply!

    MissingMethodException: Method not found: 'UnityEngine.GameObject.TakeDamage'.

    And a lot more but I don't think you need that? It starts with:

    Boo.Lang.Runtime.DynamicDispatching.MethodDispatcherFactory.ProduceExtensionDispatcher ()
    Boo.Lang.Runtime.DynamicDispatching.MethodDispatcherFactory.Create ()

    Etc.
     
  13. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    TakeDamage isn't a method of the GameObject class, TakeDamage is a piecemaker method and GameObject is a class supplied by Unity itself, you'd want to use objects supplied by the piecemaker API

    i think?
     
  14. Goat45

    Goat45

    Joined:
    Feb 3, 2013
    Posts:
    3
    Tnx lazygunn, that makes sense, so it must be something like this (correct me if Im wrong):

    Code (csharp):
    1. [piecemakerObject].TakeDamage(5f,transform.position,transform.position,gameObject);
    And do you know where I can find the Piecemaker objects?

    EDIT:
    I tried the following from a previous post

    Code (csharp):
    1. PieceDestructable.Destruct(instigator, damageDirection, damageGiverPosition, force, upForce, explosionRadius);
    But I get

    BCE0005: Unknown identifier: 'PieceDestructable'.
     
    Last edited: Feb 12, 2013
  15. lazygunn

    lazygunn

    Joined:
    Jul 24, 2011
    Posts:
    2,749
    PieceDestructable is the class but you want to use the method on a specific object that is an instance of the class in your game, so if you'd specified that in your code you would use its name

    You might want to figure some things out about object orientated programming before continuing on this
     
  16. AzraelKans

    AzraelKans

    Joined:
    Oct 29, 2009
    Posts:
    135
    Im back to this thread. :)

    Is piecemaker still being worked on? is been a while since I hear about piecemaker 2.0 I was eagerly waiting for that release.

    Anyway I have been working recently with a version of our game for iPad (2) and I have found the instancing seems really slow while using PieceMaker, is not due to the number of instances (since I have greatly decreased the number of slices for that version) and is not the instancing itself, since there are enemies being instanced (Im going to use pooling but right now they are normal instances) so Im not sure why is that happening. Has anyone been able to run piecemaker in an iPad at a good framerate?
     
  17. artician

    artician

    Joined:
    Nov 27, 2009
    Posts:
    343
    Hi,
    I purchased Piecemaker tonight for use in a personal project, and I'm getting errors when I try to process a simple cube.
    I am running Unity 3.5.6f4.

    My object is a cube, minus one face (the bottom). Otherwise the entire model is a single mesh with a total of 5 faces. (Note: I noticed you recommended closed meshes, so I also tried this with a cube and received the same error).
    The steps I take for this error are:

    I assign the mesh for the object.
    I apply the proper material (same as the original GameObject).
    I deselect "Search and Split Isolated Meshparts".
    I change the "Level Count" property to 2.
    In the 'Root', 'Level 1' and 'Level 2' properties, the only field I change is to set the "Collider" property to "none".
    I do not enter any data into any other field, and otherwise all settings are default.

    When I click Process, I immediately get a series of repeating errors, and I'm forced to shutdown the Unity windows process.
    Because the error window doesn't allow the standard Windows ctrl-c for copying the error dialog, I will repeat the error text here. I sure hope you can help because this is a pain.

    "Error

    An error ocured(sic) while executing the operation, please verify your settings and try again.

    UnityEngine.MissingComponentException: There is no 'Collider' attached to the "New Game Object" game object, but a script is trying to access it.
    You probably need to add a Collider to the game object 'New Game Object'. Or your script needs to check if the component is attached before using it.
    at (wrapper managed-to-native) UnityEngine.Collider:set_sharedMaterial (UnityEngine.PhysicsMaterial) at Piecemaker.DefaultLevelPropertyApplicatorBase.ApplyOnTarget (UnityEngine.gameObject.gameObject, ApplyTargetType targetType, UnityEngine.Mesh.shardMesh, UnityEngine.Mesh collisionMesh, Piecemaker.Settings settings) [0x00261] in
    E:\_Projects\gameDev\<omittedforprivacy>\Assets\PieceMaker\Scripts\Piecemaker\Applicators\PiecemakerDefaultLevelpropertyApplicator.cs:131

    at Piecemaker.DefaultLevelPropertyApplicatorBase.ApplyOnTarget (UnityEngine.gameObject.gameObject, ApplyTargetType targetType, UnityEngine.Mesh.shardMesh, UnityEngine.Mesh collisionMesh, Piecemaker.Settings settings) [0x00000] in
    E:\_Projects\gameDev\<omittedforprivacy>\Assets\PieceMaker\Scripts\Piecemaker\Applicators\PiecemakerDefaultLevelpropertyApplicator.cs:189

    at Piecemaker.PiecemakerCore.CreateGameObject (UnityEngine.Mesh shardMesh, Piecemaker.LevelData levelData) [0x00288] in
    E:\_Projects\gameDev\<omittedforprivacy>\gameData\\Assets\PieceMaker\Editor\Common\PiecemakerCore.cs:285
    at Piecemaker.PiecemakerCore.FinishedProcessing () [0x00016] in
    E:\_Projects\gameDev\<omittedforprivacy>\gameData\\Assets\PieceMaker\Editor\Common\PiecemakerCore.cs:428"

    Apologies for any typos, that was a lot of text. I hope you can help.

    Thanks in advance.
     
    Last edited: Feb 21, 2013
  18. Supauch

    Supauch

    Joined:
    Jan 8, 2013
    Posts:
    1
    How well does this work on iOS/Android devices?
     
  19. artician

    artician

    Joined:
    Nov 27, 2009
    Posts:
    343
    Is there no support for this product?
     
  20. Adam-Buckner

    Adam-Buckner

    Joined:
    Jun 27, 2007
    Posts:
    5,664
    Artician: Most of those errors seem both self explanatory and not related to this product.

    If you read these in detail:

    • UnityEngine.MissingComponentException says there is an error and that you are missing a component.
    • There is no 'Collider' attached to the "New Game Object" game object, but a script is trying to access it. tells you what component is missing ('Collider') and what game object it's missing from ('New Game Object').
    • You probably need to add a Collider to the game object 'New Game Object'. tells you what to do (Add a collider to 'New Game Object')
    • Or your script needs to check if the component is attached before using it. This is an alternative if your object may or may not have a collider: Check for it first before trying to access it.
     
  21. wccrawford

    wccrawford

    Joined:
    Sep 30, 2011
    Posts:
    2,039
    It looks like Marrrk hasn't posted since December. He may have some life issues he's dealing with. If you've got direct contact info for him, I'd use that to try to get ahold of him for support.
     
  22. nilly

    nilly

    Joined:
    Mar 25, 2013
    Posts:
    1
    Hi, hopefully marrrk will come online and see this, otherwise someone else might offer some advice. I bought this a while ago and are now putting it to use, what i need and cant get to work is getting an object i my case a vase, to break when being pushed from a table to the ground to break, not much force here, cant get it to work even with zero lifepoints, any tip on how to go about this? need to break at hitting the floor basicly, without any damage made to it.

    And how would i go about breaking an object thru javascript only? without interacting with the object ingame with the character..
    might be able to script the vase breakage if i new how to communicate with PM from js.

    Thanks for any help!
     
  23. Adam-Buckner

    Adam-Buckner

    Joined:
    Jun 27, 2007
    Posts:
    5,664
    IIRC, and it's been a while since I've look at the contents of this package... you can call the destruction function, so: OnCollisionEnter if Other.Tag == Floor - DestructionFunction();

    You'd have to look thru the code to see what is being called specifically.

    fwiw, ymmv ...
     
  24. MegaStevenLP

    MegaStevenLP

    Joined:
    Feb 27, 2013
    Posts:
    69
    Could you release a limited free Version?
     
  25. Headworker

    Headworker

    Joined:
    Sep 6, 2012
    Posts:
    28
    Does anybody know if Marrk has been resurrected?
    Ive bought the package, and it seems to be solid, but I am still having problems to figure out the code to get rid of error warnings and to make it do exactly what I want.
     
  26. Adam-Buckner

    Adam-Buckner

    Joined:
    Jun 27, 2007
    Posts:
    5,664
    Not sure of the state of Marrk.

    If you post the warnings you are getting, we can try to sort thru them.

    In general, errors and warnings will be somewhat self explanatory, if you take the time and care to read them. If you are still confused, select the warning in the upper console, and the details for that warning will be printed in the lower console, where you will be able to select and copy it. Paste them here in a post.We'll see if we can get it to work.

    Lastly, if they are simply warnings, they could simply be ignored in many cases, even if they are annoying to see in the console.
     
  27. Headworker

    Headworker

    Joined:
    Sep 6, 2012
    Posts:
    28
    Thanks a lot Adam for jumping in :)

    Note: Ive been working and researching 20+ hours to get this to work. But I just dont know how to fix the following problems. I think the tool is great, but without some help I just wont be able to use it. I did send a pm to marrk about my problem, but (so far, was yesterday) got no answer.

    1st Problem : Every time I stop Playmode I get the following Error: !IsPlayingOrAllowExecuteInEditMode ()
    My Guess is that this error is somehow connected to the tool-integrated Thread Utilities, which are frankly way beyond my comprehension at the moment.
    2nd Problem: I am only using the Split(gun) part of the tool, to split meshes in my current prototype. Id like to delete some of the unnessary scripts of the package from my project, but my dependency research has not yet been sucessful.

    3rd (and biggest Problem): My Meshes get split, then there is a delay of about 5 seconds and then the colliders get resized, i tried ticking and unticking every option, sometimes they also seem to be cutted in odd angles (quite randomly, most time they are cut perfect).

    4th (and smallest Problem): Some functions used by the package are deprecated and Ive swapped them with the recommended ones. I wonder if this could be part off the reason of the odd behaviour.
     
  28. Headworker

    Headworker

    Joined:
    Sep 6, 2012
    Posts:
    28
    To clarify 3:

    The main problem is that both resulting meshes keep the pre-cut collider after the slice. This results in odd collision behaviour.


    Edit: Does anybody know about my options to get a (partial) refund? The tool is unusable at its current state and with no support it has a null value for me.
     
    Last edited: Jan 24, 2014
  29. allinlabs

    allinlabs

    Joined:
    Dec 31, 2012
    Posts:
    15
    Hello all.

    Is this package really unusable like previously stated? No update / support / bugfix from the creator?
     
  30. Adam-Buckner

    Adam-Buckner

    Joined:
    Jun 27, 2007
    Posts:
    5,664
    It's hard to say. It was "working" for me the last time I used it in Unity 4. You may find there is some value buying this and modifying the scripts. The last update was for Unity 3.4.2 on Feb 16 2012, so tread carefully. You may find that there are other mesh cutting packages on the store if you search... who knows?

    FWIW: I've not touched this in years, nor have I heard from Marrk in a while. Please realize that this is a rather stale thread and a very stale product.
     
  31. allinlabs

    allinlabs

    Joined:
    Dec 31, 2012
    Posts:
    15
    Thank you for your answer! I searched for similar assets on the store, and already tried some.
    • Exploder is easy to use and fast on mobile, but it cuts the whole mesh, you can't choose which part is cutted.
    • Fracturing and Destruction has some pretty cool features like structural behavior, but on the other and it's not a real time fracturing tool.
    • DinoFracture has real time fracturing features, but when i'm using it, even whith simple models, I have some serious FPS drops. I'm still trying to figuring out how to use it, it might be my best option
    • Shatter Toolkit seems very promising too, I haven't tried it, I'm wondering how well optimized it is, especially on mobile. Still waiting for the developer to answer me before buying.
    • Mesh Severe Blade seems very cool on paper, but there's no demo, no video and the developer never answered any questions, so I'll consider it a scam
    There's also Fracture Pro and Turbo Slicer. But I'm not sure the first one will let me cut meshes the way I want or will perform well on mobile; and the second one is not cheap, not cheap at all...
     
  32. Adam-Buckner

    Adam-Buckner

    Joined:
    Jun 27, 2007
    Posts:
    5,664
    Mesh Severing Blade is probably not a scam as much as another stale package. It was uploaded in 2013:
    Version: 1.2.1 (Dec 12, 2013)
    Originally released: 12 December 2013
    Package has been submitted using Unity 4.0.0.

    Don't forget that support and updates take a developer's time, and - if for some reason - the package doesn't get a lot of attention, it's difficult for a developer to continue to invest time into it.
     
  33. zugsoft

    zugsoft

    Joined:
    Apr 23, 2014
    Posts:
    453
    Shatter Tool kit works well on Mobile, I Will create a apk with all feature today for you.
     
  34. allinlabs

    allinlabs

    Joined:
    Dec 31, 2012
    Posts:
    15
    Thanks a bunch! <3
    I actually saw your post about the android performance on the Shatter Toolkit thread, but your link was dead and I want to test it myself.