Posted By

mauroego on 01/27/09


Tagged

prototype rewind as2


Versions (?)

AS2 Rewind Prototype


 / Published in: ActionScript
 

  1. MovieClip.prototype.rewind = function(from, to) {
  2. this.from = from
  3. this.to = to
  4.  
  5. if (!from)
  6. this.from = this._currentframe
  7.  
  8. if (!to)
  9. this.to = 1
  10.  
  11. if (this.from <= this.to)
  12. return
  13.  
  14. this.gotoAndStop(this.from)
  15. this.onEnterFrame = function() {
  16. if (this._currentframe == this.to) {
  17. this.onEnterFrame = null
  18. return
  19. }
  20. this.prevFrame()
  21. }
  22. }

Report this snippet  

You need to login to post a comment.