浏览代码

[Bot] Automated dotnet-format update

/devlogs-4-addressable-assets
gheraibia 3 年前
当前提交
005ee0b6
共有 4 个文件被更改,包括 20 次插入18 次删除
  1. 5
      UOP1_Project/Assets/Scripts/Editor/Pathway/PathWayNavMeshUI.cs
  2. 6
      UOP1_Project/Assets/Scripts/Editor/Pathway/PathwayEditor.cs
  3. 13
      UOP1_Project/Assets/Scripts/Editor/Pathway/PathwayGizmos.cs
  4. 14
      UOP1_Project/Assets/Scripts/Editor/Pathway/PathwayNavMesh.cs

5
UOP1_Project/Assets/Scripts/Editor/Pathway/PathWayNavMeshUI.cs


{
private Pathway _pathway;
private PathwayNavMesh _pathwayNavMesh;
public PathWayNavMeshUI(Pathway pathway)
{
_pathway = pathway;

}
}
public void UpdatePath() {
public void UpdatePath()
{
if (!_pathway.DisplayProbes)
{

6
UOP1_Project/Assets/Scripts/Editor/Pathway/PathwayEditor.cs


private Pathway _pathway;
private PathwayHandles _pathwayHandles;
private PathWayNavMeshUI _pathWayNavMeshUI;
private enum LIST_MODIFICATION { ADD, SUPP, DRAG, OTHER};
private enum LIST_MODIFICATION { ADD, SUPP, DRAG, OTHER };
private LIST_MODIFICATION _currentListModification;
private int _indexCurrentModification;

_pathWayNavMeshUI.RealTime(index);
_pathWayNavMeshUI.RealTime(index);
}
public override void OnInspectorGUI()

{
serializedObject.UpdateIfRequiredOrScript();
if (_reorderableList.index >= _reorderableList.serializedProperty.arraySize )
if (_reorderableList.index >= _reorderableList.serializedProperty.arraySize)
{
_reorderableList.index = _reorderableList.serializedProperty.arraySize - 1;
}

13
UOP1_Project/Assets/Scripts/Editor/Pathway/PathwayGizmos.cs


using UnityEditor;
public class PathwayGizmos
public class PathwayGizmos
{
{
if (!pathway.ToggledNavMeshDisplay)
{
DrawHandlesPath(pathway);

}
private static void DrawLabel(Pathway pathway,Vector3 path, int index)
private static void DrawLabel(Pathway pathway, Vector3 path, int index)
{
GUIStyle style = new GUIStyle();
Vector3 textHeight = Vector3.up;

private static void DrawNavMeshPath(Pathway pathway)
{
Handles.color = pathway.LineColor;
for (int i = 0 ; i < pathway.Path.Count - 1; i++)
for (int i = 0; i < pathway.Path.Count - 1; i++)
if (i < pathway.Waypoints.Count) {
if (i < pathway.Waypoints.Count)
{
DrawLabel(pathway, pathway.Waypoints[i].waypoint, i);
}
}

14
UOP1_Project/Assets/Scripts/Editor/Pathway/PathwayNavMesh.cs


using System.Collections.Generic;
using System.Linq;
public class PathwayNavMesh
public class PathwayNavMesh
public PathwayNavMesh(Pathway pathway)
{
_pathway = pathway;

{
_pathway.Waypoints[startIndex].corners = result;
}
return result != null;
}

if (_pathway.Waypoints.Count > 1 && index <_pathway.Waypoints.Count)
if (_pathway.Waypoints.Count > 1 && index < _pathway.Waypoints.Count)
{
if (index == 0)
{

else if (index == _pathway.Waypoints.Count - 1)
{
else
else
{
canUpdate = CopyCorners(index - 1, index);
canUpdate &= CopyCorners(index, index + 1);

正在加载...
取消
保存