Browse Source

同步修改

develop
杨栋梁 4 years ago
parent
commit
ca36a016a0
  1. 35
      Assets/MscPublic/Assets/Resources/UI/FloorItem.prefab
  2. 4
      Assets/Scripts/Common/Disasters/Wound_Trapped/HaemalStrand.cs
  3. 47
      Assets/Scripts/Common/Disasters/Wound_Trapped/TrappedMoveFree.cs
  4. 20
      Assets/Scripts/Common/ReportSystem/UIViewQuestionnaire.cs

35
Assets/MscPublic/Assets/Resources/UI/FloorItem.prefab

@ -64,8 +64,6 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_Sprite: {fileID: 21300000, guid: 5448f37be88977646bc3013883817301, type: 3}
m_Type: 0
m_PreserveAspect: 0
@ -158,8 +156,6 @@ MonoBehaviour:
onValueChanged:
m_PersistentCalls:
m_Calls: []
m_TypeName: UnityEngine.UI.Toggle+ToggleEvent, UnityEngine.UI, Version=1.0.0.0,
Culture=neutral, PublicKeyToken=null
m_IsOn: 0
--- !u!114 &886484853937208961
MonoBehaviour:
@ -244,8 +240,6 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_Sprite: {fileID: 0}
m_Type: 0
m_PreserveAspect: 0
@ -318,8 +312,6 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_FontData:
m_Font: {fileID: 12800000, guid: cfad5fdf0e7e7ad45bbbc3bd066cb609, type: 3}
m_FontSize: 22
@ -346,7 +338,6 @@ GameObject:
- component: {fileID: 222551298539894938}
- component: {fileID: 114451063700641064}
- component: {fileID: 6151036416438185726}
- component: {fileID: 2229400231140118989}
m_Layer: 5
m_Name: Background
m_TagString: Untagged
@ -400,8 +391,6 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_Sprite: {fileID: 0}
m_Type: 1
m_PreserveAspect: 0
@ -454,29 +443,7 @@ MonoBehaviour:
onValueChanged:
m_PersistentCalls:
m_Calls: []
m_TypeName: UnityEngine.UI.Toggle+ToggleEvent, UnityEngine.UI, Version=1.0.0.0,
Culture=neutral, PublicKeyToken=null
m_IsOn: 0
--- !u!114 &2229400231140118989
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1711419534937118}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 16a33de889563db4fa6b5f24e003e464, type: 3}
m_Name:
m_EditorClassIdentifier:
buildNum:
floorNum: 0
interlayerNum: 0
MyChildFloors: []
floorsPanelManager: {fileID: 0}
MyText: {fileID: 114464141237427192}
HasChild: {fileID: 0}
MyTarget: {fileID: 0}
--- !u!1 &1967893008667110
GameObject:
m_ObjectHideFlags: 0
@ -540,8 +507,6 @@ MonoBehaviour:
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI,
Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
m_Sprite: {fileID: 21300000, guid: 25d9b074034294a4c81cbcf69bff3c82, type: 3}
m_Type: 0
m_PreserveAspect: 0

4
Assets/Scripts/Common/Disasters/Wound_Trapped/HaemalStrand.cs

@ -296,10 +296,10 @@ public class HaemalStrand : MonoBehaviour
safearea.HasWounderNum= safearea.HasWounderNum+1;
if (TargetObj.GetComponent<TrappedMoveFree>())
{
TargetObj.GetComponent<NavMeshAgent>().SetDestination(TargetObj.transform.position);
//TargetObj.GetComponent<NavMeshAgent>().SetDestination(TargetObj.transform.position);
TargetObj.GetComponent<TrappedMoveFree>().TargetPosition = TargetObj.transform.position;
TargetObj.GetComponent<TrappedPathFind>().pathFindEnable = false;
TargetObj.GetComponent<NavMeshAgent>().baseOffset = 0.2f;
//TargetObj.GetComponent<NavMeshAgent>().baseOffset = 0.2f;
TargetObj.GetComponent<TrappedMoveFree>().IsBefirstAirOrMoving = false;
TargetObj.GetComponent<TrappedMoveFree>().OverMoveOrGuidance = true;
TargetObj.GetComponent<TrappedMoveFree>().SaveFrirmanUserId = fireman1.GetComponent<BaseGameObjInfo>().UserID;

47
Assets/Scripts/Common/Disasters/Wound_Trapped/TrappedMoveFree.cs

@ -186,7 +186,7 @@ public class TrappedMoveFree : MonoBehaviour
public void OnEnable()
{
//MessageDispatcher.AddListener("SetGuidpathIndex", AddGuidIndex);
// MessageDispatcher.AddListener("MOVE_MAN_COMMAND", MoveExcute);
MessageDispatcher.AddListener("MOVE_MAN_COMMAND", MoveExcute);
MessageDispatcher.AddListener("GUIDANCE_MAN_COMMAND", GuidanceTrapped);
MessageDispatcher.AddListener("FRISTAID_MAN_COMMAND", FristAidTrapped);
MessageDispatcher.AddListener("TRAPPED_MOVE_FOLLOW_GUIDE_POINT_COMMAND", MoveFollowGuidPoint);
@ -203,7 +203,7 @@ public class TrappedMoveFree : MonoBehaviour
public void OnDestroy()
{
// MessageDispatcher.RemoveListener("SetGuidpathIndex", AddGuidIndex);
//MessageDispatcher.RemoveListener("MOVE_MAN_COMMAND", MoveExcute);
MessageDispatcher.RemoveListener("MOVE_MAN_COMMAND", MoveExcute);
MessageDispatcher.RemoveListener("GUIDANCE_MAN_COMMAND", GuidanceTrapped);
MessageDispatcher.RemoveListener("FRISTAID_MAN_COMMAND", FristAidTrapped);
MessageDispatcher.RemoveListener("TRAPPED_MOVE_FOLLOW_GUIDE_POINT_COMMAND", MoveFollowGuidPoint);
@ -219,7 +219,7 @@ public class TrappedMoveFree : MonoBehaviour
public void OnDisable()
{
//MessageDispatcher.RemoveListener("SetGuidpathIndex", AddGuidIndex);
// MessageDispatcher.RemoveListener("MOVE_MAN_COMMAND", MoveExcute);
MessageDispatcher.RemoveListener("MOVE_MAN_COMMAND", MoveExcute);
MessageDispatcher.RemoveListener("GUIDANCE_MAN_COMMAND", GuidanceTrapped);
MessageDispatcher.RemoveListener("FRISTAID_MAN_COMMAND", FristAidTrapped);
MessageDispatcher.RemoveListener("TRAPPED_MOVE_FOLLOW_GUIDE_POINT_COMMAND", MoveFollowGuidPoint);
@ -403,6 +403,7 @@ public class TrappedMoveFree : MonoBehaviour
if (info.gameObjID == GetComponent<BaseGameObjInfo>().gameObjID)
{
if (IsBefirstAirOrMoving)
{
@ -419,21 +420,27 @@ public class TrappedMoveFree : MonoBehaviour
LoadPromptWin.Instance.LoadTextPromptWindow("该人员被营救,不能再进行操作", 1f);
return;
}
if (fireMan.GetComponent<FiremanMoveTrapped>().trappedlist.Count > 0)
//if (fireMan.GetComponent<FiremanMoveTrapped>().trappedlist.Count > 0)
//{
// if (fireMan.GetComponent<FiremanMoveTrapped>().trappedlist.Contains(info.gameObjID))
// {
// LoadPromptWin.Instance.LoadTextPromptWindow("该人员已跟随移动", 1f);
// return;
// }
// else
// {
// LoadPromptWin.Instance.LoadTextPromptWindow("不能同时移动多名人员", 1f);
// return;
// }
//}
if (!IsMoveState && !OverMoveOrGuidance)
{
if (fireMan.GetComponent<FiremanMoveTrapped>().trappedlist.Contains(info.gameObjID))
{
LoadPromptWin.Instance.LoadTextPromptWindow("该人员已跟随移动", 1f);
return;
}
else
if (Haemal > 50)
{
LoadPromptWin.Instance.LoadTextPromptWindow("不能同时移动多名人员", 1f);
LoadPromptWin.Instance.LoadTextPromptWindow("该被困人员不需要移动", 1f);
return;
}
}
if (!IsMoveState && !OverMoveOrGuidance)
{
if (Vector3.Distance(fireMan.transform.position, transform.position) > 3)
{
LoadPromptWin.Instance.LoadTextPromptWindow("请靠近需救助人员", 1f);
@ -869,12 +876,12 @@ public class TrappedMoveFree : MonoBehaviour
//引导
if (Guidance)
{
if (guidPoint.Count == 1 /*&& Vector3.Distance(transform.position, guidPoint[0]) < 2*/)
{
if (TargetPosition != guidPoint[0])
if (TargetPosition!=guidPoint[0])
{
Debug.Log("<color=#00aa00ff>" + "sssssssss" + "</color>");
Debug.Log("<color=#00aa00ff>" + "sssssssss"+ "</color>");
TargetPosition = guidPoint[0];
if (CurrentUserInfo.room != null && CurrentUserInfo.mySelf.Id == CurrentUserInfo.room.Owner.UserInfo.Id)
{
@ -913,7 +920,7 @@ public class TrappedMoveFree : MonoBehaviour
}
else if (guidPoint.Count > 1)
{
if (!guidPoint.Contains(TargetPosition))
if (!guidPoint.Contains(TargetPosition))
{
AddGuidIndex();
}
@ -1021,11 +1028,11 @@ public class TrappedMoveFree : MonoBehaviour
void AniamtorSet()
{
if (Haemal <= 50)
if (Haemal <= 50)
{
return;
}
if (nav.enabled == false)
if (nav.enabled==false)
{
return;
}

20
Assets/Scripts/Common/ReportSystem/UIViewQuestionnaire.cs

@ -35,6 +35,13 @@ public class UIViewQuestionnaire : UIView
private void Awake()
{
if (!CheckZD())
{
LoadPromptWin.Instance.LoadTextPromptWindow("未检测到中队,跳过打分环节",2f);
gameObject.SetActive(false);
return;
}
// 读取数据
Questions = ResourceManager.LoadJson<List<Question>>("Question.json");
if (ReportDataMgr.IsVictory)
@ -53,7 +60,20 @@ public class UIViewQuestionnaire : UIView
StartCoroutine(CreateItem());
ButtonEnter.GetComponent<Button>().interactable = false;
}
private bool CheckZD()
{
bool has = false;
for (int i = 0; i < CurrentUserInfo.room.UserList.Count; i++)
{
if (CurrentUserInfo.room.UserList[i].Role==Role.)
{
has = true;
break;
}
}
return has;
}
internal void SetSyncData(List<Question> questions)
{
// count +1

Loading…
Cancel
Save