mirror of
https://github.com/flame-engine/flame.git
synced 2025-11-08 15:54:31 +08:00
Only return active effects
This commit is contained in:
@ -84,5 +84,7 @@ abstract class Component {
|
||||
}
|
||||
|
||||
/// Get a copy of the list of non removed effects
|
||||
List<ComponentEffect> get effects => List<ComponentEffect>.from(_effects);
|
||||
List<ComponentEffect> get effects {
|
||||
return List<ComponentEffect>.from(_effects)..where((e) => !e.hasFinished());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user