20240906基线

This commit is contained in:
liuyu 2024-09-06 10:58:09 +08:00
parent 17067bc33d
commit 877e3fb7cc
2 changed files with 21 additions and 10 deletions

View File

@ -51,6 +51,10 @@ public class TB_UserExamStat
/// </summary>
public float currentScore = 0;
public List<ReconnectSubScoreInfo> allSubScore = new List<ReconnectSubScoreInfo>();
/// <summary>
/// 用户经历过的场景
/// </summary>
//public List<string> experiencedScene = new List<string>();
/// <summary>
/// 背包中所有的工具和材料

View File

@ -20,8 +20,8 @@ public class ReconnectMgr : SingletonMono<ReconnectMgr>
private TB_UserExamStat UserExamStat = new TB_UserExamStat();
private string localStatPath = "";
private Coroutine coroutine;//自动保存倒计时
[HideInInspector]
public List<string> experiencedScene = new List<string>();//用户经历过的场景
//[HideInInspector]
//public List<string> experiencedScene = new List<string>();//用户经历过的场景
/// <summary>
/// 初始化函数,记录时间间隔
@ -29,15 +29,22 @@ public class ReconnectMgr : SingletonMono<ReconnectMgr>
public void Init( )
{
localStatPath = Application.streamingAssetsPath + "/" + localStatFileName;
experiencedScene.Clear();
UserExamStat.experiencedScene.Clear();//清空用户经历过的场景
//experiencedScene.Clear();
}
/// <summary>
/// 用户每经历一个场景就需要保存一个场景的数据
/// </summary>
public void IntoNewScene(string sceneName)
{
}
//public bool IntoNewScene(string sceneName)
//{
// if (UserExamStat.experiencedScene.Contains(sceneName))
// return false;
// else
// {
// UserExamStat.experiencedScene.Add(sceneName);
// return true;
// }
//}
ReconnectMgr()//构造函数
{
@ -204,7 +211,7 @@ public class ReconnectMgr : SingletonMono<ReconnectMgr>
if (item.triggerName == ret.triggerName)
{
item.gameObject.SetActive(true);
if (item.gameObject.GetComponent<Tool_SelectComponent>() == null)
if (item.gameObject.GetComponent<Tool_SelectComponent>() == null)//工具材料已经恢复过了
{
item.transform.localPosition = ret.selfPosInScene;
item.transform.localEulerAngles = ret.selfRotInScene;