add some extra assets FX and SFX

This commit is contained in:
Robii Aragon
2026-03-29 23:03:14 -07:00
parent 6ef3eb1535
commit 24dc66a81e
10142 changed files with 2535978 additions and 36608 deletions

View File

@@ -0,0 +1,48 @@
using UnityEngine;
using System.Collections;
using UnityEditor;
using EzySlice;
/**
* This is a simple Editor helper script for rapid testing/prototyping!
*/
[CustomEditor(typeof(ShatterExample))]
public class ShatterExampleEditor : Editor {
public GameObject source;
public Material crossMat;
public int slice;
public override void OnInspectorGUI() {
ShatterExample plane = (ShatterExample)target;
source = (GameObject)EditorGUILayout.ObjectField(source, typeof(GameObject), true);
if (source == null) {
EditorGUILayout.LabelField("Add a GameObject to Shatter.");
return;
}
if (!source.activeInHierarchy) {
EditorGUILayout.LabelField("Object is Hidden. Cannot Slice.");
return;
}
if (source.GetComponent<MeshFilter>() == null) {
EditorGUILayout.LabelField("GameObject must have a MeshFilter.");
return;
}
crossMat = (Material)EditorGUILayout.ObjectField(crossMat, typeof(Material), true);
slice = EditorGUILayout.IntSlider(slice, 1, 20);
if (GUILayout.Button("Shatter Object")) {
if (plane.ShatterObject(source, slice, crossMat)) {
source.SetActive(false);
}
}
}
}