File tree Expand file tree Collapse file tree
src/gameobjects/components Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -359,7 +359,7 @@ var Pipeline = {
359359 } ,
360360
361361 /**
362- * Removes a single Post Pipeline instance from this Game Object, based on the given name, and destroys it .
362+ * Removes a type of Post Pipeline instances from this Game Object, based on the given name, and destroys them .
363363 *
364364 * If you wish to remove all Post Pipelines use the `resetPostPipeline` method instead.
365365 *
@@ -375,7 +375,7 @@ var Pipeline = {
375375 {
376376 var pipelines = this . postPipelines ;
377377
378- for ( var i = 0 ; i < pipelines . length ; i ++ )
378+ for ( var i = pipelines . length - 1 ; i >= 0 ; i -- )
379379 {
380380 var instance = pipelines [ i ] ;
381381
@@ -386,11 +386,11 @@ var Pipeline = {
386386 instance . destroy ( ) ;
387387
388388 SpliceOne ( pipelines , i ) ;
389-
390- return this ;
391389 }
392390 }
393391
392+ this . hasPostPipeline = ( this . postPipelines . length > 0 ) ;
393+
394394 return this ;
395395 } ,
396396
You can’t perform that action at this time.
0 commit comments