fix: if `m_Particles` contains null, an error will occur

close #214
pull/225/head
mob-sakai 2022-07-01 15:40:06 +09:00
parent c1538a8399
commit 550d0c43be
1 changed files with 1 additions and 0 deletions

View File

@ -290,6 +290,7 @@ namespace Coffee.UIExtensions
var j = 0; var j = 0;
for (var i = 0; i < particles.Count; i++) for (var i = 0; i < particles.Count; i++)
{ {
if (!particles[i]) continue;
GetRenderer(j++).Set(this, particles[i], false); GetRenderer(j++).Set(this, particles[i], false);
if (particles[i].trails.enabled) if (particles[i].trails.enabled)
{ {