Compare commits
No commits in common. "c612770c447780f89501e76b16f24bf6eced8bb8" and "b2aa63b940ca76b37fa8e03931d543ea4bf62b44" have entirely different histories.
c612770c44
...
b2aa63b940
|
@ -62,7 +62,7 @@ public class Mastermanagement : MonoBehaviour
|
|||
{
|
||||
for (int i = 0; i < dragControllers.Count; i++)
|
||||
{
|
||||
if (dragControllers[i].gameObject.name == game.name && !dragControllers[i].gameObject.activeSelf)
|
||||
if (dragControllers[i].gameObject.name == game.name&& !dragControllers[i].gameObject.activeSelf)
|
||||
{
|
||||
dragControllers[i].gameObject.SetActive(true);
|
||||
break;
|
||||
|
@ -83,7 +83,7 @@ public class Mastermanagement : MonoBehaviour
|
|||
if (weapongames.Contains(obj))
|
||||
{
|
||||
weapongames.Remove(obj);
|
||||
DeviceManager.Instance.RemoveDevice(obj);
|
||||
DeviceManager.Instance.devices.Remove(obj.GetComponent<EquipmentCommon>());
|
||||
Destroy(obj);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -38,7 +38,7 @@ RenderSettings:
|
|||
m_ReflectionIntensity: 1
|
||||
m_CustomReflection: {fileID: 0}
|
||||
m_Sun: {fileID: 1113159741}
|
||||
m_IndirectSpecularColor: {r: 0.16234362, g: 0.306482, b: 0.6709422, a: 1}
|
||||
m_IndirectSpecularColor: {r: 0.030100383, g: 0.03369107, b: 0.03534769, a: 1}
|
||||
m_UseRadianceAmbientProbe: 0
|
||||
--- !u!157 &3
|
||||
LightmapSettings:
|
||||
|
@ -37848,7 +37848,7 @@ GameObject:
|
|||
m_Icon: {fileID: 0}
|
||||
m_NavMeshLayer: 0
|
||||
m_StaticEditorFlags: 0
|
||||
m_IsActive: 1
|
||||
m_IsActive: 0
|
||||
--- !u!224 &754191142
|
||||
RectTransform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -49516,8 +49516,6 @@ MonoBehaviour:
|
|||
- {fileID: 745447508}
|
||||
- {fileID: 1213021907}
|
||||
mastermanagement: {fileID: 147647013}
|
||||
postureBtn: {fileID: 1594140421}
|
||||
teacherBtn: {fileID: 1565322412}
|
||||
--- !u!4 &1436809530
|
||||
Transform:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -59994,7 +59992,29 @@ MonoBehaviour:
|
|||
m_TargetGraphic: {fileID: 1565322413}
|
||||
m_OnClick:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Calls:
|
||||
- m_Target: {fileID: 1719983405}
|
||||
m_MethodName: SetActive
|
||||
m_Mode: 6
|
||||
m_Arguments:
|
||||
m_ObjectArgument: {fileID: 0}
|
||||
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
|
||||
m_IntArgument: 0
|
||||
m_FloatArgument: 0
|
||||
m_StringArgument:
|
||||
m_BoolArgument: 1
|
||||
m_CallState: 2
|
||||
- m_Target: {fileID: 754191141}
|
||||
m_MethodName: SetActive
|
||||
m_Mode: 6
|
||||
m_Arguments:
|
||||
m_ObjectArgument: {fileID: 0}
|
||||
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
|
||||
m_IntArgument: 0
|
||||
m_FloatArgument: 0
|
||||
m_StringArgument:
|
||||
m_BoolArgument: 0
|
||||
m_CallState: 2
|
||||
--- !u!114 &1565322413
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -60775,7 +60795,29 @@ MonoBehaviour:
|
|||
m_TargetGraphic: {fileID: 1594140422}
|
||||
m_OnClick:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
m_Calls:
|
||||
- m_Target: {fileID: 754191141}
|
||||
m_MethodName: SetActive
|
||||
m_Mode: 6
|
||||
m_Arguments:
|
||||
m_ObjectArgument: {fileID: 0}
|
||||
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
|
||||
m_IntArgument: 0
|
||||
m_FloatArgument: 0
|
||||
m_StringArgument:
|
||||
m_BoolArgument: 1
|
||||
m_CallState: 2
|
||||
- m_Target: {fileID: 1719983405}
|
||||
m_MethodName: SetActive
|
||||
m_Mode: 6
|
||||
m_Arguments:
|
||||
m_ObjectArgument: {fileID: 0}
|
||||
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
|
||||
m_IntArgument: 0
|
||||
m_FloatArgument: 0
|
||||
m_StringArgument:
|
||||
m_BoolArgument: 0
|
||||
m_CallState: 2
|
||||
--- !u!114 &1594140422
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
|
@ -63922,7 +63964,7 @@ MonoBehaviour:
|
|||
m_PreInfinity: 2
|
||||
m_PostInfinity: 2
|
||||
m_RotationOrder: 4
|
||||
randSeed: 683195703
|
||||
randSeed: 3823234
|
||||
isDoingTransition: 0
|
||||
minimumHeight: 0
|
||||
--- !u!114 &1820978574
|
||||
|
@ -70850,7 +70892,7 @@ MonoBehaviour:
|
|||
m_HorizontalOverflow: 0
|
||||
m_VerticalOverflow: 0
|
||||
m_LineSpacing: 1
|
||||
m_Text: "\u8FDB\u5165\u5BFC\u8C03"
|
||||
m_Text: "\u8FDB\u5165\u6001\u52BF"
|
||||
--- !u!222 &1972282669
|
||||
CanvasRenderer:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
|
@ -1,30 +0,0 @@
|
|||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class PostureController : MonoBehaviour
|
||||
{
|
||||
public List<EquipmentCommon> redObjs = new List<EquipmentCommon>();
|
||||
public List<EquipmentCommon> blueObjs = new List<EquipmentCommon>();
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void OnEnable()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
private void GetSceneInfo()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 16abbb3ac7fac0b4a85fa24a4ceefd26
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
|
@ -92,12 +92,6 @@ public class DeviceManager : MonoSingleton<DeviceManager>
|
|||
}
|
||||
}
|
||||
|
||||
public void RemoveDevice(GameObject obj)
|
||||
{
|
||||
if (devices.Contains(obj.GetComponent<EquipmentCommon>()))
|
||||
devices.Remove(obj.GetComponent<EquipmentCommon>());
|
||||
}
|
||||
|
||||
public int GetPlayerDevice()
|
||||
{
|
||||
List<GameObject> temp = new List<GameObject>();
|
||||
|
|
|
@ -8,7 +8,6 @@ using System.Collections.Generic;
|
|||
using System.Linq;
|
||||
using Tenkoku.Core;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
using static InterfaceManager;
|
||||
|
||||
public class GameManager : MonoSingleton<GameManager>
|
||||
|
@ -38,20 +37,9 @@ public class GameManager : MonoSingleton<GameManager>
|
|||
|
||||
public Mastermanagement mastermanagement;
|
||||
|
||||
public Button postureBtn;
|
||||
public Button teacherBtn;
|
||||
|
||||
// Start is called before the first frame update
|
||||
// Start is called before the first frame update
|
||||
private void Awake()
|
||||
{
|
||||
postureBtn.onClick.AddListener(() =>
|
||||
{
|
||||
ChangeView(0);
|
||||
});
|
||||
teacherBtn.onClick.AddListener(() =>
|
||||
{
|
||||
ChangeView(2);
|
||||
});
|
||||
SyncCreateRoom.getroomusersRequset += OnGetRoomUsers;
|
||||
SyncCreateRoom.send2roomRequset += OnRoomInfo;
|
||||
SyncPlayerTransform spt = Instantiate(playerTransformPrefab);
|
||||
|
@ -199,17 +187,6 @@ public class GameManager : MonoSingleton<GameManager>
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 切换视图
|
||||
/// </summary>
|
||||
/// <param name="index"></param>
|
||||
public void ChangeView(int index)
|
||||
{
|
||||
Teacher.gameObject.SetActive(index == 0);
|
||||
student.gameObject.SetActive(index == 1);
|
||||
posture.gameObject.SetActive(index == 2);
|
||||
}
|
||||
|
||||
public void AddPlayers(SyncPlayerTransform s)
|
||||
{
|
||||
if (!players.Contains(s))
|
||||
|
@ -392,22 +369,16 @@ public class GameManager : MonoSingleton<GameManager>
|
|||
device.transform.position = new Vector3(float.Parse(tran[1]), float.Parse(tran[2]), float.Parse(tran[3]));
|
||||
device.transform.eulerAngles = new Vector3(float.Parse(tran[4]), float.Parse(tran[5]), float.Parse(tran[6]));
|
||||
}
|
||||
else
|
||||
{
|
||||
string[] deviceTran = data.r1.Split(',');
|
||||
|
||||
device.transform.position = new Vector3(float.Parse(deviceTran[0]), float.Parse(deviceTran[1]), float.Parse(deviceTran[2]));
|
||||
device.transform.eulerAngles = new Vector3(float.Parse(deviceTran[3]), float.Parse(deviceTran[4]), float.Parse(deviceTran[5]));
|
||||
}
|
||||
string[] deviceTran = data.r1.Split(',');
|
||||
|
||||
device.transform.position = new Vector3(float.Parse(deviceTran[0]), float.Parse(deviceTran[1]), float.Parse(deviceTran[2]));
|
||||
device.transform.eulerAngles = new Vector3(float.Parse(deviceTran[3]), float.Parse(deviceTran[4]), float.Parse(deviceTran[5]));
|
||||
if (!string.IsNullOrEmpty(data.r2) || data.r2 != "")
|
||||
{
|
||||
int wrjModelCount = int.Parse(data.r2);
|
||||
UnmannedAerialVehicleManage uavm = device.GetComponent<UnmannedAerialVehicleManage>();
|
||||
if (uavm)
|
||||
{
|
||||
uavm.wrjModel = (WRJModel)wrjModelCount;
|
||||
device.name = uavm.wrjModel.ToString();
|
||||
}
|
||||
if (device.GetComponent<UnmannedAerialVehicleManage>())
|
||||
device.GetComponent<UnmannedAerialVehicleManage>().wrjModel = (WRJModel)wrjModelCount;
|
||||
}
|
||||
|
||||
Debug.Log($"<color=yellow>是否是player{data.r3 == GlobalFlag.currentUser.user_id}</color>");
|
||||
|
@ -492,7 +463,7 @@ public class GameManager : MonoSingleton<GameManager>
|
|||
|
||||
private void OnDisable()
|
||||
{
|
||||
Debug.Log("OnDisable GameManager");
|
||||
Debug.Log("OnDisable");
|
||||
Leaverroom();
|
||||
}
|
||||
|
||||
|
|
|
@ -134,7 +134,7 @@ public class UIBootstrap : MonoSingleton<UIBootstrap>
|
|||
|
||||
private void OnDisable()
|
||||
{
|
||||
Debug.Log("OnDisable UIBootstrap");
|
||||
Debug.Log("OnDisable");
|
||||
AdamSync.SyncCreateRoom.leaveRoomRequset -= OnLeaveRoomInfo;
|
||||
string _msg = "leaveroom ";
|
||||
_ = AdamSync.SyncCreateRoom.SendMessageAsync(_msg);
|
||||
|
|
|
@ -56,7 +56,6 @@ namespace AdamSync
|
|||
|
||||
private void OnDisable()
|
||||
{
|
||||
Debug.Log("1212");
|
||||
SyncCreateRoom.CloseClint();
|
||||
isLinkAgain = false;
|
||||
}
|
||||
|
|
|
@ -127,7 +127,7 @@ public class UnmannedAerialVehicle : MonoBehaviour
|
|||
Bao.transform.localPosition = Vector3.zero;
|
||||
Bao.transform.SetParent(null);
|
||||
Bao.SetActive(true);
|
||||
DeviceManager.Instance.RemoveDevice(gameObject);
|
||||
|
||||
Destroy(gameObject);
|
||||
}
|
||||
|
||||
|
@ -159,7 +159,7 @@ public class UnmannedAerialVehicle : MonoBehaviour
|
|||
}
|
||||
//重点打击目标
|
||||
HighPriorityTarget highPriorityTarget = _transform.GetComponent<HighPriorityTarget>();
|
||||
if (highPriorityTarget)
|
||||
if (highPriorityTarget )
|
||||
{
|
||||
highPriorityTarget.BeAssaulted(atkPos, true);
|
||||
}
|
||||
|
@ -169,10 +169,7 @@ public class UnmannedAerialVehicle : MonoBehaviour
|
|||
Bao.transform.SetParent(null);
|
||||
Bao.SetActive(true);
|
||||
if (_equipmentCommon)
|
||||
{
|
||||
DeviceManager.Instance.RemoveDevice(_transform.gameObject);
|
||||
Destroy(_transform.gameObject);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
///上传日志
|
||||
|
@ -289,8 +286,7 @@ public class UnmannedAerialVehicle : MonoBehaviour
|
|||
GameObject obj = Instantiate(bulletPrefab, bulletPoint.position, bulletPoint.rotation);
|
||||
obj.SetActive(true);
|
||||
|
||||
obj.transform.DOMove(v3, 2).SetEase(Ease.Linear).OnComplete(() =>
|
||||
{
|
||||
obj.transform.DOMove(v3, 2).SetEase(Ease.Linear).OnComplete(() => {
|
||||
Destroy(obj);
|
||||
});
|
||||
ShellBoom sb = obj.AddComponent<ShellBoom>();
|
||||
|
|
Loading…
Reference in New Issue