2 using System.Collections.Generic;
\r
4 using System.Runtime.InteropServices;
\r
5 using System.Drawing;
\r
10 internal class CAct演奏DrumsレーンフラッシュD : CActivity
\r
14 public CAct演奏DrumsレーンフラッシュD()
\r
16 this.stレーンサイズ = new STレーンサイズ[ 8 ]
\r
18 new STレーンサイズ( 36 * 3 - 36 * 3, 36 ),
\r
19 new STレーンサイズ( 77 * 3 - 36 * 3, 30 ),
\r
20 new STレーンサイズ( 111 * 3 - 36 * 3, 30 ),
\r
21 new STレーンサイズ( 146 * 3 - 36 * 3, 42 ),
\r
22 new STレーンサイズ( 193 * 3 - 36 * 3, 30 ),
\r
23 new STレーンサイズ( 227 * 3 - 36 * 3, 30 ),
\r
24 new STレーンサイズ( 261 * 3 - 36 * 3, 30 ),
\r
25 new STレーンサイズ( 295 * 3 - 36 * 3, 36 )
\r
27 this.strファイル名 = new string[] {
\r
28 @"Graphics\ScreenPlayDrums lane flush cymbal.png",
\r
29 @"Graphics\ScreenPlayDrums lane flush hihat.png",
\r
30 @"Graphics\ScreenPlayDrums lane flush snare.png",
\r
31 @"Graphics\ScreenPlayDrums lane flush bass.png",
\r
32 @"Graphics\ScreenPlayDrums lane flush hitom.png",
\r
33 @"Graphics\ScreenPlayDrums lane flush lowtom.png",
\r
34 @"Graphics\ScreenPlayDrums lane flush floortom.png",
\r
35 @"Graphics\ScreenPlayDrums lane flush cymbal.png",
\r
36 @"Graphics\ScreenPlayDrums lane flush cymbal reverse.png",
\r
37 @"Graphics\ScreenPlayDrums lane flush hihat reverse.png",
\r
38 @"Graphics\ScreenPlayDrums lane flush snare reverse.png",
\r
39 @"Graphics\ScreenPlayDrums lane flush bass reverse.png",
\r
40 @"Graphics\ScreenPlayDrums lane flush hitom reverse.png",
\r
41 @"Graphics\ScreenPlayDrums lane flush lowtom reverse.png",
\r
42 @"Graphics\ScreenPlayDrums lane flush floortom reverse.png",
\r
43 @"Graphics\ScreenPlayDrums lane flush cymbal reverse.png"
\r
45 base.b活性化してない = true;
\r
51 public void Start( Eレーン lane, float f強弱度合い )
\r
53 int num = (int) ( ( 1f - f強弱度合い ) * 55f );
\r
54 this.ct進行[ (int) lane ] = new CCounter( num, 100, 4, CDTXMania.Instance.Timer );
\r
60 public override void On活性化()
\r
62 for ( int i = 0; i < 8; i++ )
\r
64 this.ct進行[ i ] = new CCounter();
\r
68 public override void On非活性化()
\r
70 for ( int i = 0; i < 8; i++ )
\r
72 this.ct進行[ i ] = null;
\r
76 public override void OnManagedリソースの作成()
\r
78 if ( !base.b活性化してない )
\r
80 for ( int i = 0; i < 0x10; i++ )
\r
82 this.txFlush[ i ] = TextureFactory.tテクスチャの生成Af( CSkin.Path( this.strファイル名[ i ] ) );
\r
84 base.OnManagedリソースの作成();
\r
87 public override void OnManagedリソースの解放()
\r
89 if ( !base.b活性化してない )
\r
91 for ( int i = 0; i < 0x10; i++ )
\r
93 TextureFactory.tテクスチャの解放( ref this.txFlush[ i ] );
\r
95 base.OnManagedリソースの解放();
\r
98 public override int On進行描画()
\r
100 if ( !base.b活性化してない )
\r
102 for ( int i = 0; i < 8; i++ )
\r
104 if ( !this.ct進行[ i ].b停止中 )
\r
106 this.ct進行[ i ].t進行();
\r
107 if ( this.ct進行[ i ].b終了値に達した )
\r
109 this.ct進行[ i ].t停止();
\r
113 for ( int j = 0; j < 8; j++ )
\r
115 if ( !this.ct進行[ j ].b停止中 )
\r
117 int x = this.stレーンサイズ[ j ].x;
\r
118 int w = this.stレーンサイズ[ j ].w;
\r
120 x = (int) ( x * ( CDTXMania.Instance.ConfigIni.eドラムレーン表示位置 == Eドラムレーン表示位置.Left ? 1.0 : 0.75 ) );
\r
121 x += ( CDTXMania.Instance.ConfigIni.eドラムレーン表示位置 == Eドラムレーン表示位置.Left ) ? 36 * 3 : 619 - 24 + 36;
\r
122 w = (int) ( w * ( CDTXMania.Instance.ConfigIni.eドラムレーン表示位置 == Eドラムレーン表示位置.Left ? 1.0 : 0.75 ) );
\r
124 //for ( int k = 0; k < 3; k++ )
\r
127 if ( CDTXMania.Instance.ConfigIni.bReverse.Drums )
\r
129 int y = ( k * 0x80 ) - ( ( this.ct進行[ j ].n現在の値 * 0x180 ) / 100 );
\r
130 for ( int m = 0; m < w; m += 42 )
\r
132 if ( this.txFlush[ j + 8 ] != null )
\r
134 this.txFlush[ j + 8 ].t2D描画(
\r
135 CDTXMania.Instance.Device,
\r
139 (int) ( ( k * 0x2a ) * Scale.X ),
\r
141 ( ( w - m ) < 0x2a ) ? (int) ( ( w - m ) * Scale.X ) : (int) ( 0x2a * Scale.X ),
\r
142 (int) ( 0x80 * 3 * Scale.Y )
\r
150 int y = ( 0x60 + ( k * 0x80 ) ) + ( ( this.ct進行[ j ].n現在の値 * 0x180 ) / 100 );
\r
153 for ( int n = 0; n < w; n += 42 )
\r
155 if ( this.txFlush[ j ] != null )
\r
157 this.txFlush[ j ].t2D描画(
\r
158 CDTXMania.Instance.Device,
\r
160 (int) ( y * Scale.Y ),
\r
162 (int) ( k * 0x2a * Scale.X ),
\r
164 ( ( w - n ) < 0x2a ) ? (int) ( ( w - n ) * Scale.X ) : (int) ( 0x2a * Scale.X ),
\r
165 (int) ( 0x80 * 3 * Scale.Y )
\r
182 #region [ private ]
\r
183 //-----------------
\r
184 [StructLayout( LayoutKind.Sequential )]
\r
185 private struct STレーンサイズ
\r
189 public STレーンサイズ( int x_, int w_ )
\r
196 private CCounter[] ct進行 = new CCounter[ 8 ];
\r
197 private readonly string[] strファイル名;
\r
198 private readonly STレーンサイズ[] stレーンサイズ;
\r
199 private CTextureAf[] txFlush = new CTextureAf[ 0x10 ];
\r
200 //-----------------
\r