Nlgp1.Parametersに各種インターフェイスを追加
@@ -79,10 +79,10 @@ | ||
79 | 79 | sprite.SpeedX = 1; |
80 | 80 | sprite.Shape.Hitted += ( sender , e ) => { |
81 | 81 | if( e.Direction == Direction.Right ) { |
82 | - e.TargetShape.Sprite.SpeedX = -0.3f; | |
82 | + e.Target.Sprite.SpeedX = -0.3f; | |
83 | 83 | } |
84 | 84 | else if( e.Direction == Direction.Left ) { |
85 | - e.TargetShape.Sprite.SpeedX = 0.3f; | |
85 | + e.Target.Sprite.SpeedX = 0.3f; | |
86 | 86 | } |
87 | 87 | }; |
88 | 88 | #endregion |
@@ -92,7 +92,7 @@ | ||
92 | 92 | sprite.Shape.Stepped += ( sender , e ) => { |
93 | 93 | bool hitsLower = false; |
94 | 94 | bool hitsUpper = true; |
95 | - foreach( SpriteShapeSteppedTarget result in e.Targets ) { | |
95 | + foreach( SpriteShapeSteppedEventArgsContact result in e.Contacts ) { | |
96 | 96 | if( result.Direction == Direction.Bottom ) { |
97 | 97 | if( result.Lower <= 0 ) { |
98 | 98 | hitsLower = true; |
@@ -102,10 +102,10 @@ | ||
102 | 102 | } |
103 | 103 | } |
104 | 104 | if( !hitsLower ) { |
105 | - e.SourceShape.Sprite.SpeedX = -0.05f; | |
105 | + e.Source.Sprite.SpeedX = -0.05f; | |
106 | 106 | } |
107 | 107 | else if( !hitsUpper ) { |
108 | - e.SourceShape.Sprite.SpeedX = +0.05f; | |
108 | + e.Source.Sprite.SpeedX = +0.05f; | |
109 | 109 | } |
110 | 110 | } |
111 | 111 | }; |
@@ -155,7 +155,7 @@ | ||
155 | 155 | case 14: |
156 | 156 | #region 10秒アイテム |
157 | 157 | sprite.Shape.Hitted += ( sender ,e ) => { |
158 | - if( e.TargetShape == PlayerStatus.Player.Sprite.Shape ) { | |
158 | + if( e.Target == PlayerStatus.Player.Sprite.Shape ) { | |
159 | 159 | PlayerStatus.TimerInitialize(); |
160 | 160 | } |
161 | 161 | }; |
@@ -79,9 +79,9 @@ | ||
79 | 79 | |
80 | 80 | #region プレーヤー自身に対するActionイベント |
81 | 81 | Player.Sprite.Shape.Hitted += ( sender , e ) => { |
82 | - if( e.Direction == Direction.Top && e.TargetShape.Sprite.IsDestroyable ) { | |
82 | + if( e.Direction == Direction.Top && e.Target.Sprite.IsDestroyable ) { | |
83 | 83 | // 上方向に移動しており、衝突したセルが破壊可能であれば、そのセルを置換します。 |
84 | - e.TargetShape.Sprite.Unload(); | |
84 | + e.Target.Sprite.Unload(); | |
85 | 85 | } |
86 | 86 | // if( Player.Attacking == AttackTypes.DivineBuster ) { |
87 | 87 | // Player.RunAttack( Player.Attacking ).Start(); |
@@ -6,26 +6,26 @@ | ||
6 | 6 | |
7 | 7 | public sealed class SpriteShapeSteppedEventArgs : EventArgs { |
8 | 8 | |
9 | - public SpriteShapeSteppedEventArgs( SpriteShape sourceShape , IEnumerable< SpriteShapeSteppedTarget > results ) { | |
10 | - this.SourceShape = sourceShape; | |
11 | - this.Targets = results; | |
9 | + public SpriteShapeSteppedEventArgs( SpriteShape source , IEnumerable< SpriteShapeSteppedEventArgsContact > contacts ) { | |
10 | + this.Source = source; | |
11 | + this.Contacts = contacts; | |
12 | 12 | } |
13 | 13 | |
14 | - public readonly SpriteShape SourceShape; | |
14 | + public readonly SpriteShape Source; | |
15 | 15 | |
16 | - public readonly IEnumerable< SpriteShapeSteppedTarget > Targets; | |
16 | + public readonly IEnumerable< SpriteShapeSteppedEventArgsContact > Contacts; | |
17 | 17 | } |
18 | 18 | |
19 | - public sealed class SpriteShapeSteppedTarget { | |
19 | + public sealed class SpriteShapeSteppedEventArgsContact { | |
20 | 20 | |
21 | - public SpriteShapeSteppedTarget( SpriteShape shape , Direction direction , float lower , float upper ) { | |
22 | - this.Shape = shape; | |
21 | + public SpriteShapeSteppedEventArgsContact( SpriteShape target , Direction direction , float lower , float upper ) { | |
22 | + this.Target = target; | |
23 | 23 | this.Direction = direction; |
24 | 24 | this.Lower = lower; |
25 | 25 | this.Upper = upper; |
26 | 26 | } |
27 | 27 | |
28 | - public readonly SpriteShape Shape; | |
28 | + public readonly SpriteShape Target; | |
29 | 29 | |
30 | 30 | public readonly Direction Direction; |
31 | 31 |
@@ -5,17 +5,17 @@ | ||
5 | 5 | |
6 | 6 | public sealed class SpriteShapeHittedEventArgs : EventArgs { |
7 | 7 | |
8 | - public SpriteShapeHittedEventArgs( SpriteShape sourceShape , SpriteShape targetShape , Direction direction , float lower , float upper ) { | |
9 | - this.SourceShape = sourceShape; | |
10 | - this.TargetShape = targetShape; | |
8 | + public SpriteShapeHittedEventArgs( SpriteShape source , SpriteShape target , Direction direction , float lower , float upper ) { | |
9 | + this.Source = source; | |
10 | + this.Target = target; | |
11 | 11 | this.Direction = direction; |
12 | 12 | this.Lower = lower; |
13 | 13 | this.Upper = upper; |
14 | 14 | } |
15 | 15 | |
16 | - public readonly SpriteShape SourceShape; | |
16 | + public readonly SpriteShape Source; | |
17 | 17 | |
18 | - public readonly SpriteShape TargetShape; | |
18 | + public readonly SpriteShape Target; | |
19 | 19 | |
20 | 20 | public readonly Direction Direction; |
21 | 21 |