Created
October 31, 2013 13:16
-
-
Save mathiassoeholm/7249504 to your computer and use it in GitHub Desktop.
Resize collider
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEditor; | |
using UnityEngine; | |
public static class NGUIResizeCollider | |
{ | |
[MenuItem("Kiloo/NGUI Tools/Resize Collider")] | |
private static void ResizeCollider() | |
{ | |
if (Selection.activeGameObject != null && (Selection.activeGameObject.collider as BoxCollider) != null) | |
{ | |
NGUITools.UpdateWidgetCollider(Selection.activeGameObject.collider as BoxCollider, true, true); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment