mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 11:35:35 +08:00
Fix TriangleDrawNode crash when aimcount is zero
This commit is contained in:
parent
3b27398f22
commit
4c592a5e65
@ -214,7 +214,7 @@ namespace osu.Game.Graphics.Backgrounds
|
|||||||
{
|
{
|
||||||
base.Draw(vertexAction);
|
base.Draw(vertexAction);
|
||||||
|
|
||||||
if (vertexBatch == null || vertexBatch.Size != Source.AimCount)
|
if (vertexBatch == null || vertexBatch.Size != Source.AimCount && Source.AimCount > 0)
|
||||||
{
|
{
|
||||||
vertexBatch?.Dispose();
|
vertexBatch?.Dispose();
|
||||||
vertexBatch = new TriangleBatch<TexturedVertex2D>(Source.AimCount, 1);
|
vertexBatch = new TriangleBatch<TexturedVertex2D>(Source.AimCount, 1);
|
||||||
|
Loading…
Reference in New Issue
Block a user