音乐盒播放功能及切歌功能
parent
369223b93a
commit
1fe8c9d3b6
|
|
@ -1348,7 +1348,7 @@ RectTransform:
|
|||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: -15, y: 1.8997192}
|
||||
m_AnchoredPosition: {x: 0, y: 1.8997192}
|
||||
m_SizeDelta: {x: 897, y: 79}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &3618704762169578808
|
||||
|
|
@ -7134,6 +7134,7 @@ GameObject:
|
|||
- component: {fileID: 83084048701683773}
|
||||
- component: {fileID: 107828929920067662}
|
||||
- component: {fileID: 1161368977060924480}
|
||||
- component: {fileID: 1169728062855375447}
|
||||
m_Layer: 5
|
||||
m_Name: Image_NotChoose
|
||||
m_TagString: Untagged
|
||||
|
|
@ -7160,7 +7161,7 @@ RectTransform:
|
|||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0.5, y: 0.5}
|
||||
m_AnchorMax: {x: 0.5, y: 0.5}
|
||||
m_AnchoredPosition: {x: -15, y: 1.8997192}
|
||||
m_AnchoredPosition: {x: 0, y: 1.8997192}
|
||||
m_SizeDelta: {x: 897, y: 79}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &107828929920067662
|
||||
|
|
@ -7201,6 +7202,50 @@ MonoBehaviour:
|
|||
m_FillOrigin: 0
|
||||
m_UseSpriteMesh: 0
|
||||
m_PixelsPerUnitMultiplier: 1
|
||||
--- !u!114 &1169728062855375447
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 6618723647660265208}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Navigation:
|
||||
m_Mode: 3
|
||||
m_WrapAround: 0
|
||||
m_SelectOnUp: {fileID: 0}
|
||||
m_SelectOnDown: {fileID: 0}
|
||||
m_SelectOnLeft: {fileID: 0}
|
||||
m_SelectOnRight: {fileID: 0}
|
||||
m_Transition: 1
|
||||
m_Colors:
|
||||
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
|
||||
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
|
||||
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
|
||||
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
|
||||
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
|
||||
m_ColorMultiplier: 1
|
||||
m_FadeDuration: 0.1
|
||||
m_SpriteState:
|
||||
m_HighlightedSprite: {fileID: 0}
|
||||
m_PressedSprite: {fileID: 0}
|
||||
m_SelectedSprite: {fileID: 0}
|
||||
m_DisabledSprite: {fileID: 0}
|
||||
m_AnimationTriggers:
|
||||
m_NormalTrigger: Normal
|
||||
m_HighlightedTrigger: Highlighted
|
||||
m_PressedTrigger: Pressed
|
||||
m_SelectedTrigger: Selected
|
||||
m_DisabledTrigger: Disabled
|
||||
m_Interactable: 1
|
||||
m_TargetGraphic: {fileID: 1161368977060924480}
|
||||
m_OnClick:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
--- !u!1 &7007514286705400024
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
|
|
@ -8914,8 +8959,8 @@ RectTransform:
|
|||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 1}
|
||||
m_AnchorMax: {x: 0, y: 1}
|
||||
m_AnchoredPosition: {x: 476.3, y: -44}
|
||||
m_SizeDelta: {x: 100, y: 100}
|
||||
m_AnchoredPosition: {x: 462.39996, y: -44}
|
||||
m_SizeDelta: {x: 924.8, y: 100}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!1 &8125218241991028635
|
||||
GameObject:
|
||||
|
|
@ -9062,7 +9107,7 @@ MonoBehaviour:
|
|||
m_OnValueChanged:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
defaultItemSize: {x: 0, y: 0}
|
||||
defaultItemSize: {x: 924.8, y: 100}
|
||||
itemTemplate: {fileID: 7367249550784157432}
|
||||
layoutType: 1
|
||||
poolSize: 3
|
||||
|
|
|
|||
|
|
@ -1,111 +0,0 @@
|
|||
using cfg.ActorCfg;
|
||||
using Framework;
|
||||
using PhxhSDK;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class AlbumManager : Singlenton<AlbumManager>, IInitable
|
||||
{
|
||||
bool initialized = false;
|
||||
|
||||
public string curMusicKey;
|
||||
|
||||
Dictionary<int, DataAlbum> albumDic = new Dictionary<int, DataAlbum>();
|
||||
List<DataAlbum> albumList = new List<DataAlbum>();
|
||||
|
||||
public readonly bool loadFromLocal = true;
|
||||
|
||||
void loadOrInit()
|
||||
{
|
||||
if(!initialized)
|
||||
{
|
||||
Init();
|
||||
initialized = true;
|
||||
}
|
||||
}
|
||||
public void Init()
|
||||
{
|
||||
DebugUtil.Log("Test: AlbumMananger init!");
|
||||
albumDic.Clear();
|
||||
var albumCfg = TableManager.Instance.Tables.AlbumConfig;
|
||||
foreach (var item in albumCfg.DataList)
|
||||
{
|
||||
albumDic.Add(item.Id, item);
|
||||
albumList.Add(item);
|
||||
}
|
||||
}
|
||||
|
||||
public void Release()
|
||||
{
|
||||
albumDic.Clear();
|
||||
albumList.Clear();
|
||||
}
|
||||
|
||||
public Dictionary<int, DataAlbum> AlbumsDic => albumDic;
|
||||
public List<DataAlbum> AlbumsLst => albumList;
|
||||
|
||||
public bool AlbumUnlocked(int albumId)
|
||||
{
|
||||
loadOrInit();
|
||||
if (loadFromLocal)
|
||||
{
|
||||
if (albumDic.ContainsKey(albumId))
|
||||
{
|
||||
if (albumDic[albumId].DefaultUnlock)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
var data = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
if (data.unlockedAlbumLst.Contains(albumId))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.LogError(albumId + " not found in album config");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.Log("服务器读取");
|
||||
return false;
|
||||
//TODO 服务器逻辑
|
||||
}
|
||||
}
|
||||
|
||||
public DataAlbum GetCurAlbum()
|
||||
{
|
||||
loadOrInit();
|
||||
if (loadFromLocal)
|
||||
{
|
||||
var localData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
if(localData != null && localData.curAlbumId > 0)
|
||||
{
|
||||
return albumDic[localData.curAlbumId];
|
||||
}
|
||||
else
|
||||
{
|
||||
return albumList[0];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.Log("服务器读取");
|
||||
return null;
|
||||
//TODO 服务器逻辑
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public class AlbumLocalData
|
||||
{
|
||||
public int curAlbumId = 0;
|
||||
public List<int> unlockedAlbumLst = new List<int>();
|
||||
}
|
||||
|
|
@ -1076,6 +1076,8 @@ public void Release()
|
|||
|
||||
if (_albumAudio != null)
|
||||
{
|
||||
_albumAudio.CriAtomPlayback.Stop(true);
|
||||
_albumAudio.SetAcbAsset(acbAsset);
|
||||
_albumAudio.audioType = AudioBase.AudioType.Music;
|
||||
_albumAudio.SetVolume(audioInfo.volume);
|
||||
_albumAudio.Play(cueName, true);
|
||||
|
|
@ -1680,14 +1682,14 @@ public void Release()
|
|||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 当前单曲时长
|
||||
/// 单曲时长
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public float GetAlbumLength()
|
||||
public float GetAlbumLength(string key)
|
||||
{
|
||||
if (_albumAudio != null)
|
||||
{
|
||||
string key = AlbumManager.Instance.curMusicKey;
|
||||
//string key = AlbumManager.Instance.curMusicKey;
|
||||
DataAudio audioData;
|
||||
|
||||
audioData = TableManager.Instance.Tables.Audios.GetByKey(key);
|
||||
|
|
@ -1699,7 +1701,36 @@ public void Release()
|
|||
if (_albumAudio.AcbAsset.Handle.GetCueInfo(audioData.CueID, out CriAtomEx.CueInfo info))
|
||||
{
|
||||
DebugUtil.Log("cue name: " + info.name);
|
||||
return info.length;
|
||||
return info.length / 1000f;
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.LogError("==== 获取专辑音乐长度失败!!!");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.Log(key + "没有专辑音乐在播放!!!");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
public float GetAlbumLength(int ID)
|
||||
{
|
||||
if (_albumAudio != null)
|
||||
{
|
||||
DataAudio audioData;
|
||||
audioData = TableManager.Instance.Tables.Audios.GetByID(ID);
|
||||
if (audioData == null)
|
||||
{
|
||||
DebugUtil.LogError("==== 播放的音频不存在!!!音频Key: {0}", ID);
|
||||
return 0;
|
||||
}
|
||||
if (_albumAudio.AcbAsset.Handle.GetCueInfo(audioData.CueID, out CriAtomEx.CueInfo info))
|
||||
{
|
||||
DebugUtil.Log("cue name: " + info.name);
|
||||
return info.length / 1000f;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -144,10 +144,19 @@ public class AudioManager: Singlenton<AudioManager>, IStart, IInitable, IUpdatab
|
|||
if (DisableAudio) return 0;
|
||||
return _audioMgrObj.GetAlbumProgress();
|
||||
}
|
||||
public float GetAlbumLength()
|
||||
public float GetAlbumLength(string musicKey)
|
||||
{
|
||||
if (DisableAudio)
|
||||
{
|
||||
DebugUtil.Log("GetAlbumLength DisableAudio");
|
||||
return 0;
|
||||
}
|
||||
return _audioMgrObj.GetAlbumLength(musicKey);
|
||||
}
|
||||
public float GetAlbumLength(int musicID)
|
||||
{
|
||||
if (DisableAudio) return 0;
|
||||
return _audioMgrObj.GetAlbumLength();
|
||||
return _audioMgrObj.GetAlbumLength(musicID);
|
||||
}
|
||||
public bool PauseAndResumeAlbum(bool pause)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -0,0 +1,8 @@
|
|||
fileFormatVersion: 2
|
||||
guid: 9709b06df036ab84b8f3827f3f1ca8d6
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
|
|
@ -0,0 +1,406 @@
|
|||
using cfg.ActorCfg;
|
||||
using Framework;
|
||||
using PhxhSDK;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using UnityEngine;
|
||||
using Gameplay;
|
||||
using cfg.AudioCfg;
|
||||
using Cysharp.Threading.Tasks;
|
||||
using TMPro;
|
||||
using System;
|
||||
using DG.DemiEditor;
|
||||
using NPOI.SS.Formula.Functions;
|
||||
|
||||
public class AlbumManager : Singlenton<AlbumManager>
|
||||
{
|
||||
public enum PlayMode
|
||||
{
|
||||
Order,
|
||||
Random,
|
||||
Single
|
||||
}
|
||||
PlayMode curPlayMode = PlayMode.Order;
|
||||
public PlayMode CurPlayMode => curPlayMode;
|
||||
|
||||
List<int> playOrderList = new();
|
||||
private int curOrderIndex = 0;
|
||||
|
||||
bool initialized = false;
|
||||
|
||||
public string curMusicKey;
|
||||
|
||||
Dictionary<int, DataAlbum> albumDic = new Dictionary<int, DataAlbum>();
|
||||
List<DataAlbum> albumList = new List<DataAlbum>();
|
||||
|
||||
public readonly bool loadFromLocal = true;
|
||||
|
||||
AlbumLocalData _saveData;
|
||||
|
||||
|
||||
public Timer playTimer = new();
|
||||
|
||||
void loadOrInit()
|
||||
{
|
||||
if(!initialized)
|
||||
{
|
||||
Init();
|
||||
initialized = true;
|
||||
playTimer.onPlayEnd += PlayNextAudio;
|
||||
}
|
||||
}
|
||||
public void Init()
|
||||
{
|
||||
albumDic.Clear();
|
||||
var albumCfg = TableManager.Instance.Tables.AlbumConfig;
|
||||
foreach (var item in albumCfg.DataList)
|
||||
{
|
||||
albumDic.Add(item.Id, item);
|
||||
albumList.Add(item);
|
||||
}
|
||||
|
||||
if (loadFromLocal)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
if (_saveData == null)
|
||||
{
|
||||
_saveData = new AlbumLocalData();
|
||||
}
|
||||
curPlayMode = (PlayMode)_saveData.curOrderMode;
|
||||
SetPlayMode(curPlayMode);
|
||||
var curAudio = CurPlayAudio();
|
||||
if (curAudio != null)
|
||||
{
|
||||
curMusicKey = curAudio.Key;
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.LogError("CurAudio is null");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
//TODO 服务器逻辑
|
||||
}
|
||||
}
|
||||
|
||||
public void Release()
|
||||
{
|
||||
albumDic.Clear();
|
||||
albumList.Clear();
|
||||
}
|
||||
|
||||
public Dictionary<int, DataAlbum> AlbumsDic => albumDic;
|
||||
public List<DataAlbum> AlbumsLst => albumList;
|
||||
|
||||
public bool AlbumUnlocked(int albumId)
|
||||
{
|
||||
loadOrInit();
|
||||
if(albumDic.ContainsKey(albumId))
|
||||
{
|
||||
if (albumDic[albumId].DefaultUnlock)//默认解锁专辑
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
int itemID = albumDic[albumId].ItemID;
|
||||
if (CategoryManager.Instance.GetItemCount(itemID) > 0)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
//int ItemID=
|
||||
DebugUtil.LogError(albumId + " not found in album config");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
public DataAlbum GetCurAlbum()
|
||||
{
|
||||
loadOrInit();
|
||||
if (loadFromLocal)
|
||||
{
|
||||
if (_saveData == null)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
if (_saveData != null && _saveData.curAlbumId > 0)
|
||||
{
|
||||
return albumDic[_saveData.curAlbumId];
|
||||
}
|
||||
else
|
||||
{
|
||||
return albumList[0];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return albumDic[_saveData.curAlbumId];
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.Log("服务器读取");
|
||||
return null;
|
||||
//TODO 服务器逻辑
|
||||
}
|
||||
}
|
||||
public int GetCurAudioIndex()
|
||||
{
|
||||
loadOrInit();
|
||||
if (_saveData == null)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
}
|
||||
return _saveData.curPlayAudioIndex;
|
||||
}
|
||||
|
||||
public void SetCurAlbum(int albumId, int audioIndex)
|
||||
{
|
||||
loadOrInit();
|
||||
if (albumDic.ContainsKey(albumId))
|
||||
{
|
||||
if (_saveData == null)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
}
|
||||
_saveData.curAlbumId = albumId;
|
||||
_saveData.curPlayAudioIndex = audioIndex;
|
||||
StorageMgr.Instance.SyncForce = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.LogError(albumId + " not found in album config");
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 专辑内容列表
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
public List<int> AlbumPlayList(int albumID)
|
||||
{
|
||||
if(albumDic.ContainsKey(albumID))
|
||||
{
|
||||
return albumDic[albumID].PlayList.ToList();
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.LogError(albumID + " not found in album config");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public List<int> CurAlbumPlayList()
|
||||
{
|
||||
if(_saveData == null)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
}
|
||||
return AlbumPlayList(_saveData.curAlbumId);
|
||||
}
|
||||
|
||||
public DataAudio CurPlayAudio()
|
||||
{
|
||||
if(_saveData == null)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
}
|
||||
var playList = CurAlbumPlayList();
|
||||
if (playList != null && playList.Count > 0)
|
||||
{
|
||||
return TableManager.Instance.Tables.Audios.GetByID(playList[_saveData.curPlayAudioIndex]);
|
||||
}
|
||||
else
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
public int CurPlayAudioIndex()
|
||||
{
|
||||
if(_saveData == null)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
}
|
||||
return _saveData.curPlayAudioIndex;
|
||||
}
|
||||
|
||||
public void SetPlayMode(PlayMode mode)
|
||||
{
|
||||
curPlayMode = mode;
|
||||
playOrderList.Clear();
|
||||
if (_saveData == null)
|
||||
{
|
||||
_saveData = StorageMgr.Instance.GetStorage<AlbumLocalData>("ALBUM_LOCAL_DATA");
|
||||
}
|
||||
for (int i = 0; i < AlbumPlayList(_saveData.curAlbumId).Count; i++)
|
||||
{
|
||||
playOrderList.Add(i);
|
||||
}
|
||||
|
||||
switch (mode)
|
||||
{
|
||||
case PlayMode.Order:
|
||||
break;
|
||||
case PlayMode.Random:
|
||||
playOrderList.Shuffle();
|
||||
break;
|
||||
case PlayMode.Single:
|
||||
int curIndex = _saveData.curPlayAudioIndex;
|
||||
for (int i = 0; i < playOrderList.Count; i++)
|
||||
{
|
||||
playOrderList[i] = curIndex;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
for (int i = 0; i < playOrderList.Count; i++)
|
||||
{
|
||||
if (playOrderList[i] == _saveData.curPlayAudioIndex)
|
||||
{
|
||||
curOrderIndex = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public async void PlayAlbumAudio(int albumID, int audioIndex)
|
||||
{
|
||||
if (albumDic.ContainsKey(albumID))
|
||||
{
|
||||
var playList = AlbumPlayList(albumID);
|
||||
if (playList != null && playList.Count > 0)
|
||||
{
|
||||
if (audioIndex >= playList.Count)
|
||||
{
|
||||
audioIndex = 0;
|
||||
}
|
||||
await AudioManager.Instance.PlayAlbum(playList[audioIndex]);
|
||||
curMusicKey = TableManager.Instance.Tables.Audios.GetByID(playList[audioIndex]).Key;
|
||||
|
||||
SetCurAlbum(albumID, audioIndex);
|
||||
|
||||
var totalSeconds = AudioManager.Instance.GetAlbumLength(playList[audioIndex]);
|
||||
playTimer.Start(totalSeconds);
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.LogError("PlayList is empty");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.LogError(albumID + " not found in album config");
|
||||
}
|
||||
}
|
||||
public void PlayPreAudio()
|
||||
{
|
||||
var playList = CurAlbumPlayList();
|
||||
if (playList != null && playList.Count > 0)
|
||||
{
|
||||
curOrderIndex--;
|
||||
if (curOrderIndex < 0)
|
||||
{
|
||||
curOrderIndex = playList.Count - 1;
|
||||
}
|
||||
|
||||
PlayAlbumAudio(GetCurAlbum().Id, playOrderList[curOrderIndex]);
|
||||
}
|
||||
}
|
||||
public void PlayNextAudio()
|
||||
{
|
||||
var playList = CurAlbumPlayList();
|
||||
if (playList != null && playList.Count > 0)
|
||||
{
|
||||
curOrderIndex++;
|
||||
if (curOrderIndex >= playList.Count)
|
||||
{
|
||||
curOrderIndex = 0;
|
||||
}
|
||||
|
||||
PlayAlbumAudio(GetCurAlbum().Id, playOrderList[curOrderIndex]);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 播放进度计时器
|
||||
/// </summary>
|
||||
public class Timer
|
||||
{
|
||||
bool isPlaying;
|
||||
float audioLength = -1;
|
||||
|
||||
public delegate void OnSecondChange();
|
||||
public event OnSecondChange onSecondChange;
|
||||
public delegate void OnPlayEnd();
|
||||
public event OnPlayEnd onPlayEnd;
|
||||
|
||||
async UniTask AudioTimer()
|
||||
{
|
||||
while (isPlaying)
|
||||
{
|
||||
float totalSeconds = AudioManager.Instance.GetAlbumProgress();
|
||||
if (totalSeconds < 0)
|
||||
{
|
||||
isPlaying = false;
|
||||
break;
|
||||
}
|
||||
|
||||
if (totalSeconds >= audioLength && audioLength > 0)
|
||||
{
|
||||
isPlaying = false;
|
||||
//AudioManager.Instance.StopMusicById(CurPlayAudio().ID);
|
||||
onPlayEnd?.Invoke();
|
||||
break;
|
||||
}
|
||||
onSecondChange?.Invoke();
|
||||
await UniTask.Delay(100);//0.1s
|
||||
}
|
||||
}
|
||||
|
||||
public void Start(float audiolen)
|
||||
{
|
||||
audioLength = audiolen;
|
||||
if (isPlaying)
|
||||
{
|
||||
return;
|
||||
}
|
||||
isPlaying = true;
|
||||
AudioTimer().Forget();
|
||||
}
|
||||
public void Start()
|
||||
{
|
||||
if (isPlaying)
|
||||
{
|
||||
return;
|
||||
}
|
||||
isPlaying = true;
|
||||
AudioTimer().Forget();
|
||||
}
|
||||
|
||||
public void Stop()
|
||||
{
|
||||
isPlaying = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public class AlbumLocalData
|
||||
{
|
||||
public int curAlbumId = 1;
|
||||
//public List<int> unlockedAlbumLst = new List<int>();
|
||||
public int curPlayAudioIndex = 0;
|
||||
|
||||
public int curOrderMode = 0;
|
||||
}
|
||||
|
|
@ -49,9 +49,10 @@ namespace Gameplay
|
|||
_DoJumpFunc(key, param);
|
||||
}
|
||||
|
||||
public static void JumpToCultivateCharacter(int uid)
|
||||
public static async void JumpToCultivateCharacter(int uid)
|
||||
{
|
||||
DebugUtil.Log("跳转至培养角色界面,传入角色参数:" + uid + "\n逻辑请在此处实现");
|
||||
await UISelectCharacterController.Open();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
|
|
@ -1,9 +1,12 @@
|
|||
using cfg.AudioCfg;
|
||||
using Cysharp.Threading.Tasks;
|
||||
using Framework;
|
||||
using Gameplay;
|
||||
using PhxhSDK;
|
||||
using System.Threading;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UIElements;
|
||||
using Button = UnityEngine.UI.Button;
|
||||
using Image = UnityEngine.UI.Image;
|
||||
|
||||
|
|
@ -106,7 +109,11 @@ public class UI_MusicPannelController : UIWindow
|
|||
///Auto Gen End///
|
||||
#endregion
|
||||
PhxhScrollView AlbumPageScrollView;
|
||||
Timer albumTimer = new();
|
||||
PhxhScrollView AudioListScrollView;
|
||||
//Timer albumTimer = new();
|
||||
|
||||
float curAudioLength = 0f;
|
||||
int curAlbumIndex = 0;
|
||||
|
||||
public static async UniTask<UIWindow> Open()
|
||||
{
|
||||
|
|
@ -132,8 +139,9 @@ public class UI_MusicPannelController : UIWindow
|
|||
UI_MusicPannelBinder.GetComponents(this);
|
||||
|
||||
AlbumPageScrollView = GetComponent<PhxhScrollView>("PhxhScrollView");
|
||||
AudioListScrollView = GetComponent<PhxhScrollView>("Image_RightBg/PhxhScrollView");
|
||||
|
||||
BindButton(Button_back, _OnClickClose);
|
||||
BindButton(Button_back, _OnClickClose);
|
||||
|
||||
if (AudioManager.Instance.IsPlayingAlbum)
|
||||
{
|
||||
|
|
@ -142,20 +150,64 @@ public class UI_MusicPannelController : UIWindow
|
|||
}
|
||||
|
||||
BindButton(Button_PlayAndPause, PauseAndResume);
|
||||
BindButton(Button_Left, preAlbum);
|
||||
BindButton(Button_Right, nextAlbum);
|
||||
BindButton(Button_Previous, preMusic);
|
||||
BindButton(Button_Next, nextMusic);
|
||||
BindButton(Button_Seq, () => { SwitchPlayMode(AlbumManager.PlayMode.Order); });
|
||||
BindButton(Button_Shu, () => { SwitchPlayMode(AlbumManager.PlayMode.Random); });
|
||||
BindButton(Button_Rep, () => { SwitchPlayMode(AlbumManager.PlayMode.Single); });
|
||||
|
||||
var albumID = AlbumManager.Instance.GetCurAlbum();
|
||||
curAlbumIndex = AlbumManager.Instance.GetCurAlbum().Id;
|
||||
|
||||
AlbumPageScrollView.SetItemCountFunc(() => AlbumManager.Instance.AlbumsLst.Count);
|
||||
AlbumPageScrollView.SetUpdateFunc(AlbumPageRefreshFunc);
|
||||
AlbumPageScrollView.itemTemplate.gameObject.SetActive(false);
|
||||
AlbumPageScrollView.UpdateData();
|
||||
|
||||
CDPagesImage(AlbumManager.Instance.GetCurAlbum().Id);
|
||||
AudioListScrollView.SetItemCountFunc(() => AlbumManager.Instance.AlbumsDic[curAlbumIndex].PlayList.Length);
|
||||
AudioListScrollView.SetUpdateFunc(AlbumListRefreshFunc);
|
||||
AudioListScrollView.itemTemplate.gameObject.SetActive(false);
|
||||
AudioListScrollView.UpdateData();
|
||||
|
||||
CDPagesImage(curAlbumIndex);
|
||||
RefreshPlayOrder();
|
||||
|
||||
AlbumManager.Instance.playTimer.onSecondChange += TimerRefresh;
|
||||
AlbumManager.Instance.playTimer.onPlayEnd += PlayEndRefresh;
|
||||
}
|
||||
|
||||
//invoke when open window
|
||||
protected override void OnShowWindow(object data = null)
|
||||
{
|
||||
|
||||
}
|
||||
//bool isPlaying = AudioManager.Instance.IsPlayingAlbum;
|
||||
PauseAndResume();
|
||||
//if (!isPlaying)
|
||||
//{
|
||||
PauseAndResume();//用于加载音频
|
||||
//}
|
||||
|
||||
|
||||
curAudioLength = AudioManager.Instance.GetAlbumLength(AlbumManager.Instance.curMusicKey);
|
||||
if (curAudioLength > 0)
|
||||
{
|
||||
int minutes = Mathf.FloorToInt(curAudioLength / 60F);
|
||||
int seconds = Mathf.FloorToInt(curAudioLength - minutes * 60);
|
||||
Text_AllTime.text = $"{minutes:00}:{seconds:00}";
|
||||
|
||||
float totalSeconds = AudioManager.Instance.GetAlbumProgress();
|
||||
|
||||
minutes = Mathf.FloorToInt(totalSeconds / 60F);
|
||||
seconds = Mathf.FloorToInt(totalSeconds - minutes * 60);
|
||||
Text_TimeNow.text = $"{minutes:00}:{seconds:00}";
|
||||
|
||||
Image_ProcessNow.fillAmount = totalSeconds / curAudioLength;
|
||||
}
|
||||
else
|
||||
{
|
||||
DebugUtil.Log("curAudioLength <= 0");
|
||||
}
|
||||
}
|
||||
|
||||
//invoke when reload window
|
||||
protected override void OnReloadWindow(object data = null)
|
||||
|
|
@ -178,39 +230,115 @@ public class UI_MusicPannelController : UIWindow
|
|||
DebugUtil.Log("resume music");
|
||||
AudioManager.Instance.ResumeBackgroundMusic();
|
||||
}
|
||||
AlbumManager.Instance.playTimer.onSecondChange -= TimerRefresh;
|
||||
AlbumManager.Instance.playTimer.onPlayEnd -= PlayEndRefresh;
|
||||
}
|
||||
|
||||
#region button_click
|
||||
async void PauseAndResume()
|
||||
|
||||
void preAlbum()
|
||||
{
|
||||
//AlbumManager.Instance.PreAlbum();
|
||||
//CDPagesImage(AlbumManager.Instance.GetCurAlbum().Id);
|
||||
curAlbumIndex--;
|
||||
if (curAlbumIndex <= 0)
|
||||
{
|
||||
curAlbumIndex = AlbumManager.Instance.AlbumsLst.Count;
|
||||
}
|
||||
CDPagesImage(curAlbumIndex);
|
||||
AudioListScrollView.UpdateData();
|
||||
}
|
||||
void nextAlbum()
|
||||
{
|
||||
curAlbumIndex++;
|
||||
if (curAlbumIndex > AlbumManager.Instance.AlbumsLst.Count)
|
||||
{
|
||||
curAlbumIndex = 1;
|
||||
}
|
||||
CDPagesImage(curAlbumIndex);
|
||||
AudioListScrollView.UpdateData();
|
||||
}
|
||||
void preMusic()
|
||||
{
|
||||
AlbumManager.Instance.PlayPreAudio();
|
||||
PlayEndRefresh();
|
||||
}
|
||||
void nextMusic()
|
||||
{
|
||||
AlbumManager.Instance.PlayNextAudio();
|
||||
PlayEndRefresh();
|
||||
}
|
||||
|
||||
void SwitchPlayMode(AlbumManager.PlayMode playMode)
|
||||
{
|
||||
if (playMode != AlbumManager.Instance.CurPlayMode)
|
||||
AlbumManager.Instance.SetPlayMode(playMode);
|
||||
RefreshPlayOrder();
|
||||
}
|
||||
void PauseAndResume()
|
||||
{
|
||||
AudioManager.Instance.IsPlayingAlbum = !AudioManager.Instance.IsPlayingAlbum;
|
||||
if (AudioManager.Instance.IsPlayingAlbum)
|
||||
{
|
||||
if (!AudioManager.Instance.PauseAndResumeAlbum(false))
|
||||
{
|
||||
await AudioManager.Instance.PlayAlbum("NLD_BGM_Album_01_01");
|
||||
AlbumManager.Instance.curMusicKey = "NLD_BGM_Album_01_01";
|
||||
albumTimer.Start(Text_TimeNow, Text_AllTime);
|
||||
Text_AllTime.text = AudioManager.Instance.GetAlbumLength().ToString();
|
||||
}
|
||||
if (!AudioManager.Instance.PauseAndResumeAlbum(false))//未播放
|
||||
{
|
||||
//await AudioManager.Instance.PlayAlbum(dataAudio.ID);
|
||||
//AlbumManager.Instance.curMusicKey = dataAudio.Key;
|
||||
//albumTimer.Start(Text_TimeNow, Image_ProcessNow, totalSeconds);
|
||||
int curAudioIndex = AlbumManager.Instance.CurPlayAudioIndex();
|
||||
AlbumManager.Instance.PlayAlbumAudio(curAlbumIndex, curAudioIndex);
|
||||
AlbumManager.Instance.SetPlayMode(AlbumManager.Instance.CurPlayMode);
|
||||
curAudioLength = AudioManager.Instance.GetAlbumLength(AlbumManager.Instance.CurPlayAudio().Key);
|
||||
int minutes = Mathf.FloorToInt(curAudioLength / 60F);
|
||||
int seconds = Mathf.FloorToInt(curAudioLength - minutes * 60);
|
||||
Text_AllTime.text = $"{minutes:00}:{seconds:00}";
|
||||
}
|
||||
//else//从暂停中恢复
|
||||
//{
|
||||
// albumTimer.Start(Text_TimeNow);
|
||||
//}
|
||||
Image_PL.gameObject.SetActive(true);
|
||||
Image_PA.gameObject.SetActive(false);
|
||||
}
|
||||
else
|
||||
{
|
||||
albumTimer.Stop();
|
||||
//albumTimer.Stop();
|
||||
AudioManager.Instance.PauseAndResumeAlbum(true);
|
||||
Image_PL.gameObject.SetActive(false);
|
||||
Image_PA.gameObject.SetActive(true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void OnPlayListClick(int index)
|
||||
{
|
||||
AudioManager.Instance.IsPlayingAlbum = true;
|
||||
|
||||
//AlbumManager.Instance.SetCurAlbum(curAlbumIndex, index);
|
||||
|
||||
AlbumManager.Instance.PlayAlbumAudio(curAlbumIndex, index);
|
||||
AlbumManager.Instance.SetPlayMode(AlbumManager.Instance.CurPlayMode);//TODO 播放模式
|
||||
|
||||
DataAudio dataAudio = TableManager.Instance.Tables.Audios.GetByID(AlbumManager.Instance.AlbumPlayList(curAlbumIndex)[index]);
|
||||
|
||||
AlbumManager.Instance.curMusicKey = dataAudio.Key;
|
||||
DebugUtil.Log("cur music key: " + dataAudio.Key);
|
||||
curAudioLength = AudioManager.Instance.GetAlbumLength(dataAudio.Key);
|
||||
int minutes = Mathf.FloorToInt(curAudioLength / 60F);
|
||||
int seconds = Mathf.FloorToInt(curAudioLength - minutes * 60);
|
||||
Text_AllTime.text = $"{minutes:00}:{seconds:00}";
|
||||
|
||||
Image_PL.gameObject.SetActive(true);
|
||||
Image_PA.gameObject.SetActive(false);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region album_page_SV
|
||||
void AlbumPageRefreshFunc(int index,RectTransform rt)
|
||||
void AlbumPageRefreshFunc(int index,RectTransform rt)
|
||||
{
|
||||
SetPageImage(rt.GetComponent<Image>(), index);
|
||||
rt.gameObject.SetActive(true);
|
||||
int ID = index + 1;
|
||||
SetPageImage(rt.GetComponent<Image>(), ID);
|
||||
}
|
||||
async void SetPageImage(Image img, int index)
|
||||
{
|
||||
|
|
@ -218,46 +346,172 @@ public class UI_MusicPannelController : UIWindow
|
|||
var sprite = await LoadAssetAsync<Sprite>(path);
|
||||
img.sprite = sprite;
|
||||
}
|
||||
#endregion
|
||||
#endregion
|
||||
|
||||
async void CDPagesImage(int index)
|
||||
#region album_list_SV
|
||||
void AlbumListRefreshFunc(int index, RectTransform rt)
|
||||
{
|
||||
var CDBpath = "Assets/Art/UI/Texture/Icon/MusicBox/" + AlbumManager.Instance.AlbumsDic[index].CoverPath + "-" + AlbumManager.Instance.AlbumsDic[index].Id + ".png";
|
||||
Image_CDB.sprite = await LoadAssetAsync<Sprite>(CDBpath);
|
||||
var CDpath = "Assets/Art/UI/Texture/Icon/MusicBox/Tapes/" + AlbumManager.Instance.AlbumsDic[index].CoverPath + ".png";
|
||||
Image_CD.sprite = await LoadAssetAsync<Sprite>(CDpath);
|
||||
Text_Name.text = AlbumManager.Instance.AlbumsDic[index].Name;
|
||||
}
|
||||
rt.gameObject.SetActive(true);
|
||||
|
||||
class Timer
|
||||
{
|
||||
TMP_Text timeTxt;
|
||||
bool isPlaying;
|
||||
TMP_Text allTime;
|
||||
|
||||
async UniTask AudioTimer()
|
||||
var audioLst = AlbumManager.Instance.AlbumPlayList(curAlbumIndex);
|
||||
if(audioLst == null)
|
||||
{
|
||||
while(isPlaying)
|
||||
DebugUtil.LogError("album list is null");
|
||||
return;
|
||||
}
|
||||
int id = index + 1;
|
||||
rt.Find("Image_ChooseBar/Text_Num_Choose").GetComponent<TMP_Text>().text = $"{id:00}";
|
||||
rt.Find("Image_NotChoose/Text_Num_NotChoose").GetComponent<TMP_Text>().text = $"{id:00}";
|
||||
|
||||
var audioID = audioLst[index];
|
||||
DataAudio audioCfg = TableManager.Instance.Tables.Audios.GetByID(audioID);//.GetConfigData(audioID);
|
||||
|
||||
if (curAlbumIndex == AlbumManager.Instance.GetCurAlbum().Id && index == AlbumManager.Instance.GetCurAudioIndex())//当前播放
|
||||
{
|
||||
rt.Find("Image_NotChoose").gameObject.SetActive(false);
|
||||
rt.Find("Image_ChooseBar").gameObject.SetActive(true);
|
||||
|
||||
var musicName = rt.Find("Image_ChooseBar/Text_MusicName_Choose").gameObject;
|
||||
var authorName = rt.Find("Image_ChooseBar/Text_Author_Choose").gameObject;
|
||||
if (musicName != null)
|
||||
{
|
||||
float totalSeconds = AudioManager.Instance.GetAlbumProgress();
|
||||
int minutes = Mathf.FloorToInt(totalSeconds / 60F);
|
||||
int seconds = Mathf.FloorToInt(totalSeconds - minutes * 60);
|
||||
timeTxt.text = $"{minutes:00}:{seconds:00}";
|
||||
//allTime.text = AudioManager.Instance.GetAlbumLength().ToString();
|
||||
await UniTask.Delay(1000);
|
||||
musicName.GetComponent<TMP_Text>().text = audioCfg.CueName;
|
||||
}
|
||||
if (authorName != null)
|
||||
{
|
||||
authorName.GetComponent<TMP_Text>().text = audioCfg.Artist;
|
||||
}
|
||||
}
|
||||
else//未播放
|
||||
{
|
||||
rt.Find("Image_NotChoose").gameObject.SetActive(true);
|
||||
rt.Find("Image_ChooseBar").gameObject.SetActive(false);
|
||||
|
||||
public void Start(TMP_Text text,TMP_Text all)
|
||||
{
|
||||
isPlaying = true;
|
||||
timeTxt = text;
|
||||
allTime = all;
|
||||
AudioTimer().Forget();
|
||||
var musicName = rt.Find("Image_NotChoose/Text_MusicName_NotChoose").gameObject;
|
||||
var authorName = rt.Find("Image_NotChoose/Text_Author_NotChoose").gameObject;
|
||||
if (musicName != null)
|
||||
{
|
||||
musicName.GetComponent<TMP_Text>().text = audioCfg.CueName;
|
||||
}
|
||||
if (authorName != null)
|
||||
{
|
||||
authorName.GetComponent<TMP_Text>().text = audioCfg.Artist;
|
||||
}
|
||||
ClearBind(rt.Find("Image_NotChoose").GetComponent<Button>());
|
||||
BindButton(rt.Find("Image_NotChoose").GetComponent<Button>(), () => OnPlayListClick(index));
|
||||
}
|
||||
public void Stop()
|
||||
{
|
||||
isPlaying = false;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
void CDPagesImage(int index)
|
||||
{
|
||||
Text_Name.text = AlbumManager.Instance.AlbumsDic[index].Name;
|
||||
var CDBpath = "Assets/Art/UI/Texture/Icon/MusicBox/" + AlbumManager.Instance.AlbumsDic[index].TapesPath + ".png";
|
||||
Image_CDB.sprite = LoadAsset<Sprite>(CDBpath);
|
||||
var CDpath = "Assets/Art/UI/Texture/Icon/MusicBox/Tapes/" + AlbumManager.Instance.AlbumsDic[index].CoverPath + ".png";
|
||||
Image_CD.sprite = LoadAsset<Sprite>(CDpath);
|
||||
|
||||
if (AlbumManager.Instance.AlbumUnlocked(index))
|
||||
{
|
||||
Text_Lock.gameObject.SetActive(true);
|
||||
}
|
||||
else
|
||||
{
|
||||
Text_Lock.gameObject.SetActive(false);
|
||||
}
|
||||
}
|
||||
void RefreshPlayOrder()
|
||||
{
|
||||
var order = AlbumManager.Instance.CurPlayMode;
|
||||
|
||||
Image_CSeq.gameObject.SetActive(order == AlbumManager.PlayMode.Order);
|
||||
Image_CShu.gameObject.SetActive(order == AlbumManager.PlayMode.Random);
|
||||
Image_CRep.gameObject.SetActive(order == AlbumManager.PlayMode.Single);
|
||||
|
||||
}
|
||||
/// <summary>
|
||||
/// 计时器更新回调
|
||||
/// </summary>
|
||||
void TimerRefresh()
|
||||
{
|
||||
float totalSeconds = AudioManager.Instance.GetAlbumProgress();
|
||||
|
||||
int minutes = Mathf.FloorToInt(totalSeconds / 60F);
|
||||
int seconds = Mathf.FloorToInt(totalSeconds - minutes * 60);
|
||||
Text_TimeNow.text = $"{minutes:00}:{seconds:00}";
|
||||
|
||||
Image_ProcessNow.fillAmount = totalSeconds / curAudioLength;
|
||||
}
|
||||
/// <summary>
|
||||
/// 当音乐播放结束或切歌时刷新显示当前播放歌曲
|
||||
/// </summary>
|
||||
void PlayEndRefresh()
|
||||
{
|
||||
AudioListScrollView.UpdateData();
|
||||
curAudioLength = AudioManager.Instance.GetAlbumLength(AlbumManager.Instance.curMusicKey);
|
||||
int minutes = Mathf.FloorToInt(curAudioLength / 60F);
|
||||
int seconds = Mathf.FloorToInt(curAudioLength - minutes * 60);
|
||||
Text_AllTime.text = $"{minutes:00}:{seconds:00}";
|
||||
}
|
||||
|
||||
///// <summary>
|
||||
///// 播放进度计时器
|
||||
///// </summary>
|
||||
//class Timer
|
||||
//{
|
||||
// TMP_Text timeTxt;
|
||||
// bool isPlaying;
|
||||
// float audioLength = -1;
|
||||
// Image progressBar;
|
||||
//
|
||||
// async UniTask AudioTimer()
|
||||
// {
|
||||
// while(isPlaying)
|
||||
// {
|
||||
// float totalSeconds = AudioManager.Instance.GetAlbumProgress();
|
||||
// if (totalSeconds < 0)
|
||||
// {
|
||||
// isPlaying = false;
|
||||
// break;
|
||||
// }
|
||||
// int minutes = Mathf.FloorToInt(totalSeconds / 60F);
|
||||
// int seconds = Mathf.FloorToInt(totalSeconds - minutes * 60);
|
||||
// timeTxt.text = $"{minutes:00}:{seconds:00}";
|
||||
//
|
||||
// if (progressBar != null && audioLength > 0)
|
||||
// {
|
||||
// progressBar.fillAmount = totalSeconds / audioLength;
|
||||
// }
|
||||
// await UniTask.Delay(1000);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// public void Start(TMP_Text text, Image progressBar, float audiolen)
|
||||
// {
|
||||
// audioLength = audiolen;
|
||||
// if (isPlaying)
|
||||
// {
|
||||
// return;
|
||||
// }
|
||||
// isPlaying = true;
|
||||
// timeTxt = text;
|
||||
// this.progressBar = progressBar;
|
||||
// AudioTimer().Forget();
|
||||
// }
|
||||
// public void Start(TMP_Text text)
|
||||
// {
|
||||
// if (isPlaying)
|
||||
// {
|
||||
// return;
|
||||
// }
|
||||
// isPlaying = true;
|
||||
// timeTxt = text;
|
||||
// AudioTimer().Forget();
|
||||
// }
|
||||
//
|
||||
// public void Stop()
|
||||
// {
|
||||
// isPlaying = false;
|
||||
// }
|
||||
//}
|
||||
}
|
||||
|
|
@ -6,7 +6,8 @@
|
|||
"TapesPath": "UI_01-1",
|
||||
"DefaultUnlock": true,
|
||||
"PlayList": [
|
||||
2009
|
||||
2009,
|
||||
2010
|
||||
],
|
||||
"ItemID": 1200001,
|
||||
"CostItems": []
|
||||
|
|
@ -19,7 +20,8 @@
|
|||
"DefaultUnlock": false,
|
||||
"PlayList": [
|
||||
100001001,
|
||||
100001002
|
||||
100001002,
|
||||
100001003
|
||||
],
|
||||
"ItemID": 1200002,
|
||||
"CostItems": [
|
||||
|
|
|
|||
|
|
@ -289,7 +289,7 @@
|
|||
"Param2": 1002,
|
||||
"Param3": 0,
|
||||
"Rarity": 0,
|
||||
"BatchUsing": false,
|
||||
"BatchUsing": true,
|
||||
"MaxCount": 0,
|
||||
"IconPath": "",
|
||||
"CoinIconPath": "",
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
"ID": 911,
|
||||
"Level": 1,
|
||||
"MaxLevel": 5,
|
||||
"SkillID": 111,
|
||||
"SkillID": 91101,
|
||||
"skillType": 0,
|
||||
"LayerID": 1,
|
||||
"Unlock": [],
|
||||
|
|
@ -35,7 +35,7 @@
|
|||
"ID": 911,
|
||||
"Level": 2,
|
||||
"MaxLevel": 5,
|
||||
"SkillID": 112,
|
||||
"SkillID": 91102,
|
||||
"skillType": 0,
|
||||
"LayerID": 1,
|
||||
"Unlock": [],
|
||||
|
|
@ -51,7 +51,7 @@
|
|||
"ID": 911,
|
||||
"Level": 3,
|
||||
"MaxLevel": 5,
|
||||
"SkillID": 0,
|
||||
"SkillID": 91103,
|
||||
"skillType": 0,
|
||||
"LayerID": 1,
|
||||
"Unlock": [],
|
||||
|
|
@ -67,7 +67,7 @@
|
|||
"ID": 911,
|
||||
"Level": 4,
|
||||
"MaxLevel": 5,
|
||||
"SkillID": 0,
|
||||
"SkillID": 91104,
|
||||
"skillType": 0,
|
||||
"LayerID": 1,
|
||||
"Unlock": [],
|
||||
|
|
@ -83,7 +83,7 @@
|
|||
"ID": 911,
|
||||
"Level": 5,
|
||||
"MaxLevel": 5,
|
||||
"SkillID": 0,
|
||||
"SkillID": 91105,
|
||||
"skillType": 0,
|
||||
"LayerID": 1,
|
||||
"Unlock": [],
|
||||
|
|
|
|||
|
|
@ -5377,5 +5377,16 @@
|
|||
"AcbPath": "Assets/Audio/Music/NLD_BGM.acb",
|
||||
"Path": "Assets/Audio/Music/NLD_BGM",
|
||||
"Artist": "Cynthia"
|
||||
},
|
||||
{
|
||||
"ID": 2010,
|
||||
"Key": "NLD_BGM_Album_01_02",
|
||||
"Type": 1,
|
||||
"IsSpeak": false,
|
||||
"CueName": "bgm_01",
|
||||
"CueID": 0,
|
||||
"AcbPath": "Assets/Audio/Music/NLD_BGM.acb",
|
||||
"Path": "Assets/Audio/Music/NLD_BGM",
|
||||
"Artist": "Cynthia"
|
||||
}
|
||||
]
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1466,8 +1466,8 @@
|
|||
"ShadowDistance": 100,
|
||||
"Name": "LevelName201001",
|
||||
"Desc": "LevelDesc201001",
|
||||
"LevelScene": "",
|
||||
"MapData": "",
|
||||
"LevelScene": "Assets/Scenes/Maps/Maps04_Snowfield/Maps04_Snowfield_1.unity",
|
||||
"MapData": "MapData_Maps04_Snowfield_1",
|
||||
"LevelData": "LevelData_1_201001",
|
||||
"StoryID": ""
|
||||
},
|
||||
|
|
@ -1505,8 +1505,8 @@
|
|||
"ShadowDistance": 100,
|
||||
"Name": "LevelName201002",
|
||||
"Desc": "LevelDesc201002",
|
||||
"LevelScene": "",
|
||||
"MapData": "",
|
||||
"LevelScene": "Assets/Scenes/Maps/Maps01_Mountainous/Maps01_Mountainous_9.unity",
|
||||
"MapData": "MapData_Maps01_Mountainous_9",
|
||||
"LevelData": "LevelData_1_201002",
|
||||
"StoryID": ""
|
||||
},
|
||||
|
|
@ -1544,8 +1544,8 @@
|
|||
"ShadowDistance": 100,
|
||||
"Name": "LevelName201003",
|
||||
"Desc": "LevelDesc201003",
|
||||
"LevelScene": "",
|
||||
"MapData": "",
|
||||
"LevelScene": "Assets/Scenes/Maps/Maps04_Snowfield/Maps04_Snowfield_14.unity",
|
||||
"MapData": "MapData_Maps04_Snowfield_14",
|
||||
"LevelData": "LevelData_1_201003",
|
||||
"StoryID": ""
|
||||
},
|
||||
|
|
|
|||
|
|
@ -60056,7 +60056,7 @@
|
|||
"Value_En": ""
|
||||
},
|
||||
{
|
||||
"Key": "Guide_19",
|
||||
"Key": "Guide_20",
|
||||
"Value": "点击选中埃琳娜",
|
||||
"Param0": "",
|
||||
"Param1": "",
|
||||
|
|
@ -60064,7 +60064,7 @@
|
|||
"Value_En": ""
|
||||
},
|
||||
{
|
||||
"Key": "Guide_20",
|
||||
"Key": "Guide_21",
|
||||
"Value": "点击格子进行移动,战斗员会自动攻击范围内的敌人",
|
||||
"Param0": "",
|
||||
"Param1": "",
|
||||
|
|
@ -60072,21 +60072,13 @@
|
|||
"Value_En": ""
|
||||
},
|
||||
{
|
||||
"Key": "Guide_22",
|
||||
"Key": "Guide_23",
|
||||
"Value": "点击敌人可以切换攻击目标",
|
||||
"Param0": "",
|
||||
"Param1": "",
|
||||
"Param2": "",
|
||||
"Value_En": ""
|
||||
},
|
||||
{
|
||||
"Key": "Guide_24",
|
||||
"Value": "战斗中也可选中备战区的战斗员随时进行上阵",
|
||||
"Param0": "",
|
||||
"Param1": "",
|
||||
"Param2": "",
|
||||
"Value_En": ""
|
||||
},
|
||||
{
|
||||
"Key": "Guide_25",
|
||||
"Value": "战斗中也可选中备战区的战斗员随时进行上阵",
|
||||
|
|
@ -60097,7 +60089,7 @@
|
|||
},
|
||||
{
|
||||
"Key": "Guide_26",
|
||||
"Value": "点击上阵区格子完成战斗员上阵",
|
||||
"Value": "战斗中也可选中备战区的战斗员随时进行上阵",
|
||||
"Param0": "",
|
||||
"Param1": "",
|
||||
"Param2": "",
|
||||
|
|
@ -60105,7 +60097,7 @@
|
|||
},
|
||||
{
|
||||
"Key": "Guide_27",
|
||||
"Value": "拖动战斗员头像到目标位置可以释放战斗员技能,克劳迪娅可以远距离狙击敌人,试试她的技能吧",
|
||||
"Value": "点击上阵区格子完成战斗员上阵",
|
||||
"Param0": "",
|
||||
"Param1": "",
|
||||
"Param2": "",
|
||||
|
|
@ -60113,7 +60105,7 @@
|
|||
},
|
||||
{
|
||||
"Key": "Guide_28",
|
||||
"Value": "选中目标",
|
||||
"Value": "拖动战斗员头像到目标位置可以释放战斗员技能,克劳迪娅可以远距离狙击敌人,试试她的技能吧",
|
||||
"Param0": "",
|
||||
"Param1": "",
|
||||
"Param2": "",
|
||||
|
|
|
|||
Loading…
Reference in New Issue