Hello Guest

Author Topic: [RELEASED] 2D ColliderGen extension for 2D Toolkit - Instant Polygon Colliders  (Read 7159 times)

Pixelcloud Games

  • Newbie
  • *
  • Posts: 3
    • View Profile
    • Pixelcloud Games
The great guys from Unikron Software liked our extension and allowed us to post the following announcement:

2D ColliderGen extension for the 2D Toolkit framework has just been released
- Create Precise Polygon Colliders for Entire Scenes at the Click of a Button - Instant 2D Physics -

We have just released the extension 2D ColliderGen which fully integrates with 2D Toolkit.
The 2D ColliderGen framework allows you to automatically generate precise polygon colliders for multiple sprites from the sprite image?s alpha-channel. It fully integrates with the 2D Toolkit SpriteCollection editor and lets you tweak the collider outline afterwards as usual, but it replaces the tedious work to manually set each single vertex by hand (and it's fun to use ;) ).

Visit the Unity Forum Thread here for more information:
http://forum.unity3d.com/threads/174072-RELEASED-2D-ColliderGen-Generate-Precise-Polygon-Colliders-For-Your-2D-Sprites







Tutorial Video
[youtube]http://www.youtube.com/watch?v=jdcz9EM3sr4[/youtube]

We have chosen to officially support 2D Toolkit because we think it's one of the three best 2D extensions for Unity and we use it ourselves, but that it could get even better with automatic MeshColliders for 2D sprites.

Hope you like it! :)
If you have any questions, don't hesitate to ask!
« Last Edit: March 17, 2013, 07:57:05 pm by Pixelcloud Games »
Harald Csaszar | Pixelcloud Games | Check out 2D ColliderGen for Unity

x8105

  • 2D Toolkit
  • Jr. Member
  • *
  • Posts: 85
    • View Profile
Say I have 4000 static Cubes in my scene collision is being detected only on 4 of the 6 sides, and in addition to this they are clumped together and in a few instances (40-60%) don't have visible sides, we want functionality of ... or at least a foot in the door to real time collider manipulation, Is this plugin strictly in the editor, or does your plugins code have ANY run time functionality that we can utilize to achieve our goal?

Pixelcloud Games

  • Newbie
  • *
  • Posts: 3
    • View Profile
    • Pixelcloud Games
Thank you for your interest in our extension!

Quote
Is this plugin strictly in the editor, or does your plugins code have ANY run time functionality that we can utilize to achieve our goal?

In general: yes - You could use functionality contained in the plugin to calculate a polygon fence for a given image at runtime, but you would have to write some code for this yourself at this time. The plugin provides methods such as BinaryAlphaThresholdImageFromTexture(), TriangleFenceOutlineFromBinaryImage(), etc, that could be used for your purpose.

However, we have not yet tried modifying MeshColliders at runtime, but you could have a look at these forum posts here [1] [2]. The Unity engine itself could come with some performance-limitations in this case, so we suggest that you try out changing MeshColliders at runtime first to see if this fits your performance requirements.

If it does, feel free to cantact us if you need any help on the issue. Maybe we will put runtime-mesh-colliders on our roadmap for future updates, so that users won't need to write any additional code to achieve this.

King Regards,
  Harald

[1] http://forum.unity3d.com/threads/32467-How-to-update-a-mesh-collider
[2] http://answers.unity3d.com/questions/171571/dynamic-mesh-collider.html
Harald Csaszar | Pixelcloud Games | Check out 2D ColliderGen for Unity