private void doAlter(SpriteBatch batch, float parentAlpha) { for (AAction p : actions) if (p.isRoot) p.step(Gdx.graphics.getDeltaTime()); for (AAction p : actionsWillRemove) actions.remove(p); for (AAction p : actionsWillAdd) actions.add(p); actionsWillRemove.clear(); actionsWillAdd.clear(); }
public boolean isActionRunningByTag(Object tag) { if (tag == null) return false; for (AAction p : actions) if (p.getTag() == tag) { return true; } return false; }
public void stopActionByTag(Object tag) { AAction action = null; for (AAction p : actions) { if (p.getTag() == tag) { action = p; break; } } stopAction(action); }
public void stopAllActions() { for (AAction p : actions) p.stop(); actions.clear(); }
public void stopAction(AAction action) { if (action == null) return; action.stop(); }
public void runAction(AAction action) { if (action == null) return; action.isRoot = true; action.startWithTarget(this); // actions.add(action); }