/** * Defines the effects of this panel. * * @param effects the effects to set */ public void setEffects(ArrayList<Effect> effects) { this.effects = effects; if (effectManager != null) { effectManager.getEffects().removeAll(effectManager.getEffects()); effectManager.getEffects().addAll(effects); } }
@Override public void setMainCanvas(Canvas mainCanvas) { this.mainCanvas = mainCanvas; this.effectManager = new EffectManager(mainCanvas); effectManager.getEffects().addAll(getEffects()); }