Exemplo n.º 1
0
 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();
 }
Exemplo n.º 2
0
 public boolean isActionRunningByTag(Object tag) {
   if (tag == null) return false;
   for (AAction p : actions)
     if (p.getTag() == tag) {
       return true;
     }
   return false;
 }
Exemplo n.º 3
0
 public void stopActionByTag(Object tag) {
   AAction action = null;
   for (AAction p : actions) {
     if (p.getTag() == tag) {
       action = p;
       break;
     }
   }
   stopAction(action);
 }
Exemplo n.º 4
0
 public void stopAllActions() {
   for (AAction p : actions) p.stop();
   actions.clear();
 }
Exemplo n.º 5
0
 public void stopAction(AAction action) {
   if (action == null) return;
   action.stop();
 }
Exemplo n.º 6
0
 public void runAction(AAction action) {
   if (action == null) return;
   action.isRoot = true;
   action.startWithTarget(this);
   // actions.add(action);
 }