No puede seleccionar más de 25 temas Los temas deben comenzar con una letra o número, pueden incluir guiones ('-') y pueden tener hasta 35 caracteres de largo.
 
 
 

28 líneas
474 B

  1. module.exports = {
  2. gotoPhaseIndex: null,
  3. repeats: 0,
  4. init: function () {
  5. if (!this.repeats) {
  6. this.end = true;
  7. return;
  8. }
  9. const event = this.event;
  10. const currentPhaseIndex = event.phases.findIndex(p => p === this);
  11. for (let i = this.gotoPhaseIndex; i < currentPhaseIndex; i++) {
  12. const phase = event.phases[i];
  13. delete phase.end;
  14. delete phase.destroyed;
  15. }
  16. event.nextPhase = this.gotoPhaseIndex;
  17. this.repeats--;
  18. this.end = true;
  19. }
  20. };