This commit is contained in:
账号名 2024-01-23 20:18:05 +08:00
commit 9489544902
6 changed files with 12 additions and 35 deletions

View File

@ -1 +1 @@
172.20.10.5:48888
127.0.0.1:48888

View File

@ -1 +1 @@
172.20.10.5
127.0.0.1

View File

@ -103,8 +103,6 @@ namespace Umawerse.FiniteStateMachines
_line.positionCount = vertices.Count;
var vs = vertices.ToArray();
_line.SetPositions(vs);
root.wrjManager.currentWRJ.wayPoints = vertices;
}
private void CorrectDirection()

View File

@ -104,7 +104,7 @@ public class ToolsBootstrap : MonoSingleton<ToolsBootstrap>
mCamera.transform.eulerAngles = new Vector3(45.8f, -13f, 0f);
mCamera.orthographic = false;
tapGesture.SetLayerMask(1 << 10);
wrjManager.currentWRJ.isAuto = false;
wrjManager.wrjMenuSetPanel.gameObject.SetActive(false);
simpleCameraController.enabled = true;
}
@ -113,18 +113,6 @@ public class ToolsBootstrap : MonoSingleton<ToolsBootstrap>
private void Update()
{
_fsm.Update();
if (Input.GetMouseButtonDown(0))
{
if (tapGesture.HitTest().collider != null)
{
if (tapGesture.HitTest().collider.gameObject.layer == 10)
{
wrjManager.currentWRJ.SetAttackTarget(tapGesture.HitTest().collider.gameObject.GetComponent<HuoPaoController>());
}
}
}
}
public void SwitchState(int indexState)
@ -152,7 +140,6 @@ public class ToolsBootstrap : MonoSingleton<ToolsBootstrap>
isDistance = false;
_fsm.SetState(StateName.line);
SwitchSet2DMap(2);
wrjManager.currentWRJ.isAuto = true;
wrjManager.wrjMenuSetPanel.gameObject.SetActive(false);
}
@ -161,11 +148,6 @@ public class ToolsBootstrap : MonoSingleton<ToolsBootstrap>
/// </summary>
public void StartDeduction()
{
//wrjManager.currentWRJ.isMove = true;
for (int i = 0; i < wrjManager.wRJControllers.Count; i++)
{
wrjManager.wRJControllers[i].SetMove();
}
}

View File

@ -42,7 +42,6 @@ namespace AdamSync
//string palyerJoinRoom = "joinroom " + "";
//_ = SyncCreateRoom.SendMessageAsync(palyerJoinRoom);
gameObject.tag = "MainCamera";
}
}
}

View File

@ -9,8 +9,6 @@ namespace Assets.Zion.Scripts.Adam
{
public class WRJManager : MonoBehaviour
{
public List<WRJController> wRJControllers = new List<WRJController>();
public WRJController currentWRJ;
public RectTransform wrjMenuSetPanel;
public RectTransform canvasRect;
@ -27,16 +25,16 @@ namespace Assets.Zion.Scripts.Adam
RaycastHit hitInfo;
if (Physics.Raycast(ray, out hitInfo, 1000))
{
if (hitInfo.collider.tag == "WRJ")
EquipmentCommon ec = hitInfo.collider.GetComponent<EquipmentCommon>();
if (ec != null && ec.isPlayer)
{
//Debug.Log("daadad");
currentWRJ = hitInfo.collider.GetComponent<WRJController>();
if (!wRJControllers.Contains(currentWRJ))
wRJControllers.Add(currentWRJ);
wrjMenuSetPanel.localScale = Vector3.one;
Vector3 posItem = GetScreenPosition(hitInfo.collider.gameObject);
wrjMenuSetPanel.gameObject.SetActive(true);
wrjMenuSetPanel.anchoredPosition = new Vector3(posItem.x + 100f, posItem.y, posItem.z);
if (hitInfo.collider.tag == "WRJ")
{
wrjMenuSetPanel.localScale = Vector3.one;
Vector3 posItem = GetScreenPosition(hitInfo.collider.gameObject);
wrjMenuSetPanel.gameObject.SetActive(true);
wrjMenuSetPanel.anchoredPosition = new Vector3(posItem.x + 100f, posItem.y, posItem.z);
}
}
}
else