(Pre. v.0.4.3) Floor voices in Tower mode
This commit is contained in:
parent
818f3966e3
commit
c407f28e57
@ -20,7 +20,7 @@ namespace TJAPlayer3
|
||||
// メソッド
|
||||
public void t再生( int nCombo, int player )
|
||||
{
|
||||
if(VoiceIndex[player] < ListCombo[player].Count)
|
||||
if (VoiceIndex[player] < ListCombo[player].Count)
|
||||
{
|
||||
|
||||
var index = ListCombo[player][VoiceIndex[player]];
|
||||
@ -33,6 +33,20 @@ namespace TJAPlayer3
|
||||
}
|
||||
}
|
||||
|
||||
public void tPlayFloorSound()
|
||||
{
|
||||
if (FloorIndex[0] < ListFloor[0].Count)
|
||||
{
|
||||
|
||||
var index = ListFloor[0][FloorIndex[0]];
|
||||
if (CFloorManagement.LastRegisteredFloor == index.nCombo)
|
||||
{
|
||||
index.soundComboVoice.t再生を開始する();
|
||||
FloorIndex[0]++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// カーソルを戻す。
|
||||
/// コンボが切れた時に使う。
|
||||
@ -49,18 +63,24 @@ namespace TJAPlayer3
|
||||
for (int i = 0; i < 2; i++)
|
||||
{
|
||||
ListCombo[i] = new List<CComboVoice>();
|
||||
ListFloor[i] = new List<CComboVoice>();
|
||||
}
|
||||
VoiceIndex = new int[] { 0, 0 };
|
||||
base.On活性化();
|
||||
FloorIndex = new int[] { 0, 0 };
|
||||
base.On活性化();
|
||||
}
|
||||
public override void OnManagedリソースの作成()
|
||||
{
|
||||
if( !base.b活性化してない )
|
||||
{
|
||||
// フォルダ内を走査してコンボボイスをListに入れていく
|
||||
// 1P、2P コンボボイス
|
||||
{
|
||||
|
||||
|
||||
// フォルダ内を走査してコンボボイスをListに入れていく
|
||||
// 1P、2P コンボボイス
|
||||
for (int i = 0; i < TJAPlayer3.ConfigIni.nPlayerCount; i++)
|
||||
{
|
||||
#region [Combo voices]
|
||||
|
||||
var currentDir = CSkin.Path(string.Format(@"Sounds\Combo_{0}P\", i + 1));
|
||||
if (Directory.Exists(currentDir))
|
||||
{
|
||||
@ -85,9 +105,35 @@ namespace TJAPlayer3
|
||||
{
|
||||
ListCombo[i].Sort();
|
||||
}
|
||||
}
|
||||
}
|
||||
base.OnManagedリソースの作成();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region [Floor voices]
|
||||
|
||||
currentDir = CSkin.Path(string.Format(@"Sounds\Tower_Combo\"));
|
||||
if (Directory.Exists(currentDir))
|
||||
{
|
||||
foreach (var item in Directory.GetFiles(currentDir))
|
||||
{
|
||||
var comboVoice = new CComboVoice();
|
||||
comboVoice.bFileFound = true;
|
||||
comboVoice.nPlayer = i;
|
||||
comboVoice.strFilePath = item;
|
||||
comboVoice.soundComboVoice = TJAPlayer3.Sound管理.tサウンドを生成する(item, ESoundGroup.Voice);
|
||||
comboVoice.nCombo = int.Parse(Path.GetFileNameWithoutExtension(item));
|
||||
ListFloor[i].Add(comboVoice);
|
||||
}
|
||||
if (ListFloor[i].Count > 0)
|
||||
{
|
||||
ListFloor[i].Sort();
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
}
|
||||
base.OnManagedリソースの作成();
|
||||
}
|
||||
}
|
||||
public override void OnManagedリソースの解放()
|
||||
@ -101,6 +147,12 @@ namespace TJAPlayer3
|
||||
TJAPlayer3.Sound管理.tサウンドを破棄する(item.soundComboVoice);
|
||||
}
|
||||
ListCombo[i].Clear();
|
||||
|
||||
foreach (var item in ListFloor[i])
|
||||
{
|
||||
TJAPlayer3.Sound管理.tサウンドを破棄する(item.soundComboVoice);
|
||||
}
|
||||
ListFloor[i].Clear();
|
||||
}
|
||||
|
||||
base.OnManagedリソースの解放();
|
||||
@ -110,10 +162,13 @@ namespace TJAPlayer3
|
||||
#region [ private ]
|
||||
//-----------------
|
||||
int[] VoiceIndex;
|
||||
int[] FloorIndex;
|
||||
|
||||
readonly List<CComboVoice>[] ListCombo = new List<CComboVoice>[2];
|
||||
//-----------------
|
||||
#endregion
|
||||
}
|
||||
readonly List<CComboVoice>[] ListFloor = new List<CComboVoice>[2];
|
||||
//-----------------
|
||||
#endregion
|
||||
}
|
||||
|
||||
public class CComboVoice : IComparable<CComboVoice>
|
||||
{
|
||||
|
@ -1804,6 +1804,8 @@ namespace TJAPlayer3
|
||||
{
|
||||
this.actComboBalloon.Start( this.actCombo.n現在のコンボ数[ nPlayer ], nPlayer );
|
||||
}
|
||||
|
||||
// Combo voice here
|
||||
this.actComboVoice.t再生( this.actCombo.n現在のコンボ数[ nPlayer ], nPlayer );
|
||||
|
||||
double dbUnit = (((60.0 / (TJAPlayer3.stage演奏ドラム画面.actPlayInfo.dbBPM))));
|
||||
|
@ -349,7 +349,8 @@ namespace TJAPlayer3
|
||||
|
||||
#region [Floor number]
|
||||
|
||||
CFloorManagement.LastRegisteredFloor = TJAPlayer3.stage演奏ドラム画面.actPlayInfo.NowMeasure[0] + 1;
|
||||
if (CFloorManagement.CurrentNumberOfLives > 0)
|
||||
CFloorManagement.LastRegisteredFloor = TJAPlayer3.stage演奏ドラム画面.actPlayInfo.NowMeasure[0] + 1;
|
||||
|
||||
string floorStr = CFloorManagement.LastRegisteredFloor.ToString();
|
||||
|
||||
@ -385,6 +386,12 @@ namespace TJAPlayer3
|
||||
|
||||
#region [Life number]
|
||||
|
||||
if (CFloorManagement.MaxNumberOfLives <= 0)
|
||||
{
|
||||
CFloorManagement.MaxNumberOfLives = 5;
|
||||
CFloorManagement.CurrentNumberOfLives = 5;
|
||||
}
|
||||
|
||||
string lifeStr = CFloorManagement.CurrentNumberOfLives.ToString();
|
||||
|
||||
len = lifeStr.Length;
|
||||
|
@ -550,7 +550,11 @@ namespace TJAPlayer3
|
||||
|
||||
this.actPanel.t歌詞テクスチャを描画する();
|
||||
|
||||
actChara.OnDraw_Balloon();
|
||||
actChara.OnDraw_Balloon();
|
||||
|
||||
// Floor voice
|
||||
if (TJAPlayer3.stage選曲.n確定された曲の難易度[0] == (int)Difficulty.Tower)
|
||||
this.actComboVoice.tPlayFloorSound();
|
||||
|
||||
this.t全体制御メソッド();
|
||||
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit 9c9d5c709f0a81fbe3bd9fd3c90822741d57f268
|
||||
Subproject commit cfa3580a0dab1354420d2d306c059cb7c30de91c
|
Loading…
x
Reference in New Issue
Block a user