修了不少东西
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Bansonic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.Events;
|
||||
using UnityEngine.UI;
|
||||
@@ -10,6 +11,8 @@ using UnityEditor;
|
||||
|
||||
public class uBag : MonoBehaviour
|
||||
{
|
||||
private const string MemorySystemComingSoonMessage = "\"记忆\"系统即将上线,敬请期待!";
|
||||
|
||||
private enum BagFilterMode
|
||||
{
|
||||
All,
|
||||
@@ -366,12 +369,17 @@ public class uBag : MonoBehaviour
|
||||
|
||||
private void HandleEquipSystemChanged(bool isOn)
|
||||
{
|
||||
SetObjectActive(bagObj, !isOn);
|
||||
SetObjectActive(equipObj, isOn);
|
||||
if (isOn)
|
||||
{
|
||||
ShowMemorySystemComingSoon();
|
||||
}
|
||||
|
||||
ForceBagViewMode();
|
||||
}
|
||||
|
||||
private void ApplyCategory(BagCategory category)
|
||||
{
|
||||
ForceBagViewMode();
|
||||
currentCategory = category;
|
||||
currentFilterMode = (BagFilterMode)category;
|
||||
if (bag_filterDropdown != null)
|
||||
@@ -408,14 +416,27 @@ public class uBag : MonoBehaviour
|
||||
{
|
||||
equipSystemToggle.onValueChanged.RemoveListener(HandleEquipSystemChanged);
|
||||
equipSystemToggle.onValueChanged.AddListener(HandleEquipSystemChanged);
|
||||
HandleEquipSystemChanged(equipSystemToggle.isOn);
|
||||
return;
|
||||
}
|
||||
|
||||
ForceBagViewMode();
|
||||
}
|
||||
|
||||
private void ForceBagViewMode()
|
||||
{
|
||||
if (equipSystemToggle != null)
|
||||
{
|
||||
equipSystemToggle.SetIsOnWithoutNotify(false);
|
||||
}
|
||||
|
||||
SetObjectActive(bagObj, true);
|
||||
SetObjectActive(equipObj, false);
|
||||
}
|
||||
|
||||
private static void ShowMemorySystemComingSoon()
|
||||
{
|
||||
gNotice.error.display(MemorySystemComingSoonMessage);
|
||||
}
|
||||
|
||||
private void HandleInventoryChanged(ExpBottleKind _, int __)
|
||||
{
|
||||
Rebuild();
|
||||
@@ -674,7 +695,7 @@ public class uBag : MonoBehaviour
|
||||
continue;
|
||||
}
|
||||
|
||||
if (story.fatherType == notebook_faterType.notebook_fatherType.content && !story.showInBag)
|
||||
if (!story.showInBag)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user