bool CustomTransform_ForFudge() { GUIContent label = new GUIContent(string.Format("Transforms({0}) with Auto Depth", _spTransformsForFudge.arraySize), "Transforms registered here automatically apply Depth as much as Global Ground Offset. " + "Excluding it from the list restores the origin transform."); EditorGUI.BeginChangeCheck(); EditorGUILayout.PropertyField(_spTransformsForFudge, label, true); if (_spTransformsForFudge.isExpanded) { using (new EditorGUILayout.HorizontalScope()) { if (GUILayout.Button("Auto Setup")) { serializedObject.ApplyModifiedProperties(); _targetIsoBasis.AutoSetup_DepthTransforms(); serializedObject.Update(); } CustomEditorGUI.Button(true, Color.gray, "Clear Depthed Transforms", () => { _spTransformsForFudge.ClearArray(); }); } } return(EditorGUI.EndChangeCheck()); }
public static void Drawer(Rect rect, GameObject _target) { IsoTile _thisTile = _target.GetComponent <IsoTile>(); Iso2DObject _iso2D = _target.GetComponent <Iso2DObject>(); SpriteRenderer sprr = _target.GetComponent <SpriteRenderer>(); Color borderColor = Util.CustomEditorGUI.Color_Tile; if (_thisTile == null && _iso2D != null) { borderColor = CustomEditorGUI.Iso2DTypeColor(_iso2D._Type); } Rect rect_inside = new Rect(rect.xMin + border, rect.yMin + border, rect.width - border * 2, rect.height - border * 2); Rect rect_preview = new Rect(rect_inside.xMin, rect_inside.yMin, cellSize, rect_inside.height); Rect rect_info_name = new Rect(rect_preview.xMax, rect_inside.yMin, rect_inside.width - cellSize - fudgeWidth, rect_inside.height * 0.5f); Rect rect_Fudge = new Rect(rect_info_name.xMax, rect_inside.yMin, fudgeWidth, rect_inside.height * 0.5f - border); Rect rect_info_Sub = new Rect(rect_info_name.xMin, rect_info_name.yMin + cellSize * 0.5f, rect_info_name.width, rect_inside.height - rect_info_name.height); Rect[] rect_btns = new Rect[] { new Rect(rect_inside.xMax - cellSize * 1.1f, rect_info_Sub.yMin, cellSize, rect_info_Sub.height), new Rect(rect_inside.xMax - cellSize * 2.2f, rect_info_Sub.yMin, cellSize, rect_info_Sub.height), new Rect(rect_inside.xMax - cellSize * 3.3f, rect_info_Sub.yMin, cellSize, rect_info_Sub.height), new Rect(rect_inside.xMax - cellSize * 4.4f, rect_info_Sub.yMin, cellSize, rect_info_Sub.height) }; bool bControllerable = (_thisTile == null || _thisTile.gameObject != _target.gameObject) || (Selection.activeGameObject != null && Selection.activeGameObject.GetComponent <IsoTileBulk>()); CustomEditorGUI.DrawBordereddRect(rect, borderColor, rect_inside, Color.clear); CustomEditorGUI.DrawSideSprite(rect_preview, _iso2D, false, false); int iLv = EditorGUI.indentLevel; EditorGUI.indentLevel = 0; EditorGUI.LabelField(rect_info_name, _target.name, EditorStyles.boldLabel); if (!IsoMap.instance.bUseIsometricSorting) { var IIsoBasis = _iso2D.GetComponentInParent <IISOBasis>(); var isOnGroundObject = false; if (IIsoBasis != null) { isOnGroundObject = IIsoBasis.IsOnGroundObject(); } else { isOnGroundObject = _iso2D.IsColliderAttachment; } float fOnGroundOffset = IsoMap.fCurrentOnGroundOffset; string msg = isOnGroundObject ? string.Format("Depth({0:0.00})", -fOnGroundOffset) : "Depth"; float _fTmp = CustomEditorGUI.FloatSlider(rect_Fudge, msg, _iso2D.FDepthFudge, -1f, 1f); if (_fTmp != _iso2D.FDepthFudge) { _iso2D.Undo_NewDepthFudge(_fTmp); } } // 서브 인포 출력 //using (new EditorGUILayout.HorizontalScope()) { float _fMinSize = Mathf.Min(rect_info_Sub.width, rect_info_Sub.height); SpriteRenderer[] _sprrList = _target.GetComponentsInChildren <SpriteRenderer>(); for (int i = 0; i < _sprrList.Length; ++i) { if (_sprrList[i].sprite != null && _sprrList[i] != sprr) { Rect _rt = EditorGUI.IndentedRect(rect_info_Sub); _rt.width = _rt.height = _fMinSize; rect_info_Sub.xMin += _fMinSize; // CustomEditorGUI.DrawSideSprite(_rt, _sprrList[i].sprite, ._Type); Util.CustomEditorGUI.DrawSprite(_rt, _sprrList[i].sprite, _sprrList[i].color, true, true); } } } if (bControllerable) { int buttonIndex = 0; CustomEditorGUI.Button(rect_btns[buttonIndex++], true, CustomEditorGUI.Color_LightYellow, "Ping!", () => { EditorGUIUtility.PingObject(_target.gameObject); }); CustomEditorGUI.Button(rect_btns[buttonIndex++], true, CustomEditorGUI.Color_LightGreen, "Iso2D", () => { Selection.activeGameObject = _target.gameObject; }); var ctlr = _target.transform.parent.GetComponentInParent <SubColliderHelper>(); if (Selection.activeGameObject != ctlr.gameObject) { CustomEditorGUI.Button(rect_btns[buttonIndex++], true, CustomEditorGUI.Color_LightGreen, "Ctlr!", () => { Selection.activeGameObject = ctlr.gameObject; }); } CustomEditorGUI.Button(rect_btns[buttonIndex++].ReSize(2f, 2f), true, CustomEditorGUI.Color_LightYellow, "Del!!", () => { _iso2D.DestoryGameObject(true, true); }); } EditorGUI.indentLevel = iLv; }
void Inspector_Tile() { if (bNoBulk) { EditorGUILayout.LabelField("Not available in No Bulk Prefab!"); return; } using (new GUIBackgroundColorScope(Color.cyan)) { refTile = (IsoTile)EditorGUILayout.ObjectField(refTile, typeof(IsoTile), allowSceneObjects: true); } using (new EditorGUILayout.HorizontalScope()) { CustomEditorGUI.Button(refTile != null, Color.cyan, "Copycat", () => { for (int i = 0; i < targets.Length; ++i) { ((IsoTile)targets[i]).Copycat(refTile); } }); CustomEditorGUI.Button(true, CustomEditorGUI.Color_LightYellow, "Duplicate", () => { List <GameObject> _selection = new List <GameObject>(); for (int i = 0; i < targets.Length; ++i) { _selection.Add(((IsoTile)targets[i]).Duplicate().gameObject); } Undo.RecordObjects(Selection.objects, "IsoTile:Dulicate"); Selection.objects = _selection.ToArray(); }); CustomEditorGUI.Button(true, CustomEditorGUI.Color_LightMagenta, "Select Bulk", () => { Selection.activeGameObject = _tile_Inspector.Bulk.gameObject; }); } using (new EditorGUILayout.HorizontalScope()) { CustomEditorGUI.Button(true, Color.magenta, "Split bulk with selected tiles.", () => { IsoMap.instance.NewBulk(_tile_Inspector.Bulk, targets.Where(r => r != null && r is IsoTile).Cast <IsoTile>()); }); } EditorGUILayout.Separator(); EditorGUILayout.LabelField(string.Format( "Grid's Tile Scale : Width({0:0.00}), Height({1:0.00})", _tile_Inspector.coordinates.TileSize.x, _tile_Inspector.coordinates.TileSize.y)); float fWidth = EditorGUIUtility.currentViewWidth * 0.25f; using (new EditorGUILayout.HorizontalScope()) { string undoName = "Use AutoFit Collider"; EditorGUILayout.LabelField("Auto Fit", GUILayout.MaxWidth(fWidth)); EditorGUI.BeginChangeCheck(); EditorGUILayout.ToggleLeft("Collider", _tile_Inspector.bAutoFit_ColliderScale, GUILayout.MaxWidth(fWidth)); if (EditorGUI.EndChangeCheck()) { bool _bTmp = !_tile_Inspector.bAutoFit_ColliderScale; for (int i = 0; i < Selection.gameObjects.Length; ++i) { if (Selection.gameObjects[i] != null) { IsoTile _tTmp = Selection.gameObjects[i].GetComponent <IsoTile>(); if (_tTmp != null) { Undo.RecordObject(_tTmp, undoName); _tTmp.bAutoFit_ColliderScale = _bTmp; _tTmp.Update_ColliderScale(); } } } } EditorGUI.BeginChangeCheck(); EditorGUILayout.ToggleLeft("Sprite", _tile_Inspector.bAutoFit_SpriteSize, GUILayout.MaxWidth(fWidth)); if (EditorGUI.EndChangeCheck()) { bool _bTmp = !_tile_Inspector.bAutoFit_SpriteSize; for (int i = 0; i < Selection.gameObjects.Length; ++i) { if (Selection.gameObjects[i] != null) { IsoTile _tTmp = Selection.gameObjects[i].GetComponent <IsoTile>(); if (_tTmp != null) { Undo.RecordObject(_tTmp, undoName); _tTmp.bAutoFit_SpriteSize = _bTmp; _tTmp.Update_Attached_Iso2DScale(true, undoName); } } } } } EditorGUILayout.Separator(); EditorGUI.indentLevel = 0; }
public override void OnInspectorGUI() { if (IsoMap.IsNull || bPrefab) { base.DrawDefaultInspector(); return; } bool bAngleChanged = false; bool bISOChanged = false; bool bGroundOffsetToggleChanged = false; float fGroundOffsetValue = 0; serializedObject.Update(); CustomEditorGUI.NewParagraph("[Game Camera]"); spGameCamera.objectReferenceValue = EditorGUILayout.ObjectField( spGameCamera.objectReferenceValue, typeof(Camera), allowSceneObjects: true); EditorGUILayout.Separator(); CustomEditorGUI.NewParagraph("[Isometric Angle]"); EditorGUI.BeginChangeCheck(); spTileAngle.vector2Value = new Vector2( Util.CustomEditorGUI.FloatSlider("Up/Down", spTileAngle.vector2Value.x, -90f, 90f, EditorGUIUtility.currentViewWidth, true), Util.CustomEditorGUI.FloatSlider("Left/Right", spTileAngle.vector2Value.y, -90f, 90f, EditorGUIUtility.currentViewWidth, true)); if (EditorGUI.EndChangeCheck()) { bAngleChanged = true; } EditorGUILayout.Separator(); using (new EditorGUILayout.HorizontalScope()) { EditorGUILayout.LabelField("Reset", GUILayout.Width(75f)); using (new GUIBackgroundColorScope(Util.CustomEditorGUI.Color_LightBlue)) { if (GUILayout.Button("30°")) { spTileAngle.vector2Value = new Vector2(30f, -45f); bAngleChanged = true; } if (GUILayout.Button("35.264°")) { spTileAngle.vector2Value = new Vector2(35.264f, -45f); bAngleChanged = true; } } } EditorGUILayout.Separator(); CustomEditorGUI.NewParagraph("[Ref Tile Sprite]"); using (new EditorGUILayout.HorizontalScope()) { float fWidth = 120f; Rect _rt = EditorGUI.IndentedRect(EditorGUI.IndentedRect(GUILayoutUtility.GetRect(fWidth, fWidth * 0.5f))); CustomEditorGUI.DrawSprite(_rt, IsoMap.instance.RefTileSprite, Color.clear, true, false); using (new EditorGUILayout.VerticalScope()) { EditorGUILayout.Separator(); spReferencePPU.floatValue = EditorGUILayout.FloatField( string.Format("Pixel Per Unit : Ref({0})", IsoMap.instance.RefTileSprite.pixelsPerUnit), spReferencePPU.floatValue); EditorGUILayout.Separator(); EditorGUI.BeginChangeCheck(); Sprite _newSprite = (Sprite)EditorGUILayout.ObjectField( IsoMap.instance.RefTileSprite, typeof(Sprite), allowSceneObjects: false); if (EditorGUI.EndChangeCheck()) { if (_newSprite != null) { IsoMap.instance.RefTileSprite = _newSprite; //spReferencePPU.floatValue = IsoMap.instance.RefTileSprite.pixelsPerUnit; } } } } EditorGUILayout.Separator(); Util.CustomEditorGUI.NewParagraph("[Util]"); using (new EditorGUILayout.HorizontalScope()) { using (new GUIBackgroundColorScope(Util.CustomEditorGUI.Color_LightYellow)) { if (GUILayout.Button("New Bulk")) { IsoMap.instance.NewBulk(); CorruptCash(); } } using (new GUIBackgroundColorScope(Util.CustomEditorGUI.Color_LightGreen)) { if (GUILayout.Button("Reset Scene Camera")) { IsoMap.instance.Update_TileAngle(); } } } #region Global ISO EditorGUILayout.Separator(); CustomEditorGUI.NewParagraph("[Isometric Sorting Order]"); using (new EditorGUI.DisabledGroupScope(Application.isPlaying)) { bFoldoutISODesc = CustomEditorGUI.CAUTION_Foldout(EditorGUILayout.GetControlRect(), bFoldoutISODesc, "Plz, Foldout & Read before use Auto ISO."); if (bFoldoutISODesc) { EditorGUILayout.HelpBox( "IsometricSortingOrder(ISO) overrides the SortingOrder of all SpriteRenderers and " + "ParticleSystemRenderers attached to game objects (including children).", MessageType.Info); EditorGUILayout.HelpBox( "ISO calculates camera direction Depth using weight " + "and position of x, y, z axis based on isometric angle.", MessageType.Info); EditorGUILayout.HelpBox("If you want to batch edit the SortingOrder of multiple tiles, " + "set below 'Auto ISO' to false and use the CAUTION function in IsoTileBulk.", MessageType.Info); EditorGUILayout.HelpBox("When Auto ISO On / Off is switched, " + "\nthe existing SO values of the renderers are backed up by their respective ISO components.", MessageType.Info); using (new EditorGUILayout.HorizontalScope()) { EditorGUILayout.HelpBox("It can be cleared with the right button " + "\nif it is reset to an unintended value during switching or if the backup value is meaningless.", MessageType.Warning); if (GUILayout.Button("Delete\nBackups")) { IsoMap.instance.Clear_All_ISO_Backup(); IsoMap.instance.Update_All_ISO(); } } EditorGUILayout.HelpBox( "If the newly added renderer is not drawn, " + "make sure that the object has an IsometricSortingOrder component.", MessageType.Warning); EditorGUI.BeginChangeCheck(); spBISSO.boolValue = EditorGUILayout.ToggleLeft("Use Auto ISO", spBISSO.boolValue); if (IsoMap.instance.bUseIsometricSorting) { EditorGUI.indentLevel++; spUseCustomResolution.boolValue = !EditorGUILayout.ToggleLeft("Use Auto Resolution", !spUseCustomResolution.boolValue); EditorGUI.indentLevel--; if (spUseCustomResolution.boolValue) { spCustomResolution.vector3Value = Util.CustomEditorGUI.Vector3Slider(spCustomResolution.vector3Value, IsoMap.vMAXResolution, "Custom Resolution of Axis", Vector3.zero, IsoMap.vMAXResolution, EditorGUIUtility.currentViewWidth); } else { EditorGUILayout.LabelField("Resolution: " + IsoMap.instance.fResolutionOfIsometric); } } if (EditorGUI.EndChangeCheck()) { bISOChanged = true; } } } #endregion #region Offset_GroundObject EditorGUILayout.Separator(); bool bUseGroundObjectOffset = spUseGroundObjectOffset.boolValue; bUseGroundObjectOffset = Util.CustomEditorGUI.NewParagraphWithHideToggle( "[Offset for GroundObject]", "Use", bUseGroundObjectOffset); if (bGroundOffsetToggleChanged = (spUseGroundObjectOffset.boolValue != bUseGroundObjectOffset)) { spUseGroundObjectOffset.boolValue = bUseGroundObjectOffset; } if (bUseGroundObjectOffset) { fGroundOffsetValue = spGroundObjectOffset.floatValue; spGroundObjectOffset.floatValue = Util.CustomEditorGUI.FloatSlider("Global Offset for OnGroundObject", spGroundObjectOffset.floatValue, 0, 1, EditorGUIUtility.currentViewWidth); CustomEditorGUI.Button(true, CustomEditorGUI.Color_LightBlue, "Default", () => spGroundObjectOffset.floatValue = IsoMap.fOnGroundOffset_Default, GUILayout.MaxWidth(EditorGUIUtility.currentViewWidth)); fGroundOffsetValue = spGroundObjectOffset.floatValue - fGroundOffsetValue; } else { EditorGUILayout.HelpBox("With this option, the depth of the following ground objects is adjusted in a batch.\n" + "All components that inherit IsometricMovement or RegularCollider.\n" + "Those are Characters and Tile Attachments.", MessageType.Info); } #endregion EditorGUILayout.Separator(); Util.CustomEditorGUI.NewParagraph("[Prefab]"); if (bEditPrefab = EditorGUILayout.ToggleLeft("Edit Prefab", bEditPrefab)) { EditorGUILayout.LabelField("Core Object"); EditorGUI.indentLevel++; spBulkPrefab.objectReferenceValue = EditorGUILayout.ObjectField("Bulk", spBulkPrefab.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spTilePrefab.objectReferenceValue = EditorGUILayout.ObjectField("Tile", spTilePrefab.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spOverlay.objectReferenceValue = EditorGUILayout.ObjectField("Overlay", spOverlay.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spTriggerPlaneOverlay.objectReferenceValue = EditorGUILayout.ObjectField("Trigger IsoPlane Overlay", spTriggerPlaneOverlay.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spTriggerCubeOverlay.objectReferenceValue = EditorGUILayout.ObjectField("Trigger Cube Overlay", spTriggerCubeOverlay.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spObstacle.objectReferenceValue = EditorGUILayout.ObjectField("Obstacle", spObstacle.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); EditorGUILayout.Separator(); EditorGUI.indentLevel--; EditorGUILayout.LabelField("Side Object"); EditorGUI.indentLevel++; spSideUnion.objectReferenceValue = EditorGUILayout.ObjectField("Union", spSideUnion.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spSideX.objectReferenceValue = EditorGUILayout.ObjectField("Axis-X", spSideX.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spSideY.objectReferenceValue = EditorGUILayout.ObjectField("Axis-Y", spSideY.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spSideZ.objectReferenceValue = EditorGUILayout.ObjectField("Axis-Z", spSideZ.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); EditorGUILayout.Separator(); EditorGUI.indentLevel--; EditorGUILayout.LabelField("Regular Collider Object"); EditorGUI.indentLevel++; spRCU.objectReferenceValue = EditorGUILayout.ObjectField("Cube", spRCU.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spRCX.objectReferenceValue = EditorGUILayout.ObjectField("Plane-YZ", spRCX.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spRCY.objectReferenceValue = EditorGUILayout.ObjectField("Plane-XZ", spRCY.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); spRCZ.objectReferenceValue = EditorGUILayout.ObjectField("Plane-XY", spRCZ.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); EditorGUILayout.Separator(); EditorGUI.indentLevel--; EditorGUILayout.LabelField("Regular Collider Object"); EditorGUI.indentLevel++; spTchPrefab.objectReferenceValue = EditorGUILayout.ObjectField("Tall Character Helper", spTchPrefab.objectReferenceValue, typeof(GameObject), allowSceneObjects: false); EditorGUI.indentLevel--; } serializedObject.ApplyModifiedProperties(); if (bISOChanged) { IsoMap.instance.UpdateIsometricSortingResolution(); if (spBISSO.boolValue) // false -> true { IsoMap.instance.Update_All_ISO(IsoMap.instance.Backup_All_ISO()); } else // true -> false { // 백업된 so로 복구 IsoMap.instance.Update_All_ISO(IsoMap.instance.Revert_All_ISO()); } } else if (bAngleChanged) { IsoMap.instance.Update_TileAngle(); IsoMap.instance.Update_All_ISO(); } if (bGroundOffsetToggleChanged) { update_GroundOffset(); } else if (fGroundOffsetValue != 0) { IsoMap.UpdateSortingOrder_All_ISOBasis(); IsoMap.UpdateGroundOffsetFudge_All_ISOBasis(ref _alIIsoBasisCash, fGroundOffsetValue); } // DrawPropertiesExcluding(serializedObject, "m_Script"); }
void SortingOrder(ref bool bLocalOnGroundToggle, ref bool bGlobalChanged, ref bool bChangedDepthTransform) { _spDoNotDestroyAutomatically.boolValue = EditorGUILayout.ToggleLeft( new GUIContent("[Tooltip] This Will not automatically destroyed.", "If you enable this option, this ISOBasis will not be automatically destroyed" + " even if the [Offset for GroundObject setting of IsoMap] is turned off."), _spDoNotDestroyAutomatically.boolValue); CustomEditorGUI.DrawSeperator(); if (IsoMap.IsNull || !IsoMap.instance.bUseIsometricSorting) { EditorGUILayout.HelpBox("SortingOrder Basis only works in Auto ISO mode.", MessageType.Info); } else { EditorGUI.BeginChangeCheck(); _spISOOffest.vector3Value = Util.CustomEditorGUI.Vector3Slider( _spISOOffest.vector3Value, Vector3.zero, "SortingOrder Basis", -0.5f * Vector3.one, 0.5f * Vector3.one, EditorGUIUtility.currentViewWidth); bLocalOnGroundToggle |= EditorGUI.EndChangeCheck(); } CustomEditorGUI.DrawSeperator(); using (new EditorGUILayout.HorizontalScope()) { EditorGUI.BeginChangeCheck(); _spOnGroundObject.boolValue = EditorGUILayout.ToggleLeft("IsOnGroundObject", _spOnGroundObject.boolValue); bLocalOnGroundToggle |= EditorGUI.EndChangeCheck(); if (_spOnGroundObject.boolValue) { bEditOnGroundOffset = EditorGUILayout.Toggle("Edit Global Offset", bEditOnGroundOffset); } } if (_spISOOffest == null) { return; } float fOnGroundOffset = IsoMap.instance.fOnGroundOffset; if (_ISOTarget == null) { Debug.LogWarning("ISOBasis must be located in the game object where the RC or ISO components reside."); return; } if (_spOnGroundObject.boolValue) { Util.CustomEditorGUI.NewParagraph("[Tooltip], What is OnGroundOffset? ", "Give them a global offset so that things on the ground are not covered by the edge of tile image of the ground.\n" + "This has the effect of changing the screen depth of the Sprite object. In particular, it affects the SO calculation in AutoIso mode."); if (IsoMap.instance.bUseIsometricSorting) { string desc = string.Format("New SortingOrder is {0}: Modified from {1}", _ISOTarget.CalcSortingOrder(true), _ISOTarget.CalcSortingOrder(false)); EditorGUILayout.LabelField(desc); } if (_targetIsoBasis.Parent != null) { EditorGUILayout.ObjectField("Parent ISOBasis", _targetIsoBasis.Parent, typeof(ISOBasis), allowSceneObjects: true); } else { if (bEditOnGroundOffset) { EditorGUI.BeginChangeCheck(); fOnGroundOffset = Util.CustomEditorGUI.FloatSlider("Global Offset", fOnGroundOffset, 0, 1, EditorGUIUtility.currentViewWidth); CustomEditorGUI.Button(true, CustomEditorGUI.Color_LightBlue, string.Format("Reset ({0})", IsoMap.fOnGroundOffset_Default), () => fOnGroundOffset = IsoMap.fOnGroundOffset_Default, GUILayout.MaxWidth(EditorGUIUtility.currentViewWidth)); bGlobalChanged |= EditorGUI.EndChangeCheck(); if (bGlobalChanged) { Undo.RecordObject(IsoMap.instance, "ISOBasis: Edit Ground Offset"); IsoMap.instance.fOnGroundOffset = fOnGroundOffset; } } EditorGUILayout.Space(); bChangedDepthTransform = CustomTransform_ForFudge(); CustomEditorGUI.DrawSeperator(); } } return; }