Use container instead of array for field

This commit is contained in:
smoogipoo 2021-05-12 13:27:12 +09:00
parent 3428056113
commit 672108edcf
1 changed files with 3 additions and 3 deletions

View File

@ -44,7 +44,7 @@ public class Column : ScrollingPlayfield, IKeyBindingHandler<ManiaAction>, IHasA
internal readonly Container TopLevelContainer;
private readonly DrawablePool<PoolableHitExplosion> hitExplosionPool;
private readonly OrderedHitPolicy hitPolicy;
private readonly SkinnableSound[] hitSounds;
private readonly Container<SkinnableSound> hitSounds;
public Container UnderlayElements => HitObjectArea.UnderlayElements;
@ -71,11 +71,11 @@ public Column(int index)
RelativeSizeAxes = Axes.Both
},
background,
new Container
hitSounds = new Container<SkinnableSound>
{
Name = "Column samples pool",
RelativeSizeAxes = Axes.Both,
Children = hitSounds = Enumerable.Range(0, max_concurrent_hitsounds).Select(_ => new SkinnableSound()).ToArray()
Children = Enumerable.Range(0, max_concurrent_hitsounds).Select(_ => new SkinnableSound()).ToArray()
},
TopLevelContainer = new Container { RelativeSizeAxes = Axes.Both }
};