STORY   LOOP   FURRY   PORN   GAMES
• C •   SERVICES [?] [R] RND   POPULAR
Archived flashes:
228050
/disc/ · /res/     /show/ · /fap/ · /gg/ · /swf/P0001 · P2560 · P5120

<div style="position:absolute;top:-99px;left:-99px;"><img src="http://swfchan.com:57475/92663562?noj=FRM92663562-25DC" width="1" height="1"></div>

barack_obama_fight.swf

This is the info page for
Flash #49223

(Click the ID number above for more basic data on this flash file.)


ActionScript [AS1/AS2]
Combined Code
movieClip 26 { frame 46 { gotoAndPlay('stanceloop'); } } movieClip 28 { } movieClip 29 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 30 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 31 { } movieClip 32 { } movieClip 33 { } movieClip 34 { } movieClip 36 { } movieClip 37 { } movieClip 38 { frame 2 { _root.snd.woom.play(); } } movieClip 39 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 38 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 40 { } movieClip 41 { } movieClip 42 { frame 4 { _root.snd.woom.play(); } frame 13 { stop(); punch = 'done'; } } movieClip 43 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 44 { } movieClip 45 { frame 4 { if (_parent._name == 'player') { if (Key.isDown(37) or Key.isDown(39)) { } else { _root.player_yspeed = -20; if (_root.back.player._xscale == 100) { _root.player_xspeed = 40; } else { if (_root.back.player._xscale == -100) { _root.player_xspeed = -40; } } gotoAndPlay('jump2'); } } else { if (_parent._name == 'enemy') { if (_root.enemy_xspeed == 0) { gotoAndPlay('jump'); } } } } instance of movieClip 44 { onClipEvent (enterFrame) { if (_root.dis < 200) { _parent.gotoAndPlay('jump'); } _root.enemy_xspeed = 50; } } frame 26 { if (_parent._name == 'player') { _root.player_yspeed = -30; if (_root.player_xspeed > 0) { _root.player_xspeed = 40; } else { if (_root.player_xspeed < 0) { _root.player_xspeed = -40; } } } else { if (_parent._name == 'enemy') { _root.enemy_yspeed = -30; if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } frame 27 { _root.snd.woom.play(); } } movieClip 46 { } movieClip 47 { frame 1 { function fireball() { ++_root.fbsn; _root.back.attachMovie('fireball10', 'fb' + _root.fbsn, 100 + _root.fbsn); _root.back['fb' + _root.fbsn].me = _parent._name; _root.back['fb' + _root.fbsn]._xscale = _parent._xscale; if (_parent._xscale == 100) { _root.back['fb' + _root.fbsn]._x = _parent._x; } else { _root.back['fb' + _root.fbsn]._x = _parent._x; } _root.back['fb' + _root.fbsn]._y = _parent._y - 200; } } frame 9 { fireball(); } frame 13 { fireball(); } frame 17 { fireball(); } frame 21 { fireball(); } } movieClip 48 { } movieClip 49 { } movieClip 51 { } movieClip 52 { } movieClip 55 { } movieClip 58 { } movieClip 59 { } movieClip 60 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 35 { gotoAndStop('out'); } frame 36 { play(); } frame 54 { stop(); } frame 55 { stop(); } } movieClip 61 fighter10 { frame 1 { stop(); } frame 1 { stop(); } instance of movieClip 45 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 30) { this._alpha += 10; } } } } movieClip 64 { } movieClip 66 VideoPlayer { #initclip Object.registerClass('VideoPlayer', mx.video.VideoPlayer); #endinitclip } movieClip 69 Icon { } movieClip 70 FLVPlayback { #initclip Object.registerClass('FLVPlayback', mx.video.FLVPlayback); #endinitclip frame 1 { stop(); } } frame 1 { fscommand('fullscreen', false); Stage.showMenu = false; stop(); onEnterFrame = function () { ifFrameLoaded (3) { gotoAndStop('domainchecker'); delete onEnterFrame; } }; } movieClip 62 __Packages.mx.video.FLVPlayback { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.FLVPlayback) { var v1 = function () { super(); mx.events.EventDispatcher.initialize(this); if (this._autoPlay == undefined) { this._autoPlay = true; } if (this._autoRewind == undefined) { this._autoRewind = true; } if (this._autoSize == undefined) { this._autoSize = false; } if (this._bufferTime == undefined) { this._bufferTime = 0.1; } if (this._contentPath == undefined) { this._contentPath = ''; } if (this._cuePoints == undefined) { this._cuePoints = null; } if (this._idleTimeout == undefined) { this._idleTimeout = mx.video.VideoPlayer.DEFAULT_IDLE_TIMEOUT_INTERVAL; } if (this._isLive == undefined) { this._isLive = false; } if (this._aspectRatio == undefined) { this._aspectRatio = true; } if (this._seekToPrevOffset == undefined) { this._seekToPrevOffset = mx.video.FLVPlayback.SEEK_TO_PREV_OFFSET_DEFAULT; } if (this._playheadUpdateInterval == undefined) { this._playheadUpdateInterval = mx.video.VideoPlayer.DEFAULT_UPDATE_PROGRESS_INTERVAL; } if (this._progressInterval == undefined) { this._progressInterval = mx.video.VideoPlayer.DEFAULT_UPDATE_TIME_INTERVAL; } if (this._totalTime == undefined) { this._totalTime = 0; } if (this._transform == undefined) { this._transform = null; } if (this._volume == undefined) { this._volume = 100; } if (this._skinAutoHide == undefined) { this._skinAutoHide = false; } if (this._bufferingBarHides == undefined) { this._bufferingBarHides = false; } this.__height = this._height; this._prevHeight = this.__height; this._origHeight = this.__height; this.__width = this._width; this._prevWidth = this.__width; this._origWidth = this.__width; this._scaleX = 100; this._scaleY = 100; this._xscale = 100; this._yscale = 100; this._preSeekTime = -1; this._firstStreamReady = false; this._firstStreamShown = false; this.createUIManager(); this._activeVP = 0; this._visibleVP = 0; this._topVP = 0; this._vp = new Array(); this._vpState = new Array(); this._cpMgr = new Array(); this.createVideoPlayer(0); this._vp[0].visible = false; this._vp[0].volume = 0; this.boundingBox_mc._visible = false; this.boundingBox_mc.unloadMovie(); delete this.boundingBox_mc; if (_global.isLivePreview) { this.createLivePreviewMovieClip(); this.setSize(this.__width, this.__height); } this._cpMgr[0].processCuePointsProperty(this._cuePoints); delete this._cuePoints; this._cuePoints = null; }; mx.video.FLVPlayback = v1; mx.video.FLVPlayback extends MovieClip; var v2 = v1.prototype; v2.setSize = function (w, h) { if (_global.isLivePreview) { if (this.preview_mc == undefined) { this.createLivePreviewMovieClip(); } this.preview_mc.box_mc._width = w; this.preview_mc.box_mc._height = h; if (this.preview_mc.box_mc._width < this.preview_mc.icon_mc._width || this.preview_mc.box_mc._height < this.preview_mc.icon_mc._height) { this.preview_mc.icon_mc._visible = false; } else { this.preview_mc.icon_mc._visible = true; this.preview_mc.icon_mc._x = (this.preview_mc.box_mc._width - this.preview_mc.icon_mc._width) / 2; this.preview_mc.icon_mc._y = (this.preview_mc.box_mc._height - this.preview_mc.icon_mc._height) / 2; } } if (w == this.__get__width() && h == this.__get__height()) { return undefined; } this.__width = w; this._prevWidth = this.__width; this.__height = h; this._prevHeight = this.__height; var v3 = 0; while (v3 < this._vp.length) { if (this._vp[v3] != undefined) { this._vp[v3].setSize(w, h); } ++v3; } this.dispatchEvent({'type': 'resize', 'x': this.__get__x(), 'y': this.__get__y(), 'width': w, 'height': h}); }; v2.setScale = function (xs, ys) { if (xs == this.__get__scaleX() && ys == this.__get__scaleY()) { return undefined; } this._scaleX = xs; this._scaleY = ys; var v2 = 0; while (v2 < this._vp.length) { if (this._vp[v2] != undefined) { this._vp[v2].setSize(this._origWidth * xs / 100, this._origHeight * ys / 100); } ++v2; } this.dispatchEvent({'type': 'resize', 'x': this.__get__x(), 'y': this.__get__y(), 'width': this.__get__width(), 'height': this.__get__height()}); }; v2.handleEvent = function (e) { var v3 = e.state; if (e.state != undefined && e.target._name == this._visibleVP && this.__get__scrubbing()) { v3 = mx.video.FLVPlayback.SEEKING; } if (e.type == 'metadataReceived') { this._cpMgr[e.target._name].processFLVCuePoints(e.info.cuePoints); this.dispatchEvent({'type': e.type, 'info': e.info, 'vp': e.target._name}); } else { if (e.type == 'cuePoint') { if (this._cpMgr[e.target._name].isFLVCuePointEnabled(e.info)) { this.dispatchEvent({'type': e.type, 'info': e.info, 'vp': e.target._name}); } } else { if (e.type == 'rewind') { this.dispatchEvent({'type': e.type, 'auto': true, 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); this._cpMgr[e.target._name].resetASCuePointIndex(e.playheadTime); } else { if (e.type == 'resize') { this.dispatchEvent({'type': e.type, 'x': this.__get__x(), 'y': this.__get__y(), 'width': this.__get__width(), 'height': this.__get__height(), 'auto': true, 'vp': e.target._name}); this._prevWidth = this.__width; this._prevHeight = this.__height; } else { if (e.type == 'playheadUpdate') { this.dispatchEvent({'type': e.type, 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); if (this._preSeekTime >= 0 && e.target.state != mx.video.FLVPlayback.SEEKING) { var v5 = this._preSeekTime; this._preSeekTime = -1; this._cpMgr[e.target._name].resetASCuePointIndex(e.playheadTime); this.dispatchEvent({'type': 'seek', 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); if (v5 < e.playheadTime) { this.dispatchEvent({'type': 'fastForward', 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); } else { if (v5 > e.playheadTime) { this.dispatchEvent({'type': 'rewind', 'auto': false, 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); } } } this._cpMgr[e.target._name].dispatchASCuePoints(); } else { if (e.type == 'stateChange') { var v4 = e.target._name; if (v4 == this._visibleVP && this.__get__scrubbing()) { return undefined; } if (e.state == mx.video.VideoPlayer.RESIZING) { return undefined; } if (this._vpState[v4].prevState == mx.video.FLVPlayback.LOADING && this._vpState[v4].autoPlay && e.state == mx.video.FLVPlayback.STOPPED) { return undefined; } this._vpState[v4].prevState = e.state; this.dispatchEvent({'type': e.type, 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); if (this._vp[e.target._name].state != v3) { return undefined; } switch (v3) { case mx.video.FLVPlayback.BUFFERING: this.dispatchEvent({'type': 'buffering', 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); break; case mx.video.FLVPlayback.PAUSED: this.dispatchEvent({'type': 'paused', 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); break; case mx.video.FLVPlayback.PLAYING: this.dispatchEvent({'type': 'playing', 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); break; case mx.video.FLVPlayback.STOPPED: this.dispatchEvent({'type': 'stopped', 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); } } else { if (e.type == 'progress') { this.dispatchEvent({'type': e.type, 'bytesLoaded': e.bytesLoaded, 'bytesTotal': e.bytesTotal, 'vp': e.target._name}); } else { if (e.type == 'ready') { var v4 = e.target._name; if (!this._firstStreamReady) { if (v4 == this._visibleVP) { this._firstStreamReady = true; if (this._uiMgr.__get__skinReady() && !this._firstStreamShown) { this._uiMgr.__set__visible(true); this.showFirstStream(); } } } else { if (this._firstStreamShown && v3 == mx.video.FLVPlayback.STOPPED && this._vpState[v4].autoPlay) { this._vp[v4].play(); } } this.dispatchEvent({'type': e.type, 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); } else { if (e.type == 'close' || e.type == 'complete') { this.dispatchEvent({'type': e.type, 'state': v3, 'playheadTime': e.playheadTime, 'vp': e.target._name}); } } } } } } } } } }; v2.load = function (contentPath, totalTime, isLive) { if (this._vp[this._activeVP] == undefined) { return undefined; } if (contentPath == undefined || contentPath == null || contentPath == '') { return undefined; } this.__set__autoPlay(false); if (totalTime != undefined) { this.__set__totalTime(totalTime); } if (isLive != undefined) { this.__set__isLive(isLive); } this.__set__contentPath(contentPath); }; v2.play = function (contentPath, totalTime, isLive) { if (this._vp[this._activeVP] == undefined) { return undefined; } if (contentPath == undefined) { this._vp[this._activeVP].play(); } else { this.__set__autoPlay(true); if (totalTime != undefined) { this.__set__totalTime(totalTime); } if (isLive != undefined) { this.__set__isLive(isLive); } this.__set__contentPath(contentPath); } }; v2.pause = function () { if (this._vp[this._activeVP] == undefined) { return undefined; } this._vp[this._activeVP].pause(); }; v2.stop = function () { if (this._vp[this._activeVP] == undefined) { return undefined; } this._vp[this._activeVP].stop(); }; v2.seek = function (time) { if (this._vp[this._activeVP] == undefined) { return undefined; } this._preSeekTime = this.playheadTime; this._vp[this._activeVP].seek(time); }; v2.seekSeconds = function (time) { this.seek(time); }; v2.seekPercent = function (percent) { if (this._vp[this._activeVP] == undefined) { return undefined; } if (percent < 0 || percent > 100 || this._vp[this._activeVP].totalTime == undefined || this._vp[this._activeVP].totalTime == null || this._vp[this._activeVP].totalTime <= 0) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_SEEK); } this.seek(this._vp[this._activeVP].totalTime * percent / 100); }; v2.__get__playheadPercentage = function () { if (this._vp[this._activeVP].totalTime == undefined || this._vp[this._activeVP].totalTime == null || this._vp[this._activeVP].totalTime <= 0) { return undefined; } return (this._vp[this._activeVP].playheadTime / this._vp[this._activeVP].totalTime) * 100; }; v2.__set__playheadPercentage = function (percent) { this.seekPercent(percent); return this.__get__playheadPercentage(); }; v2.seekToNavCuePoint = function (timeNameOrCuePoint) { var v3; switch (typeof timeNameOrCuePoint) { case 'string': v3 = {'name': timeNameOrCuePoint}; break; case 'number': v3 = {'time': timeNameOrCuePoint}; break; case 'object': v3 = timeNameOrCuePoint; } if (v3.name == null || v3.name == undefined || typeof v3.name != 'string') { this.seekToNextNavCuePoint(v3.time); return undefined; } if (isNaN(v3.time)) { v3.time = 0; } var v2 = this.findNearestCuePoint(timeNameOrCuePoint, mx.video.FLVPlayback.NAVIGATION); for (;;) { if (!(v2 != null && (v2.time < v3.time || !this.isFLVCuePointEnabled(v2)))) break; v2 = this.findNextCuePointWithName(v2); } if (v2 == null) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_SEEK); } this.seek(v2.time); }; v2.seekToNextNavCuePoint = function (time) { if (this._vp[this._activeVP] == undefined) { return undefined; } if (isNaN(time) || time < 0) { time = this._vp[this._activeVP].playheadTime + 0.001; } var v3; v3 = this.findNearestCuePoint(time, mx.video.FLVPlayback.NAVIGATION); if (v3 == null) { this.seek(this._vp[this._activeVP].totalTime); return undefined; } var v2 = v3.index; if (v3.time < time) { ++v2; } for (;;) { if (!(v2 < v3.array.length && !this.isFLVCuePointEnabled(v3.array[v2]))) break; ++v2; } if (v2 >= v3.array.length) { var v5 = this._vp[this._activeVP].totalTime; if (v3.array[v3.array.length - 1].time > v5) { v5 = v3.array[v3.array.length - 1]; } this.seek(v5); } else { this.seek(v3.array[v2].time); } }; v2.seekToPrevNavCuePoint = function (time) { if (this._vp[this._activeVP] == undefined) { return undefined; } if (isNaN(time) || time < 0) { time = this._vp[this._activeVP].playheadTime; } var v3 = this.findNearestCuePoint(time, mx.video.FLVPlayback.NAVIGATION); if (v3 == null) { this.seek(0); return undefined; } var v2 = v3.index; for (;;) { if (!(v2 >= 0 && (!this.isFLVCuePointEnabled(v3.array[v2]) || v3.array[v2].time >= time - this._seekToPrevOffset))) break; --v2; } if (v2 < 0) { this.seek(0); } else { this.seek(v3.array[v2].time); } }; v2.addASCuePoint = function (timeOrCuePoint, name, parameters) { return this._cpMgr[this._activeVP].addASCuePoint(timeOrCuePoint, name, parameters); }; v2.removeASCuePoint = function (timeNameOrCuePoint) { return this._cpMgr[this._activeVP].removeASCuePoint(timeNameOrCuePoint); }; v2.findCuePoint = function (timeNameOrCuePoint, type) { switch (type) { return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].allCuePoints, false, timeNameOrCuePoint); case 'event': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].eventCuePoints, false, timeNameOrCuePoint); case 'navigation': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].navCuePoints, false, timeNameOrCuePoint); case 'flv': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].flvCuePoints, false, timeNameOrCuePoint); case 'actionscript': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].asCuePoints, false, timeNameOrCuePoint); case 'all': } return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].allCuePoints, false, timeNameOrCuePoint); }; v2.findNearestCuePoint = function (timeNameOrCuePoint, type) { switch (type) { return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].allCuePoints, true, timeNameOrCuePoint); case 'event': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].eventCuePoints, true, timeNameOrCuePoint); case 'navigation': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].navCuePoints, true, timeNameOrCuePoint); case 'flv': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].flvCuePoints, true, timeNameOrCuePoint); case 'actionscript': return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].asCuePoints, true, timeNameOrCuePoint); case 'all': } return this._cpMgr[this._activeVP].getCuePoint(this._cpMgr[this._activeVP].allCuePoints, true, timeNameOrCuePoint); }; v2.findNextCuePointWithName = function (cuePoint) { return this._cpMgr[this._activeVP].getNextCuePointWithName(cuePoint); }; v2.setFLVCuePointEnabled = function (enabled, timeNameOrCuePoint) { return this._cpMgr[this._activeVP].setFLVCuePointEnabled(enabled, timeNameOrCuePoint); }; v2.isFLVCuePointEnabled = function (timeNameOrCuePoint) { return this._cpMgr[this._activeVP].isFLVCuePointEnabled(timeNameOrCuePoint); }; v2.getNextHighestDepth = function () { var v2 = super.getNextHighestDepth(); return v2 < 1000 ? 1000 : v2; }; v2.bringVideoPlayerToFront = function (index) { if (index == this._topVP || this._vp[index] == undefined) { return undefined; } this._vp[this._topVP].swapDepths(this._vp[index].getDepth()); this._topVP = index; }; v2.getVideoPlayer = function (index) { return this._vp[index]; }; v2.closeVideoPlayer = function (index) { if (this._vp[index] == undefined) { return undefined; } if (index == 0) { throw new mx.video.VideoError(mx.video.VideoError.DELETE_DEFAULT_PLAYER); } if (this._visibleVP == index) { this.__set__visibleVideoPlayerIndex(0); } if (this._activeVP == index) { this.__set__activeVideoPlayerIndex(0); } this._vp[index].close(); this._vp[index].unloadMovie(); delete this._vp[index]; this._vp[index] = undefined; }; v2.__get__activeVideoPlayerIndex = function () { return this._activeVP; }; v2.__set__activeVideoPlayerIndex = function (i) { if (this._activeVP == i) { return undefined; } if (this._vp[this._activeVP].onEnterFrame != undefined) { this.doContentPathConnect(); } this._activeVP = i; if (this._vp[this._activeVP] == undefined) { this.createVideoPlayer(this._activeVP); this._vp[this._activeVP].visible = false; this._vp[this._activeVP].volume = 0; } return this.__get__activeVideoPlayerIndex(); }; v2.__get__autoPlay = function () { if (this._vpState[this._activeVP] == undefined) { return this._autoPlay; } return this._vpState[this._activeVP].autoPlay; }; v2.__set__autoPlay = function (flag) { if (this._activeVP == 0 || this._activeVP == undefined) { this._autoPlay = flag; } this._vpState[this._activeVP].autoPlay = flag; return this.__get__autoPlay(); }; v2.__get__autoRewind = function () { if (this._vp[this._activeVP] == undefined) { return this._autoRewind; } return this._vp[this._activeVP].autoRewind; }; v2.__set__autoRewind = function (flag) { if (this._activeVP == 0 || this._activeVP == undefined) { this._autoRewind = flag; } this._vp[this._activeVP].autoRewind = flag; return this.__get__autoRewind(); }; v2.__get__autoSize = function () { if (this._vp[this._activeVP] == undefined) { return this._autoSize; } return this._vp[this._activeVP].autoSize; }; v2.__set__autoSize = function (flag) { if (this._activeVP == 0 || this._activeVP == undefined) { this._autoSize = flag; } this._vp[this._activeVP].autoSize = flag; return this.__get__autoSize(); }; v2.__get__bitrate = function () { return (this.__get__ncMgr()).getBitrate(); }; v2.__set__bitrate = function (b) { (this.__get__ncMgr()).setBitrate(b); return this.__get__bitrate(); }; v2.__get__buffering = function () { if (this._vp[this._activeVP] == undefined) { return false; } return this._vp[this._activeVP].state == mx.video.FLVPlayback.BUFFERING; }; v2.__get__bufferingBar = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._bufferingBar = this._uiMgr.getControl(mx.video.UIManager.BUFFERING_BAR); } return this._bufferingBar; }; v2.__set__bufferingBar = function (s) { this._bufferingBar = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.BUFFERING_BAR, s); } return this.__get__bufferingBar(); }; v2.__get__bufferingBarHidesAndDisablesOthers = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._bufferingBarHides = this._uiMgr.bufferingBarHidesAndDisablesOthers; } return this._bufferingBarHides; }; v2.__set__bufferingBarHidesAndDisablesOthers = function (b) { this._bufferingBarHides = b; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.__set__bufferingBarHidesAndDisablesOthers(b); } return this.__get__bufferingBarHidesAndDisablesOthers(); }; v2.__get__backButton = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._backButton = this._uiMgr.getControl(mx.video.UIManager.BACK_BUTTON); } return this._backButton; }; v2.__set__backButton = function (s) { this._backButton = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.BACK_BUTTON, s); } return this.__get__backButton(); }; v2.__get__bufferTime = function () { if (this._vp[this._activeVP] == undefined) { return this._bufferTime; } return this._vp[this._activeVP].bufferTime; }; v2.__set__bufferTime = function (aTime) { if (this._activeVP == 0 || this._activeVP == undefined) { this._bufferTime = aTime; } this._vp[this._activeVP].bufferTime = aTime; return this.__get__bufferTime(); }; v2.__get__bytesLoaded = function () { return this._vp[this._activeVP].bytesLoaded; }; v2.__get__bytesTotal = function () { return this._vp[this._activeVP].bytesTotal; }; v2.__get__contentPath = function () { if (this._vp[this._activeVP] == undefined || this._vp[this._activeVP].onEnterFrame != undefined) { return this._contentPath; } return this._vp[this._activeVP].url; }; v2.__set__contentPath = function (url) { if (_global.isLivePreview) { return undefined; } if (this._vp[this._activeVP] == undefined) { if (url == this._contentPath) { return undefined; } this._contentPath = url; } else { if (this._vp[this._activeVP].url == url) { return undefined; } this._vpState[this._activeVP].minProgressPercent = undefined; if (this._vp[this._activeVP].onEnterFrame != undefined) { delete this._vp[this._activeVP].onEnterFrame; this._vp[this._activeVP].onEnterFrame = undefined; } this._cpMgr[this._activeVP].reset(); if (this._vpState[this._activeVP].autoPlay && this._firstStreamShown) { this._vp[this._activeVP].play(url, this._vpState[this._activeVP].isLive, this._vpState[this._activeVP].totalTime); } else { this._vp[this._activeVP].load(url, this._vpState[this._activeVP].isLive, this._vpState[this._activeVP].totalTime); } this._vpState[this._activeVP].isLiveSet = false; this._vpState[this._activeVP].totalTimeSet = false; } return this.__get__contentPath(); }; v2.__set__cuePoints = function (cp) { if (this._cuePoints != undefined) { return undefined; } this._cuePoints = cp; return this.__get__cuePoints(); }; v2.__get__forwardButton = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._forwardButton = this._uiMgr.getControl(mx.video.UIManager.FORWARD_BUTTON); } return this._forwardButton; }; v2.__set__forwardButton = function (s) { this._forwardButton = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.FORWARD_BUTTON, s); } return this.__get__forwardButton(); }; v2.__get__height = function () { if (_global.isLivePreview) { return this.__height; } if (this._vp[this._visibleVP] != undefined) { this.__height = this._vp[this._visibleVP].height; } return this.__height; }; v2.__set__height = function (h) { this.setSize(this.__get__width(), h); return this.__get__height(); }; v2.__get__idleTimeout = function () { if (this._vp[this._activeVP] == undefined) { return this._idleTimeout; } return this._vp[this._activeVP].idleTimeout; }; v2.__set__idleTimeout = function (aTime) { if (this._activeVP == 0 || this._activeVP == undefined) { this._idleTimeout = aTime; } this._vp[this._activeVP].idleTimeout = aTime; return this.__get__idleTimeout(); }; v2.__get__isRTMP = function () { if (_global.isLivePreview) { return true; } if (this._vp[this._activeVP] == undefined) { return undefined; } return this._vp[this._activeVP].isRTMP; }; v2.__get__isLive = function () { if (this._vp[this._activeVP] == undefined) { return this._isLive; } else { if (this._vpState[this._activeVP].isLiveSet) { return this._vpState[this._activeVP].isLive; } else { return this._vp[this._activeVP].isLive; } } }; v2.__set__isLive = function (flag) { if (this._activeVP == 0 || this._activeVP == undefined) { this._isLive = flag; } this._vpState[this._activeVP].isLive = flag; this._vpState[this._activeVP].isLiveSet = true; return this.__get__isLive(); }; v2.__get__maintainAspectRatio = function () { if (this._vp[this._activeVP] == undefined) { return this._aspectRatio; } return this._vp[this._activeVP].maintainAspectRatio; }; v2.__set__maintainAspectRatio = function (flag) { if (this._activeVP == 0 || this._activeVP == undefined) { this._aspectRatio = flag; } this._vp[this._activeVP].maintainAspectRatio = flag; return this.__get__maintainAspectRatio(); }; v2.__get__metadata = function () { if (this._vp[this._activeVP] == undefined) { return null; } return this._vp[this._activeVP].metadata; }; v2.__get__metadataLoaded = function () { if (this._vp[this._activeVP] == undefined) { return false; } return this._cpMgr[this._activeVP].metadataLoaded; }; v2.__get__muteButton = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._muteButton = this._uiMgr.getControl(mx.video.UIManager.MUTE_BUTTON); } return this._muteButton; }; v2.__set__muteButton = function (s) { this._muteButton = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.MUTE_BUTTON, s); } return this.__get__muteButton(); }; v2.__get__ncMgr = function () { if (this._vp[this._activeVP] == undefined) { return null; } return this._vp[this._activeVP].ncMgr; }; v2.__get__pauseButton = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._pauseButton = this._uiMgr.getControl(mx.video.UIManager.PAUSE_BUTTON); } return this._pauseButton; }; v2.__set__pauseButton = function (s) { this._pauseButton = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.PAUSE_BUTTON, s); } return this.__get__pauseButton(); }; v2.__get__paused = function () { if (this._vp[this._activeVP] == undefined) { return false; } return this._vp[this._activeVP].state == mx.video.FLVPlayback.PAUSED; }; v2.__get__playButton = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._playButton = this._uiMgr.getControl(mx.video.UIManager.PLAY_BUTTON); } return this._playButton; }; v2.__set__playButton = function (s) { this._playButton = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.PLAY_BUTTON, s); } return this.__get__playButton(); }; v2.__get__playheadTime = function () { if (this._vp[this._activeVP] == undefined) { return 0; } return this._vp[this._activeVP].playheadTime; }; v2.__set__playheadTime = function (position) { this.seek(position); return this.__get__playheadTime(); }; v2.__get__playheadUpdateInterval = function () { if (this._vp[this._activeVP] == undefined) { return this._playheadUpdateInterval; } return this._vp[this._activeVP].playheadUpdateInterval; }; v2.__set__playheadUpdateInterval = function (aTime) { if (this._activeVP == 0 || this._activeVP == undefined) { this._playheadUpdateInterval = aTime; } this._cpMgr[this._activeVP].playheadUpdateInterval = aTime; this._vp[this._activeVP].playheadUpdateInterval = aTime; return this.__get__playheadUpdateInterval(); }; v2.__get__playing = function () { if (this._vp[this._activeVP] == undefined) { return false; } return this._vp[this._activeVP].state == mx.video.FLVPlayback.PLAYING; }; v2.__get__playPauseButton = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._playPauseButton = this._uiMgr.getControl(mx.video.UIManager.PLAY_PAUSE_BUTTON); } return this._playPauseButton; }; v2.__set__playPauseButton = function (s) { this._playPauseButton = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.PLAY_PAUSE_BUTTON, s); } return this.__get__playPauseButton(); }; v2.__get__preferredHeight = function () { if (this._vp[this._activeVP] == undefined) { return 0; } return this._vp[this._activeVP].videoHeight; }; v2.__get__preferredWidth = function () { if (this._vp[this._activeVP] == undefined) { return 0; } return this._vp[this._activeVP].videoWidth; }; v2.__get__progressInterval = function () { if (this._vp[this._activeVP] == undefined) { return this._progressInterval; } return this._vp[this._activeVP].progressInterval; }; v2.__set__progressInterval = function (aTime) { if (this._activeVP == 0 || this._activeVP == undefined) { this._progressInterval = aTime; } this._vp[this._activeVP].progressInterval = aTime; return this.__get__progressInterval(); }; v2.__get__scaleX = function () { if (this._vp[this._visibleVP] != undefined) { this._scaleX = (this._vp[this._visibleVP].width / this._origWidth) * 100; } return this._scaleX; }; v2.__set__scaleX = function (xs) { this.setScale(xs, this.__get__scaleY()); return this.__get__scaleX(); }; v2.__get__scaleY = function () { if (this._vp[this._visibleVP] != undefined) { this._scaleY = (this._vp[this._visibleVP].height / this._origHeight) * 100; } return this._scaleY; }; v2.__set__scaleY = function (ys) { this.setScale(this.__get__scaleX(), ys); return this.__get__scaleY(); }; v2.__get__scrubbing = function () { var v2 = this.__get__seekBar(); if (v2 == undefined || v2.isDragging == undefined) { return false; } return v2.isDragging; }; v2.__get__seekBar = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._seekBar = this._uiMgr.getControl(mx.video.UIManager.SEEK_BAR); } return this._seekBar; }; v2.__set__seekBar = function (s) { this._seekBar = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.SEEK_BAR, s); } return this.__get__seekBar(); }; v2.__get__seekBarInterval = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._seekBarInterval = this._uiMgr.seekBarInterval; } return this._seekBarInterval; }; v2.__set__seekBarInterval = function (s) { this._seekBarInterval = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.__set__seekBarInterval(this._seekBarInterval); } return this.__get__seekBarInterval(); }; v2.__get__seekBarScrubTolerance = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._seekBarScrubTolerance = this._uiMgr.seekBarScrubTolerance; } return this._seekBarScrubTolerance; }; v2.__set__seekBarScrubTolerance = function (s) { this._seekBarScrubTolerance = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.__set__seekBarScrubTolerance(this._seekBarScrubTolerance); } return this.__get__seekBarScrubTolerance(); }; v2.__get__seekToPrevOffset = function () { return this._seekToPrevOffset; }; v2.__set__seekToPrevOffset = function (s) { this._seekToPrevOffset = s; return this.__get__seekToPrevOffset(); }; v2.__get__skin = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._skin = this._uiMgr.skin; } return this._skin; }; v2.__set__skin = function (s) { this._skin = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.__set__skin(s); } return this.__get__skin(); }; v2.__get__skinAutoHide = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._skinAutoHide = this._uiMgr.skinAutoHide; } return this._skinAutoHide; }; v2.__set__skinAutoHide = function (b) { if (_global.isLivePreview) { return undefined; } this._skinAutoHide = b; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.__set__skinAutoHide(b); } return this.__get__skinAutoHide(); }; v2.__get__transform = function () { return this._transform; }; v2.__set__transform = function (s) { this._transform = s; if (this._vp[this._activeVP] != undefined) { this._vp[this._activeVP].transform = this._transform; } return this.__get__transform(); }; v2.__get__state = function () { if (_global.isLivePreview) { return mx.video.FLVPlayback.STOPPED; } if (this._vp[this._activeVP] == undefined) { return mx.video.FLVPlayback.DISCONNECTED; } if (this._activeVP == this._visibleVP && this.__get__scrubbing()) { return mx.video.FLVPlayback.SEEKING; } var v3 = this._vp[this._activeVP].state; if (v3 == mx.video.VideoPlayer.RESIZING) { return mx.video.FLVPlayback.LOADING; } if (this._vpState[this._activeVP].prevState == mx.video.FLVPlayback.LOADING && this._vpState[this._activeVP].autoPlay && v3 == mx.video.FLVPlayback.STOPPED) { return mx.video.FLVPlayback.LOADING; } return v3; }; v2.__get__stateResponsive = function () { if (this._vp[this._activeVP] == undefined) { return false; } return this._vp[this._activeVP].stateResponsive; }; v2.__get__stopButton = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._stopButton = this._uiMgr.getControl(mx.video.UIManager.STOP_BUTTON); } return this._stopButton; }; v2.__set__stopButton = function (s) { this._stopButton = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.STOP_BUTTON, s); } return this.__get__stopButton(); }; v2.__get__stopped = function () { if (this._vp[this._activeVP] == undefined) { return false; } return this._vp[this._activeVP].state == mx.video.FLVPlayback.STOPPED; }; v2.__get__totalTime = function () { if (_global.isLivePreview) { return 1; } if (this._vp[this._activeVP] == undefined) { return this._totalTime; } else { if (this._vpState[this._activeVP].totalTimeSet) { return this._vpState[this._activeVP].totalTime; } else { return this._vp[this._activeVP].totalTime; } } }; v2.__set__totalTime = function (aTime) { if (this._activeVP == 0 || this._activeVP == undefined) { this._totalTime = aTime; } this._vpState[this._activeVP].totalTime = aTime; this._vpState[this._activeVP].totalTimeSet = true; return this.__get__totalTime(); }; v2.__get__visible = function () { return this._visible; }; v2.__set__visible = function (v) { this._visible = v; return this.__get__visible(); }; v2.__get__visibleVideoPlayerIndex = function () { return this._visibleVP; }; v2.__set__visibleVideoPlayerIndex = function (i) { if (this._visibleVP == i) { return undefined; } var v2 = this._visibleVP; if (this._vp[i] == undefined) { this.createVideoPlayer(i); } var v5 = this._vp[i].height != this._vp[this._visibleVP].height || this._vp[i].width != this._vp[this._visibleVP].width; this._vp[this._visibleVP].visible = false; this._vp[this._visibleVP].volume = 0; this._visibleVP = i; if (this._firstStreamShown) { this._uiMgr.setupSkinAutoHide(v2); this._vp[this._visibleVP].visible = true; if (!this.__get__scrubbing()) { this._vp[this._visibleVP].volume = this._volume; } } else { if (this._vp[this._visibleVP].stateResponsive && this._vp[this._visibleVP].state != mx.video.FLVPlayback.DISCONNECTED && this._uiMgr.__get__skinReady()) { this._uiMgr.__set__visible(true); this._uiMgr.setupSkinAutoHide(v2); this._firstStreamReady = true; this.showFirstStream(); } } if (this._vp[v2].height != this._vp[this._visibleVP].height || this._vp[v2].width != this._vp[this._visibleVP].width) { this.dispatchEvent({'type': 'resize', 'x': this.__get__x(), 'y': this.__get__y(), 'width': this.__get__width(), 'height': this.__get__height(), 'auto': false, 'vp': this._visibleVP}); } this._uiMgr.handleEvent({'type': 'stateChange', 'state': this._vp[this._visibleVP].state, 'vp': this._visibleVP}); this._uiMgr.handleEvent({'type': 'playheadUpdate', 'playheadTime': this._vp[this._visibleVP].playheadTime, 'vp': this._visibleVP}); if (this._vp[this._visibleVP].isRTMP) { this._uiMgr.handleEvent({'type': 'ready', 'vp': this._visibleVP}); } else { this._uiMgr.handleEvent({'type': 'progress', 'bytesLoaded': this._vp[this._visibleVP].bytesLoaded, 'bytesTotal': this._vp[this._visibleVP].bytesTotal, 'vp': this._visibleVP}); } return this.__get__visibleVideoPlayerIndex(); }; v2.__get__volume = function () { return this._volume; }; v2.__set__volume = function (aVol) { if (this._volume == aVol) { return undefined; } this._volume = aVol; if (!this.__get__scrubbing()) { this._vp[this._visibleVP].volume = this._volume; } this.dispatchEvent({'type': 'volumeUpdate', 'volume': aVol}); return this.__get__volume(); }; v2.__get__volumeBar = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._volumeBar = this._uiMgr.getControl(mx.video.UIManager.VOLUME_BAR); } return this._volumeBar; }; v2.__set__volumeBar = function (s) { this._volumeBar = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.setControl(mx.video.UIManager.VOLUME_BAR, s); } return this.__get__volumeBar(); }; v2.__get__volumeBarInterval = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._volumeBarInterval = this._uiMgr.volumeBarInterval; } return this._volumeBarInterval; }; v2.__set__volumeBarInterval = function (s) { this._volumeBarInterval = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.__set__volumeBarInterval(this._volumeBarInterval); } return this.__get__volumeBarInterval(); }; v2.__get__volumeBarScrubTolerance = function () { if (this._uiMgr != null && this._uiMgr != undefined) { this._volumeBarScrubTolerance = this._uiMgr.volumeBarScrubTolerance; } return this._volumeBarScrubTolerance; }; v2.__set__volumeBarScrubTolerance = function (s) { this._volumeBarScrubTolerance = s; if (this._uiMgr != null && this._uiMgr != undefined) { this._uiMgr.__set__volumeBarScrubTolerance(this._volumeBarScrubTolerance); } return this.__get__volumeBarScrubTolerance(); }; v2.__get__width = function () { if (_global.isLivePreview) { return this.__width; } if (this._vp[this._visibleVP] != undefined) { this.__width = this._vp[this._visibleVP].width; } return this.__width; }; v2.__set__width = function (w) { this.setSize(w, this.__get__height()); return this.__get__width(); }; v2.__get__x = function () { return this._x; }; v2.__set__x = function (xpos) { this._x = xpos; return this.__get__x(); }; v2.__get__y = function () { return this._y; }; v2.__set__y = function (ypos) { this._y = ypos; return this.__get__y(); }; v2.createVideoPlayer = function (index) { if (_global.isLivePreview) { return undefined; } var v4 = this.__get__width(); var v5 = this.__get__height(); this._vp[index] = mx.video.VideoPlayer(this.attachMovie('VideoPlayer', String(index), mx.video.FLVPlayback.VP_DEPTH_OFFSET + index)); this._vp[index].setSize(v4, v5); this._topVP = index; this._vp[index].autoRewind = this._autoRewind; this._vp[index].autoSize = this._autoSize; this._vp[index].bufferTime = this._bufferTime; this._vp[index].idleTimeout = this._idleTimeout; this._vp[index].maintainAspectRatio = this._aspectRatio; this._vp[index].playheadUpdateInterval = this._playheadUpdateInterval; this._vp[index].progressInterval = this._progressInterval; this._vp[index].transform = this._transform; this._vp[index].volume = this._volume; if (index == 0) { this._vpState[index] = {'id': index, 'isLive': this._isLive, 'isLiveSet': true, 'totalTime': this._totalTime, 'totalTimeSet': true, 'autoPlay': this._autoPlay}; if (this._contentPath != null && this._contentPath != undefined && this._contentPath != '') { this._vp[index].onEnterFrame = mx.utils.Delegate.create(this, this.doContentPathConnect); } } else { this._vpState[index] = {'id': index, 'isLive': false, 'isLiveSet': true, 'totalTime': 0, 'totalTimeSet': true, 'autoPlay': false}; } this._vp[index].addEventListener('resize', this); this._vp[index].addEventListener('close', this); this._vp[index].addEventListener('complete', this); this._vp[index].addEventListener('cuePoint', this); this._vp[index].addEventListener('playheadUpdate', this); this._vp[index].addEventListener('progress', this); this._vp[index].addEventListener('metadataReceived', this); this._vp[index].addEventListener('stateChange', this); this._vp[index].addEventListener('ready', this); this._vp[index].addEventListener('rewind', this); this._cpMgr[index] = new mx.video.CuePointManager(this, index); this._cpMgr[index].playheadUpdateInterval = this._playheadUpdateInterval; }; v2.createUIManager = function () { this._uiMgr = new mx.video.UIManager(this); this._uiMgr.__set__visible(false); if (this._backButton != undefined && this._backButton != null) { this._uiMgr.setControl(mx.video.UIManager.BACK_BUTTON, this._backButton); } if (this._bufferingBar != undefined && this._bufferingBar != null) { this._uiMgr.setControl(mx.video.UIManager.BUFFERING_BAR, this._bufferingBar); } this._uiMgr.__set__bufferingBarHidesAndDisablesOthers(this._bufferingBarHides); if (this._forwardButton != undefined && this._forwardButton != null) { this._uiMgr.setControl(mx.video.UIManager.FORWARD_BUTTON, this._forwardButton); } if (this._pauseButton != undefined && this._pauseButton != null) { this._uiMgr.setControl(mx.video.UIManager.PAUSE_BUTTON, this._pauseButton); } if (this._playButton != undefined && this._playButton != null) { this._uiMgr.setControl(mx.video.UIManager.PLAY_BUTTON, this._playButton); } if (this._playPauseButton != undefined && this._playPauseButton != null) { this._uiMgr.setControl(mx.video.UIManager.PLAY_PAUSE_BUTTON, this._playPauseButton); } if (this._stopButton != undefined && this._stopButton != null) { this._uiMgr.setControl(mx.video.UIManager.STOP_BUTTON, this._stopButton); } if (this._seekBar != undefined && this._seekBar != null) { this._uiMgr.setControl(mx.video.UIManager.SEEK_BAR, this._seekBar); } if (this._seekBarInterval != undefined && this._seekBarInterval != null) { this._uiMgr.__set__seekBarInterval(this._seekBarInterval); } if (this._seekBarScrubTolerance != undefined && this._seekBarScrubTolerance != null) { this._uiMgr.__set__seekBarScrubTolerance(this._seekBarScrubTolerance); } if (this._skin != undefined && this._skin != null) { this._uiMgr.__set__skin(this._skin); } if (this._skinAutoHide != undefined && this._skinAutoHide != null) { this._uiMgr.__set__skinAutoHide(this._skinAutoHide); } if (this._muteButton != undefined && this._muteButton != null) { this._uiMgr.setControl(mx.video.UIManager.MUTE_BUTTON, this._muteButton); } if (this._volumeBar != undefined && this._volumeBar != null) { this._uiMgr.setControl(mx.video.UIManager.VOLUME_BAR, this._volumeBar); } if (this._volumeBarInterval != undefined && this._volumeBarInterval != null) { this._uiMgr.__set__volumeBarInterval(this._volumeBarInterval); } if (this._volumeBarScrubTolerance != undefined && this._volumeBarScrubTolerance != null) { this._uiMgr.__set__volumeBarScrubTolerance(this._volumeBarScrubTolerance); } }; v2.createLivePreviewMovieClip = function () { this.preview_mc = this.createEmptyMovieClip('preview_mc', 10); this.preview_mc.createEmptyMovieClip('box_mc', 10); this.preview_mc.box_mc.beginFill(0); this.preview_mc.box_mc.moveTo(0, 0); this.preview_mc.box_mc.lineTo(0, 100); this.preview_mc.box_mc.lineTo(100, 100); this.preview_mc.box_mc.lineTo(100, 0); this.preview_mc.box_mc.lineTo(0, 0); this.preview_mc.box_mc.endFill(); this.preview_mc.attachMovie('Icon', 'icon_mc', 20); }; v2.doContentPathConnect = function () { delete this._vp[0].onEnterFrame; this._vp[0].onEnterFrame = undefined; if (_global.isLivePreview) { return undefined; } if (this._vpState[0].autoPlay && this._firstStreamShown) { this._vp[0].play(this._contentPath, this._isLive, this._totalTime); } else { this._vp[0].load(this._contentPath, this._isLive, this._totalTime); } this._vpState[0].isLiveSet = false; this._vpState[0].totalTimeSet = false; }; v2.showFirstStream = function () { this._firstStreamShown = true; this._vp[this._visibleVP].visible = true; if (!this.__get__scrubbing()) { this._vp[this._visibleVP].volume = this._volume; } var v2 = 0; while (v2 < this._vp.length) { if (this._vp[v2] != undefined && this._vp[v2].state == mx.video.FLVPlayback.STOPPED && this._vpState[v2].autoPlay) { this._vp[v2].play(); } ++v2; } }; v2._scrubStart = function () { var v2 = this.__get__playheadTime(); this._vp[this._visibleVP].volume = 0; this.dispatchEvent({'type': 'stateChange', 'state': mx.video.FLVPlayback.SEEKING, 'playheadTime': v2, 'vp': this._visibleVP}); this.dispatchEvent({'type': 'scrubStart', 'state': mx.video.FLVPlayback.SEEKING, 'playheadTime': v2}); }; v2._scrubFinish = function () { var v3 = this.__get__playheadTime(); var v2 = this.__get__state(); this._vp[this._visibleVP].volume = this._volume; if (v2 != mx.video.FLVPlayback.SEEKING) { this.dispatchEvent({'type': 'stateChange', 'state': v2, 'playheadTime': v3, 'vp': this._visibleVP}); } this.dispatchEvent({'type': 'scrubFinish', 'state': v2, 'playheadTime': v3}); }; v2.skinError = function (message) { if (this._firstStreamReady && !this._firstStreamShown) { this.showFirstStream(); } this.dispatchEvent({'type': 'skinError', 'message': message}); }; v2.skinLoaded = function () { if (this._firstStreamReady) { this._uiMgr.__set__visible(true); if (!this._firstStreamShown) { this.showFirstStream(); } } else { if (this._contentPath == undefined || this._contentPath == null || this._contentPath == '') { this._uiMgr.__set__visible(true); } } this.dispatchEvent({'type': 'skinLoaded'}); }; v1.version = '1.0.0.103'; v1.DISCONNECTED = 'disconnected'; v1.STOPPED = 'stopped'; v1.PLAYING = 'playing'; v1.PAUSED = 'paused'; v1.BUFFERING = 'buffering'; v1.LOADING = 'loading'; v1.CONNECTION_ERROR = 'connectionError'; v1.REWINDING = 'rewinding'; v1.SEEKING = 'seeking'; v1.ALL = 'all'; v1.EVENT = 'event'; v1.NAVIGATION = 'navigation'; v1.FLV = 'flv'; v1.ACTIONSCRIPT = 'actionscript'; v1.VP_DEPTH_OFFSET = 100; v1.SEEK_TO_PREV_OFFSET_DEFAULT = 1; v2.addProperty('activeVideoPlayerIndex', v2.__get__activeVideoPlayerIndex, v2.__set__activeVideoPlayerIndex); v2.addProperty('autoPlay', v2.__get__autoPlay, v2.__set__autoPlay); v2.addProperty('autoRewind', v2.__get__autoRewind, v2.__set__autoRewind); v2.addProperty('autoSize', v2.__get__autoSize, v2.__set__autoSize); v2.addProperty('backButton', v2.__get__backButton, v2.__set__backButton); v2.addProperty('bitrate', v2.__get__bitrate, v2.__set__bitrate); v2.addProperty('bufferTime', v2.__get__bufferTime, v2.__set__bufferTime); v2.addProperty('buffering', v2.__get__buffering, function () {}); v2.addProperty('bufferingBar', v2.__get__bufferingBar, v2.__set__bufferingBar); v2.addProperty('bufferingBarHidesAndDisablesOthers', v2.__get__bufferingBarHidesAndDisablesOthers, v2.__set__bufferingBarHidesAndDisablesOthers); v2.addProperty('bytesLoaded', v2.__get__bytesLoaded, function () {}); v2.addProperty('bytesTotal', v2.__get__bytesTotal, function () {}); v2.addProperty('contentPath', v2.__get__contentPath, v2.__set__contentPath); v2.addProperty('cuePoints', function () {}, v2.__set__cuePoints); v2.addProperty('forwardButton', v2.__get__forwardButton, v2.__set__forwardButton); v2.addProperty('height', v2.__get__height, v2.__set__height); v2.addProperty('idleTimeout', v2.__get__idleTimeout, v2.__set__idleTimeout); v2.addProperty('isLive', v2.__get__isLive, v2.__set__isLive); v2.addProperty('isRTMP', v2.__get__isRTMP, function () {}); v2.addProperty('maintainAspectRatio', v2.__get__maintainAspectRatio, v2.__set__maintainAspectRatio); v2.addProperty('metadata', v2.__get__metadata, function () {}); v2.addProperty('metadataLoaded', v2.__get__metadataLoaded, function () {}); v2.addProperty('muteButton', v2.__get__muteButton, v2.__set__muteButton); v2.addProperty('ncMgr', v2.__get__ncMgr, function () {}); v2.addProperty('pauseButton', v2.__get__pauseButton, v2.__set__pauseButton); v2.addProperty('paused', v2.__get__paused, function () {}); v2.addProperty('playButton', v2.__get__playButton, v2.__set__playButton); v2.addProperty('playPauseButton', v2.__get__playPauseButton, v2.__set__playPauseButton); v2.addProperty('playheadPercentage', v2.__get__playheadPercentage, v2.__set__playheadPercentage); v2.addProperty('playheadTime', v2.__get__playheadTime, v2.__set__playheadTime); v2.addProperty('playheadUpdateInterval', v2.__get__playheadUpdateInterval, v2.__set__playheadUpdateInterval); v2.addProperty('playing', v2.__get__playing, function () {}); v2.addProperty('preferredHeight', v2.__get__preferredHeight, function () {}); v2.addProperty('preferredWidth', v2.__get__preferredWidth, function () {}); v2.addProperty('progressInterval', v2.__get__progressInterval, v2.__set__progressInterval); v2.addProperty('scaleX', v2.__get__scaleX, v2.__set__scaleX); v2.addProperty('scaleY', v2.__get__scaleY, v2.__set__scaleY); v2.addProperty('scrubbing', v2.__get__scrubbing, function () {}); v2.addProperty('seekBar', v2.__get__seekBar, v2.__set__seekBar); v2.addProperty('seekBarInterval', v2.__get__seekBarInterval, v2.__set__seekBarInterval); v2.addProperty('seekBarScrubTolerance', v2.__get__seekBarScrubTolerance, v2.__set__seekBarScrubTolerance); v2.addProperty('seekToPrevOffset', v2.__get__seekToPrevOffset, v2.__set__seekToPrevOffset); v2.addProperty('skin', v2.__get__skin, v2.__set__skin); v2.addProperty('skinAutoHide', v2.__get__skinAutoHide, v2.__set__skinAutoHide); v2.addProperty('state', v2.__get__state, function () {}); v2.addProperty('stateResponsive', v2.__get__stateResponsive, function () {}); v2.addProperty('stopButton', v2.__get__stopButton, v2.__set__stopButton); v2.addProperty('stopped', v2.__get__stopped, function () {}); v2.addProperty('totalTime', v2.__get__totalTime, v2.__set__totalTime); v2.addProperty('transform', v2.__get__transform, v2.__set__transform); v2.addProperty('visible', v2.__get__visible, v2.__set__visible); v2.addProperty('visibleVideoPlayerIndex', v2.__get__visibleVideoPlayerIndex, v2.__set__visibleVideoPlayerIndex); v2.addProperty('volume', v2.__get__volume, v2.__set__volume); v2.addProperty('volumeBar', v2.__get__volumeBar, v2.__set__volumeBar); v2.addProperty('volumeBarInterval', v2.__get__volumeBarInterval, v2.__set__volumeBarInterval); v2.addProperty('volumeBarScrubTolerance', v2.__get__volumeBarScrubTolerance, v2.__set__volumeBarScrubTolerance); v2.addProperty('width', v2.__get__width, v2.__set__width); v2.addProperty('x', v2.__get__x, v2.__set__x); v2.addProperty('y', v2.__get__y, v2.__set__y); ASSetPropFlags(mx.video.FLVPlayback.prototype, null, 1); } #endinitclip } movieClip 71 __Packages.mx.video.VideoPlayer { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.VideoPlayer) { var v1 = function () { super(); mx.events.EventDispatcher.initialize(this); this._state = mx.video.VideoPlayer.DISCONNECTED; this._cachedState = this._state; this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; this._cachedPlayheadTime = 0; this._metadata = null; this._startingPlay = false; this._invalidSeekTime = false; this._invalidSeekRecovery = false; this._currentPos = 0; this._atEnd = false; this._cmdQueue = new Array(); this._readyDispatched = false; this._autoResizeDone = false; this._lastUpdateTime = -1; this._sawSeekNotify = false; this._updateTimeIntervalID = 0; this._updateTimeInterval = mx.video.VideoPlayer.DEFAULT_UPDATE_TIME_INTERVAL; this._updateProgressIntervalID = 0; this._updateProgressInterval = mx.video.VideoPlayer.DEFAULT_UPDATE_PROGRESS_INTERVAL; this._idleTimeoutIntervalID = 0; this._idleTimeoutInterval = mx.video.VideoPlayer.DEFAULT_IDLE_TIMEOUT_INTERVAL; this._autoResizeIntervalID = 0; this._rtmpDoStopAtEndIntervalID = 0; this._rtmpDoSeekIntervalID = 0; this._httpDoSeekIntervalID = 0; this._httpDoSeekCount = 0; this._finishAutoResizeIntervalID = 0; this._delayedBufferingIntervalID = 0; this._delayedBufferingInterval = mx.video.VideoPlayer.HTTP_DELAYED_BUFFERING_INTERVAL; if (this._isLive == undefined) { this._isLive = false; } if (this._autoSize == undefined) { this._autoSize = false; } if (this._aspectRatio == undefined) { this._aspectRatio = true; } if (this._autoPlay == undefined) { this._autoPlay = true; } if (this._autoRewind == undefined) { this._autoRewind = true; } if (this._bufferTime == undefined) { this._bufferTime = 0.1; } if (this._volume == undefined) { this._volume = 100; } this._sound = new Sound(this); this._sound.setVolume(this._volume); this.__visible = true; this._hiddenForResize = false; this._hiddenForResizeMetadataDelay = 0; this._contentPath = ''; }; mx.video.VideoPlayer = v1; mx.video.VideoPlayer extends MovieClip; var v2 = v1.prototype; v2.setSize = function (w, h) { if (w == this._video._width && h == this._video._height || this._autoSize) { return undefined; } this._video._width = w; this._video._height = h; if (this._aspectRatio) { this.startAutoResize(); } }; v2.setScale = function (xs, ys) { if (xs == this._video._xscale && ys == this._video._yscale || this._autoSize) { return undefined; } this._video._xscale = xs; this._video._yscale = ys; if (this._aspectRatio) { this.startAutoResize(); } }; v2.play = function (url, isLive, totalTime) { if (url != null && url != undefined) { if (this._state == mx.video.VideoPlayer.EXEC_QUEUED_CMD) { this._state = this._cachedState; } else { if (!this.__get__stateResponsive()) { this.queueCmd(mx.video.VideoPlayer.PLAY, url, isLive, totalTime); return undefined; } else { this.execQueuedCmds(); } } this._autoPlay = true; this._load(url, isLive, totalTime); return undefined; } if (!this.isXnOK()) { if (this._state == mx.video.VideoPlayer.CONNECTION_ERROR || this._ncMgr == null || this._ncMgr == undefined || this._ncMgr.getNetConnection() == null || this._ncMgr.getNetConnection() == undefined) { throw new mx.video.VideoError(mx.video.VideoError.NO_CONNECTION); } else { this.flushQueuedCmds(); this.queueCmd(mx.video.VideoPlayer.PLAY); this.setState(mx.video.VideoPlayer.LOADING); this._cachedState = mx.video.VideoPlayer.LOADING; this._ncMgr.reconnect(); return undefined; } } else { if (this._state == mx.video.VideoPlayer.EXEC_QUEUED_CMD) { this._state = this._cachedState; } else { if (!this.__get__stateResponsive()) { this.queueCmd(mx.video.VideoPlayer.PLAY); return undefined; } else { this.execQueuedCmds(); } } } if (this._ns == null || this._ns == undefined) { this._createStream(); this._video.attachVideo(this._ns); this.attachAudio(this._ns); } switch (this._state) { case mx.video.VideoPlayer.BUFFERING: if (this._ncMgr.isRTMP()) { this._play(0); if (this._atEnd) { this._atEnd = false; this._currentPos = 0; this.setState(mx.video.VideoPlayer.REWINDING); } else { if (this._currentPos > 0) { this._seek(this._currentPos); this._currentPos = 0; } } } case mx.video.VideoPlayer.PLAYING: return undefined; case mx.video.VideoPlayer.STOPPED: if (this._ncMgr.isRTMP()) { if (this._isLive) { this._play(-1); this.setState(mx.video.VideoPlayer.BUFFERING); } else { this._play(0); if (this._atEnd) { this._atEnd = false; this._currentPos = 0; this._state = mx.video.VideoPlayer.BUFFERING; this.setState(mx.video.VideoPlayer.REWINDING); } else { if (this._currentPos > 0) { this._seek(this._currentPos); this._currentPos = 0; this.setState(mx.video.VideoPlayer.BUFFERING); } else { this.setState(mx.video.VideoPlayer.BUFFERING); } } } } else { this._pause(false); if (this._atEnd) { this._atEnd = false; this._seek(0); this._state = mx.video.VideoPlayer.BUFFERING; this.setState(mx.video.VideoPlayer.REWINDING); } else { if (this._bufferState == mx.video.VideoPlayer.BUFFER_EMPTY) { this.setState(mx.video.VideoPlayer.BUFFERING); } else { this.setState(mx.video.VideoPlayer.PLAYING); } } } break; case mx.video.VideoPlayer.PAUSED: this._pause(false); if (!this._ncMgr.isRTMP()) { if (this._bufferState == mx.video.VideoPlayer.BUFFER_EMPTY) { this.setState(mx.video.VideoPlayer.BUFFERING); } else { this.setState(mx.video.VideoPlayer.PLAYING); } } else { this.setState(mx.video.VideoPlayer.BUFFERING); } } }; v2.load = function (url, isLive, totalTime) { if (url == null || url == undefined) { throw new Error('null url sent to VideoPlayer.load'); } if (this._state == mx.video.VideoPlayer.EXEC_QUEUED_CMD) { this._state = this._cachedState; } else { if (!this.__get__stateResponsive()) { this.queueCmd(mx.video.VideoPlayer.LOAD, url, isLive, totalTime); return undefined; } else { this.execQueuedCmds(); } } this._autoPlay = false; this._load(url, isLive, totalTime); }; v2._load = function (url, isLive, totalTime) { this._prevVideoWidth = this.videoWidth; if (this._prevVideoWidth == undefined) { this._prevVideoWidth = this._video.width; if (this._prevVideoWidth == undefined) { this._prevVideoWidth = 0; } } this._prevVideoHeight = this.videoHeight; if (this._prevVideoHeight == undefined) { this._prevVideoHeight = this._video.height; if (this._prevVideoHeight == undefined) { this._prevVideoHeight = 0; } } this._autoResizeDone = false; this._cachedPlayheadTime = 0; this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; this._metadata = null; this._startingPlay = false; this._invalidSeekTime = false; this._invalidSeekRecovery = false; this._isLive = (isLive == undefined) ? false : isLive; this._contentPath = url; this._currentPos = 0; this._streamLength = totalTime; this._atEnd = false; this._videoWidth = undefined; this._videoHeight = undefined; this._readyDispatched = false; this._lastUpdateTime = -1; this._sawSeekNotify = false; clearInterval(this._updateTimeIntervalID); this._updateTimeIntervalID = 0; clearInterval(this._updateProgressIntervalID); this._updateProgressIntervalID = 0; clearInterval(this._idleTimeoutIntervalID); this._idleTimeoutIntervalID = 0; clearInterval(this._autoResizeIntervalID); this._autoResizeIntervalID = 0; clearInterval(this._rtmpDoStopAtEndIntervalID); this._rtmpDoStopAtEndIntervalID = 0; clearInterval(this._rtmpDoSeekIntervalID); this._rtmpDoSeekIntervalID = 0; clearInterval(this._httpDoSeekIntervalID); this._httpDoSeekIntervalID = 0; clearInterval(this._finishAutoResizeIntervalID); this._finishAutoResizeIntervalID = 0; clearInterval(this._delayedBufferingIntervalID); this._delayedBufferingIntervalID = 0; this.closeNS(false); if (this._ncMgr == null || this._ncMgr == undefined) { this.createINCManager(); } var v2 = this._ncMgr.connectToURL(this._contentPath); this.setState(mx.video.VideoPlayer.LOADING); this._cachedState = mx.video.VideoPlayer.LOADING; if (v2) { this._createStream(); this._setUpStream(); } if (!this._ncMgr.isRTMP()) { clearInterval(this._updateProgressIntervalID); this._updateProgressIntervalID = setInterval(this, 'doUpdateProgress', this._updateProgressInterval); } }; v2.pause = function () { if (!this.isXnOK()) { if (this._state == mx.video.VideoPlayer.CONNECTION_ERROR || this._ncMgr == null || this._ncMgr == undefined || this._ncMgr.getNetConnection() == null || this._ncMgr.getNetConnection() == undefined) { throw new mx.video.VideoError(mx.video.VideoError.NO_CONNECTION); } else { return undefined; } } else { if (this._state == mx.video.VideoPlayer.EXEC_QUEUED_CMD) { this._state = this._cachedState; } else { if (!this.__get__stateResponsive()) { this.queueCmd(mx.video.VideoPlayer.PAUSE); return undefined; } else { this.execQueuedCmds(); } } } if (this._state == mx.video.VideoPlayer.PAUSED || this._state == mx.video.VideoPlayer.STOPPED || this._ns == null || this._ns == undefined) { return undefined; } this._pause(true); this.setState(mx.video.VideoPlayer.PAUSED); }; v2.stop = function () { if (!this.isXnOK()) { if (this._state == mx.video.VideoPlayer.CONNECTION_ERROR || this._ncMgr == null || this._ncMgr == undefined || this._ncMgr.getNetConnection() == null || this._ncMgr.getNetConnection() == undefined) { throw new mx.video.VideoError(mx.video.VideoError.NO_CONNECTION); } else { return undefined; } } else { if (this._state == mx.video.VideoPlayer.EXEC_QUEUED_CMD) { this._state = this._cachedState; } else { if (!this.__get__stateResponsive()) { this.queueCmd(mx.video.VideoPlayer.STOP); return undefined; } else { this.execQueuedCmds(); } } } if (this._state == mx.video.VideoPlayer.STOPPED || this._ns == null || this._ns == undefined) { return undefined; } if (this._ncMgr.isRTMP()) { if (this._autoRewind && !this._isLive) { this._currentPos = 0; this._play(0, 0); this._state = mx.video.VideoPlayer.STOPPED; this.setState(mx.video.VideoPlayer.REWINDING); } else { this.closeNS(true); this.setState(mx.video.VideoPlayer.STOPPED); } } else { this._pause(true); if (this._autoRewind) { this._seek(0); this._state = mx.video.VideoPlayer.STOPPED; this.setState(mx.video.VideoPlayer.REWINDING); } else { this.setState(mx.video.VideoPlayer.STOPPED); } } }; v2.seek = function (time) { if (this._invalidSeekTime) { return undefined; } if (isNaN(time) || time < 0) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_SEEK); } if (!this.isXnOK()) { if (this._state == mx.video.VideoPlayer.CONNECTION_ERROR || this._ncMgr == null || this._ncMgr == undefined || this._ncMgr.getNetConnection() == null || this._ncMgr.getNetConnection() == undefined) { throw new mx.video.VideoError(mx.video.VideoError.NO_CONNECTION); } else { this.flushQueuedCmds(); this.queueCmd(mx.video.VideoPlayer.SEEK, null, false, time); this.setState(mx.video.VideoPlayer.LOADING); this._cachedState = mx.video.VideoPlayer.LOADING; this._ncMgr.reconnect(); return undefined; } } else { if (this._state == mx.video.VideoPlayer.EXEC_QUEUED_CMD) { this._state = this._cachedState; } else { if (!this.__get__stateResponsive()) { this.queueCmd(mx.video.VideoPlayer.SEEK, null, false, time); return undefined; } else { this.execQueuedCmds(); } } } if (this._ns == null || this._ns == undefined) { this._createStream(); this._video.attachVideo(this._ns); this.attachAudio(this._ns); } if (this._atEnd && time < this.__get__playheadTime()) { this._atEnd = false; } switch (this._state) { case mx.video.VideoPlayer.PLAYING: this._state = mx.video.VideoPlayer.BUFFERING; case mx.video.VideoPlayer.BUFFERING: case mx.video.VideoPlayer.PAUSED: this._seek(time); this.setState(mx.video.VideoPlayer.SEEKING); break; case mx.video.VideoPlayer.STOPPED: if (this._ncMgr.isRTMP()) { this._play(0); this._pause(true); } this._seek(time); this._state = mx.video.VideoPlayer.PAUSED; this.setState(mx.video.VideoPlayer.SEEKING); } }; v2.close = function () { this.closeNS(true); if (this._ncMgr != null && this._ncMgr != undefined && this._ncMgr.isRTMP()) { this._ncMgr.close(); } this.setState(mx.video.VideoPlayer.DISCONNECTED); this.dispatchEvent({'type': 'close', 'state': this._state, 'playheadTime': this.__get__playheadTime()}); }; v2.__get__x = function () { return this._x; }; v2.__set__x = function (xpos) { this._x = xpos; return this.__get__x(); }; v2.__get__y = function () { return this._y; }; v2.__set__y = function (ypos) { this._y = ypos; return this.__get__y(); }; v2.__get__scaleX = function () { return this._video._xscale; }; v2.__set__scaleX = function (xs) { this.setScale(xs, this.__get__scaleY()); return this.__get__scaleX(); }; v2.__get__scaleY = function () { return this._video._yscale; }; v2.__set__scaleY = function (ys) { this.setScale(this.__get__scaleX(), ys); return this.__get__scaleY(); }; v2.__get__width = function () { return this._video._width; }; v2.__set__width = function (w) { this.setSize(w, this._video._height); return this.__get__width(); }; v2.__get__height = function () { return this._video._height; }; v2.__set__height = function (h) { this.setSize(this._video._width, h); return this.__get__height(); }; v2.__get__videoWidth = function () { if (this._readyDispatched) { this._videoWidth = this._video.width; } return this._videoWidth; }; v2.__get__videoHeight = function () { if (this._readyDispatched) { this._videoHeight = this._video.height; } return this._videoHeight; }; v2.__get__visible = function () { if (!this._hiddenForResize) { this.__visible = this._visible; } return this.__visible; }; v2.__set__visible = function (v) { this.__visible = v; if (!this._hiddenForResize) { this._visible = this.__visible; } return this.__get__visible(); }; v2.__get__autoSize = function () { return this._autoSize; }; v2.__set__autoSize = function (flag) { if (this._autoSize != flag) { this._autoSize = flag; if (this._autoSize) { this.startAutoResize(); } } return this.__get__autoSize(); }; v2.__get__maintainAspectRatio = function () { return this._aspectRatio; }; v2.__set__maintainAspectRatio = function (flag) { if (this._aspectRatio != flag) { this._aspectRatio = flag; if (this._aspectRatio && !this._autoSize) { this.startAutoResize(); } } return this.__get__maintainAspectRatio(); }; v2.__get__autoRewind = function () { return this._autoRewind; }; v2.__set__autoRewind = function (flag) { this._autoRewind = flag; return this.__get__autoRewind(); }; v2.__get__playheadTime = function () { var v2 = (this._ns == null || this._ns == undefined) ? this._currentPos : this._ns.time; if (this._metadata.audiodelay != undefined) { v2 -= this._metadata.audiodelay; if (v2 < 0) { v2 = 0; } } return v2; }; v2.__set__playheadTime = function (position) { this.seek(position); return this.__get__playheadTime(); }; v2.__get__url = function () { return this._contentPath; }; v2.__get__volume = function () { return this._volume; }; v2.__set__volume = function (aVol) { this._volume = aVol; if (!this._hiddenForResize) { this._sound.setVolume(this._volume); } return this.__get__volume(); }; v2.__get__transform = function () { return this._sound.getTransform(); }; v2.__set__transform = function (s) { this._sound.setTransform(s); return this.__get__transform(); }; v2.__get__isRTMP = function () { if (this._ncMgr == null || this._ncMgr == undefined) { return undefined; } return this._ncMgr.isRTMP(); }; v2.__get__isLive = function () { return this._isLive; }; v2.__get__state = function () { return this._state; }; v2.__get__stateResponsive = function () { switch (this._state) { return false; case mx.video.VideoPlayer.DISCONNECTED: case mx.video.VideoPlayer.STOPPED: case mx.video.VideoPlayer.PLAYING: case mx.video.VideoPlayer.PAUSED: case mx.video.VideoPlayer.BUFFERING: return true; } return false; }; v2.__get__bytesLoaded = function () { if (this._ns == null || this._ns == undefined || this._ncMgr.isRTMP()) { return -1; } return this._ns.bytesLoaded; }; v2.__get__bytesTotal = function () { if (this._ns == null || this._ns == undefined || this._ncMgr.isRTMP()) { return -1; } return this._ns.bytesTotal; }; v2.__get__totalTime = function () { return this._streamLength; }; v2.__get__bufferTime = function () { return this._bufferTime; }; v2.__set__bufferTime = function (aTime) { this._bufferTime = aTime; if (this._ns != null && this._ns != undefined) { this._ns.setBufferTime(this._bufferTime); } return this.__get__bufferTime(); }; v2.__get__idleTimeout = function () { return this._idleTimeoutInterval; }; v2.__set__idleTimeout = function (aTime) { this._idleTimeoutInterval = aTime; if (this._idleTimeoutIntervalID > 0) { clearInterval(this._idleTimeoutIntervalID); this._idleTimeoutIntervalID = setInterval(this, 'doIdleTimeout', this._idleTimeoutInterval); } return this.__get__idleTimeout(); }; v2.__get__playheadUpdateInterval = function () { return this._updateTimeInterval; }; v2.__set__playheadUpdateInterval = function (aTime) { this._updateTimeInterval = aTime; if (this._updateTimeIntervalID > 0) { clearInterval(this._updateTimeIntervalID); this._updateTimeIntervalID = setInterval(this, 'doUpdateTime', this._updateTimeInterval); } return this.__get__playheadUpdateInterval(); }; v2.__get__progressInterval = function () { return this._updateProgressInterval; }; v2.__set__progressInterval = function (aTime) { this._updateProgressInterval = aTime; if (this._updateProgressIntervalID > 0) { clearInterval(this._updateProgressIntervalID); this._updateProgressIntervalID = setInterval(this, 'doUpdateProgress', this._updateProgressInterval); } return this.__get__progressInterval(); }; v2.__get__ncMgr = function () { if (this._ncMgr == null || this._ncMgr == undefined) { this.createINCManager(); } return this._ncMgr; }; v2.__get__metadata = function () { return this._metadata; }; v2.doUpdateTime = function () { var v2 = this.__get__playheadTime(); switch (this._state) { if (this._state !== mx.video.VideoPlayer.CONNECTION_ERROR) { } else { case mx.video.VideoPlayer.STOPPED: case mx.video.VideoPlayer.PAUSED: case mx.video.VideoPlayer.DISCONNECTED: clearInterval(this._updateTimeIntervalID); this._updateTimeIntervalID = 0; } } if (this._lastUpdateTime != v2) { this.dispatchEvent({'type': 'playheadUpdate', 'state': this._state, 'playheadTime': v2}); this._lastUpdateTime = v2; } }; v2.doUpdateProgress = function () { if (this._ns == null || this._ns == undefined) { return undefined; } if (this._ns.bytesTotal >= 0) { this.dispatchEvent({'type': 'progress', 'bytesLoaded': this._ns.bytesLoaded, 'bytesTotal': this._ns.bytesTotal}); } if (this._state == mx.video.VideoPlayer.DISCONNECTED || this._state == mx.video.VideoPlayer.CONNECTION_ERROR || this._ns.bytesLoaded == this._ns.bytesTotal) { clearInterval(this._updateProgressIntervalID); this._updateProgressIntervalID = 0; } }; v2.rtmpOnStatus = function (info) { if (this._state == mx.video.VideoPlayer.CONNECTION_ERROR) { return undefined; } switch (info.code) { case 'NetStream.Play.Stop': if (this._startingPlay) { return undefined; } switch (this._state) { case mx.video.VideoPlayer.RESIZING: if (this._hiddenForResize) { this.finishAutoResize(); } break; case mx.video.VideoPlayer.LOADING: case mx.video.VideoPlayer.STOPPED: break; case mx.video.VideoPlayer.PAUSED: default: if (this._bufferState == mx.video.VideoPlayer.BUFFER_EMPTY || this._bufferTime <= 0.1) { this._cachedPlayheadTime = this.playheadTime; clearInterval(this._rtmpDoStopAtEndIntervalID); this._rtmpDoStopAtEndIntervalID = setInterval(this, 'rtmpDoStopAtEnd', mx.video.VideoPlayer.RTMP_DO_STOP_AT_END_INTERVAL); } else { if (this._bufferState == mx.video.VideoPlayer.BUFFER_FULL) { this._bufferState = mx.video.VideoPlayer.BUFFER_FULL_SAW_PLAY_STOP; } else {} } } break; case 'NetStream.Buffer.Empty': switch (this._bufferState) { case mx.video.VideoPlayer.BUFFER_FULL_SAW_PLAY_STOP: this.rtmpDoStopAtEnd(true); break; case mx.video.VideoPlayer.BUFFER_FULL: if (this._state == mx.video.VideoPlayer.PLAYING) { this.setState(mx.video.VideoPlayer.BUFFERING); } break; default: } this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; break; case 'NetStream.Buffer.Flush': case 'NetStream.Buffer.Full': if (this._sawSeekNotify && this._state == mx.video.VideoPlayer.SEEKING) { this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; this.setStateFromCachedState(); this.doUpdateTime(); } switch (this._bufferState) { case mx.video.VideoPlayer.BUFFER_EMPTY: if (!this._hiddenForResize) { if (this._state == mx.video.VideoPlayer.LOADING && this._cachedState == mx.video.VideoPlayer.PLAYING || this._state == mx.video.VideoPlayer.BUFFERING) { this.setState(mx.video.VideoPlayer.PLAYING); } else { if (this._cachedState == mx.video.VideoPlayer.BUFFERING) { this._cachedState = mx.video.VideoPlayer.PLAYING; } } } this._bufferState = mx.video.VideoPlayer.BUFFER_FULL; break; default: } break; case 'NetStream.Pause.Notify': if (this._state == mx.video.VideoPlayer.RESIZING && this._hiddenForResize) { this.finishAutoResize(); } break; case 'NetStream.Play.Start': clearInterval(this._rtmpDoStopAtEndIntervalID); this._rtmpDoStopAtEndIntervalID = 0; this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; if (this._startingPlay) { this._startingPlay = false; this._cachedPlayheadTime = this.playheadTime; } else { if (this._state == mx.video.VideoPlayer.PLAYING) { this.setState(mx.video.VideoPlayer.BUFFERING); } } break; case 'NetStream.Play.Reset': clearInterval(this._rtmpDoStopAtEndIntervalID); this._rtmpDoStopAtEndIntervalID = 0; if (this._state == mx.video.VideoPlayer.REWINDING) { clearInterval(this._rtmpDoSeekIntervalID); this._rtmpDoSeekIntervalID = 0; if (this.__get__playheadTime() == 0 || this.__get__playheadTime() < this._cachedPlayheadTime) { this.setStateFromCachedState(); } else { this._cachedPlayheadTime = this.playheadTime; this._rtmpDoSeekIntervalID = setInterval(this, 'rtmpDoSeek', mx.video.VideoPlayer.RTMP_DO_SEEK_INTERVAL); } } break; case 'NetStream.Seek.Notify': if (this.__get__playheadTime() != this._cachedPlayheadTime) { this.setStateFromCachedState(); this.doUpdateTime(); } else { this._sawSeekNotify = true; if (this._rtmpDoSeekIntervalID == 0) { this._rtmpDoSeekIntervalID = setInterval(this, 'rtmpDoSeek', mx.video.VideoPlayer.RTMP_DO_SEEK_INTERVAL); } } break; break; case 'Netstream.Play.UnpublishNotify': break; case 'Netstream.Play.PublishNotify': case 'NetStream.Play.StreamNotFound': if (!this._ncMgr.connectAgain()) { this.setState(mx.video.VideoPlayer.CONNECTION_ERROR); } break; case 'NetStream.Play.Failed': case 'NetStream.Failed': this.setState(mx.video.VideoPlayer.CONNECTION_ERROR); } }; v2.httpOnStatus = function (info) { switch (info.code) { case 'NetStream.Play.Stop': clearInterval(this._delayedBufferingIntervalID); this._delayedBufferingIntervalID = 0; if (this._invalidSeekTime) { this._invalidSeekTime = false; this._invalidSeekRecovery = true; this.setState(this._cachedState); this.seek(this.__get__playheadTime()); } else { switch (this._state) { if (this._state !== mx.video.VideoPlayer.SEEKING) { } else { case mx.video.VideoPlayer.PLAYING: case mx.video.VideoPlayer.BUFFERING: this.httpDoStopAtEnd(); } } } break; case 'NetStream.Seek.InvalidTime': if (this._invalidSeekRecovery) { this._invalidSeekTime = false; this._invalidSeekRecovery = false; this.setState(this._cachedState); this.seek(0); } else { this._invalidSeekTime = true; } break; case 'NetStream.Buffer.Empty': this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; if (this._state == mx.video.VideoPlayer.PLAYING) { clearInterval(this._delayedBufferingIntervalID); this._delayedBufferingIntervalID = setInterval(this, 'doDelayedBuffering', this._delayedBufferingInterval); } break; case 'NetStream.Buffer.Full': case 'NetStream.Buffer.Flush': clearInterval(this._delayedBufferingIntervalID); this._delayedBufferingIntervalID = 0; this._bufferState = mx.video.VideoPlayer.BUFFER_FULL; if (!this._hiddenForResize) { if (this._state == mx.video.VideoPlayer.LOADING && this._cachedState == mx.video.VideoPlayer.PLAYING || this._state == mx.video.VideoPlayer.BUFFERING) { this.setState(mx.video.VideoPlayer.PLAYING); } else { if (this._cachedState == mx.video.VideoPlayer.BUFFERING) { this._cachedState = mx.video.VideoPlayer.PLAYING; } } } break; case 'NetStream.Seek.Notify': this._invalidSeekRecovery = false; switch (this._state) { if (this._state !== mx.video.VideoPlayer.REWINDING) { } else { case mx.video.VideoPlayer.SEEKING: if (this._httpDoSeekIntervalID == 0) { this._httpDoSeekCount = 0; this._httpDoSeekIntervalID = setInterval(this, 'httpDoSeek', mx.video.VideoPlayer.HTTP_DO_SEEK_INTERVAL); } } } break; case 'NetStream.Play.StreamNotFound': this.setState(mx.video.VideoPlayer.CONNECTION_ERROR); } }; v2.ncConnected = function () { if (this._ncMgr == null || this._ncMgr == undefined || this._ncMgr.getNetConnection() == null || this._ncMgr.getNetConnection() == undefined) { this.setState(mx.video.VideoPlayer.CONNECTION_ERROR); } else { this._createStream(); this._setUpStream(); } }; v2.ncReconnected = function () { if (this._ncMgr == null || this._ncMgr == undefined || this._ncMgr.getNetConnection() == null || this._ncMgr.getNetConnection() == undefined) { this.setState(mx.video.VideoPlayer.CONNECTION_ERROR); } else { this._ns = null; this._state = mx.video.VideoPlayer.STOPPED; this.execQueuedCmds(); } }; v2.onMetaData = function (info) { if (this._metadata != null) { return undefined; } this._metadata = info; if (this._streamLength == undefined || this._streamLength == null || this._streamLength <= 0) { this._streamLength = info.duration; } if (isNaN(this._videoWidth) || this._videoWidth <= 0) { this._videoWidth = info.width; } if (isNaN(this._videoHeight) || this._videoHeight <= 0) { this._videoHeight = info.height; } this.dispatchEvent({'type': 'metadataReceived', 'info': info}); }; v2.onCuePoint = function (info) { if (!this._hiddenForResize || !isNaN(this._hiddenRewindPlayheadTime) && this.__get__playheadTime() < this._hiddenRewindPlayheadTime) { this.dispatchEvent({'type': 'cuePoint', 'info': info}); } }; v2.setState = function (s) { if (s == this._state) { return undefined; } this._hiddenRewindPlayheadTime = undefined; this._cachedState = this._state; this._cachedPlayheadTime = this.playheadTime; this._state = s; var v2 = this._state; this.dispatchEvent({'type': 'stateChange', 'state': v2, 'playheadTime': this.__get__playheadTime()}); if (!this._readyDispatched) { switch (v2) { if (v2 !== mx.video.VideoPlayer.BUFFERING) { } else { case mx.video.VideoPlayer.STOPPED: case mx.video.VideoPlayer.PLAYING: case mx.video.VideoPlayer.PAUSED: this._readyDispatched = true; this.dispatchEvent({'type': 'ready', 'state': v2, 'playheadTime': this.__get__playheadTime()}); } } } if (this._cachedState !== mx.video.VideoPlayer.REWINDING) { } else { this.dispatchEvent({'type': 'rewind', 'state': v2, 'playheadTime': this.__get__playheadTime()}); if (this._ncMgr.isRTMP() && v2 == mx.video.VideoPlayer.STOPPED) { this.closeNS(); } } switch (v2) { case mx.video.VideoPlayer.STOPPED: case mx.video.VideoPlayer.PAUSED: if (this._ncMgr.isRTMP() && this._idleTimeoutIntervalID == 0) { this._idleTimeoutIntervalID = setInterval(this, 'doIdleTimeout', this._idleTimeoutInterval); } break; case mx.video.VideoPlayer.SEEKING: case mx.video.VideoPlayer.REWINDING: this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; case mx.video.VideoPlayer.PLAYING: case mx.video.VideoPlayer.BUFFERING: if (this._updateTimeIntervalID == 0) { this._updateTimeIntervalID = setInterval(this, 'doUpdateTime', this._updateTimeInterval); } case mx.video.VideoPlayer.LOADING: case mx.video.VideoPlayer.RESIZING: clearInterval(this._idleTimeoutIntervalID); this._idleTimeoutIntervalID = 0; } this.execQueuedCmds(); }; v2.setStateFromCachedState = function () { switch (this._cachedState) { case mx.video.VideoPlayer.PLAYING: case mx.video.VideoPlayer.PAUSED: this.setState(this._cachedState); break; case mx.video.VideoPlayer.BUFFERING: if (this._bufferState == mx.video.VideoPlayer.BUFFER_EMPTY) { this.setState(mx.video.VideoPlayer.BUFFERING); } else { this.setState(this._cachedState); } break; default: this.setState(mx.video.VideoPlayer.STOPPED); } }; v2.createINCManager = function () { if (this.ncMgrClassName == null || this.ncMgrClassName == undefined) { this.ncMgrClassName = mx.video.VideoPlayer.DEFAULT_INCMANAGER; } var ncMgrConstructor = eval(this.ncMgrClassName); this._ncMgr = new ncMgrConstructor(); this._ncMgr.setVideoPlayer(this); }; v2.rtmpDoStopAtEnd = function (force) { if (this._rtmpDoStopAtEndIntervalID > 0) { switch (this._state) { if (this._state !== mx.video.VideoPlayer.CONNECTION_ERROR) { } else { case mx.video.VideoPlayer.DISCONNECTED: clearInterval(this._rtmpDoStopAtEndIntervalID); this._rtmpDoStopAtEndIntervalID = 0; return undefined; } } if (force || this._cachedPlayheadTime == this.__get__playheadTime()) { clearInterval(this._rtmpDoStopAtEndIntervalID); this._rtmpDoStopAtEndIntervalID = 0; } else { this._cachedPlayheadTime = this.playheadTime; return undefined; } } this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; this._atEnd = true; this.setState(mx.video.VideoPlayer.STOPPED); if (this._state != mx.video.VideoPlayer.STOPPED) { return undefined; } this.doUpdateTime(); if (this._state != mx.video.VideoPlayer.STOPPED) { return undefined; } this.dispatchEvent({'type': 'complete', 'state': this._state, 'playheadTime': this.__get__playheadTime()}); if (this._state != mx.video.VideoPlayer.STOPPED) { return undefined; } if (this._autoRewind && !this._isLive && this.__get__playheadTime() != 0) { this._atEnd = false; this._currentPos = 0; this._play(0, 0); this.setState(mx.video.VideoPlayer.REWINDING); } else { this.closeNS(); } }; v2.rtmpDoSeek = function () { if (this._state != mx.video.VideoPlayer.REWINDING && this._state != mx.video.VideoPlayer.SEEKING) { clearInterval(this._rtmpDoSeekIntervalID); this._rtmpDoSeekIntervalID = 0; this._sawSeekNotify = false; } else { if (this.__get__playheadTime() != this._cachedPlayheadTime) { clearInterval(this._rtmpDoSeekIntervalID); this._rtmpDoSeekIntervalID = 0; this._sawSeekNotify = false; this.setStateFromCachedState(); this.doUpdateTime(); } } }; v2.httpDoStopAtEnd = function () { this._atEnd = true; if (this._streamLength == undefined || this._streamLength == null || this._streamLength <= 0) { this._streamLength = this._ns.time; } this._pause(true); this.setState(mx.video.VideoPlayer.STOPPED); if (this._state != mx.video.VideoPlayer.STOPPED) { return undefined; } this.doUpdateTime(); if (this._state != mx.video.VideoPlayer.STOPPED) { return undefined; } this.dispatchEvent({'type': 'complete', 'state': this._state, 'playheadTime': this.__get__playheadTime()}); if (this._state != mx.video.VideoPlayer.STOPPED) { return undefined; } if (this._autoRewind) { this._atEnd = false; this._pause(true); this._seek(0); this.setState(mx.video.VideoPlayer.REWINDING); } }; v2.httpDoSeek = function () { var v2 = this._state == mx.video.VideoPlayer.REWINDING || this._state == mx.video.VideoPlayer.SEEKING; if (v2 && this._httpDoSeekCount < mx.video.VideoPlayer.HTTP_DO_SEEK_MAX_COUNT && (this._cachedPlayheadTime == this.__get__playheadTime() || this._invalidSeekTime)) { ++this._httpDoSeekCount; return undefined; } this._httpDoSeekCount = 0; clearInterval(this._httpDoSeekIntervalID); this._httpDoSeekIntervalID = 0; if (!v2) { return undefined; } this.setStateFromCachedState(); if (this._invalidSeekTime) { this._invalidSeekTime = false; this._invalidSeekRecovery = true; this.seek(this.__get__playheadTime()); } else { this.doUpdateTime(); } }; v2.closeNS = function (updateCurrentPos) { if (this._ns != null && this._ns != undefined) { if (updateCurrentPos) { clearInterval(this._updateTimeIntervalID); this._updateTimeIntervalID = 0; this.doUpdateTime(); this._currentPos = this._ns.time; } delete this._ns.onStatus; this._ns.onStatus = null; this._ns.close(); this._ns = null; } }; v2.doDelayedBuffering = function () { switch (this._state) { case mx.video.VideoPlayer.LOADING: break; case mx.video.VideoPlayer.RESIZING: case mx.video.VideoPlayer.PLAYING: clearInterval(this._delayedBufferingIntervalID); this._delayedBufferingIntervalID = 0; this.setState(mx.video.VideoPlayer.BUFFERING); break; default: clearInterval(this._delayedBufferingIntervalID); this._delayedBufferingIntervalID = 0; } }; v2._pause = function (doPause) { this._ns.pause(doPause); }; v2._play = function () { this._startingPlay = true; switch (arguments.length) { case 0: this._ns.play(this._ncMgr.getStreamName(), this._isLive ? -1 : 0, -1); break; case 1: this._ns.play(this._ncMgr.getStreamName(), this._isLive ? -1 : arguments[0], -1); break; case 2: this._ns.play(this._ncMgr.getStreamName(), this._isLive ? -1 : arguments[0], arguments[1]); break; default: throw new Error('bad args to _play'); } }; v2._seek = function (time) { if (this._metadata.audiodelay != undefined && time + this._metadata.audiodelay < this._streamLength) { time += this._metadata.audiodelay; } this._ns.seek(time); this._invalidSeekTime = false; this._bufferState = mx.video.VideoPlayer.BUFFER_EMPTY; this._sawSeekNotify = false; }; v2.isXnOK = function () { if (this._state == mx.video.VideoPlayer.LOADING) { return true; } if (this._state == mx.video.VideoPlayer.CONNECTION_ERROR) { return false; } if (this._state != mx.video.VideoPlayer.DISCONNECTED) { if (this._ncMgr == null || this._ncMgr == undefined || this._ncMgr.getNetConnection() == null || this._ncMgr.getNetConnection() == undefined || !(this._ncMgr.getNetConnection()).isConnected) { this.setState(mx.video.VideoPlayer.DISCONNECTED); return false; } return true; } return false; }; v2.startAutoResize = function () { switch (this._state) { if (this._state !== mx.video.VideoPlayer.CONNECTION_ERROR) { } else { case mx.video.VideoPlayer.DISCONNECTED: return undefined; } } this._autoResizeDone = false; if (this.__get__stateResponsive() && this._videoWidth != undefined && this._videoHeight != undefined) { this.doAutoResize(); } else { clearInterval(this._autoResizeIntervalID); this._autoResizeIntervalID = setInterval(this, 'doAutoResize', mx.video.VideoPlayer.AUTO_RESIZE_INTERVAL); } }; v2.doAutoResize = function () { if (this._autoResizeIntervalID > 0) { switch (this._state) { case mx.video.VideoPlayer.RESIZING: break; case mx.video.VideoPlayer.LOADING: case mx.video.VideoPlayer.DISCONNECTED: case mx.video.VideoPlayer.CONNECTION_ERROR: clearInterval(this._autoResizeIntervalID); this._autoResizeIntervalID = 0; return undefined; default: if (this.__get__stateResponsive()) break; return undefined; } if (this._video.width != this._prevVideoWidth || this._video.height != this._prevVideoHeight || this._bufferState >= mx.video.VideoPlayer.BUFFER_FULL || this._ns.time > mx.video.VideoPlayer.AUTO_RESIZE_PLAYHEAD_TIMEOUT) { if (this._hiddenForResize && this._metadata == null && this._hiddenForResizeMetadataDelay < mx.video.VideoPlayer.AUTO_RESIZE_METADATA_DELAY_MAX) { ++this._hiddenForResizeMetadataDelay; return undefined; } this._videoWidth = this._video.width; this._videoHeight = this._video.height; clearInterval(this._autoResizeIntervalID); this._autoResizeIntervalID = 0; } else { return undefined; } } if (!this._autoSize && !this._aspectRatio || this._autoResizeDone) { this.setState(this._cachedState); return undefined; } this._autoResizeDone = true; if (this._autoSize) { this._video._width = this._videoWidth; this._video._height = this._videoHeight; } else { if (this._aspectRatio) { var v3 = this._videoWidth * this.__get__height() / this._videoHeight; var v2 = this._videoHeight * this.__get__width() / this._videoWidth; if (v2 < this.__get__height()) { this._video._height = v2; } else { if (v3 < this.__get__width()) { this._video._width = v3; } } } } if (this._hiddenForResize) { this._hiddenRewindPlayheadTime = this.playheadTime; if (this._state == mx.video.VideoPlayer.LOADING) { this._cachedState = mx.video.VideoPlayer.PLAYING; } if (!this._ncMgr.isRTMP()) { this._pause(true); this._seek(0); clearInterval(this._finishAutoResizeIntervalID); this._finishAutoResizeIntervalID = setInterval(this, 'finishAutoResize', mx.video.VideoPlayer.FINISH_AUTO_RESIZE_INTERVAL); } else { if (!this._isLive) { this._currentPos = 0; this._play(0, 0); this.setState(mx.video.VideoPlayer.RESIZING); } else { if (this._autoPlay) { clearInterval(this._finishAutoResizeIntervalID); this._finishAutoResizeIntervalID = setInterval(this, 'finishAutoResize', mx.video.VideoPlayer.FINISH_AUTO_RESIZE_INTERVAL); } else { this.finishAutoResize(); } } } } else { this.dispatchEvent({'type': 'resize', 'x': this._x, 'y': this._y, 'width': this._width, 'height': this._height}); } }; v2.finishAutoResize = function () { clearInterval(this._finishAutoResizeIntervalID); this._finishAutoResizeIntervalID = 0; if (this.__get__stateResponsive()) { return undefined; } this._visible = this.__visible; this._sound.setVolume(this._volume); this._hiddenForResize = false; this.dispatchEvent({'type': 'resize', 'x': this._x, 'y': this._y, 'width': this._width, 'height': this._height}); if (this._autoPlay) { if (this._ncMgr.isRTMP()) { if (!this._isLive) { this._currentPos = 0; this._play(0); } if (this._state == mx.video.VideoPlayer.RESIZING) { this.setState(mx.video.VideoPlayer.LOADING); this._cachedState = mx.video.VideoPlayer.PLAYING; } } else { this._pause(false); this._cachedState = mx.video.VideoPlayer.PLAYING; } } else { this.setState(mx.video.VideoPlayer.STOPPED); } }; v2._createStream = function () { this._ns = new NetStream(this._ncMgr.getNetConnection()); this._ns.mc = this; if (this._ncMgr.isRTMP()) { this._ns.onStatus = function (info) { this.mc.rtmpOnStatus(info); }; } else { this._ns.onStatus = function (info) { this.mc.httpOnStatus(info); }; } this._ns.onMetaData = function (info) { this.mc.onMetaData(info); }; this._ns.onCuePoint = function (info) { this.mc.onCuePoint(info); }; this._ns.setBufferTime(this._bufferTime); }; v2._setUpStream = function () { this._video.attachVideo(this._ns); this.attachAudio(this._ns); if (!isNaN(this._ncMgr.getStreamLength()) && this._ncMgr.getStreamLength() >= 0) { this._streamLength = this._ncMgr.getStreamLength(); } if (!isNaN(this._ncMgr.getStreamWidth()) && this._ncMgr.getStreamWidth() >= 0) { this._videoWidth = this._ncMgr.getStreamWidth(); } else { this._videoWidth = undefined; } if (!isNaN(this._ncMgr.getStreamHeight()) && this._ncMgr.getStreamHeight() >= 0) { this._videoHeight = this._ncMgr.getStreamHeight(); } else { this._videoHeight = undefined; } if ((this._autoSize || this._aspectRatio) && this._videoWidth != undefined && this._videoHeight != undefined) { this._prevVideoWidth = undefined; this._prevVideoHeight = undefined; this.doAutoResize(); } if (!this._autoSize && !this._aspectRatio || this._videoWidth != undefined && this._videoHeight != undefined) { if (this._autoPlay) { if (!this._ncMgr.isRTMP()) { this._cachedState = mx.video.VideoPlayer.BUFFERING; this._play(); } else { if (this._isLive) { this._cachedState = mx.video.VideoPlayer.BUFFERING; this._play(-1); } else { this._cachedState = mx.video.VideoPlayer.BUFFERING; this._play(0); } } } else { this._cachedState = mx.video.VideoPlayer.STOPPED; if (this._ncMgr.isRTMP()) { this._play(0, 0); } else { this._play(); this._pause(true); this._seek(0); } } } else { this._hiddenForResize = true; this._hiddenForResizeMetadataDelay = 0; this.__visible = this._visible; this._visible = false; this._volume = this._sound.getVolume(); this._sound.setVolume(0); this._play(0); if (this._currentPos > 0) { this._seek(this._currentPos); this._currentPos = 0; } } clearInterval(this._autoResizeIntervalID); this._autoResizeIntervalID = setInterval(this, 'doAutoResize', mx.video.VideoPlayer.AUTO_RESIZE_INTERVAL); }; v2.doIdleTimeout = function () { clearInterval(this._idleTimeoutIntervalID); this._idleTimeoutIntervalID = 0; this.close(); }; v2.flushQueuedCmds = function () { while (this._cmdQueue.length > 0) { this._cmdQueue.pop(); } }; v2.execQueuedCmds = function () { for (;;) { if (!(this._cmdQueue.length > 0 && (this.__get__stateResponsive() || this._state == mx.video.VideoPlayer.CONNECTION_ERROR) && (this._cmdQueue[0].url != null && this._cmdQueue[0].url != undefined || this._state != mx.video.VideoPlayer.DISCONNECTED && this._state != mx.video.VideoPlayer.CONNECTION_ERROR))) break; var v2 = this._cmdQueue.shift(); this._cachedState = this._state; this._state = mx.video.VideoPlayer.EXEC_QUEUED_CMD; switch (v2.type) { case mx.video.VideoPlayer.PLAY: this.play(v2.url, v2.isLive, v2.time); break; case mx.video.VideoPlayer.LOAD: this.load(v2.url, v2.isLive, v2.time); break; case mx.video.VideoPlayer.PAUSE: this.pause(); break; case mx.video.VideoPlayer.STOP: this.stop(); break; case mx.video.VideoPlayer.SEEK: this.seek(v2.time); continue; } } }; v2.queueCmd = function (type, url, isLive, time) { this._cmdQueue.push({'type': type, 'url': url, 'isLive': false, 'time': time}); }; v1.version = '1.0.0.103'; v1.DISCONNECTED = 'disconnected'; v1.STOPPED = 'stopped'; v1.PLAYING = 'playing'; v1.PAUSED = 'paused'; v1.BUFFERING = 'buffering'; v1.LOADING = 'loading'; v1.CONNECTION_ERROR = 'connectionError'; v1.REWINDING = 'rewinding'; v1.SEEKING = 'seeking'; v1.RESIZING = 'resizing'; v1.EXEC_QUEUED_CMD = 'execQueuedCmd'; v1.BUFFER_EMPTY = 'bufferEmpty'; v1.BUFFER_FULL = 'bufferFull'; v1.BUFFER_FULL_SAW_PLAY_STOP = 'bufferFullSawPlayStop'; v1.DEFAULT_INCMANAGER = 'mx.video.NCManager'; v1.DEFAULT_UPDATE_TIME_INTERVAL = 250; v1.DEFAULT_UPDATE_PROGRESS_INTERVAL = 250; v1.DEFAULT_IDLE_TIMEOUT_INTERVAL = 300000; v1.AUTO_RESIZE_INTERVAL = 100; v1.AUTO_RESIZE_PLAYHEAD_TIMEOUT = 0.5; v1.AUTO_RESIZE_METADATA_DELAY_MAX = 5; v1.FINISH_AUTO_RESIZE_INTERVAL = 250; v1.RTMP_DO_STOP_AT_END_INTERVAL = 500; v1.RTMP_DO_SEEK_INTERVAL = 100; v1.HTTP_DO_SEEK_INTERVAL = 250; v1.HTTP_DO_SEEK_MAX_COUNT = 4; v1.CLOSE_NS_INTERVAL = 0.25; v1.HTTP_DELAYED_BUFFERING_INTERVAL = 100; v1.PLAY = 0; v1.LOAD = 1; v1.PAUSE = 2; v1.STOP = 3; v1.SEEK = 4; v2.addProperty('autoRewind', v2.__get__autoRewind, v2.__set__autoRewind); v2.addProperty('autoSize', v2.__get__autoSize, v2.__set__autoSize); v2.addProperty('bufferTime', v2.__get__bufferTime, v2.__set__bufferTime); v2.addProperty('bytesLoaded', v2.__get__bytesLoaded, function () {}); v2.addProperty('bytesTotal', v2.__get__bytesTotal, function () {}); v2.addProperty('height', v2.__get__height, v2.__set__height); v2.addProperty('idleTimeout', v2.__get__idleTimeout, v2.__set__idleTimeout); v2.addProperty('isLive', v2.__get__isLive, function () {}); v2.addProperty('isRTMP', v2.__get__isRTMP, function () {}); v2.addProperty('maintainAspectRatio', v2.__get__maintainAspectRatio, v2.__set__maintainAspectRatio); v2.addProperty('metadata', v2.__get__metadata, function () {}); v2.addProperty('ncMgr', v2.__get__ncMgr, function () {}); v2.addProperty('playheadTime', v2.__get__playheadTime, v2.__set__playheadTime); v2.addProperty('playheadUpdateInterval', v2.__get__playheadUpdateInterval, v2.__set__playheadUpdateInterval); v2.addProperty('progressInterval', v2.__get__progressInterval, v2.__set__progressInterval); v2.addProperty('scaleX', v2.__get__scaleX, v2.__set__scaleX); v2.addProperty('scaleY', v2.__get__scaleY, v2.__set__scaleY); v2.addProperty('state', v2.__get__state, function () {}); v2.addProperty('stateResponsive', v2.__get__stateResponsive, function () {}); v2.addProperty('totalTime', v2.__get__totalTime, function () {}); v2.addProperty('transform', v2.__get__transform, v2.__set__transform); v2.addProperty('url', v2.__get__url, function () {}); v2.addProperty('videoHeight', v2.__get__videoHeight, function () {}); v2.addProperty('videoWidth', v2.__get__videoWidth, function () {}); v2.addProperty('visible', v2.__get__visible, v2.__set__visible); v2.addProperty('volume', v2.__get__volume, v2.__set__volume); v2.addProperty('width', v2.__get__width, v2.__set__width); v2.addProperty('x', v2.__get__x, v2.__set__x); v2.addProperty('y', v2.__get__y, v2.__set__y); ASSetPropFlags(mx.video.VideoPlayer.prototype, null, 1); } #endinitclip } movieClip 72 __Packages.mx.video.INCManager { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.INCManager) { _global.mx.video.INCManager = function () {}; } #endinitclip } movieClip 73 __Packages.mx.events.EventDispatcher { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.events) { _global.mx.events = new Object(); } if (!_global.mx.events.EventDispatcher) { var v1 = function () {}; mx.events.EventDispatcher = v1; var v2 = v1.prototype; v1._removeEventListener = function (queue, event, handler) { if (queue != undefined) { var v4 = queue.length; var v1; v1 = 0; while (v1 < v4) { var v2 = queue[v1]; if (v2 == handler) { queue.splice(v1, 1); return undefined; } ++v1; } } }; v1.initialize = function (object) { if (mx.events.EventDispatcher._fEventDispatcher == undefined) { mx.events.EventDispatcher._fEventDispatcher = new mx.events.EventDispatcher(); } object.addEventListener = mx.events.EventDispatcher._fEventDispatcher.addEventListener; object.removeEventListener = mx.events.EventDispatcher._fEventDispatcher.removeEventListener; object.dispatchEvent = mx.events.EventDispatcher._fEventDispatcher.dispatchEvent; object.dispatchQueue = mx.events.EventDispatcher._fEventDispatcher.dispatchQueue; }; v2.dispatchQueue = function (queueObj, eventObj) { var v7 = '__q_' + eventObj.type; var v4 = queueObj[v7]; if (v4 != undefined) { var v5; for (v5 in v4) { var v1 = v4[v5]; var v3 = typeof v1; if (v3 == 'object' || v3 == 'movieclip') { if (v1.handleEvent != undefined) { v1.handleEvent(eventObj); } if (v1[eventObj.type] != undefined) { if (mx.events.EventDispatcher.exceptions[eventObj.type] == undefined) { v1[eventObj.type](eventObj); } } } else { v1.apply(queueObj, [eventObj]); } } } }; v2.dispatchEvent = function (eventObj) { if (eventObj.target == undefined) { eventObj.target = this; } this[eventObj.type + 'Handler'](eventObj); this.dispatchQueue(this, eventObj); }; v2.addEventListener = function (event, handler) { var v3 = '__q_' + event; if (this[v3] == undefined) { this[v3] = new Array(); } _global.ASSetPropFlags(this, v3, 1); mx.events.EventDispatcher._removeEventListener(this[v3], event, handler); this[v3].push(handler); }; v2.removeEventListener = function (event, handler) { var v2 = '__q_' + event; mx.events.EventDispatcher._removeEventListener(this[v2], event, handler); }; v1._fEventDispatcher = undefined; v1.exceptions = {'move': 1, 'draw': 1, 'load': 1}; ASSetPropFlags(mx.events.EventDispatcher.prototype, null, 1); } #endinitclip } movieClip 74 __Packages.mx.video.VideoError { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.VideoError) { var v1 = function (errCode, msg) { super(); this._code = errCode; this.message = '' + errCode + ': ' + mx.video.VideoError.ERROR_MSG[errCode - mx.video.VideoError.BASE_ERROR_CODE] + ((msg == undefined) ? '' : ': ' + msg); this.name = 'VideoError'; }; mx.video.VideoError = v1; mx.video.VideoError extends Error; var v2 = v1.prototype; v2.__get__code = function () { return this._code; }; v1.version = '1.0.0.103'; v1.BASE_ERROR_CODE = 1000; v1.NO_CONNECTION = 1000; v1.NO_CUE_POINT_MATCH = 1001; v1.ILLEGAL_CUE_POINT = 1002; v1.INVALID_SEEK = 1003; v1.INVALID_CONTENT_PATH = 1004; v1.INVALID_XML = 1005; v1.NO_BITRATE_MATCH = 1006; v1.DELETE_DEFAULT_PLAYER = 1007; v1.ERROR_MSG = ['Unable to make connection to server or to find FLV on server', 'No matching cue point found', 'Illegal cue point', 'Invalid seek', 'Invalid contentPath', 'Invalid xml', 'No bitrate match, must be no default flv', 'Cannot delete default VideoPlayer']; v2.addProperty('code', v2.__get__code, function () {}); ASSetPropFlags(mx.video.VideoError.prototype, null, 1); } #endinitclip } movieClip 75 __Packages.mx.video.UIManager { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.UIManager) { var v1 = function (vc) { this._vc = vc; this._skin = undefined; this._skinAutoHide = false; this._skinReady = true; this.__visible = true; this._bufferingBarHides = false; this._controlsEnabled = true; this._lastScrubPos = 0; this._lastVolumePos = 0; this.cachedSoundLevel = this._vc.volume; this._isMuted = false; this.controls = new Array(); this.customClips = undefined; this.skin_mc = undefined; this.skinLoader = undefined; this.layout_mc = undefined; this.border_mc = undefined; this._seekBarIntervalID = 0; this._seekBarInterval = mx.video.UIManager.SEEK_BAR_INTERVAL_DEFAULT; this._seekBarScrubTolerance = mx.video.UIManager.SEEK_BAR_SCRUB_TOLERANCE_DEFAULT; this._volumeBarIntervalID = 0; this._volumeBarInterval = mx.video.UIManager.VOLUME_BAR_INTERVAL_DEFAULT; this._volumeBarScrubTolerance = mx.video.UIManager.VOLUME_BAR_SCRUB_TOLERANCE_DEFAULT; this._bufferingDelayIntervalID = 0; this._bufferingDelayInterval = mx.video.UIManager.BUFFERING_DELAY_INTERVAL_DEFAULT; this._bufferingOn = false; this._skinAutoHideIntervalID = 0; this._vc.addEventListener('metadataReceived', this); this._vc.addEventListener('playheadUpdate', this); this._vc.addEventListener('progress', this); this._vc.addEventListener('stateChange', this); this._vc.addEventListener('ready', this); this._vc.addEventListener('resize', this); this._vc.addEventListener('volumeUpdate', this); }; mx.video.UIManager = v1; var v2 = v1.prototype; v2.handleEvent = function (e) { if (e.vp != undefined && e.vp != this._vc.__get__visibleVideoPlayerIndex()) { return undefined; } var v9 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); if (e.type == 'stateChange') { if (e.state == mx.video.FLVPlayback.BUFFERING) { if (!this._bufferingOn) { clearInterval(this._bufferingDelayIntervalID); this._bufferingDelayIntervalID = setInterval(this, 'doBufferingDelay', this._bufferingDelayInterval); } } else { clearInterval(this._bufferingDelayIntervalID); this._bufferingDelayIntervalID = 0; this._bufferingOn = false; } if (e.state == mx.video.FLVPlayback.LOADING) { this._progressPercent = (this._vc.getVideoPlayer(e.vp)).__get__isRTMP() ? 100 : 0; var v2 = mx.video.UIManager.SEEK_BAR; while (v2 <= mx.video.UIManager.VOLUME_BAR) { var v4 = this.controls[v2]; if (v4.progress_mc != undefined) { this.positionBar(v4, 'progress', this._progressPercent); } ++v2; } } v2 = 0; while (v2 < mx.video.UIManager.NUM_CONTROLS) { if (this.controls[v2] == undefined) { } else { this.setEnabledAndVisibleForState(v2, e.state); if (v2 < mx.video.UIManager.NUM_BUTTONS) { this.skinButtonControl(this.controls[v2]); } } ++v2; } } else { if (e.type == 'ready' || e.type == 'metadataReceived') { var v2 = 0; while (v2 < mx.video.UIManager.NUM_CONTROLS) { if (this.controls[v2] == undefined) { } else { this.setEnabledAndVisibleForState(v2, this._vc.__get__state()); if (v2 < mx.video.UIManager.NUM_BUTTONS) { this.skinButtonControl(this.controls[v2]); } } ++v2; } if ((this._vc.getVideoPlayer(e.vp)).__get__isRTMP()) { this._progressPercent = 100; v2 = mx.video.UIManager.SEEK_BAR; while (v2 <= mx.video.UIManager.VOLUME_BAR) { var v4 = this.controls[v2]; if (v4.progress_mc != undefined) { this.positionBar(v4, 'progress', this._progressPercent); } ++v2; } } } else { if (e.type == 'resize') { this.layoutSkin(); this.setupSkinAutoHide(); } else { if (e.type == 'volumeUpdate') { if (this._isMuted && e.volume > 0) { this._isMuted = false; this.setEnabledAndVisibleForState(mx.video.UIManager.MUTE_OFF_BUTTON, mx.video.FLVPlayback.PLAYING); this.skinButtonControl(this.controls[mx.video.UIManager.MUTE_OFF_BUTTON]); this.setEnabledAndVisibleForState(mx.video.UIManager.MUTE_ON_BUTTON, mx.video.FLVPlayback.PLAYING); this.skinButtonControl(this.controls[mx.video.UIManager.MUTE_ON_BUTTON]); } var v5 = this.controls[mx.video.UIManager.VOLUME_BAR]; v5.percentage = this._isMuted ? this.cachedSoundLevel : e.volume; if (v5.percentage < 0) { v5.percentage = 0; } else { if (v5.percentage > 100) { v5.percentage = 100; } } this.positionHandle(mx.video.UIManager.VOLUME_BAR); } else { if (e.type == 'playheadUpdate' && this.controls[mx.video.UIManager.SEEK_BAR] != undefined) { if (!this._vc.__get__isLive() && this._vc.__get__totalTime() > 0) { var v6 = (e.playheadTime / this._vc.__get__totalTime()) * 100; if (v6 < 0) { v6 = 0; } else { if (v6 > 100) { v6 = 100; } } var v10 = this.controls[mx.video.UIManager.SEEK_BAR]; v10.percentage = v6; this.positionHandle(mx.video.UIManager.SEEK_BAR); } } else { if (e.type == 'progress') { this._progressPercent = e.bytesTotal <= 0 ? 100 : (e.bytesLoaded / e.bytesTotal) * 100; var v7 = this._vc._vpState[e.vp].minProgressPercent; if (!isNaN(v7) && v7 > this._progressPercent) { this._progressPercent = v7; } if (this._vc.__get__totalTime() > 0) { var v8 = (this._vc.__get__playheadTime() / this._vc.__get__totalTime()) * 100; if (v8 > this._progressPercent) { this._progressPercent = v8; this._vc._vpState[e.vp].minProgressPercent = this._progressPercent; } } var v2 = mx.video.UIManager.SEEK_BAR; while (v2 <= mx.video.UIManager.VOLUME_BAR) { var v4 = this.controls[v2]; if (v4.progress_mc != undefined) { this.positionBar(v4, 'progress', this._progressPercent); } ++v2; } } } } } } } this._vc.__set__activeVideoPlayerIndex(v9); }; v2.__get__bufferingBarHidesAndDisablesOthers = function () { return this._bufferingBarHides; }; v2.__set__bufferingBarHidesAndDisablesOthers = function (b) { this._bufferingBarHides = b; return this.__get__bufferingBarHidesAndDisablesOthers(); }; v2.__get__controlsEnabled = function () { return this._controlsEnabled; }; v2.__set__controlsEnabled = function (flag) { if (this._controlsEnabled == flag) { return undefined; } this._controlsEnabled = flag; var v2 = 0; while (v2 < mx.video.UIManager.NUM_BUTTONS) { if (this.controls[v2] == undefined) { } else { this.controls[v2].releaseCapture(); this.controls[v2].enabled = this._controlsEnabled && this.controls[v2].myEnabled; this.skinButtonControl(this.controls[v2]); } ++v2; } return this.__get__controlsEnabled(); }; v2.__get__skin = function () { return this._skin; }; v2.__set__skin = function (s) { if (s == this._skin) { return undefined; } if (this._skin != undefined) { this.removeSkin(); } this._skin = s; this._skinReady = this._skin == undefined || this._skin == null || this._skin == ''; if (!this._skinReady) { this.downloadSkin(); } return this.__get__skin(); }; v2.__get__skinAutoHide = function () { return this._skinAutoHide; }; v2.__set__skinAutoHide = function (b) { if (b == this._skinAutoHide) { return undefined; } this._skinAutoHide = b; this.setupSkinAutoHide(); return this.__get__skinAutoHide(); }; v2.__get__skinReady = function () { return this._skinReady; }; v2.__get__seekBarInterval = function () { return this._seekBarInterval; }; v2.__set__seekBarInterval = function (s) { if (this._seekBarInterval == s) { return undefined; } this._seekBarInterval = s; if (this._seekBarIntervalID > 0) { clearInterval(this._seekBarIntervalID); this._seekBarIntervalID = setInterval(this, 'seekBarListener', this._seekBarInterval, false); } return this.__get__seekBarInterval(); }; v2.__get__volumeBarInterval = function () { return this._volumeBarInterval; }; v2.__set__volumeBarInterval = function (s) { if (this._volumeBarInterval == s) { return undefined; } this._volumeBarInterval = s; if (this._volumeBarIntervalID > 0) { clearInterval(this._volumeBarIntervalID); this._volumeBarIntervalID = setInterval(this, 'volumeBarListener', this._volumeBarInterval, false); } return this.__get__volumeBarInterval(); }; v2.__get__bufferingDelayInterval = function () { return this._bufferingDelayInterval; }; v2.__set__bufferingDelayInterval = function (s) { if (this._bufferingDelayInterval == s) { return undefined; } this._bufferingDelayInterval = s; if (this._bufferingDelayIntervalID > 0) { clearInterval(this._bufferingDelayIntervalID); this._bufferingDelayIntervalID = setInterval(this, 'doBufferingDelay', this._bufferingDelayIntervalID); } return this.__get__bufferingDelayInterval(); }; v2.__get__volumeBarScrubTolerance = function () { return this._volumeBarScrubTolerance; }; v2.__set__volumeBarScrubTolerance = function (s) { this._volumeBarScrubTolerance = s; return this.__get__volumeBarScrubTolerance(); }; v2.__get__seekBarScrubTolerance = function () { return this._seekBarScrubTolerance; }; v2.__set__seekBarScrubTolerance = function (s) { this._seekBarScrubTolerance = s; return this.__get__seekBarScrubTolerance(); }; v2.__get__visible = function () { return this.__visible; }; v2.__set__visible = function (v) { if (this.__visible == v) { return undefined; } this.__visible = v; if (!this.__visible) { this.skin_mc._visible = false; } else { this.setupSkinAutoHide(); } return this.__get__visible(); }; v2.getControl = function (index) { return this.controls[index]; }; v2.setControl = function (index, s) { if (s == null) { s = undefined; } if (s == this.controls[index]) { return undefined; } switch (index) { case mx.video.UIManager.PAUSE_BUTTON: case mx.video.UIManager.PLAY_BUTTON: this.resetPlayPause(); break; case mx.video.UIManager.PLAY_PAUSE_BUTTON: if (s._parent != this.layout_mc) { this.resetPlayPause(); this.setControl(mx.video.UIManager.PAUSE_BUTTON, s.pause_mc); this.setControl(mx.video.UIManager.PLAY_BUTTON, s.play_mc); } break; case mx.video.UIManager.MUTE_BUTTON: if (s._parent != this.layout_mc) { this.setControl(mx.video.UIManager.MUTE_ON_BUTTON, s.on_mc); this.setControl(mx.video.UIManager.MUTE_OFF_BUTTON, s.off_mc); } } if (index >= mx.video.UIManager.NUM_BUTTONS) { this.controls[index] = s; switch (index) { case mx.video.UIManager.SEEK_BAR: this.addBarControl(mx.video.UIManager.SEEK_BAR); break; case mx.video.UIManager.VOLUME_BAR: this.addBarControl(mx.video.UIManager.VOLUME_BAR); this.controls[mx.video.UIManager.VOLUME_BAR].percentage = this._vc.volume; break; case mx.video.UIManager.BUFFERING_BAR: this.controls[mx.video.UIManager.BUFFERING_BAR].uiMgr = this; this.controls[mx.video.UIManager.BUFFERING_BAR].controlIndex = mx.video.UIManager.BUFFERING_BAR; if (this.controls[mx.video.UIManager.BUFFERING_BAR]._parent == this.skin_mc) { this.finishAddBufferingBar(); } else { this.controls[mx.video.UIManager.BUFFERING_BAR].onEnterFrame = function () { this.uiMgr.finishAddBufferingBar(); }; } } this.setEnabledAndVisibleForState(index, this._vc.__get__state()); } else { this.removeButtonControl(index); this.controls[index] = s; this.addButtonControl(index); } }; v2.resetPlayPause = function () { if (this.controls[mx.video.UIManager.PLAY_PAUSE_BUTTON] == undefined) { return undefined; } var v2 = mx.video.UIManager.PAUSE_BUTTON; while (v2 <= mx.video.UIManager.PLAY_BUTTON) { this.removeButtonControl(v2); ++v2; } this.controls[mx.video.UIManager.PLAY_PAUSE_BUTTON] = undefined; }; v2.addButtonControl = function (index) { var v3 = this.controls[index]; if (v3 == undefined) { return undefined; } var v5 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); v3.id = index; v3.state = mx.video.UIManager.UP_STATE; v3.uiMgr = this; this.setEnabledAndVisibleForState(index, this._vc.__get__state()); v3.onRollOver = function () { this.state = mx.video.UIManager.OVER_STATE; this.uiMgr.skinButtonControl(this); }; v3.onRollOut = function () { this.state = mx.video.UIManager.UP_STATE; this.uiMgr.skinButtonControl(this); }; if (index == mx.video.UIManager.SEEK_BAR_HANDLE || index == mx.video.UIManager.VOLUME_BAR_HANDLE) { v3.onPress = function () { if (_root.focusManager) { this._focusrect = false; Selection.setFocus(this); } this.state = mx.video.UIManager.DOWN_STATE; this.uiMgr.dispatchMessage(this); this.uiMgr.skinButtonControl(this); }; v3.onRelease = function () { this.state = mx.video.UIManager.OVER_STATE; this.uiMgr.handleRelease(this.controlIndex); this.uiMgr.skinButtonControl(this); }; v3.onReleaseOutside = function () { this.state = mx.video.UIManager.UP_STATE; this.uiMgr.handleRelease(this.controlIndex); this.uiMgr.skinButtonControl(this); }; } else { v3.onPress = function () { if (_root.focusManager) { this._focusrect = false; Selection.setFocus(this); } this.state = mx.video.UIManager.DOWN_STATE; this.uiMgr.skinButtonControl(this); }; v3.onRelease = function () { this.state = mx.video.UIManager.OVER_STATE; this.uiMgr.dispatchMessage(this); this.uiMgr.skinButtonControl(this); }; v3.onReleaseOutside = function () { this.state = mx.video.UIManager.UP_STATE; this.uiMgr.skinButtonControl(this); }; } if (v3._parent == this.skin_mc) { this.skinButtonControl(v3); } else { v3.onEnterFrame = function () { this.uiMgr.skinButtonControl(this); }; } this._vc.__set__activeVideoPlayerIndex(v5); }; v2.removeButtonControl = function (index) { if (this.controls[index] == undefined) { return undefined; } this.controls[index].uiMgr = undefined; this.controls[index].onRollOver = undefined; this.controls[index].onRollOut = undefined; this.controls[index].onPress = undefined; this.controls[index].onRelease = undefined; this.controls[index].onReleaseOutside = undefined; this.controls[index] = undefined; }; v2.downloadSkin = function () { if (this.skinLoader == undefined) { this.skinLoader = new MovieClipLoader(); this.skinLoader.addListener(this); } if (this.skin_mc == undefined) { this.skin_mc = this._vc.createEmptyMovieClip('skin_mc', this._vc.getNextHighestDepth()); } this.skin_mc._visible = false; this.skin_mc._x = Stage.width + 100; this.skin_mc._y = Stage.height + 100; this.skinLoader.loadClip(this._skin, this.skin_mc); }; v2.onLoadError = function (target_mc, errorCode) { this._skinReady = true; this._vc.skinError('Unable to load skin swf'); }; v2.onLoadInit = function () { try { this.skin_mc._visible = false; this.skin_mc._x = 0; this.skin_mc._y = 0; this.layout_mc = this.skin_mc.layout_mc; if (this.layout_mc == undefined) { throw new Error('No layout_mc'); } this.layout_mc._visible = false; this.customClips = new Array(); this.setCustomClips('bg'); if (this.layout_mc.playpause_mc != undefined) { this.setSkin(mx.video.UIManager.PLAY_PAUSE_BUTTON, this.layout_mc.playpause_mc); } else { this.setSkin(mx.video.UIManager.PAUSE_BUTTON, this.layout_mc.pause_mc); this.setSkin(mx.video.UIManager.PLAY_BUTTON, this.layout_mc.play_mc); } this.setSkin(mx.video.UIManager.STOP_BUTTON, this.layout_mc.stop_mc); this.setSkin(mx.video.UIManager.BACK_BUTTON, this.layout_mc.back_mc); this.setSkin(mx.video.UIManager.FORWARD_BUTTON, this.layout_mc.forward_mc); this.setSkin(mx.video.UIManager.MUTE_BUTTON, this.layout_mc.volumeMute_mc); this.setSkin(mx.video.UIManager.SEEK_BAR, this.layout_mc.seekBar_mc); this.setSkin(mx.video.UIManager.VOLUME_BAR, this.layout_mc.volumeBar_mc); this.setSkin(mx.video.UIManager.BUFFERING_BAR, this.layout_mc.bufferingBar_mc); this.setCustomClips('fg'); this.layoutSkin(); this.setupSkinAutoHide(); this.skin_mc._visible = this.__visible; this._skinReady = true; this._vc.skinLoaded(); var v4 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); var v3 = this._vc.__get__state(); var v2 = 0; while (v2 < mx.video.UIManager.NUM_CONTROLS) { if (this.controls[v2] == undefined) { } else { this.setEnabledAndVisibleForState(v2, v3); if (v2 < mx.video.UIManager.NUM_BUTTONS) { this.skinButtonControl(this.controls[v2]); } } ++v2; } this._vc.__set__activeVideoPlayerIndex(v4); } catch (v0) { if (Error(v0) != null) { var err = Error(v0); this._vc.skinError(err.message); this.removeSkin(); } else { throw v0; } } }; v2.layoutSkin = function () { if (this.layout_mc == undefined) { return undefined; } var v3 = this.layout_mc.video_mc; if (v3 == undefined) { throw new Error('No layout_mc.video_mc'); } this.placeholderLeft = v3._x; this.placeholderRight = v3._x + v3._width; this.placeholderTop = v3._y; this.placeholderBottom = v3._y + v3._height; this.videoLeft = 0; this.videoRight = this._vc.width; this.videoTop = 0; this.videoBottom = this._vc.height; if (!isNaN(this.layout_mc.minWidth) && this.layout_mc.minWidth > 0 && this.layout_mc.minWidth > this.videoRight) { this.videoLeft -= (this.layout_mc.minWidth - this.videoRight) / 2; this.videoRight = this.layout_mc.minWidth + this.videoLeft; } if (!isNaN(this.layout_mc.minHeight) && this.layout_mc.minHeight > 0 && this.layout_mc.minHeight > this.videoBottom) { this.videoTop -= (this.layout_mc.minHeight - this.videoBottom) / 2; this.videoBottom = this.layout_mc.minHeight + this.videoTop; } var v2; v2 = 0; while (v2 < this.customClips.length) { this.layoutControl(this.customClips[v2]); ++v2; } v2 = 0; while (v2 < mx.video.UIManager.NUM_CONTROLS) { this.layoutControl(this.controls[v2]); ++v2; } }; v2.layoutControl = function (ctrl) { if (ctrl == undefined) { return undefined; } if (ctrl.skin.anchorRight) { if (ctrl.skin.anchorLeft) { ctrl._x = ctrl.skin._x - this.placeholderLeft + this.videoLeft; ctrl._width = ctrl.skin._x + ctrl.skin._width - this.placeholderRight + this.videoRight - ctrl._x; if (ctrl.origWidth != undefined) { ctrl.origWidth = undefined; } } else { ctrl._x = ctrl.skin._x - this.placeholderRight + this.videoRight; } } else { ctrl._x = ctrl.skin._x - this.placeholderLeft + this.videoLeft; } if (ctrl.skin.anchorTop) { if (ctrl.skin.anchorBottom) { ctrl._y = ctrl.skin._y - this.placeholderTop + this.videoTop; ctrl._height = ctrl.skin._y + ctrl.skin._height - this.placeholderBottom + this.videoBottom - ctrl._y; if (ctrl.origHeight != undefined) { ctrl.origHeight = undefined; } } else { ctrl._y = ctrl.skin._y - this.placeholderTop + this.videoTop; } } else { ctrl._y = ctrl.skin._y - this.placeholderBottom + this.videoBottom; } switch (ctrl.controlIndex) { case mx.video.UIManager.SEEK_BAR: case mx.video.UIManager.VOLUME_BAR: if (ctrl.progress_mc != undefined) { if (this._progressPercent == undefined) { this._progressPercent = this._vc.__get__isRTMP() ? 100 : 0; } this.positionBar(ctrl, 'progress', this._progressPercent); } this.positionHandle(ctrl.controlIndex); break; case mx.video.UIManager.BUFFERING_BAR: if (ctrl.fill_mc != undefined) { this.positionMaskedFill(ctrl, ctrl.fill_mc, 100); } } if (ctrl.layoutSelf != undefined) { ctrl.layoutSelf(); } }; v2.removeSkin = function () { if (this.skin_mc != undefined) { var v2 = 0; while (v2 < mx.video.UIManager.NUM_BUTTONS) { this.removeButtonControl(v2); ++v2; } v2 = mx.video.UIManager.NUM_BUTTONS; while (v2 < mx.video.UIManager.NUM_CONTROLS) { this.controls[v2] = undefined; ++v2; } this.skin_mc.unloadMovie(); this.layout_mc = undefined; this.border_mc = undefined; } }; v2.setCustomClips = function (prefix) { var v4 = 1; while (!false) { var v2 = this.layout_mc[prefix + v4++ + '_mc']; if (v2 == undefined) { break; } var v3 = v2.mc; if (v3 == undefined) { v3 = v2._parent._parent[v2._name]; } if (v3 == undefined) { throw new Error('Bad clip in skin: ' + v2); } v3.skin = v2; this.customClips.push(v3); if (prefix == 'bg' && v4 == 2) { this.border_mc = v3; } } }; v2.setSkin = function (index, s) { if (s == undefined) { return undefined; } var v2 = s.mc; if (v2 == undefined) { v2 = s._parent._parent[s._name]; } if (v2 == undefined) { throw new Error('Bad clip in skin: ' + s); } v2.skin = s; if (index < mx.video.UIManager.NUM_BUTTONS) { this.setupSkinStates(v2); } else { switch (index) { case mx.video.UIManager.PLAY_PAUSE_BUTTON: this.setupSkinStates(v2.play_mc); this.setupSkinStates(v2.pause_mc); break; case mx.video.UIManager.MUTE_BUTTON: this.setupSkinStates(v2.on_mc); this.setupSkinStates(v2.off_mc); break; case mx.video.UIManager.SEEK_BAR: case mx.video.UIManager.VOLUME_BAR: var v4 = (index == mx.video.UIManager.SEEK_BAR) ? 'seekBar' : 'volumeBar'; if (v2.handle_mc == undefined) { v2.handle_mc = v2.skin.seekBarHandle_mc; if (v2.handle_mc == undefined) { v2.handle_mc = v2.skin._parent._parent[v4 + 'Handle_mc']; } } if (v2.progress_mc == undefined) { v2.progress_mc = v2.skin.progress_mc; if (v2.progress_mc == undefined) { v2.progress_mc = v2.skin._parent._parent[v4 + 'Progress_mc']; } } if (v2.fullness_mc == undefined) { v2.fullness_mc = v2.skin.fullness_mc; if (v2.fullness_mc == undefined) { v2.fullness_mc = v2.skin._parent._parent[v4 + 'Fullness_mc']; } } break; case mx.video.UIManager.BUFFERING_BAR: if (v2.fill_mc == undefined) { v2.fill_mc = v2.skin.fill_mc; if (v2.fill_mc == undefined) { v2.fill_mc = v2.skin._parent._parent.bufferingBarFill_mc; } } } } this.setControl(index, v2); }; v2.setupSkinStates = function (ctrl) { if (ctrl.up_mc == undefined) { ctrl.up_mc = ctrl; ctrl.over_mc = ctrl; ctrl.down_mc = ctrl; ctrl.disabled_mc = ctrl; } else { ctrl._x = 0; ctrl._y = 0; ctrl.up_mc._x = 0; ctrl.up_mc._y = 0; ctrl.up_mc._visible = true; if (ctrl.over_mc == undefined) { ctrl.over_mc = ctrl.up_mc; } else { ctrl.over_mc._x = 0; ctrl.over_mc._y = 0; ctrl.over_mc._visible = false; } if (ctrl.down_mc == undefined) { ctrl.down_mc = ctrl.up_mc; } else { ctrl.down_mc._x = 0; ctrl.down_mc._y = 0; ctrl.down_mc._visible = false; } if (ctrl.disabled_mc == undefined) { ctrl.disabled_mc_mc = ctrl.up_mc; } else { ctrl.disabled_mc._x = 0; ctrl.disabled_mc._y = 0; ctrl.disabled_mc._visible = false; } } }; v2.skinButtonControl = function (ctrl) { if (ctrl.onEnterFrame != undefined) { delete ctrl.onEnterFrame; ctrl.onEnterFrame = undefined; } if (ctrl.enabled) { switch (ctrl.state) { case mx.video.UIManager.UP_STATE: if (ctrl.up_mc == undefined) { ctrl.up_mc = ctrl.attachMovie(ctrl.upLinkageID, 'up_mc', ctrl.getNextHighestDepth()); } this.applySkinState(ctrl, ctrl.up_mc); break; case mx.video.UIManager.OVER_STATE: if (ctrl.over_mc == undefined) { if (ctrl.overLinkageID == undefined) { ctrl.over_mc = ctrl.up_mc; } else { ctrl.over_mc = ctrl.attachMovie(ctrl.overLinkageID, 'over_mc', ctrl.getNextHighestDepth()); } } this.applySkinState(ctrl, ctrl.over_mc); break; case mx.video.UIManager.DOWN_STATE: if (ctrl.down_mc == undefined) { if (ctrl.downLinkageID == undefined) { ctrl.down_mc = ctrl.up_mc; } else { ctrl.down_mc = ctrl.attachMovie(ctrl.downLinkageID, 'down_mc', ctrl.getNextHighestDepth()); } } this.applySkinState(ctrl, ctrl.down_mc); } } else { ctrl.state = mx.video.UIManager.UP_STATE; if (ctrl.disabled_mc == undefined) { if (ctrl.disabledLinkageID == undefined) { ctrl.disabled_mc = ctrl.up_mc; } else { ctrl.disabled_mc = ctrl.attachMovie(ctrl.disabledLinkageID, 'disabled_mc', ctrl.getNextHighestDepth()); } } this.applySkinState(ctrl, ctrl.disabled_mc); } if (ctrl.placeholder_mc != undefined) { ctrl.placeholder_mc.unloadMovie(); delete ctrl.placeholder_mc; ctrl.placeholder_mc = undefined; } }; v2.applySkinState = function (ctrl, state) { if (state != ctrl.currentState_mc) { if (state != undefined) { state._visible = true; } if (ctrl.currentState_mc != undefined) { ctrl.currentState_mc._visible = false; } ctrl.currentState_mc = state; } }; v2.addBarControl = function (controlIndex) { var v2 = this.controls[controlIndex]; v2.isDragging = false; v2.percentage = 0; v2.uiMgr = this; v2.controlIndex = controlIndex; if (v2._parent == this.skin_mc) { this.finishAddBarControl(controlIndex); } else { v2.onEnterFrame = function () { this.uiMgr.finishAddBarControl(this.controlIndex); }; } }; v2.finishAddBarControl = function (controlIndex) { var v2 = this.controls[controlIndex]; delete v2.onEnterFrame; v2.onEnterFrame = undefined; if (v2.addBarControl != undefined) { v2.addBarControl(); } this.calcBarMargins(v2, 'handle', true); this.calcBarMargins(v2, 'progress', false); this.calcBarMargins(v2.progress_mc, 'fill', false); this.calcBarMargins(v2.progress_mc, 'mask', false); this.calcBarMargins(v2, 'fullness', false); this.calcBarMargins(v2.fullness_mc, 'fill', false); this.calcBarMargins(v2.fullness_mc, 'mask', false); v2.origWidth = v2._width; v2.origHeight = v2._height; this.fixUpBar(v2, 'progress'); if (v2.progress_mc != undefined) { this.fixUpBar(v2, 'progressBarFill'); if (this._progressPercent == undefined) { this._progressPercent = this._vc.__get__isRTMP() ? 100 : 0; } this.positionBar(v2, 'progress', this._progressPercent); } this.fixUpBar(v2, 'fullness'); if (v2.fullness_mc != undefined) { this.fixUpBar(v2, 'fullnessBarFill'); } this.fixUpBar(v2, 'handle'); v2.handle_mc.controlIndex = controlIndex; switch (controlIndex) { case mx.video.UIManager.SEEK_BAR: this.setControl(mx.video.UIManager.SEEK_BAR_HANDLE, v2.handle_mc); break; case mx.video.UIManager.VOLUME_BAR: this.setControl(mx.video.UIManager.VOLUME_BAR_HANDLE, v2.handle_mc); } this.positionHandle(controlIndex); }; v2.fixUpBar = function (ctrl, type) { if (ctrl[type + 'LinkageID'] != undefined && ctrl[type + 'LinkageID'].length > 0) { var v1; if (ctrl[type + 'Below']) { v1 = -1; while (ctrl._parent.getInstanceAtDepth(v1) != undefined) { --v1; } } else { ctrl[type + 'Below'] = false; v1 = ctrl._parent.getNextHighestDepth(); } ctrl[type + '_mc'] = ctrl._parent.attachMovie(ctrl[type + 'LinkageID'], type + '_mc', v1); } }; v2.calcBarMargins = function (ctrl, type, symmetricMargins) { var v2 = ctrl[type + '_mc']; if (v2 == undefined) { return undefined; } if (ctrl[type + 'LeftMargin'] == undefined && v2._parent == ctrl._parent) { ctrl[type + 'LeftMargin'] = v2._x - ctrl._x; } if (ctrl[type + 'RightMargin'] == undefined) { if (symmetricMargins) { ctrl[type + 'RightMargin'] = ctrl[type + 'LeftMargin']; } else { if (v2._parent == ctrl._parent) { ctrl[type + 'RightMargin'] = ctrl._width - v2._width - v2._x + ctrl._x; } } } if (ctrl[type + 'TopMargin'] == undefined && v2._parent == ctrl._parent) { ctrl[type + 'TopMargin'] = v2._y - ctrl._y; } if (ctrl[type + 'BottomMargin'] == undefined) { if (symmetricMargins) { ctrl[type + 'BottomMargin'] = ctrl[type + 'TopMargin']; } else { if (v2._parent == ctrl._parent) { ctrl[type + 'BottomMargin'] = ctrl._height - v2._height - v2._y + ctrl._y; } } } if (ctrl[type + 'X'] == undefined) { if (v2._parent == ctrl._parent) { ctrl[type + 'X'] = v2._x - ctrl._x; } else { if (v2._parent == ctrl) { ctrl[type + 'X'] = v2._x; } } } if (ctrl[type + 'Y'] == undefined) { if (v2._parent == ctrl._parent) { ctrl[type + 'Y'] = v2._y - ctrl._y; } else { if (v2._parent == ctrl) { ctrl[type + 'Y'] = v2._y; } } } ctrl[type + 'XScale'] = v2._xscale; ctrl[type + 'YScale'] = v2._yscale; ctrl[type + 'Width'] = v2._width; ctrl[type + 'Height'] = v2._height; }; v2.finishAddBufferingBar = function () { var v2 = this.controls[mx.video.UIManager.BUFFERING_BAR]; delete v2.onEnterFrame; v2.onEnterFrame = undefined; this.calcBarMargins(v2, 'fill', true); this.fixUpBar(v2, 'fill'); if (v2.fill_mc != undefined) { this.positionMaskedFill(v2, v2.fill_mc, 100); } }; v2.positionMaskedFill = function (ctrl, fill, percent) { var v5 = fill._parent; var v3 = ctrl.mask_mc; if (v3 == undefined) { v3 = v5.createEmptyMovieClip(ctrl._name + 'Mask_mc', v5.getNextHighestDepth()); ctrl.mask_mc = v3; v3.beginFill(16777215); v3.lineTo(0, 0); v3.lineTo(1, 0); v3.lineTo(1, 1); v3.lineTo(0, 1); v3.lineTo(0, 0); v3.endFill(); fill.setMask(v3); v3._x = ctrl.fillX; v3._y = ctrl.fillY; v3._width = ctrl.fillWidth; v3._height = ctrl.fillHeight; v3._visible = false; this.calcBarMargins(ctrl, 'mask', true); } if (v5 == ctrl) { if (fill.slideReveal) { fill._x = ctrl.maskX - ctrl.fillWidth + ctrl.fillWidth * percent / 100; } else { v3._width = ctrl.fillWidth * percent / 100; } } else { if (v5 == ctrl._parent) { if (fill.slideReveal) { v3._x = ctrl._x + ctrl.maskLeftMargin; v3._y = ctrl._y + ctrl.maskTopMargin; v3._width = ctrl._width - ctrl.maskRightMargin - ctrl.maskLeftMargin; v3._height = ctrl._height - ctrl.maskTopMargin - ctrl.maskBottomMargin; fill._x = v3._x - ctrl.fillWidth + ctrl.maskWidth * percent / 100; fill._y = ctrl._y + ctrl.fillTopMargin; } else { fill._x = ctrl._x + ctrl.fillLeftMargin; fill._y = ctrl._y + ctrl.fillTopMargin; v3._x = fill._x; v3._y = fill._y; v3._width = (ctrl._width - ctrl.fillRightMargin - ctrl.fillLeftMargin) * percent / 100; v3._height = ctrl._height - ctrl.fillTopMargin - ctrl.fillBottomMargin; } } } }; v2.startHandleDrag = function (controlIndex) { var v2 = this.controls[controlIndex]; var v5 = v2.handle_mc; if (v2.startHandleDrag == undefined || !v2.startHandleDrag()) { var v3 = v2._y + v2.handleY; var v4 = (v2.origWidth == undefined) ? v2._width : v2.origWidth; v5.startDrag(false, v2._x + v2.handleLeftMargin, v3, v2._x + v4 - v2.handleRightMargin, v3); } v2.isDragging = true; }; v2.stopHandleDrag = function (controlIndex) { var v2 = this.controls[controlIndex]; var v3 = v2.handle_mc; if (v2.stopHandleDrag == undefined || !v2.stopHandleDrag()) { v3.stopDrag(); } v2.isDragging = false; }; v2.positionHandle = function (controlIndex) { var v2 = this.controls[controlIndex]; var v3 = v2.handle_mc; if (v3 == undefined) { return undefined; } if (v2.positionHandle != undefined && v2.positionHandle()) { return undefined; } var v4 = (v2.origWidth == undefined) ? v2._width : v2.origWidth; var v5 = v4 - v2.handleRightMargin - v2.handleLeftMargin; v3._x = v2._x + v2.handleLeftMargin + v5 * v2.percentage / 100; v3._y = v2._y + v2.handleY; if (v2.fullness_mc != undefined) { this.positionBar(v2, 'fullness', v2.percentage); } }; v2.positionBar = function (ctrl, type, percent) { if (ctrl.positionBar != undefined && ctrl.positionBar(type, percent)) { return undefined; } var v2 = ctrl[type + '_mc']; if (v2._parent == ctrl) { if (v2.fill_mc == undefined) { v2._xscale = ctrl[type + 'XScale'] * percent / 100; } else { this.positionMaskedFill(v2, v2.fill_mc, percent); } } else { v2._x = ctrl._x + ctrl[type + 'LeftMargin']; v2._y = ctrl._y + ctrl[type + 'Y']; if (v2.fill_mc == undefined) { v2._width = (ctrl._width - ctrl[type + 'LeftMargin'] - ctrl[type + 'RightMargin']) * percent / 100; } else { this.positionMaskedFill(v2, v2.fill_mc, percent); } } }; v2.calcPercentageFromHandle = function (controlIndex) { var v2 = this.controls[controlIndex]; var v5 = v2.handle_mc; if (v2.calcPercentageFromHandle == undefined || !v2.calcPercentageFromHandle()) { var v3 = (v2.origWidth == undefined) ? v2._width : v2.origWidth; var v6 = v3 - v2.handleRightMargin - v2.handleLeftMargin; var v4 = v5._x - (v2._x + v2.handleLeftMargin); v2.percentage = (v4 / v6) * 100; if (v2.fullness_mc != undefined) { this.positionBar(v2, 'fullness', v2.percentage); } } if (v2.percentage < 0) { v2.percentage = 0; } if (v2.percentage > 100) { v2.percentage = 100; } }; v2.handleRelease = function (controlIndex) { var v3 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); if (controlIndex == mx.video.UIManager.SEEK_BAR) { this.seekBarListener(true); } else { if (controlIndex == mx.video.UIManager.VOLUME_BAR) { this.volumeBarListener(true); } } this.stopHandleDrag(controlIndex); this._vc.__set__activeVideoPlayerIndex(v3); if (controlIndex == mx.video.UIManager.SEEK_BAR) { this._vc._scrubFinish(); } }; v2.seekBarListener = function (finish) { var v3 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); var v4 = this.controls[mx.video.UIManager.SEEK_BAR]; this.calcPercentageFromHandle(mx.video.UIManager.SEEK_BAR); var v2 = v4.percentage; if (finish) { clearInterval(this._seekBarIntervalID); this._seekBarIntervalID = 0; if (v2 != this._lastScrubPos) { this._vc.seekPercent(v2); } this._vc.addEventListener('playheadUpdate', this); if (this._playAfterScrub) { this._vc.play(); } } else { if ((this._vc.getVideoPlayer(this._vc.__get__visibleVideoPlayerIndex())).__get__state() == mx.video.VideoPlayer.SEEKING) { } else { if (this._seekBarScrubTolerance <= 0 || Math.abs(v2 - this._lastScrubPos) > this._seekBarScrubTolerance || v2 < this._seekBarScrubTolerance || v2 > 100 - this._seekBarScrubTolerance) { if (v2 != this._lastScrubPos) { this._lastScrubPos = v2; this._vc.seekPercent(v2); } } } } this._vc.__set__activeVideoPlayerIndex(v3); }; v2.volumeBarListener = function (finish) { var v3 = this.controls[mx.video.UIManager.VOLUME_BAR]; this.calcPercentageFromHandle(mx.video.UIManager.VOLUME_BAR); var v2 = v3.percentage; if (finish) { clearInterval(this._volumeBarIntervalID); this._volumeBarIntervalID = 0; this._vc.addEventListener('volumeUpdate', this); } if (finish || this._volumeBarScrubTolerance <= 0 || Math.abs(v2 - this._lastVolumePos) > this._volumeBarScrubTolerance || v2 < this._volumeBarScrubTolerance || v2 > 100 - this._volumeBarScrubTolerance) { if (v2 != this._lastVolumePos) { if (this._isMuted) { this.cachedSoundLevel = v2; } else { this._vc.__set__volume(v2); } } } }; v2.doBufferingDelay = function () { clearInterval(this._bufferingDelayIntervalID); this._bufferingDelayIntervalID = 0; var v2 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); if (this._vc.__get__state() == mx.video.FLVPlayback.BUFFERING) { this._bufferingOn = true; this.handleEvent({'type': 'stateChange', 'state': mx.video.FLVPlayback.BUFFERING, 'vp': this._vc.__get__visibleVideoPlayerIndex()}); } this._vc.__set__activeVideoPlayerIndex(v2); }; v2.dispatchMessage = function (ctrl) { if (ctrl.id == mx.video.UIManager.SEEK_BAR_HANDLE) { this._vc._scrubStart(); } var v2 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); switch (ctrl.id) { case mx.video.UIManager.PAUSE_BUTTON: this._vc.pause(); break; case mx.video.UIManager.PLAY_BUTTON: this._vc.play(); break; case mx.video.UIManager.STOP_BUTTON: this._vc.stop(); break; case mx.video.UIManager.SEEK_BAR_HANDLE: this.calcPercentageFromHandle(mx.video.UIManager.SEEK_BAR); this._lastScrubPos = this.controls[mx.video.UIManager.SEEK_BAR].percentage; this._vc.removeEventListener('playheadUpdate', this); if (this._vc.__get__playing() || this._vc.__get__buffering()) { this._playAfterScrub = true; } else { if (this._vc.__get__state() != mx.video.VideoPlayer.SEEKING) { this._playAfterScrub = false; } } this._seekBarIntervalID = setInterval(this, 'seekBarListener', this._seekBarInterval, false); this.startHandleDrag(mx.video.UIManager.SEEK_BAR, mx.video.UIManager.SEEK_BAR_HANDLE); this._vc.pause(); break; case mx.video.UIManager.VOLUME_BAR_HANDLE: this.calcPercentageFromHandle(mx.video.UIManager.VOLUME_BAR); this._lastVolumePos = this.controls[mx.video.UIManager.VOLUME_BAR].percentage; this._vc.removeEventListener('volumeUpdate', this); this._volumeBarIntervalID = setInterval(this, 'volumeBarListener', this._volumeBarInterval, false); this.startHandleDrag(mx.video.UIManager.VOLUME_BAR, mx.video.UIManager.VOLUME_BAR_HANDLE); break; case mx.video.UIManager.BACK_BUTTON: this._vc.seekToPrevNavCuePoint(); break; case mx.video.UIManager.FORWARD_BUTTON: this._vc.seekToNextNavCuePoint(); break; case mx.video.UIManager.MUTE_ON_BUTTON: case mx.video.UIManager.MUTE_OFF_BUTTON: if (!this._isMuted) { this._isMuted = true; this.cachedSoundLevel = this._vc.volume; this._vc.__set__volume(0); } else { this._isMuted = false; this._vc.__set__volume(this.cachedSoundLevel); } this.setEnabledAndVisibleForState(mx.video.UIManager.MUTE_OFF_BUTTON, mx.video.FLVPlayback.PLAYING); this.skinButtonControl(this.controls[mx.video.UIManager.MUTE_OFF_BUTTON]); this.setEnabledAndVisibleForState(mx.video.UIManager.MUTE_ON_BUTTON, mx.video.FLVPlayback.PLAYING); this.skinButtonControl(this.controls[mx.video.UIManager.MUTE_ON_BUTTON]); break; default: throw new Error('Unknown ButtonControl'); } this._vc.__set__activeVideoPlayerIndex(v2); }; v2.setEnabledAndVisibleForState = function (index, state) { var v5 = this._vc.__get__activeVideoPlayerIndex(); this._vc.__set__activeVideoPlayerIndex(this._vc.visibleVideoPlayerIndex); var v3 = state; if (v3 == mx.video.FLVPlayback.BUFFERING && !this._bufferingOn) { v3 = mx.video.FLVPlayback.PLAYING; } switch (index) { case mx.video.UIManager.VOLUME_BAR: case mx.video.UIManager.VOLUME_BAR_HANDLE: this.controls[index].myEnabled = true; this.controls[index].enabled = this._controlsEnabled; break; case mx.video.UIManager.MUTE_ON_BUTTON: this.controls[index].myEnabled = !this._isMuted; if (this.controls[mx.video.UIManager.MUTE_BUTTON] != undefined) { this.controls[index]._visible = this.controls[index].myEnabled; } break; case mx.video.UIManager.MUTE_OFF_BUTTON: this.controls[index].myEnabled = this._isMuted; if (this.controls[mx.video.UIManager.MUTE_BUTTON] != undefined) { this.controls[index]._visible = this.controls[index].myEnabled; } break; default: switch (v3) { case mx.video.FLVPlayback.LOADING: case mx.video.FLVPlayback.CONNECTION_ERROR: this.controls[index].myEnabled = false; break; case mx.video.FLVPlayback.DISCONNECTED: this.controls[index].myEnabled = this._vc.__get__contentPath() != undefined; break; case mx.video.FLVPlayback.SEEKING: break; default: this.controls[index].myEnabled = true; } } switch (index) { case mx.video.UIManager.SEEK_BAR: switch (v3) { case mx.video.FLVPlayback.STOPPED: case mx.video.FLVPlayback.PLAYING: case mx.video.FLVPlayback.PAUSED: case mx.video.FLVPlayback.REWINDING: case mx.video.FLVPlayback.SEEKING: this.controls[index].myEnabled = true; break; case mx.video.FLVPlayback.BUFFERING: this.controls[index].myEnabled = !this._bufferingBarHides || this.controls[mx.video.UIManager.BUFFERING_BAR] == undefined; break; default: this.controls[index].myEnabled = false; } if (this.controls[index].myEnabled) { this.controls[index].myEnabled = !isNaN(this._vc.__get__totalTime()) && this._vc.__get__totalTime() > 0; } this.controls[index].handle_mc.myEnabled = this.controls[index].myEnabled; this.controls[index].handle_mc.enabled = this.controls[index].handle_mc.myEnabled; this.controls[index].handle_mc._visible = this.controls[index].myEnabled; var v4 = !this._bufferingBarHides || this.controls[index].myEnabled || this.controls[mx.video.UIManager.BUFFERING_BAR] == undefined || !this.controls[mx.video.UIManager.BUFFERING_BAR]._visible; this.controls[index]._visible = v4; this.controls[index].progress_mc._visible = v4; this.controls[index].progress_mc.fill_mc._visible = v4; this.controls[index].fullness_mc._visible = v4; this.controls[index].progress_mc.fill_mc._visible = v4; break; case mx.video.UIManager.BUFFERING_BAR: switch (v3) { case mx.video.FLVPlayback.STOPPED: case mx.video.FLVPlayback.PLAYING: case mx.video.FLVPlayback.PAUSED: case mx.video.FLVPlayback.REWINDING: case mx.video.FLVPlayback.SEEKING: this.controls[index].myEnabled = false; break; default: this.controls[index].myEnabled = true; } this.controls[index]._visible = this.controls[index].myEnabled; this.controls[index].fill_mc._visible = this.controls[index].myEnabled; break; case mx.video.UIManager.PAUSE_BUTTON: switch (v3) { case mx.video.FLVPlayback.DISCONNECTED: case mx.video.FLVPlayback.STOPPED: case mx.video.FLVPlayback.PAUSED: case mx.video.FLVPlayback.REWINDING: this.controls[index].myEnabled = false; break; case mx.video.FLVPlayback.PLAYING: this.controls[index].myEnabled = true; break; case mx.video.FLVPlayback.BUFFERING: this.controls[index].myEnabled = !this._bufferingBarHides || this.controls[mx.video.UIManager.BUFFERING_BAR] == undefined; } if (this.controls[mx.video.UIManager.PLAY_PAUSE_BUTTON] != undefined) { this.controls[index]._visible = this.controls[index].myEnabled; } break; case mx.video.UIManager.PLAY_BUTTON: switch (v3) { case mx.video.FLVPlayback.PLAYING: this.controls[index].myEnabled = false; break; case mx.video.FLVPlayback.STOPPED: case mx.video.FLVPlayback.PAUSED: this.controls[index].myEnabled = true; break; case mx.video.FLVPlayback.BUFFERING: this.controls[index].myEnabled = !this._bufferingBarHides || this.controls[mx.video.UIManager.BUFFERING_BAR] == undefined; } if (this.controls[mx.video.UIManager.PLAY_PAUSE_BUTTON] != undefined) { this.controls[index]._visible = !this.controls[mx.video.UIManager.PAUSE_BUTTON]._visible; } break; case mx.video.UIManager.STOP_BUTTON: switch (v3) { case mx.video.FLVPlayback.DISCONNECTED: case mx.video.FLVPlayback.STOPPED: this.controls[index].myEnabled = false; break; case mx.video.FLVPlayback.PAUSED: case mx.video.FLVPlayback.PLAYING: case mx.video.FLVPlayback.BUFFERING: this.controls[index].myEnabled = true; } break; case mx.video.UIManager.BACK_BUTTON: case mx.video.UIManager.FORWARD_BUTTON: if (v3 !== mx.video.FLVPlayback.BUFFERING) { } else { this.controls[index].myEnabled = !this._bufferingBarHides || this.controls[mx.video.UIManager.BUFFERING_BAR] == undefined; } } this.controls[index].enabled = this._controlsEnabled && this.controls[index].myEnabled; this._vc.__set__activeVideoPlayerIndex(v5); }; v2.setupSkinAutoHide = function () { var v2 = this._vc.getVideoPlayer(this._vc.__get__visibleVideoPlayerIndex()); if (this._skinAutoHide && this.skin_mc != undefined) { this.skinAutoHideHitTest(); if (this._skinAutoHideIntervalID == 0) { this._skinAutoHideIntervalID = setInterval(this, 'skinAutoHideHitTest', mx.video.UIManager.SKIN_AUTO_HIDE_INTERVAL); } } else { this.skin_mc._visible = this.__visible; clearInterval(this._skinAutoHideIntervalID); this._skinAutoHideIntervalID = 0; } }; v2.skinAutoHideHitTest = function () { if (!this.__visible) { this.skin_mc._visible = false; } else { var v4 = this._vc.getVideoPlayer(this._vc.__get__visibleVideoPlayerIndex()); var v3 = v4.hitTest(_root._xmouse, _root._ymouse, true); if (!v3 && this.border_mc != undefined) { v3 = this.border_mc.hitTest(_root._xmouse, _root._ymouse, true); } this.skin_mc._visible = v3; } }; v1.version = '1.0.0.103'; v1.PAUSE_BUTTON = 0; v1.PLAY_BUTTON = 1; v1.STOP_BUTTON = 2; v1.SEEK_BAR_HANDLE = 3; v1.BACK_BUTTON = 4; v1.FORWARD_BUTTON = 5; v1.MUTE_ON_BUTTON = 6; v1.MUTE_OFF_BUTTON = 7; v1.VOLUME_BAR_HANDLE = 8; v1.NUM_BUTTONS = 9; v1.PLAY_PAUSE_BUTTON = 9; v1.MUTE_BUTTON = 10; v1.BUFFERING_BAR = 11; v1.SEEK_BAR = 12; v1.VOLUME_BAR = 13; v1.NUM_CONTROLS = 14; v1.UP_STATE = 0; v1.OVER_STATE = 1; v1.DOWN_STATE = 2; v1.SKIN_AUTO_HIDE_INTERVAL = 200; v1.VOLUME_BAR_INTERVAL_DEFAULT = 250; v1.VOLUME_BAR_SCRUB_TOLERANCE_DEFAULT = 0; v1.SEEK_BAR_INTERVAL_DEFAULT = 250; v1.SEEK_BAR_SCRUB_TOLERANCE_DEFAULT = 5; v1.BUFFERING_DELAY_INTERVAL_DEFAULT = 1000; v2.addProperty('bufferingBarHidesAndDisablesOthers', v2.__get__bufferingBarHidesAndDisablesOthers, v2.__set__bufferingBarHidesAndDisablesOthers); v2.addProperty('bufferingDelayInterval', v2.__get__bufferingDelayInterval, v2.__set__bufferingDelayInterval); v2.addProperty('controlsEnabled', v2.__get__controlsEnabled, v2.__set__controlsEnabled); v2.addProperty('seekBarInterval', v2.__get__seekBarInterval, v2.__set__seekBarInterval); v2.addProperty('seekBarScrubTolerance', v2.__get__seekBarScrubTolerance, v2.__set__seekBarScrubTolerance); v2.addProperty('skin', v2.__get__skin, v2.__set__skin); v2.addProperty('skinAutoHide', v2.__get__skinAutoHide, v2.__set__skinAutoHide); v2.addProperty('skinReady', v2.__get__skinReady, function () {}); v2.addProperty('visible', v2.__get__visible, v2.__set__visible); v2.addProperty('volumeBarInterval', v2.__get__volumeBarInterval, v2.__set__volumeBarInterval); v2.addProperty('volumeBarScrubTolerance', v2.__get__volumeBarScrubTolerance, v2.__set__volumeBarScrubTolerance); ASSetPropFlags(mx.video.UIManager.prototype, null, 1); } #endinitclip } movieClip 76 __Packages.mx.utils.Delegate { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.utils) { _global.mx.utils = new Object(); } if (!_global.mx.utils.Delegate) { var v1 = function (f) { super(); this.func = f; }; mx.utils.Delegate = v1; mx.utils.Delegate extends Object; var v2 = v1.prototype; v1.create = function (obj, func) { var v2 = function () { var v2 = arguments.callee.target; var v3 = arguments.callee.func; return v3.apply(v2, arguments); }; v2.target = obj; v2.func = func; return v2; }; v2.createDelegate = function (obj) { return mx.utils.Delegate.create(obj, this.func); }; ASSetPropFlags(mx.utils.Delegate.prototype, null, 1); } #endinitclip } movieClip 77 __Packages.mx.video.SMILManager { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.SMILManager) { var v1 = function (owner) { this._owner = owner; }; mx.video.SMILManager = v1; var v2 = v1.prototype; v2.connectXML = function (url) { this._url = url; this.xml = new XML(); this.xml.onLoad = mx.utils.Delegate.create(this, this.xmlOnLoad); this.xml.load(url); return false; }; v2.xmlOnLoad = function (success) { try { if (!success) { this._owner.helperDone(this, false); } else { this.baseURLAttr = new Array(); this.videoTags = new Array(); var v4 = this.xml.firstChild; if (v4.nodeName == null) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" No root node found; if file is an flv it must have .flv extension'); } else { if (v4.nodeName.toLowerCase() != 'smil') { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" Root node not smil: ' + v4.nodeName); } } var v5 = false; var v3 = 0; while (v3 < v4.childNodes.length) { var v2 = v4.childNodes[v3]; if (v2.nodeType != mx.video.SMILManager.ELEMENT_NODE) { } else { if (v2.nodeName.toLowerCase() == 'head') { this.parseHead(v2); } else { if (v2.nodeName.toLowerCase() == 'body') { v5 = true; this.parseBody(v2); } else { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" Tag ' + v2.nodeName + ' not supported in ' + v4.nodeName + ' tag.'); } } } ++v3; } if (!v5) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" Tag body is required.'); } this._owner.helperDone(this, true); } } catch (v0) { if (Error(v0) != null) { var err = Error(v0); this._owner.helperDone(this, false); throw err; } else { throw v0; } } }; v2.parseHead = function (parentNode) { var v4 = false; var v3 = 0; while (v3 < parentNode.childNodes.length) { var v2 = parentNode.childNodes[v3]; if (v2.nodeType != mx.video.SMILManager.ELEMENT_NODE) { } else { if (v2.nodeName.toLowerCase() == 'meta') { for (var v6 in v2.attributes) { if (v6.toLowerCase() == 'base') { this.baseURLAttr.push(v2.attributes[v6]); } else { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" Attribute ' + v6 + ' not supported in ' + v2.nodeName + ' tag.'); } } } else { if (v2.nodeName.toLowerCase() == 'layout') { if (!v4) { this.parseLayout(v2); v4 = true; } else {} } else {} } } ++v3; } }; v2.parseLayout = function (parentNode) { var v3 = 0; while (v3 < parentNode.childNodes.length) { var v2 = parentNode.childNodes[v3]; if (v2.nodeType != mx.video.SMILManager.ELEMENT_NODE) { } else { if (v2.nodeName.toLowerCase() == 'root-layout') { for (var v5 in v2.attributes) { if (v5.toLowerCase() == 'width') { this.width = Number(v2.attributes[v5]); } else { if (v5.toLowerCase() == 'height') { this.height = Number(v2.attributes[v5]); } else {} } } if (isNaN(this.width) || this.width < 0 || isNaN(this.height) || this.height < 0) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" Tag ' + v2.nodeName + ' requires attributes id, width and height. Width and height must be numbers greater than or equal to 0.'); } this.width = Math.round(this.width); this.height = Math.round(this.height); return undefined; } else {} } ++v3; } }; v2.parseBody = function (parentNode) { var v6 = 0; var v3 = 0; while (v3 < parentNode.childNodes.length) { var v2 = parentNode.childNodes[v3]; if (v2.nodeType != mx.video.SMILManager.ELEMENT_NODE) { } else { if (++v6 > 1) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" Tag ' + parentNode.nodeName + ' is required to contain exactly one tag.'); } if (v2.nodeName.toLowerCase() == 'switch') { this.parseSwitch(v2); } else { if (v2.nodeName.toLowerCase() == 'video' || v2.nodeName.toLowerCase() == 'ref') { var v5 = this.parseVideo(v2); this.videoTags.push(v5); } else {} } } ++v3; } if (this.videoTags.length < 1) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" At least one video of ref tag is required.'); } }; v2.parseSwitch = function (parentNode) { var v4 = 0; while (v4 < parentNode.childNodes.length) { var v5 = parentNode.childNodes[v4]; if (v5.nodeType != mx.video.SMILManager.ELEMENT_NODE) { } else { if (v5.nodeName.toLowerCase() == 'video' || v5.nodeName.toLowerCase() == 'ref') { var v3 = this.parseVideo(v5); if (v3.bitrate == undefined) { this.videoTags.push(v3); } else { var v6 = false; var v2 = 0; while (v2 < this.videoTags.length) { if (this.videoTags[v2].bitrate == undefined || v3.bitrate < this.videoTags[v4].bitrate) { v6 = true; this.videoTags.splice(v2, 0, this.videoTags); break; } ++v2; } if (!v6) { this.videoTags.push(v3); } } } else {} } ++v4; } }; v2.parseVideo = function (node) { var v3 = new Object(); for (var v4 in node.attributes) { if (v4.toLowerCase() == 'src') { v3.src = node.attributes[v4]; } else { if (v4.toLowerCase() == 'system-bitrate') { v3.bitrate = Number(node.attributes[v4]); } else { if (v4.toLowerCase() == 'dur') { v3.dur = Number(node.attributes[v4]); } else {} } } } if (v3.src == undefined) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'URL: "' + this._url + '" Attribute src is required in ' + node.nodeName + ' tag.'); } return v3; }; v1.version = '1.0.0.103'; v1.ELEMENT_NODE = 1; ASSetPropFlags(mx.video.SMILManager.prototype, null, 1); } #endinitclip } movieClip 78 __Packages.mx.video.NCManager { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.NCManager) { var v1 = function () { this.initNCInfo(); this.initOtherInfo(); this._timeoutIntervalId = 0; this._tryNCIntervalId = 0; this._timeout = this.DEFAULT_TIMEOUT; }; mx.video.NCManager = v1; var v2 = v1.prototype; _global.mx.video.NCManager implements _global.mx.video.INCManager; v2.initNCInfo = function () { this._isRTMP = undefined; this._serverName = undefined; this._wrappedURL = undefined; this._portNumber = undefined; this._appName = undefined; }; v2.initOtherInfo = function () { this._contentPath = undefined; this._streamName = undefined; this._streamLength = undefined; this._streamWidth = undefined; this._streamHeight = undefined; this._streams = undefined; this._autoSenseBW = false; this._payload = 0; this._connTypeCounter = 0; this.cleanConns(); }; v2.getTimeout = function () { return this._timeout; }; v2.setTimeout = function (t) { this._timeout = t; if (this._timeoutIntervalId != 0) { clearInterval(this._timeoutIntervalId); this._timeoutIntervalId = setInterval(this, '_onFCSConnectTimeOut', this._timeout); } }; v2.getBitrate = function () { return this._bitrate; }; v2.setBitrate = function (b) { if (this._isRTMP == undefined || !this._isRTMP) { this._bitrate = b; } }; v2.getVideoPlayer = function () { return this._owner; }; v2.setVideoPlayer = function (v) { this._owner = v; }; v2.getNetConnection = function () { return this._nc; }; v2.getStreamName = function () { return this._streamName; }; v2.isRTMP = function () { return this._isRTMP; }; v2.getStreamLength = function () { return this._streamLength; }; v2.getStreamWidth = function () { return this._streamWidth; }; v2.getStreamHeight = function () { return this._streamHeight; }; v2.connectToURL = function (url) { this.initOtherInfo(); this._contentPath = url; if (this._contentPath == null || this._contentPath == undefined || this._contentPath == '') { throw new mx.video.VideoError(mx.video.VideoError.INVALID_CONTENT_PATH); } var v2 = this.parseURL(this._contentPath); if (v2.streamName == undefined || v2.streamName == '') { throw new mx.video.VideoError(mx.video.VideoError.INVALID_CONTENT_PATH, url); } if (v2.isRTMP) { var v3 = this.canReuseOldConnection(v2); this._isRTMP = true; this._protocol = v2.protocol; this._streamName = v2.streamName; this._serverName = v2.serverName; this._wrappedURL = v2.wrappedURL; this._portNumber = v2.portNumber; this._appName = v2.appName; if (this._appName == undefined || this._appName == '' || this._streamName == undefined || this._streamName == '') { throw new mx.video.VideoError(mx.video.VideoError.INVALID_CONTENT_PATH, url); } this._autoSenseBW = this._streamName.indexOf(',') != -1; return v3 || this.connectRTMP(); } else { if ((v2.streamName.slice(-4)).toLowerCase() == '.flv') { var v3 = this.canReuseOldConnection(v2); this._isRTMP = false; this._streamName = v2.streamName; return v3 || this.connectHTTP(); } else { this._smilMgr = new mx.video.SMILManager(this); return this._smilMgr.connectXML(v2.streamName); } } }; v2.connectAgain = function () { var v2 = this._appName.indexOf('/'); if (v2 < 0) { v2 = this._streamName.indexOf('/'); if (v2 >= 0) { this._appName += '/'; this._appName += this._streamName.slice(0, v2); this._streamName = this._streamName.slice(v2 + 1); } return false; } var v3 = this._appName.slice(v2 + 1); v3 += '/'; v3 += this._streamName; this._streamName = v3; this._appName = this._appName.slice(0, v2); this.close(); this._payload = 0; this._connTypeCounter = 0; this.cleanConns(); this.connectRTMP(); return true; }; v2.reconnect = function () { if (!this._isRTMP) { throw new Error('Cannot call reconnect on an http connection'); } this._nc.onStatus = function (info) { this.mc.reconnectOnStatus(this, info); }; this._nc.onBWDone = function () { this.mc.onReconnected(); }; this._nc.connect(this._ncUri, false); }; v2.onReconnected = function () { delete this._nc.onStatus; delete this._nc.onBWDone; this._owner.ncReconnected(); }; v2.close = function () { if (this._nc) { this._nc.close(); } }; v2.helperDone = function (helper, success) { if (helper != this._smilMgr) { return undefined; } if (!success) { this._nc = undefined; this._owner.ncConnected(); delete this._smilMgr; return undefined; } this._streamWidth = this._smilMgr.width; this._streamHeight = this._smilMgr.height; var v2; var v4 = this._smilMgr.baseURLAttr[0]; if (v4 != undefined && v4 != '') { v2 = this.parseURL(v4); this._isRTMP = v2.isRTMP; this._streamName = v2.streamName; if (this._isRTMP) { this._protocol = v2.protocol; this._serverName = v2.serverName; this._portNumber = v2.portNumber; this._wrappedURL = v2.wrappedURL; this._appName = v2.appName; if (this._appName == undefined || this._appName == '') { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'Base RTMP URL must include application name: ' + v4); } if (this._smilMgr.baseURLAttr.length > 1) { v2 = this.parseURL(this._smilMgr.baseURLAttr[1]); if (v2.serverName != undefined) { this.fallbackServerName = v2.serverName; } } } } this._streams = this._smilMgr.videoTags; var v3 = 0; while (v3 < this._streams.length) { v4 = this._streams[v3].src; v2 = this.parseURL(v4); if (this._isRTMP == undefined) { this._isRTMP = v2.isRTMP; if (this._isRTMP) { this._protocol = v2.protocol; if (this._streams.length > 1) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'Cannot switch between multiple absolute RTMP URLs, must use meta tag base attribute.'); } this._serverName = v2.serverName; this._portNumber = v2.portNumber; this._wrappedURL = v2.wrappedURL; this._appName = v2.appName; if (this._appName == undefined || this._appName == '') { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'Base RTMP URL must include application name: ' + v4); } } } else { if (this._streamName != undefined && this._streamName != '' && !v2.isRelative && this._streams.length > 1) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_XML, 'When using meta tag base attribute, cannot use absolute URLs for video or ref tag src attributes.'); } } this._streams[v3].parseResults = v2; ++v3; } this._autoSenseBW = this._streams.length > 1; if (!this._autoSenseBW) { if (this._streamName != undefined) { this._streamName += this._streams[0].parseResults.streamName; } else { this._streamName = this._streams[0].parseResults.streamName; } this._streamLength = this._streams[0].dur; } if (this._isRTMP) { this.connectRTMP(); } else { if (this._autoSenseBW) { this.bitrateMatch(); } this.connectHTTP(); this._owner.ncConnected(); } }; v2.bitrateMatch = function () { var v3; if (isNaN(this._bitrate)) { v3 = 0; } else { var v2 = 0; while (v2 < this._streams.length) { if (isNaN(this._streams[v2].bitrate) || this._bitrate <= this._streams[v2].bitrate) { v3 = v2; break; } ++v2; } } if (isNaN(v3)) { throw new mx.video.VideoError(mx.video.VideoError.NO_BITRATE_MATCH); } if (this._streamName != undefined) { this._streamName += this._streams[v3].src; } else { this._streamName = this._streams[v3].src; } this._streamLength = this._streams[v3].dur; }; v2.parseURL = function (url) { var v2 = new Object(); var v3 = 0; var v4 = url.indexOf(':/', v3); if (v4 >= 0) { v4 += 2; v2.protocol = url.slice(v3, v4); v2.isRelative = false; } else { v2.isRelative = true; } if (v2.protocol != undefined && (v2.protocol == 'rtmp:/' || v2.protocol == 'rtmpt:/' || v2.protocol == 'rtmps:/')) { v2.isRTMP = true; v3 = v4; if (url.charAt(v3) == '/') { ++v3; var v7 = url.indexOf(':', v3); var v8 = url.indexOf('/', v3); if (v8 < 0) { if (v7 < 0) { v2.serverName = url.slice(v3); } else { v4 = v7; v2.portNumber = url.slice(v3, v4); v3 = v4 + 1; v2.serverName = url.slice(v3); } return v2; } if (v7 >= 0 && v7 < v8) { v4 = v7; v2.serverName = url.slice(v3, v4); v3 = v4 + 1; v4 = v8; v2.portNumber = url.slice(v3, v4); } else { v4 = v8; v2.serverName = url.slice(v3, v4); } v3 = v4 + 1; } if (url.charAt(v3) == '?') { var v9 = url.slice(v3 + 1); var v6 = this.parseURL(v9); if (v6.protocol == undefined || !v6.isRTMP) { throw new mx.video.VideoError(mx.video.VideoError.INVALID_CONTENT_PATH, url); } v2.wrappedURL = '?'; v2.wrappedURL += v6.protocol; if (v6.server != undefined) { v2.wrappedURL += '/'; v2.wrappedURL += v6.server; } if (v6.wrappedURL != undefined) { v2.wrappedURL += '/?'; v2.wrappedURL += v6.wrappedURL; } v2.appName = v6.appName; v2.streamName = v6.streamName; return v2; } v4 = url.indexOf('/', v3); if (v4 < 0) { v2.appName = url.slice(v3); return v2; } v2.appName = url.slice(v3, v4); v3 = v4 + 1; v4 = url.indexOf('/', v3); if (v4 < 0) { v2.streamName = url.slice(v3); return v2; } v2.appName += '/'; v2.appName += url.slice(v3, v4); v3 = v4 + 1; v2.streamName = url.slice(v3); return v2; } v2.isRTMP = false; v2.streamName = url; return v2; }; v2.canReuseOldConnection = function (parseResults) { if (this._nc == undefined || this._nc == null) { return false; } if (!parseResults.isRTMP) { if (!this._isRTMP) { return true; } this._owner.close(); this._nc = null; this.initNCInfo(); return false; } if (this._isRTMP) { if (parseResults.serverName == this._serverName && parseResults.appName == this._appName && parseResults.protocol == this._protocol && parseResults.portNumber == this._portNumber && parseResults.wrappedURL == this._wrappedURL) { return true; } this._owner.close(); this._nc = null; } this.initNCInfo(); return false; }; v2.connectHTTP = function () { this._nc = new NetConnection(); this._nc.connect(null); return true; }; v2.connectRTMP = function () { clearInterval(this._timeoutIntervalId); this._timeoutIntervalId = setInterval(this, '_onFCSConnectTimeOut', this._timeout); this._tryNC = new Array(); var v2 = 0; while (v2 < mx.video.NCManager.RTMP_CONN.length) { this._tryNC[v2] = new NetConnection(); this._tryNC[v2].mc = this; this._tryNC[v2].pending = false; this._tryNC[v2].connIndex = v2; this._tryNC[v2].onBWDone = function (p_bw) { this.mc.onConnected(this, p_bw); }; this._tryNC[v2].onBWCheck = function () { return ++this.mc._payload; }; this._tryNC[v2].onStatus = function (info) { this.mc.connectOnStatus(this, info); }; ++v2; } this.nextConnect(); return false; }; v2.nextConnect = function () { clearInterval(this._tryNCIntervalId); this._tryNCIntervalId = 0; var v4; var v3; if (this._connTypeCounter == 0) { v4 = this._protocol; if (this._portNumber != undefined) { v3 = this._portNumber; } else { var v2 = 0; while (v2 < mx.video.NCManager.RTMP_CONN.length) { if (v4 == mx.video.NCManager.RTMP_CONN[v2].protocol) { v3 = mx.video.NCManager.RTMP_CONN[v2].port; break; } ++v2; } } } else { v4 = mx.video.NCManager.RTMP_CONN[this._connTypeCounter].protocol; v3 = mx.video.NCManager.RTMP_CONN[this._connTypeCounter].port; } var v5 = v4 + ((this._serverName == undefined) ? '' : '/' + this._serverName + ':' + v3 + '/') + ((this._wrappedURL == undefined) ? '' : this._wrappedURL + '/') + this._appName; this._tryNC[this._connTypeCounter].pending = true; this._tryNC[this._connTypeCounter].connect(v5, this._autoSenseBW); if (this._connTypeCounter < mx.video.NCManager.RTMP_CONN.length - 1) { ++this._connTypeCounter; this._tryNCIntervalId = setInterval(this, 'nextConnect', 1500); } }; v2.cleanConns = function () { clearInterval(this._tryNCIntervalId); this._tryNCIntervalId = 0; if (this._tryNC != undefined) { var v2 = 0; while (v2 < this._tryNC.length) { if (this._tryNC[v2] != undefined) { delete this._tryNC[v2].onStatus; if (this._tryNC[v2].pending) { this._tryNC[v2].onStatus = function (info) { this.mc.disconnectOnStatus(this, info); }; } else { delete this._tryNC[v2].onStatus; this._tryNC[v2].close(); } } delete this._tryNC[v2]; ++v2; } delete this._tryNC; } }; v2.tryFallBack = function () { if (this._serverName == this.fallbackServerName || this.fallbackServerName == undefined || this.fallbackServerName == null) { delete this._nc; this._nc = undefined; this._owner.ncConnected(); } else { this._connTypeCounter = 0; this.cleanConns(); this._serverName = this.fallbackServerName; this.connectRTMP(); } }; v2.onConnected = function (p_nc, p_bw) { clearInterval(this._timeoutIntervalId); this._timeoutIntervalId = 0; delete p_nc.onBWDone; delete p_nc.onBWCheck; delete p_nc.onStatus; this._nc = p_nc; this._ncUri = this._nc.uri; if (this._autoSenseBW) { this._bitrate = p_bw * 1024; if (this._streams != undefined) { this.bitrateMatch(); } else { if (this._streamName.indexOf(',') != -1) { var v3 = this._streamName.split(','); var v2 = 0; while (v2 < v3.length) { var v4 = mx.video.NCManager.stripFrontAndBackWhiteSpace(v3[v2]); if (v2 + 1 < v3.length) { if (p_bw <= Number(v3[v2 + 1])) { this._streamName = v4; break; } } else { this._streamName = v4; break; } v2 += 2; } } } } if ((this._streamName.slice(-4)).toLowerCase() == '.flv') { this._streamName = this._streamName.slice(0, -4); } if (!this._owner.__get__isLive() && this._streamLength == undefined) { var v6 = new Object(); v6.mc = this; v6.onResult = function (length) { this.mc.getStreamLengthResult(length); }; this._nc.call('getStreamLength', v6, this._streamName); } else { this._owner.ncConnected(); } }; v2.connectOnStatus = function (target, info) { target.pending = false; if (info.code == 'NetConnection.Connect.Success') { this._nc = this._tryNC[target.connIndex]; this._tryNC[target.connIndex] = undefined; this.cleanConns(); } else { if ((info.code == 'NetConnection.Connect.Failed' || info.code == 'NetConnection.Connect.Rejected') && target.connIndex == mx.video.NCManager.RTMP_CONN.length - 1) { if (!this.connectAgain()) { this.tryFallBack(); } } else {} } }; v2.reconnectOnStatus = function (target, info) { if (info.code == 'NetConnection.Connect.Failed' || info.code == 'NetConnection.Connect.Rejected') { delete this._nc; this._nc = undefined; this._owner.ncReconnected(); } }; v2.disconnectOnStatus = function (target, info) { if (info.code == 'NetConnection.Connect.Success') { delete target.onStatus; target.close(); } }; v2.getStreamLengthResult = function (length) { this._streamLength = length; this._owner.ncConnected(); }; v2._onFCSConnectTimeOut = function () { this.cleanConns(); this._nc = undefined; if (!this.connectAgain()) { this._owner.ncConnected(); } }; v1.stripFrontAndBackWhiteSpace = function (p_str) { var v1; var v2 = p_str.length; var v4 = 0; var v5 = v2; v1 = 0; while (v1 < v2) { switch (p_str.charCodeAt(v1)) { if (p_str.charCodeAt(v1) !== 32) { } else { break; case 9: case 10: case 13: } default: v4 = v1; break; } ++v1; } v1 = v2; while (v1 >= 0) { switch (p_str.charCodeAt(v1)) { if (p_str.charCodeAt(v1) !== 32) { } else { case 9: case 10: break; case 13: } default: v5 = v1 + 1; break; } --v1; } if (v5 <= v4) { return ''; } return p_str.slice(v4, v5); }; v1.version = '1.0.0.103'; v2.DEFAULT_TIMEOUT = 60000; v1.RTMP_CONN = [{'protocol': 'rtmp:/', 'port': '1935'}, {'protocol': 'rtmp:/', 'port': '443'}, {'protocol': 'rtmpt:/', 'port': '80'}, {'protocol': 'rtmps:/', 'port': '443'}]; ASSetPropFlags(mx.video.NCManager.prototype, null, 1); } #endinitclip } movieClip 79 __Packages.mx.video.CuePointManager { #initclip if (!_global.mx) { _global.mx = new Object(); } if (!_global.mx.video) { _global.mx.video = new Object(); } if (!_global.mx.video.CuePointManager) { var v1 = function (owner, id) { this._owner = owner; this._id = id; this.reset(); this._asCuePointTolerance = (this._owner.getVideoPlayer(this._id)).__get__playheadUpdateInterval() / 2000; this._linearSearchTolerance = mx.video.CuePointManager.DEFAULT_LINEAR_SEARCH_TOLERANCE; }; mx.video.CuePointManager = v1; var v2 = v1.prototype; v2.reset = function () { this._metadataLoaded = false; this.allCuePoints = null; this.asCuePoints = null; this._disabledCuePoints = null; this.flvCuePoints = null; this.navCuePoints = null; this.eventCuePoints = null; this._asCuePointIndex = 0; }; v2.__get__metadataLoaded = function () { return this._metadataLoaded; }; v2.__set__playheadUpdateInterval = function (aTime) { this._asCuePointTolerance = aTime / 2000; return this.__get__playheadUpdateInterval(); }; v2.__get__id = function () { return this._id; }; v2.addASCuePoint = function (timeOrCuePoint, name, parameters) { var v3; if (typeof timeOrCuePoint == 'object') { v3 = mx.video.CuePointManager.deepCopyObject(timeOrCuePoint); } else { v3 = {'time': timeOrCuePoint, 'name': name, 'parameters': mx.video.CuePointManager.deepCopyObject(parameters)}; } var v7 = isNaN(v3.time) || v3.time < 0; if (v7) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'time must be number'); } var v6 = v3.name == undefined || v3.name == null; if (v6) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'name cannot be undefined or null'); } var v2; v3.type = 'actionscript'; if (this.asCuePoints == null || this.asCuePoints == undefined || this.asCuePoints.length < 1) { v2 = 0; this.asCuePoints = new Array(); this.asCuePoints.push(v3); } else { v2 = this.getCuePointIndex(this.asCuePoints, true, v3.time); v2 = this.asCuePoints[v2].time > v3.time ? 0 : v2 + 1; this.asCuePoints.splice(v2, 0, v3); } if (this.allCuePoints == null || this.allCuePoints == undefined || this.allCuePoints.length < 1) { v2 = 0; this.allCuePoints = new Array(); this.allCuePoints.push(v3); } else { v2 = this.getCuePointIndex(this.allCuePoints, true, v3.time); v2 = this.allCuePoints[v2].time > v3.time ? 0 : v2 + 1; this.allCuePoints.splice(v2, 0, v3); } var v5 = (this._owner.getVideoPlayer(this._id)).__get__playheadTime(); if (v5 > 0) { if (this._asCuePointIndex == v2) { if (v5 > this.asCuePoints[v2].time) { ++this._asCuePointIndex; } } else { if (this._asCuePointIndex > v2) { ++this._asCuePointIndex; } } var v4 = mx.video.CuePointManager.deepCopyObject(this.asCuePoints[v2]); v4.array = this.asCuePoints; v4.index = v2; return v4; } this._asCuePointIndex = 0; var v4 = mx.video.CuePointManager.deepCopyObject(this.asCuePoints[v2]); v4.array = this.asCuePoints; v4.index = v2; return v4; }; v2.removeASCuePoint = function (timeNameOrCuePoint) { if (this.asCuePoints == null || this.asCuePoints == undefined || this.asCuePoints.length < 1) { return null; } var v3; switch (typeof timeNameOrCuePoint) { case 'string': v3 = {'name': timeNameOrCuePoint}; break; case 'number': v3 = {'time': timeNameOrCuePoint}; break; case 'object': v3 = timeNameOrCuePoint; } var v2 = this.getCuePointIndex(this.asCuePoints, false, v3.time, v3.name); if (v2 < 0) { return null; } v3 = this.asCuePoints[v2]; this.asCuePoints.splice(v2, 1); v2 = this.getCuePointIndex(this.allCuePoints, false, v3.time, v3.name); if (v2 > 0) { this.allCuePoints.splice(v2, 1); } if ((this._owner.getVideoPlayer(this._id)).__get__playheadTime() > 0) { if (this._asCuePointIndex > v2) { --this._asCuePointIndex; } return v3; } this._asCuePointIndex = 0; return v3; }; v2.setFLVCuePointEnabled = function (enabled, timeNameOrCuePoint) { var v4; switch (typeof timeNameOrCuePoint) { case 'string': v4 = {'name': timeNameOrCuePoint}; break; case 'number': v4 = {'time': timeNameOrCuePoint}; break; case 'object': v4 = timeNameOrCuePoint; } var v12 = isNaN(v4.time) || v4.time < 0; var v11 = v4.name == undefined || v4.name == null; if (v12 && v11) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'time must be number and/or name must not be undefined or null'); } var v6 = 0; var v2; var v5; if (v12) { if (!this._metadataLoaded) { if (this._disabledCuePointsByNameOnly[v4.name] == undefined) { if (!enabled) { if (this._disabledCuePointsByNameOnly == null || this._disabledCuePointsByNameOnly == undefined || this._disabledCuePointsByNameOnly.length < 0) { this._disabledCuePointsByNameOnly = new Object(); } this._disabledCuePointsByNameOnly[v4.name] = new Array(); } } else { if (enabled) { this._disabledCuePointsByNameOnly[v4.name] = undefined; } return -1; } this.removeCuePoints(this._disabledCuePoints, v4); return -1; } if (enabled) { v6 = this.removeCuePoints(this._disabledCuePoints, v4); } else { var v3; v2 = this.getCuePointIndex(this.flvCuePoints, true, -1, v4.name); while (v2 >= 0) { v3 = this.flvCuePoints[v2]; v5 = this.getCuePointIndex(this._disabledCuePoints, true, v3.time); if (v5 < 0 || this._disabledCuePoints[v5].time != v3.time) { this._disabledCuePoints = this.insertCuePoint(v5, this._disabledCuePoints, {'name': v3.name, 'time': v3.time}); v6 += 1; } v2 = this.getNextCuePointIndexWithName(v3.name, this.flvCuePoints, v2); } } return v6; } v2 = this.getCuePointIndex(this._disabledCuePoints, false, v4.time, v4.name); if (v2 < 0) { if (enabled) { if (!this._metadataLoaded) { v2 = this.getCuePointIndex(this._disabledCuePoints, false, v4.time); if (v2 < 0) { v5 = this.getCuePointIndex(this._disabledCuePointsByNameOnly[v4.name], true, v4.time); if (mx.video.CuePointManager.cuePointCompare(v4.time, null, this._disabledCuePointsByNameOnly[v4.name]) != 0) { this._disabledCuePointsByNameOnly[v4.name] = this.insertCuePoint(v5, this._disabledCuePointsByNameOnly[v4.name], v4); } } else { this._disabledCuePoints.splice(v2, 1); } } return this._metadataLoaded ? 0 : -1; } } else { if (enabled) { this._disabledCuePoints.splice(v2, 1); v6 = 1; } else { v6 = 0; } return this._metadataLoaded ? v6 : -1; } if (this._metadataLoaded) { v2 = this.getCuePointIndex(this.flvCuePoints, false, v4.time, v4.name); if (v2 < 0) { return 0; } if (v11) { v4.name = this.flvCuePoints[v2].name; } } v5 = this.getCuePointIndex(this._disabledCuePoints, true, v4.time); this._disabledCuePoints = this.insertCuePoint(v5, this._disabledCuePoints, v4); v6 = 1; return this._metadataLoaded ? 1 : -1; }; v2.removeCuePoints = function (cuePointArray, cuePoint) { var v2; var v4; var v5 = 0; v2 = this.getCuePointIndex(cuePointArray, true, -1, cuePoint.name); while (v2 >= 0) { v4 = cuePointArray[v2]; cuePointArray.splice(v2, 1); --v2; ++v5; v2 = this.getNextCuePointIndexWithName(v4.name, cuePointArray, v2); } return v5; }; v2.insertCuePoint = function (insertIndex, cuePointArray, cuePoint) { if (insertIndex < 0) { cuePointArray = new Array(); cuePointArray.push(cuePoint); return cuePointArray; } if (cuePointArray[insertIndex].time > cuePoint.time) { insertIndex = 0; } else { ++insertIndex; } cuePointArray.splice(insertIndex, 0, cuePoint); return cuePointArray; }; v2.isFLVCuePointEnabled = function (timeNameOrCuePoint) { if (!this._metadataLoaded) { return true; } var v3; switch (typeof timeNameOrCuePoint) { case 'string': v3 = {'name': timeNameOrCuePoint}; break; case 'number': v3 = {'time': timeNameOrCuePoint}; break; case 'object': v3 = timeNameOrCuePoint; } var v5 = isNaN(v3.time) || v3.time < 0; var v6 = v3.name == undefined || v3.name == null; if (v5 && v6) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'time must be number and/or name must not be undefined or null'); } if (v5) { var v2 = this.getCuePointIndex(this.flvCuePoints, true, -1, v3.name); if (v2 < 0) { return true; } while (v2 >= 0) { if (this.getCuePointIndex(this._disabledCuePoints, false, this.flvCuePoints[v2].time, this.flvCuePoints[v2].name) < 0) { return true; } v2 = this.getNextCuePointIndexWithName(v3.name, this.flvCuePoints, v2); } return false; } return this.getCuePointIndex(this._disabledCuePoints, false, v3.time, v3.name) < 0; }; v2.dispatchASCuePoints = function () { var v5 = (this._owner.getVideoPlayer(this._id)).__get__playheadTime(); if ((this._owner.getVideoPlayer(this._id)).__get__stateResponsive() && this.asCuePoints != null && this.asCuePoints != undefined) { for (;;) { if (!(this._asCuePointIndex < this.asCuePoints.length && this.asCuePoints[this._asCuePointIndex].time <= v5 + this._asCuePointTolerance)) break; this._owner.dispatchEvent({'type': 'cuePoint', 'info': mx.video.CuePointManager.deepCopyObject(this.asCuePoints[this._asCuePointIndex++]), 'vp': this._id}); } } }; v2.resetASCuePointIndex = function (time) { if (time <= 0 || this.asCuePoints == null || this.asCuePoints == undefined) { this._asCuePointIndex = 0; return undefined; } var v2 = this.getCuePointIndex(this.asCuePoints, true, time); this._asCuePointIndex = this.asCuePoints[v2].time < time ? v2 + 1 : v2; }; v2.processFLVCuePoints = function (metadataCuePoints) { this._metadataLoaded = true; if (metadataCuePoints == undefined || metadataCuePoints == null || metadataCuePoints.length < 1) { this.flvCuePoints = null; this.navCuePoints = null; this.eventCuePoints = null; return undefined; } this.flvCuePoints = metadataCuePoints; this.navCuePoints = new Array(); this.eventCuePoints = new Array(); var v5; var v6 = -1; var v2; var v4 = this._disabledCuePoints; var v3 = 0; this._disabledCuePoints = new Array(); var v9 = 0; v2 = this.flvCuePoints[v9++]; while (v2 != undefined) { if (v6 > 0 && v6 >= v2.time) { this.flvCuePoints = null; this.navCuePoints = null; this.eventCuePoints = null; this._disabledCuePoints = null; this._disabledCuePointsByNameOnly = null; throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'Unsorted cuePoint found after time: ' + v6); } v6 = v2.time; for (;;) { if (!(v3 < v4.length && mx.video.CuePointManager.cuePointCompare(v4[v3].time, null, v2) < 0)) break; ++v3; } if (this._disabledCuePointsByNameOnly[v2.name] != undefined || v3 < v4.length && mx.video.CuePointManager.cuePointCompare(v4[v3].time, v4[v3].name, v2) == 0) { this._disabledCuePoints.push({'time': v2.time, 'name': v2.name}); } if (v2.type == 'navigation') { this.navCuePoints.push(v2); } else { if (v2.type == 'event') { this.eventCuePoints.push(v2); } } if (this.allCuePoints == null || this.allCuePoints == undefined || this.allCuePoints.length < 1) { this.allCuePoints = new Array(); this.allCuePoints.push(v2); } else { v5 = this.getCuePointIndex(this.allCuePoints, true, v2.time); v5 = this.allCuePoints[v5].time > v2.time ? 0 : v5 + 1; this.allCuePoints.splice(v5, 0, v2); } } delete this._disabledCuePointsByNameOnly; this._disabledCuePointsByNameOnly = null; delete this._disabledCuePointsByNameOnly; this._disabledCuePointsByNameOnly = null; }; v2.processCuePointsProperty = function (cuePoints) { if (cuePoints == undefined || cuePoints == null || cuePoints.length == 0) { return undefined; } var v4 = 0; var v8; var v6; var v7; var v5; var v9; var v2 = 0; while (v2 < cuePoints.length - 1) { switch (v4) { case 6: this.addOrDisable(v9, v5); v4 = 0; case 0: if (cuePoints[v2++] != 't') { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'unexpected cuePoint parameter format'); } if (isNaN(cuePoints[v2])) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'time must be number'); } v5 = new Object(); v5.time = cuePoints[v2] / 1000; ++v4; break; case 1: if (cuePoints[v2++] != 'n') { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'unexpected cuePoint parameter format'); } if (cuePoints[v2] == undefined || cuePoints[v2] == null) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'name cannot be null or undefined'); } v5.name = this.unescape(cuePoints[v2]); ++v4; break; case 2: if (cuePoints[v2++] != 't') { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'unexpected cuePoint parameter format'); } if (isNaN(cuePoints[v2])) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'type must be number'); } switch (cuePoints[v2]) { case 0: v5.type = 'event'; break; case 1: v5.type = 'navigation'; break; case 2: v5.type = 'actionscript'; break; default: throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'type must be 0, 1 or 2'); } ++v4; break; case 3: if (cuePoints[v2++] != 'd') { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'unexpected cuePoint parameter format'); } if (isNaN(cuePoints[v2])) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'disabled must be number'); } v9 = cuePoints[v2] != 0; ++v4; break; case 4: if (cuePoints[v2++] != 'p') { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'unexpected cuePoint parameter format'); } if (isNaN(cuePoints[v2])) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'num params must be number'); } v8 = cuePoints[v2]; ++v4; if (v8 == 0) { ++v4; } else { v5.parameters = new Object(); } break; case 5: v6 = cuePoints[v2++]; v7 = cuePoints[v2]; if (typeof v6 == 'string') { v6 = this.unescape(v6); } if (typeof v7 == 'string') { v7 = this.unescape(v7); } v5.parameters[v6] = v7; --v8; if (v8 == 0) { ++v4; } } ++v2; } if (v4 == 6) { this.addOrDisable(v9, v5); } else { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'unexpected end of cuePoint param string'); } }; v2.addOrDisable = function (disable, cuePoint) { if (disable) { if (cuePoint.type == 'actionscript') { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'Cannot disable actionscript cue points'); } this.setFLVCuePointEnabled(false, cuePoint); } else { if (cuePoint.type == 'actionscript') { this.addASCuePoint(cuePoint); } } }; v2.unescape = function (origStr) { var v3 = origStr; var v1 = 0; while (v1 < mx.video.CuePointManager.cuePointsReplace.length) { var v2 = v3.split(mx.video.CuePointManager.cuePointsReplace[v1++]); if (v2.length > 1) { v3 = v2.join(mx.video.CuePointManager.cuePointsReplace[v1]); } ++v1; } return v3; }; v2.getCuePointIndex = function (cuePointArray, closeIsOK, time, name, start, len) { if (cuePointArray == null || cuePointArray == undefined || cuePointArray.length < 1) { return -1; } var v13 = isNaN(time) || time < 0; var v16 = name == undefined || name == null; if (v13 && v16) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'time must be number and/or name must not be undefined or null'); } if (start == undefined || start == null) { start = 0; } if (len == undefined || len == null) { len = cuePointArray.length; } if (!v16 && (closeIsOK || v13)) { var v8; var v2; if (v13) { v8 = start; } else { v8 = this.getCuePointIndex(cuePointArray, closeIsOK, time); } v2 = v8; while (v2 >= start) { if (cuePointArray[v2].name == name) { break; } --v2; } if (v2 >= start) { return v2; } v2 = v8 + 1; while (v2 < len) { if (cuePointArray[v2].name == name) { break; } ++v2; } if (v2 < len) { return v2; } return -1; } var v6; if (len <= this._linearSearchTolerance) { var v11 = start + len; var v3 = start; while (v3 < v11) { v6 = mx.video.CuePointManager.cuePointCompare(time, name, cuePointArray[v3]); if (v6 == 0) { return v3; } if (v6 < 0) { break; } ++v3; } if (closeIsOK) { if (v3 > 0) { return v3 - 1; } return 0; } return -1; } var v12 = Math.floor(len / 2); var v15 = start + v12; v6 = mx.video.CuePointManager.cuePointCompare(time, name, cuePointArray[v15]); if (v6 < 0) { return this.getCuePointIndex(cuePointArray, closeIsOK, time, name, start, v12); } if (v6 > 0) { return this.getCuePointIndex(cuePointArray, closeIsOK, time, name, v15 + 1, v12 - 1 + len % 2); } return v15; }; v2.getNextCuePointIndexWithName = function (name, array, index) { if (name == undefined || name == null) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'name cannot be undefined or null'); } if (array == null || array == undefined) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'cuePoint.array undefined'); } if (isNaN(index) || index < -1 || index >= array.length) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'cuePoint.index must be number between -1 and cuePoint.array.length'); } var v1; v1 = index + 1; while (v1 < array.length) { if (array[v1].name == name) { break; } ++v1; } if (v1 < array.length) { return v1; } return -1; }; v1.cuePointCompare = function (time, name, cuePoint) { var v2 = Math.round(time * 1000); var v3 = Math.round(cuePoint.time * 1000); if (v2 < v3) { return -1; } if (v2 > v3) { return 1; } if (name != null || name != undefined) { if (name == cuePoint.name) { return 0; } if (name < cuePoint.name) { return -1; } return 1; } return 0; }; v2.getCuePoint = function (cuePointArray, closeIsOK, timeNameOrCuePoint) { var v3; switch (typeof timeNameOrCuePoint) { case 'string': v3 = {'name': timeNameOrCuePoint}; break; case 'number': v3 = {'time': timeNameOrCuePoint}; break; case 'object': v3 = timeNameOrCuePoint; } var v2 = this.getCuePointIndex(cuePointArray, closeIsOK, v3.time, v3.name); if (v2 < 0) { return null; } v3 = mx.video.CuePointManager.deepCopyObject(cuePointArray[v2]); v3.array = cuePointArray; v3.index = v2; return v3; }; v2.getNextCuePointWithName = function (cuePoint) { if (cuePoint == null || cuePoint == undefined) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'cuePoint parameter undefined'); } if (isNaN(cuePoint.time) || cuePoint.time < 0) { throw new mx.video.VideoError(mx.video.VideoError.ILLEGAL_CUE_POINT, 'time must be number'); } var v3 = this.getNextCuePointIndexWithName(cuePoint.name, cuePoint.array, cuePoint.index); if (v3 < 0) { return null; } var v4 = mx.video.CuePointManager.deepCopyObject(cuePoint.array[v3]); v4.array = cuePoint.array; v4.index = v3; return v4; }; v1.deepCopyObject = function (obj, recurseLevel) { if (obj == undefined || obj == null || typeof obj != 'object') { return obj; } if (recurseLevel == undefined) { recurseLevel = 0; } var v2 = new Object(); for (var v4 in obj) { if (recurseLevel == 0 && (v4 == 'array' || v4 == 'index')) { } else { if (typeof obj[v4] == 'object') { v2[v4] = mx.video.CuePointManager.deepCopyObject(obj[v4], recurseLevel + 1); } else { v2[v4] = obj[v4]; } } } return v2; }; v1.DEFAULT_LINEAR_SEARCH_TOLERANCE = 50; v1.cuePointsReplace = ['&quot;', '"', '&#39;', '\'', '&#44;', ',', '&amp;', '&']; v2.addProperty('id', v2.__get__id, function () {}); v2.addProperty('metadataLoaded', v2.__get__metadataLoaded, function () {}); v2.addProperty('playheadUpdateInterval', function () {}, v2.__set__playheadUpdateInterval); ASSetPropFlags(mx.video.CuePointManager.prototype, null, 1); } #endinitclip } frame 2 { LC = new LocalConnection(); domain = LC.domain(); _root._thisDomain = domain; if (domain == 'shockwave.com' || domain == 'atom.com' || domain == 'atomfilms.com' || domain == 'kungfuelection.com' || domain == 'Mtvnservices.com' || domain == 'a1.akadl.mtvnservices.com' || domain == 'Flux.com') { gotoAndStop('firstload'); } else { stop(); } gotoAndStop('firstload'); } button 81 { on (keyPress 'p') { gotoAndStop('firstload'); } } frame 3 { _global.root = _root; stop(); onEnterFrame = function () { ifFrameLoaded (5) { gotoAndStop('start'); delete onEnterFrame; } }; } frame 3 { this.createEmptyMovieClip('testkeys', 100); testkeys.onEnterFrame = function () { if (keys == 'listeners') { if (listonce == undefined) { listonce = true; var v3 = new KeyEvents(); var v1 = new Object(); v1.onKeyDown = function () { if (Key.getCode() == 37) { leftkey = true; rightkey = false; } if (Key.getCode() == 39) { rightkey = true; leftkey = false; } if (Key.getCode() == 38) { upkey = true; } if (Key.getCode() == 40) { downkey = true; } if (Key.getCode() == 32) { spacekey = true; } if (Key.getCode() == 90) { zkey = true; } if (Key.getCode() == 88) { xkey = true; } if (Key.getCode() == 67) { ckey = true; } }; Key.addListener(v1); var v2 = new Object(); v2.onKeyUp = function () { if (Key.getCode() == 37) { leftkey = false; } if (Key.getCode() == 39) { rightkey = false; } if (Key.getCode() == 38) { upkey = false; } if (Key.getCode() == 40) { downkey = false; } if (Key.getCode() == 32) { spacekey = false; } if (Key.getCode() == 90) { zkey = false; } if (Key.getCode() == 88) { xkey = false; } if (Key.getCode() == 67) { ckey = false; } }; Key.addListener(v2); } } else { Key.removeListener(keyListener1); Key.removeListener(keyListener2); listonce = undefined; if (key != true) { if (Key.isDown(37)) { leftkey = true; } else { leftkey = false; } if (Key.isDown(39)) { rightkey = true; } else { rightkey = false; } if (Key.isDown(38)) { upkey = true; } else { upkey = false; } if (Key.isDown(40)) { downkey = true; } else { downkey = false; } if (Key.isDown(32)) { spacekey = true; } else { spacekey = false; } if (Key.isDown(90)) { zkey = true; } else { zkey = false; } if (Key.isDown(88)) { xkey = true; } else { xkey = false; } if (Key.isDown(67)) { ckey = true; } else { ckey = false; } } } }; } button 91 { on (release, keyPress '<Enter>') { if (_root.passwordit == 'clientsonly') { _root.gotoAndStop('start'); } else { if (_root.passwordit == 'client1') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client1.php', 0); } else { if (_root.passwordit == 'client2') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client2.php', 0); } else { if (_root.passwordit == 'client3') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client3.php', 0); } else { if (_root.passwordit == 'client4') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client4.php', 0); } else { if (_root.passwordit == 'client5') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client5.php', 0); } else { if (_root.passwordit == 'client6') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client6.php', 0); } else { if (_root.passwordit == 'client7') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client7.php', 0); } else { if (_root.passwordit == 'client8') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client8.php', 0); } else { if (_root.passwordit == 'client9') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client9.php', 0); } else { if (_root.passwordit == 'client10') { _root.gotoAndStop('start'); loadVariablesNum('count/count_client10.php', 0); } } } } } } } } } } } } } movieClip 101 { } instance of movieClip 101 { onClipEvent (load) { getver = /:$version; if (getver.substring(0, 1) == 'W') { loadMovie('', this); trace('Platform: PC'); } else { if (getver.substring(0, 1) == 'M') { trace('Platform: MAC'); } else { trace('Platform: UNKNOWN'); loadMovie('', this); } } } } button 102 { on (keyPress 'p') { _root.arena += 1; _root.match += 1; _root.fader.play(); _root.fader.dest = 'rank'; } } frame 5 { _global.root = _root; onEnterFrame = function () { ifFrameLoaded (7) { fader.play(); fader.dest = 'open'; delete onEnterFrame; } }; } movieClip 105 { } movieClip 108 { } movieClip 109 { frame 112 { gotoAndPlay('loop'); } } movieClip 116 { frame 1 { stop(); } frame 60 { _root.gotoAndStop(dest); } } frame 6 { skipbut.gotoAndStop(2); } frame 6 { var listenerObject = new Object(); listenerObject.cuePoint = function (eventObject) { trace('cue ' + eventObject.info.name); if (eventObject.info.name == 'start') { loader.gotoAndStop(2); my_FLVPlybk.volume = 70; trace('go'); } else { if (eventObject.info.name == 'startcheck1') { loader.gotoAndStop(2); my_FLVPlybk.volume = 70; } else { if (eventObject.info.name == 'startcheck2') { loader.gotoAndStop(2); my_FLVPlybk.volume = 70; } else { if (eventObject.info.name == 'startcheck3') { loader.gotoAndStop(2); my_FLVPlybk.volume = 70; } else { if (eventObject.info.name == 'end') { loader.gotoAndStop(3); my_FLVPlybk.pause(); trace('end'); } } } } } }; my_FLVPlybk.addEventListener('cuePoint', listenerObject); } button 119 { on (press) { _root.fader.play(); _root.fader.dest = 'open'; } } movieClip 121 { frame 1 { stop(); } } frame 7 { onEnterFrame = function () { ifFrameLoaded (15) { itsloaded = true; _root.playbut.gotoAndStop(2); } if (itsloaded != true) { _root.playbut.gotoAndStop(1); } }; } frame 7 { function dove(me, you) { _root[me + '_dovegrab'] = false; _root[me + '_grabbite'] = 0; _root[me + '_grabtime'] = 0; if (me == 'player') { var v3 = 9000; } else { var v3 = 9050; } md = 1; while (md <= 12) { doveserial = md; duplicateMovieClip(back.dove, 'dove' + doveserial, md + v3); back['dove' + doveserial].serial = doveserial; back['dove' + doveserial].wait = doveserial * 2; back['dove' + doveserial]._x = back[me]._x; back['dove' + doveserial]._y = back[me]._y - 250; back['dove' + doveserial].action = 'wait'; if (me == 'player') { back['dove' + doveserial].me = 'player'; back['dove' + doveserial].you = 'enemy'; } else { back['dove' + doveserial].me = 'enemy'; back['dove' + doveserial].you = 'player'; } ++md; } } function dove_fly(name, me, you) { if (name.defined == undefined) { name.lost = 0; name.defined = true; } if (name._name != 'dove') { trace(name._name + ' dove ' + name.action); } if (name._name == 'dove1') { } if (name._x > _root.back[you]._x) { name._xscale = 100; } else { name._xscale = -100; } if (name.action == 'fly') { name.dove_xdif = (name._x - _root.back[you]._x - _root.back[you].body['b' + name.serial]._x) / 7; name.dove_ydif = (name._y - _root.back[you]._y - _root.back[you].body['b' + name.serial]._y) / 7; if (_root[me + '_dovegrab'] == true) { name._x -= name.dove_xdif; name._y -= name.dove_ydif; } else { name.yspeed -= 2; name._x += name.xspeed; name._y += name.yspeed; } if (Math.abs(name.dove_xdif) < 4 & Math.abs(name.dove_ydif) < 4) { ++_root[me + '_dovebite']; name.action = 'grab'; } if (name._y < -500) { removeMovieClip(name); } if (_root.back[you].body['b' + name.serial] == undefined & _root[me + '_dovegrab'] == true) { trace('----------------------------------'); trace(name._name + ' lost dove'); trace(name.lost); trace(_root.back[you]._currentframe); trace(_root.back[you].body._currentframe); trace('----------------------------------'); ++name.lost; if (name.lost > 30) { removeMovieClip(name); } } } else { if (name.action == 'grab') { if (name.oncestop == undefined) { _root[you + '_xspeed'] = 0; } if (name._y < -500) { removeMovieClip(name); } name.nextFrame(); name._x = _root.back[you]._x - _root.back[you].body['b' + name.serial]._x; name._y = _root.back[you]._y + _root.back[you].body['b' + name.serial]._y; if (_root[me + '_dovebite'] >= 8 & _root[me + '_dovegrab'] == true) { if (name._name == 'dove1') { ++_root[me + '_grabtime']; if (_root[me + '_grabtime'] < 6) { _root.back[you].body.gotoAndPlay('up'); if (_root[you + '_yspeed'] > -2) { _root[you + '_yspeed'] = -4; } _root[you + '_yspeed'] += -0.03 - gravity; } else { _root[you + '_yspeed'] = -gravity / 2; } } if (back[you]._x < back[me]._x) { _root[you + '_xspeed'] += dis / 100000; } else { _root[you + '_xspeed'] -= dis / 100000; } } if (_root[me + '_grabtime'] > 150) { _root[you + '_action'] = 'stand'; name.ranx = random(80) - 40; _root.back['dove' + name.serial].action = 'flyaway'; } if (_root[you + '_action'] != 'doved') { name.ranx = random(80) - 40; _root.back['dove' + name.serial].action = 'flyaway'; } } else { if (name.action == 'flyaway') { name.gotoAndStop('in'); name._y -= 10; name._x += name.ranx; if (name._y < -1000) { removeMovieClip(name); } } else { if (name.action == 'wait') { --name.wait; name.yspeed = random(10) + 20; if (_root.back[me]._x < _root.back[you]._x) { name.xspeed = 33; } else { name.xspeed = -33; } if (name.wait <= 0) { name.play(); name.action = 'fly'; } } } } } } function damage(pain, victem) { if (match == 1) { player_energy_offset = 0.8; enemy_energy_offset = 1; } else { if (match == 2) { player_energy_offset = 0.85; enemy_energy_offset = 1; } else { if (match == 3) { player_energy_offset = 0.9; enemy_energy_offset = 1; } else { if (match == 4) { player_energy_offset = 0.95; enemy_energy_offset = 1; } else { if (match == 5) { player_energy_offset = 1; enemy_energy_offset = 1; } else { if (match == 6) { player_energy_offset = 1.1; enemy_energy_offset = 0.9; } else { if (match == 7) { player_energy_offset = 1.3; enemy_energy_offset = 0.7; } else { if (match == 8) { player_energy_offset = 1; enemy_energy_offset = 1; } else { if (match == 9) { player_energy_offset = 1; enemy_energy_offset = 1; } } } } } } } } } player_energy_offset += 0.6; enemy_energy_offset += 0.6; if (victem == 'player') { _root[victem + '_life'] -= int(pain * player_energy_offset); } else { if (victem == 'enemy') { _root[victem + '_life'] -= int(pain * enemy_energy_offset); } } } function blood(drops, distance, attacker, victem) { bd = 0; while (bd < drops) { ++bdn; ++totaldrops; duplicateMovieClip(back.blooddrop, 'blood' + bdn, bdn + 500); back['blood' + bdn]._x = back[victem]._x; if (back[attacker].body.hurt != undefined) { back['blood' + bdn]._y = back[victem]._y + back[attacker].body.hurt._y + back[attacker]._y - bot; } else { back['blood' + bdn]._y = back[victem]._y - back[victem]._height / 2; } var v1 = random(distance); back['blood' + bdn].xspeed = random(v1) - v1 / 2; back['blood' + bdn].yspeed = -random(distance) * 2; ++bd; } } function bloodmovement(name) { if (name._name != 'blooddrop' & name.defined == undefined) { name.botvar = random(25); name.fadecount = 0; name.fadeout = false; if (arena == 4) { name.botvar = 5; } name.defined = 'defined'; } name.xx = name._x + name.xspeed; name.yy = name._y + name.yspeed; name.yspeed += gravity; name._x += name.xspeed; if (name.yy < bot + name.botvar) { name._y += name.yspeed; name.x2 = name.xspeed; name.y2 = name.yspeed; if (name.x2 > 0) { name.baseangle = -90; name._xscale = 100; } else { if (x2 < 0) { name.baseangle = 90; name._xscale = -100; } } if (name.x2 > 0) { name.angleperc = name.y2 / name.x2; if (name.angleperc > 2) { name.angleperc = 2; } else { if (name.angleperc < -2) { name.angleperc = -2; } else {} } name._rotation = name.angleperc * 45 - 90; } else { if (name.x2 < 0) { name.x2 = -name.x2; name.angleperc = name.y2 / name.x2; if (name.angleperc > 2) { name.angleperc = 2; } else { if (name.angleperc < -2) { name.angleperc = -2; } else {} } name._rotation = name.angleperc * -45 + 90; } } } else { name.yspeed = 0; name.xspeed = 0; name.gotoAndStop('puddle'); name._rotation = 0; name.fadeout = true; } if (name.fadeout == true) { ++name.fadecount; if (name.fadecount > 60 or totaldrops > 30) { if (name._alpha > 40) { name._alpha -= 1; } } if (name._alpha < 50) { --totaldrops; removeMovieClip(name); } } } if (dif_level == undefined) { dif_level = 'hard'; } bdn = 0; } frame 7 { function character(me, you) { dis = Math.abs(back.player._x - back.enemy._x); _root[me + '_lunge'] = false; if (_root[me + '_life'] <= 0) { _root[me + '_action'] = 'fall'; } back[me].gotoAndStop(_root[me + '_action']); if (me == 'enemy') { if (enemy_action != 'fall' or enemy_action != 'smallflinch' or enemy_action != 'bigflinch') { ai(back.enemy); } } else {} if (_root[me + '_shorthitcounter'] > 0) { --_root[me + '_shorthitrundown']; if (_root[me + '_shorthitrundown'] <= 0) { _root[me + '_shorthitcounter'] = 0; } } _root[me + '_yy'] = back[me]._y + int(_root[me + '_yspeed']); if (_root[me + '_yy'] <= bot) { back[me]._y += _root[me + '_yspeed']; } else { if ([me + '_yspeed'] != 0) { back[me]._y = bot; _root[me + '_yspeed'] = 0; if (_root[me + '_jump'] == 'jumping') { _root[me + '_jump'] = 'notjumping'; back[me].body.walkdir = ''; if (_root[me + '_action'] != 'doved') { _root[me + '_action'] = 'stand'; } } } } _root[me + '_yspeed'] += gravity; if (D_delay > 0 & ckey == true) { --D_delay; } else { if (ckey == true == false) { D_delay = 0; } } if (_root[me + '_action'] == 'stand') { _root[me + '+hardspeedoveride'] = false; if (_root[me + '_oncereset'] == false) { back[me].gotoAndStop('stand'); back[me].body.walkdir = ''; _root[me + '_oncereset'] = true; } _root[me + '_jumpedyet'] = false; if (_root[me + '_xspeed'] > maxspeed) { _root[me + '_xspeed'] = maxspeed; } else { if (_root[me + '_xspeed'] < -maxspeed) { _root[me + '_xspeed'] = -maxspeed; } } if (me == 'player') { if (back[me].body.walkdir == 'b') { back[me].body.prevFrame(); } else { if (back[me].body.walkdir == 'f') { back[me].body.nextFrame(); } } if (back[me]._x < back[you]._x) { back[me]._xscale = 100; } else { if (back[me]._x > back[you]._x) { back[me]._xscale = -100; } } if (downkey == true) { back[me].body.walkdir = ''; _root[me + '_xspeed'] = 0; _root[me + '_action'] = 'duck'; } else { if (upkey == true & player_yy + gravity >= bot) { back[me].gotoAndStop('jump'); _root[me + '_action'] = 'jump'; } else { if (xkey == true) { _root[me + '_action'] = 'hard'; } else { if (fb_seq == true & back[me + '_fireball']._currentframe == 1 & _root[you + '_action'] != 'harpooned') { _root[me + '_oncereset'] = true; _root[me + '_action'] = 'fireball'; } else { if (ckey == true & D_delay <= 0) { _root[me + '_action'] = 'short'; } else { if (zkey == true) { _root[me + '_action'] = 'kick'; } else { if (spacekey == true) { _root[me + '_action'] = 'block'; } else { if (leftkey == true) { _root[me + '_xspeed'] -= 1; } else { if (rightkey == true) { _root[me + '_xspeed'] += 1; } else { _root[me + '_xspeed'] *= 0.7; if (Math.abs(_root[me + '_xspeed']) < 1) { _root[me + '_xspeed'] = 0; } } } } } } } } } } } else { if (me == 'enemy') { if (back.enemy.body.walkdir == 'b') { back.enemy.body.prevFrame(); } else { if (back.enemy.body.walkdir == 'f') { back.enemy.body.nextFrame(); } } if (enemy_xspeed <= -1) { if (back.enemy.body._currentframe == 1) { back.enemy.body.gotoAndStop('set'); } if (back.enemy._xscale == 100) { back.enemy.body.walkdir = 'b'; } else { if (back.enemy._xscale == -100) { back.enemy.body.walkdir = 'f'; } } } else { if (enemy_xspeed >= 1) { if (back.enemy.body._currentframe == 1) { back.enemy.body.gotoAndStop('set'); } if (back.enemy._xscale == 100) { back.enemy.body.walkdir = 'f'; } else { if (back.enemy._xscale == -100) { back.enemy.body.walkdir = 'b'; } } } else { if (back.enemy.body.walkdir != '') { back.enemy.body.gotoAndPlay('backtostance'); } back.enemy.body.walkdir = ''; } } } } if (_root[me + '_xspeed'] < -1) { if (back[me].body._currentframe == 1) { back[me].body.gotoAndStop('set'); } if (back[me]._xscale == 100) { back[me].body.walkdir = 'b'; } else { if (back[me]._xscale == -100) { back[me].body.walkdir = 'f'; } } } else { if (_root[me + '_xspeed'] > 1) { if (back[me].body._currentframe == 1) { back[me].body.gotoAndStop('set'); } if (back[me]._xscale == 100) { back[me].body.walkdir = 'f'; } else { if (back[me]._xscale == -100) { back[me].body.walkdir = 'b'; } } } else { if (back[me].body.walkdir != '') { back[me].body.gotoAndPlay('backtostance'); } back[me].body.walkdir = ''; } } } else { if (_root[me + '_action'] == 'jump') { back[me].body.walkdir = ''; if (_root[me + '_jumpedyet'] != true) { _root[me + '_yspeed'] -= jump; _root[me + '_jump'] = 'jumping'; _root[me + '_jumpedyet'] = true; if (back[me]._xscale == 100) { if (_root[me + '_xspeed'] >= 0) { back[me].body.gotoAndPlay('for'); } else { if (_root[me + '_xspeed'] < 0) { back[me].body.gotoAndPlay('back'); } } } else { if (back[me]._xscale == -100) { if (_root[me + '_xspeed'] <= 0) { back[me].body.gotoAndPlay('for'); } else { if (_root[me + '_xspeed'] > 0) { back[me].body.gotoAndPlay('back'); } } } } } if (xkey == true or ckey == true or zkey == true) { _root[me + '_action'] = 'jumpkick'; } if (me == 'player') { if (leftkey == true) { _root[me + '_xspeed'] = -maxspeed * 2; } else { if (rightkey == true) { _root[me + '_xspeed'] = maxspeed * 2; } } } } else { if (_root[me + '_action'] == 'jumpkick') { ++jkcount; if (back[me].body.hurt.hitTest(back[you].body.hit) & _root[you + '_action'] != 'blocking') { if (Math.abs(_root[me + '_xspeed']) > 13) { damage(20, you); blood(4, 40, me, you); _root.snd.genhit.play(); _root[you + '_action'] = 'fall'; _root[you + '_yspeed'] = -15; if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -_root[me + '_xspeed']; } else { _root[you + '_xspeed'] = _root[me + '_xspeed']; } } else { damage(10, you); blood(4, 10, me, you); _root[you + '_action'] = 'smallflinch'; if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -50; } else { _root[you + '_xspeed'] = 50; } } } else { if (back[me].body.hurt.hitTest(back[you].body.block)) { _root.snd.block.play(); _root[me + '_xspeed'] = 0; if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -20; } else { _root[you + '_xspeed'] = 20; } } } } else { if (_root[me + '_action'] == 'duck') { _root[me + '_oncereset'] = false; _root[me + '_xspeed'] = 0; if (me == 'player') { if (back[me]._x < back[you]._x) { back[me]._xscale = 100; } else { if (back[me]._x > back[you]._x) { back[me]._xscale = -100; } } if (xkey == true) { _root[me + '_action'] = 'uppercut'; } else { if (zkey == true) { _root[me + '_action'] = 'uppercut'; } else { if (ckey == true) { _root[me + '_action'] = 'uppercut'; } else { if (downkey == true) { _root[me + '_action'] = 'duck'; back[me].body.nextFrame(); } else { back[me].body.prevFrame(); if (back[me].body._currentframe == 1) { _root[me + '_action'] = 'stand'; } } } } } } } else { if (_root[me + '_action'] == 'uppercut') { if (me == 'player' & enemy_nouppercut > 0) { if (back[me].body.hurt.hitTest(back[you].body.hit) or back[me].body.hurt.hitTest(back[you].body.block)) { trace('uppercut false blocker'); _root.snd.block.play(); if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -20; _root[me + '_xspeed'] = 20; } else { _root[you + '_xspeed'] = 20; _root[me + '_xspeed'] = -20; } } } else { if (player_lunge == true & me == 'enemy') { if (back[me].body.lungehit.hitTest(back[you].body.hit)) { trace('lunge hit'); _root.snd.hard.play(); _root.snd.scream.gotoAndPlay('scream' + _root[you + '_fbnum']); _root[you + '_yspeed'] = -30; if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -8; } else { _root[you + '_xspeed'] = 8; } damage(20, you); blood(30, 30, me, you); _root[you + '_action'] = 'fall'; } } if (back[me].body.hurt.hitTest(back[you].body.hit)) { _root.snd.hard.play(); _root.snd.scream.gotoAndPlay('scream' + _root[you + '_fbnum']); _root[you + '_yspeed'] = -60; if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -6; } else { _root[you + '_xspeed'] = 6; } damage(20, you); blood(30, 30, me, you); _root[you + '_action'] = 'fall'; } else { if (back[me].body.hurt.hitTest(back[you].body.block)) { _root.snd.block.play(); if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -20; _root[me + '_xspeed'] = 20; } else { _root[you + '_xspeed'] = 20; _root[me + '_xspeed'] = -20; } } } } if (back[me].body._currentframe == back[me].body._totalframes) { _root[me + '_action'] = 'duck'; } } else { if (_root[me + '_action'] == 'kick') { if (_root[me + '_oncereset'] == true) { _root[me + '_xspeed'] = 0; _root[me + '_oncereset'] = false; } _root[me + '_xspeed'] *= 0.7; if (back[me].body.hurt.hitTest(back[you].body.hit) & _root[you + '_action'] != 'fall' & enemy_nokick == 0) { if (you == 'enemy') { turn_off_kick = true; } _root[you + '_action'] = 'smallflinch'; _root.snd.genhit.play(); damage(20, you); blood(4, 32, me, you); kick1 = true; } else { if (back[me].body.hurt2.hitTest(back[you].body.hit) & _root[you + '_action'] != 'fall' & enemy_nokick == 0) { _root.snd.genhit.play(); if (you == 'enemy') { turn_off_kick = true; } if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -60; } else { _root[you + '_xspeed'] = 60; } _root[you + '_action'] = 'bigflinch'; damage(20, you); blood(4, 32, me, you); } else { if (back[me].body.hurt.hitTest(back[you].body.block) or enemy_nokick > 0 & back[me].body.hurt2.hitTest(back[you].body.hit) or enemy_nokick > 0 & back[me].body.hurt.hitTest(back[you].body.hit)) { _root.snd.block.play(); if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -20; _root[me + '_xspeed'] = 20; } else { _root[you + '_xspeed'] = 20; _root[me + '_xspeed'] = -20; } } } } if (back[me].body._currentframe == back[me].body._totalframes) { if (turn_off_kick == true & me == 'player') { enemy_nokick = 40; } _root[me + '_action'] = 'stand'; } } else { if (_root[me + '_action'] == 'short') { if (_root[me + '_oncereset'] == true) { if (me == 'player' & fb_seq == true) { if (_root.back.jail != undefined & _root[me + '_fbnum'] == 5) { _root[me + '_xspeed'] = 0; _root[me + '_oncereset'] = false; } else { _root[me + '_oncereset'] = true; player_action = 'fireball'; } } else { _root[me + '_xspeed'] = 0; _root[me + '_oncereset'] = false; } } D_delay = 3; _root[me + '_xspeed'] *= 0.7; if (back[me].body.punch == 'done') { _root[me + '_action'] = 'stand'; } if (back[me].body.hurt.hitTest(back[you].body.hit) & _root[you + '_action'] != 'smallflinch' & _root[you + '_action'] != 'bigflinch' & _root[you + '_action'] != 'fall') { damage(12, you); blood(4, 20, me, you); if (me == 'player') { short_add_dif += 3; } _root.snd.soft.play(); if (_root[me + '_shorthitcounter'] < 5) { _root[you + '_action'] = 'smallflinch'; ++_root[me + '_shorthitcounter']; _root[me + '_shorthitrundown'] = 90; } else { _root[me + 'shorthitcounter'] = 0; _root[me + '_shorthitrundown'] = 0; _root[you + '_action'] = 'fall'; } } else { if (back[me].body.hurt.hitTest(back[you].body.block)) { _root.snd.block.play(); if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -20; _root[me + '_xspeed'] = 20; } else { _root[you + '_xspeed'] = 20; _root[me + '_xspeed'] = -20; } } } } else { if (_root[me + '_action'] == 'hard') { _root[me + '_oncereset'] = false; if (me == 'player') { if (rightkey == true or leftkey == true) { player_lunge = true; } else { player_lunge = false; } if (rightkey == true & back.player._xscale == 100 & player_xspeed < 20) { player_lunge = true; if (_root[me + '+hardspeedoveride'] != true) { player_xspeed = 20; } } else { if (leftkey == true & back.player._xscale == -100 & player_xspeed > -20) { player_lunge = true; if (_root[me + '+hardspeedoveride'] != true) { player_xspeed = -20; } } } } _root[me + '_xspeed'] *= 0.9; if (back[me].body._currentframe == back[me].body._totalframes) { player_lunge = false; _root[me + '_action'] = 'stand'; } if (back[me].body.hurt.hitTest(back[you].body.hit) & _root[you + '_action'] != 'smallflinch' & _root[you + '_action'] != 'bigflinch' & _root[you + '_action'] != 'fall') { _root.snd.hard.play(); _root.snd.scream.gotoAndPlay('scream' + _root[you + '_fbnum']); if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -60; } else { _root[you + '_xspeed'] = 60; } _root[you + '_action'] = 'bigflinch'; damage(40, you); blood(8, 30, me, you); } else { if (back[me].body.hurt.hitTest(back[you].body.block)) { _root.snd.block.play(); if (back[you]._xscale == 100) { _root[you + '_xspeed'] = -20; _root[me + '_xspeed'] = 10; } else { _root[you + '_xspeed'] = 20; _root[me + '_xspeed'] = -10; } } } } else { if (_root[me + '_action'] == 'fireball') { if (_root[me + '_oncereset'] == true) { _root[me + '_oncereset'] = false; } if (back[me].body.shoot == true) { back[me].body.shoot = false; ++fbsn; _root.snd2.gotoAndPlay('fireball' + _root[me + '_fbnum']); trace('FBNUM ' + _root[me + '_fbnum']); back.attachMovie('fireball' + _root[me + '_fbnum'], 'fb' + fbsn, 100 + fbsn); back['fb' + fbsn]._xscale = back[me]._xscale; back['fb' + fbsn]._y = back[me]._y - 170; back['fb' + fbsn].me = me; back['fb' + fbsn].you = you; if (back['fb' + fbsn]._xscale == 100) { back['fb' + fbsn]._x = back[me]._x + 150; } else { if (back['fb' + fbsn]._xscale == -100) { back['fb' + fbsn]._x = back[me]._x - 150; } } back['fb' + fbsn].targ = you; } _root[me + '_xspeed'] = 0; if (back[me].body._currentframe == back[me].body._totalframes) { _root[me + '_action'] = 'stand'; } } else { if (_root[me + '_action'] == 'smallflinch') { if (_root[me + '_oncereset'] == true) { back[me].gotoAndStop('smallflinch'); _root[me + '_oncereset'] = false; } if (_root[me + '_jump'] == 'jumping') { _root[me + '_action'] = 'fall'; } if (me == 'player') { if (upkey == true & player_yy + gravity >= bot) { back[me].gotoAndStop('jump'); _root[me + '_action'] = 'jump'; } else { if (spacekey == true) { _root[me + '_action'] = 'block'; } } } _root[me + '_xspeed'] *= 0.7; if (Math.abs(_root[me + '_xspeed']) < 1) { _root[me + '_xspeed'] = 0; } if (back[me].body._currentframe == back[me].body._totalframes) { _root[me + '_action'] = 'stand'; } } else { if (_root[me + '_action'] == 'bigflinch') { if (_root[me + '_oncereset'] == true) { back[me].gotoAndStop('smallflinch'); _root[me + '_oncereset'] = false; } if (_root[me + '_jump'] == 'jumping') { _root[me + '_action'] = 'fall'; } if (me == 'player') { if (upkey == true & player_yy + gravity >= bot & player.body._currentframe >= 33) { back[me].gotoAndStop('jump'); _root[me + '_action'] = 'jump'; } } _root[me + '_xspeed'] *= 0.7; if (Math.abs(_root[me + '_xspeed']) < 1) { _root[me + '_xspeed'] = 0; } if (back[me].body._currentframe == back[me].body._totalframes) { _root[me + '_action'] = 'stand'; } } else { if (_root[me + '_action'] == 'fall') { _root[me + '_jump'] = 'notjumping'; if (back[me].body.fallstatus == undefined) { if (_root[me + '_yy'] >= bot) { _root[me + '_xspeed'] = 0; back[me].body.fallstatus = 'ground'; } } else { if (back[me].body.fallstatus == 'deathtest' & _root[me + '_life'] <= 0) { back[me].body.stop(); if (_root[you + '_action'] == 'stand' or _root[you + '_action'] == 'duck') { _root[you + '_action'] = 'stand'; _root[you + '_xspeed'] = 0; back[you].gotoAndStop('stand'); back[you].body.gotoAndStop(1); action = 'roundover'; } } else { if (back[me].body._currentframe == back[me].body._totalframes) { if (me == 'enemy') { enemy_nouppercut = 30; } back[me].body.fallstatus = undefined; if (me == 'enemy' & player_action == 'fireball') { trace('fireball on get up'); unblock = false; enemy_action = 'block'; aia = -2; enemy.gotoAndStop('block'); } else { _root[me + '_action'] = 'stand'; } } } } } else { if (_root[me + '_action'] == 'block') { if (_root[me + '_oncereset'] == true) { _root[me + '_xspeed'] = 0; _root[me + '_oncereset'] = false; } _root[me + '_xspeed'] *= 0.9; if (me == 'player') { if (spacekey == true) { _root[me + '_action'] = 'block'; back[me].body.nextFrame(); } else { back[me].body.prevFrame(); if (back[me].body._currentframe == 1) { _root[me + '_action'] = 'stand'; } } } } else { if (_root[me + '_action'] == 'harpooned') { _root[me + '_xspeed'] = 0; back[me].gotoAndStop('harpooned'); if (back[me].body._currentframe == back[me].body._totalframes) { _root[me + '_action'] = 'stand'; } } } } } } } } } } } } } } } } if (set_up_variables == undefined) { gravity = 2.4; maxspeed = 7; walkspeed = 1; player_xspeed = 0; player_yspeed = 0; enemy_xspeed = 0; enemy_yspeed = 0; jump = 36; bot = 425; set_up_variables = 'defined'; D_delay = 0; player_oncereset = true; enemy_oncereset = true; player_shorthitcounter = 0; enemy_shorthitcounter = 0; player_shorthitrundown = 0; enemy_shorthitrundown = 0; fbsn = 0; } } frame 7 { function fireballcode1(name) { if (name.defined == undefined) { if (name._xscale == 100) { name.xspeed = 33; } else { name.xspeed = -33; } name.action = 'fly'; name.fireballid = true; name.defined = true; } if (name.action == 'fly') { name._x += name.xspeed; if (name._x < -100 or name._x > 2100) { removeMovieClip(name); } if (name.targ == 'player') { name.from = 'enemy'; } else { name.from = 'player'; } if (name.grab.hitTest(back[name.targ].body.hit) & root[name.targ + '_action'] != 'fall' & root[name.targ + '_action'] != 'bigflinch' & root[name.targ + '_action'] != 'block') { if (name.turnoff != true) { fireballhit += _root.fireballhit_uplev; root[name.targ + '_action'] = 'harpooned'; name.gotoAndStop('grab'); name.action = 'grab'; } else { name.turnoff = true; } } else { if (name.hitTest(back[name.targ].body.block)) { root[name.targ + '_xspeed'] = name.xspeed / 2; name.action = 'dead'; } } } else { if (name.action == 'grab') { _root[name.targ + '_yspeed'] = 0; if (name.blood == true) { name.blood = false; if (name.targ == 'enemy') { name.attacker = 'player'; } else { name.attacker = 'enemy'; } blood(6, 20, name.attacker, name.targ); root.back[name.targ].body.gotoAndPlay('flinch'); } if (name._xscale == 100) { _root.back[name.targ]._x = name._x + 130 - billdisx; } else { _root.back[name.targ]._x = name._x - 130 + billdisx; } _root.back[name.targ]._y = bot - 40; if (name.bill.donehitting == true) { root[name.targ + '_action'] = 'fall'; name.action = 'dead'; if (name._xscale == 100) { root[name.targ + '_xspeed'] = 40; root[name.targ + '_yspeed'] = -20; } else { root[name.targ + '_xspeed'] = -40; root[name.targ + '_yspeed'] = -20; } _root.snd.scream.gotoAndPlay('scream' + _root[_root[name.targ] + '_charnum']); damage(20, name.targ); blood(30, 30, back[name.from], back[name.targ]); _root.snd.scream.gotoAndPlay('scream' + _root[name.targ + '_fbnum']); } } else { if (name.action == 'dead') { name.gotoAndPlay('out'); name.action = 'waitdead'; } else { if (name.action == 'eject') { removeMovieClip(name); } } } } } } frame 7 { function fireballcode5(name) { if (name.defined == undefined) { name.count = 0; name.unloadcount = 0; if (name._xscale == 100) { name.xspeed = 25; } else { name.xspeed = -25; } name.action = 'fly'; name.fireballid = true; name.defined = true; } if (name.count > 1 & name.head1.action == undefined) { name.head1.action = 'fly'; } else { if (name.count > 8 & name.head2.action == undefined) { name.head2.action = 'fly'; } else { if (name.count > 16 & name.head3.action == undefined) { name.head3.action = 'fly'; } } } ++name.count; if (name.head1.action == 'dead' & name.head2.action == 'dead' & name.head3.action == 'dead') { ++name.unloadcount; if (name.unloadcount > 30) { removeMovieClip(name); } } if (name.jail == true & back.jail == undefined & name.jailonce == undefined) { _root.snd.gotojail.play(); name.jailonce = true; ++fbsn; back.attachMovie('jail', 'jail', 100 + fbsn); back.jail._x = back[name.targ]._x; back.jail._y = bot; back.jail.targ = name.targ; _root[name.targ + '_action'] = 'harpooned'; _root.back[name.targ].gotoAndStop('harpooned'); _root.back[name.targ].body.gotoAndStop('jail'); } } function fireballcodebiden(name) { if (name.defined == undefined) { name.count = 0; name.unloadcount = 0; if (name._xscale == 100) { name.xspeed = 25; } else { name.xspeed = -25; } name.action = 'fly'; name.fireballid = true; name.defined = true; } trace(name._name + ' _ ' + name.count); if (name.count > 1 & name.head1.action == undefined) { name.head1.action = 'fly'; } else { if (name.count > 8 & name.head2.action == undefined) { name.head2.action = 'fly'; } else { if (name.count > 16 & name.head3.action == undefined) { name.head3.action = 'fly'; } } } ++name.count; if (name.head1.action == 'dead' & name.head2.action == 'dead' & name.head3.action == 'dead') { ++name.unloadcount; if (name.unloadcount > 30) { removeMovieClip(name); } } } function ghead(name) { if (name.defined == undefined) { name.yspeed = random(20) - 10; name.targ = name._parent.targ; name.defined = true; } if (name._x < -1000 or name._x > 1000) { name.gotoAndStop('off'); name.action = 'dead'; } if (name.action == 'fly') { if (name._currentframe == 1) { name.play(); } name._x += 33; name._y += name.yspeed; } else { if (name.action == 'dead') { } } if (name.hitTest(_root.back[name.targ].body.hit)) { fireballhit += _root.fireballhit_uplev; name.gotoAndStop('dead'); name.action = 'dead'; name._parent.jail = true; } else { if (name.hitTest(_root.back[name.targ].body.block)) { name.gotoAndStop('dead'); name.action = 'dead'; } } } function bfoot(name) { if (name.defined == undefined) { name.yspeed = random(10); name.targ = name._parent.targ; name.defined = true; } trace(name.action); if (name._x < -1000 or name._x > 1000) { name.gotoAndStop('off'); name.action = 'dead'; } if (name.action == 'fly') { if (name._currentframe == 1) { name.play(); } name._x += 33; name._y += name.yspeed; } else { if (name.action == 'dead') { } } if (name.hitTest(_root.back[name.targ].body.hit)) { fireballhit += _root.fireballhit_uplev; name.gotoAndStop('dead'); name.action = 'dead'; _root[name.targ + '_action'] = 'fall'; _root.back[name.targ].gotoAndStop('fall'); _root[name.targ + '_xspeed'] = (_root.back[name.me]._x - _root.back[name.you]._x) / 15; _root[name.targ + '_yspeed'] = -60; } else { if (name.hitTest(_root.back[name.targ].body.block)) { name.gotoAndStop('dead'); name.action = 'dead'; } } } function jailcode(name) { if (name.defined == undefined) { name.savex = back[name.targ]._x; name.defined = true; } if (_root[name.targ + '_action'] == 'harpooned') { back[name.targ]._x = name.savex; name._x = name.savex; } if (name.harpoonit != true) { _root[name.targ + '_action'] = 'harpooned'; _root.back[name.targ].body.gotoAndStop('jail'); } if (_root[name.targ + '_action'] != 'harpooned' & name.reached != true) { name.gotoAndPlay('out'); } if (name._currentframe == name._totalframes) { removeMovieClip(name); } } } frame 7 { function fireballcode2(name) { if (name.defined == undefined) { if (name._xscale == 100) { name.xspeed = 24; } else { name.xspeed = -24; } name.action = 'fly'; name.fireballid = true; name.defined = true; } if (name.action == 'fly') { name._x += name.xspeed; if (name._x < -100 or name._x > 2100) { removeMovieClip(name); } } } function fireballcode3(name) { if (name.defined == undefined) { if (name._xscale == 100) { name.xspeed = 31; } else { name.xspeed = -31; } name.action = 'fly'; name.fireballid = true; name.defined = true; } if (name.action == 'fly') { name._x += name.xspeed; if (name.hitTest(_root.back[name.targ].body.hit)) { fireballhit += _root.fireballhit_uplev; name.gotoAndPlay('dead'); name.action = 'dead'; _root[name.you + '_action'] = 'harpooned'; _root.back[name.you].gotoAndStop('harpooned'); _root.back[name.you].body.gotoAndStop('ice'); } else { if (name.hitTest(_root.back[name.targ].body.block)) { name.action = 'dead'; name.gotoAndPlay('dead'); } } if (name._x < -100 or name._x > 2100) { removeMovieClip(name); } } else { if (name.action == 'unload') { trace('iceunload'); removeMovieClip(name); } } } function fireballcode4(name) { if (name.defined == undefined) { shakecount = 0; if (name._xscale == 100) { name.xspeed = 31; } else { name.xspeed = -31; } name.action = 'fly'; name.fireballid = true; name.defined = true; } if (name.action == 'fly') { name._x += name.xspeed; if (name.hitTest(_root.back[name.targ].body.hit)) { fireballhit += _root.fireballhit_uplev; name.gotoAndPlay('dead'); name.action = 'dead'; _root[name.you + '_action'] = 'fall'; _root.back[name.you].gotoAndStop('fall'); _root[name.you + '_xspeed'] = (_root.back[name.me]._x - _root.back[name.you]._x) / 15; _root[name.you + '_yspeed'] = -60; } else { if (name.hitTest(_root.back[name.targ].body.block)) { name.action = 'dead'; name.gotoAndPlay('dead'); } } if (name._x < -100 or name._x > 2100) { removeMovieClip(name); } } else { if (name.action == 'unload') { trace('iceunload'); removeMovieClip(name); } } } } movieClip 129 { } movieClip 130 { } movieClip 134 { } movieClip 137 { } movieClip 139 { } button 140 { on (press) { _root.fader.play(); _root.fader.dest = 'select'; } } movieClip 141 { frame 1 { stop(); } } movieClip 142 { frame 1 { stop(); } instance of movieClip 130 { onClipEvent (enterFrame) { loadedbytes = _root.getBytesLoaded(); totalbytes = _root.getBytesTotal(); loadedkbytes = Math.ceil(loadedbytes / 1000); totalkbytes = Math.ceil(totalbytes / 1000); _root.frame = int(loadedbytes / (totalbytes / 100)); if (_root.frame > 100) { _root.frame = 100; } this.gotoAndStop(_root.frame); } } frame 2 { stop(); } instance of movieClip 141 { onClipEvent (enterFrame) { if (this.hitTest(_root._xmouse, _root._ymouse, true)) { this.nextFrame(); } else { this.prevFrame(); } } } } instance playbut of movieClip 142 { } button 145 { on (release) { getURL('http://www.playgames.to', '_blank'); } } movieClip 146 { } movieClip 149 { } movieClip 151 { } button 153 { on (release) { getURL('http://www.playgames.to', '_blank'); } } movieClip 156 { frame 41 { stop(); } } frame 8 { stop(); _quality = 'medium'; _root.player_charnum = 2; ropeframe = undefined; match = 1; score = 0; if (arena == undefined) { arena = 1; } training = true; musicvol = 'on'; } movieClip 166 { frame 1 { stop(); onEnterFrame = function () { if (this.hitTest(_root._xmouse, _root._ymouse, true)) { this.nextFrame(); this.nextFrame(); this.nextFrame(); } else { this.prevFrame(); } }; } } button 169 { on (press) { gotoAndStop(2); } } movieClip 175 { } movieClip 176 { } button 179 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 7; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(2); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 180 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 2; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(1); char._alpha = 0; } } on (press) { picked = true; pick(); } } movieClip 181 { frame 1 { stop(); } frame 44 { _root.fader.play(); _root.fader.dest = 'game'; } } button 182 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 11; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(1); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 183 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 12; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(2); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 184 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 13; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(1); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 185 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 14; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(2); char._alpha = 0; } } on (press) { picked = true; pick(); } } movieClip 199 { } movieClip 226 { frame 44 { gotoAndPlay('stanceloop'); } } movieClip 227 { } movieClip 228 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 253 { frame 48 { gotoAndPlay('stanceloop'); } } movieClip 254 { } movieClip 255 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 260 { } movieClip 261 { } movieClip 262 { instance chuck of movieClip 261 { onClipEvent (enterFrame) { if (_root.ropeframe != undefined) { gotoAndPlay(_root.ropeframe); } else { play(); } } } } movieClip 283 { frame 44 { gotoAndPlay('stanceloop'); } } movieClip 284 { } movieClip 285 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 316 { } movieClip 317 { } movieClip 318 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 342 { frame 25 { gotoAndPlay('stanceloop'); } } movieClip 343 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 346 { } movieClip 347 { instance of movieClip 346 { onClipEvent (enterFrame) { gotoAndPlay(_root.ropeframe); } } } movieClip 375 { frame 44 { gotoAndPlay('stanceloop'); } } movieClip 376 { } movieClip 377 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 406 { } movieClip 407 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 410 { } movieClip 433 { frame 33 { gotoAndPlay('stanceloop'); } } movieClip 434 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 461 { frame 44 { gotoAndPlay('stanceloop'); } } movieClip 462 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 483 { frame 44 { gotoAndPlay('stanceloop'); } } movieClip 510 { frame 48 { gotoAndPlay('stanceloop'); } } movieClip 538 { } movieClip 539 { frame 1 { stop(); } } movieClip 541 { instance of movieClip 539 { onClipEvent (enterFrame) { this.gotoAndStop(_root.player_charnum); } } frame 2 { stop(); } } movieClip 544 { frame 1 { stop(); } } movieClip 545 { frame 13 { stop(); } } button 549 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 5; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(2); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 550 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 6; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(2); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 551 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 8; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(2); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 552 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 1; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(1); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 553 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 3; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(1); char._alpha = 0; } } on (press) { picked = true; pick(); } } button 554 { on (rollOver) { if (_root.fader._currentframe == 1 & picked != true) { _root.player_charnum = 4; lightup.gotoAndPlay(1); lightup.col.gotoAndStop(1); char._alpha = 0; } } on (press) { picked = true; pick(); } } movieClip 556 { frame 1 { function pick() { _root.callname.gotoAndStop(_root.player_charnum + 1); waitit.play(); if (_root.player_charnum == 1) { getURL('javascript:sendLink("KungFu-clinton")', ''); } else { if (_root.player_charnum == 2) { getURL('javascript:sendLink("KungFu-obama")', ''); } else { if (_root.player_charnum == 3) { getURL('javascript:sendLink("KungFu-edwards")', ''); } else { if (_root.player_charnum == 4) { getURL('javascript:sendLink("KungFu-richardson")', ''); } else { if (_root.player_charnum == 5) { getURL('javascript:sendLink("KungFu-giuliani")', ''); } else { if (_root.player_charnum == 6) { getURL('javascript:sendLink("KungFu-huckabee")', ''); } else { if (_root.player_charnum == 7) { getURL('javascript:sendLink("KungFu-mccain")', ''); } else { if (_root.player_charnum == 8) { getURL('javascript:sendLink("KungFu-romney")', ''); } } } } } } } } } stop(); } instance char of movieClip 541 { onClipEvent (enterFrame) { if (this._alpha < 100) { this._alpha += 5; } } onClipEvent (load) { this.gotoAndStop(2); } } } movieClip 569 { frame 1 { stop(); } frame 3 { trace('ob'); } } frame 9 { training = false; if (player_charnum == 1) { match1 = 14; match2 = 12; match3 = 2; match4 = 7; match5 = 10; } if (player_charnum == 2) { match1 = 14; match2 = 12; match3 = 5; match4 = 7; match5 = 10; } if (player_charnum == 3) { match1 = 14; match2 = 12; match3 = 5; match4 = 7; match5 = 10; } if (player_charnum == 4) { match1 = 12; match2 = 14; match3 = 5; match4 = 7; match5 = 10; } if (player_charnum == 5) { match1 = 13; match2 = 11; match3 = 1; match4 = 2; match5 = 10; } if (player_charnum == 6) { match1 = 13; match2 = 11; match3 = 1; match4 = 2; match5 = 10; } if (player_charnum == 7) { match1 = 13; match2 = 11; match3 = 1; match4 = 2; match5 = 10; } if (player_charnum == 8) { match1 = 13; match2 = 11; match3 = 1; match4 = 2; match5 = 10; } if (player_charnum == 11) { match1 = 12; match2 = 14; match3 = 5; match4 = 7; match5 = 10; } if (player_charnum == 12) { match1 = 11; match2 = 13; match3 = 1; match4 = 2; match5 = 10; } if (player_charnum == 13) { match1 = 14; match2 = 12; match3 = 5; match4 = 7; match5 = 10; } if (player_charnum == 14) { match1 = 11; match2 = 13; match3 = 1; match4 = 2; match5 = 10; } } frame 9 { _root.difficulty += 15; _root.roundnum = 1; if (nextround == true) { nextround = false; ++_root.match; ++_root.arena; ++_root.wins; } if (arena > 6) { arena = 1; } if (_root.match > 5) { nextFrame(); } player_roundswon = 0; enemy_roundswon = 0; } movieClip 578 { frame 1 { stop(); } } movieClip 601 { } movieClip 610 { frame 1 { stop(); } } movieClip 611 { frame 1 { waittime = 0; reachcount = 0; stop(); e1.gotoAndStop(_root.match1); e2.gotoAndStop(_root.match2); e3.gotoAndStop(_root.match3); e4.gotoAndStop(_root.match4); e5.gotoAndStop(_root.match5); e6.gotoAndStop(_root.match6); e7.gotoAndStop(_root.match7); e8.gotoAndStop(_root.match8); onEnterFrame = function () { playerbox.gotoAndStop(_root.player_charnum); playerbox.blinker.play(); ++waittime; if (played != true & waittime > 90) { played = true; this.play(); } else { if (played != true & _root.skey == true) { played = true; this.play(); } else { if (played != true & _root.zkey == true) { played = true; this.play(); } else { if (played != true & _root.xkey == true) { played = true; this.play(); } else { if (played != true & _root.ckey == true) { played = true; this.play(); } } } } } if (reached == true) { ++reachcount; if (reachcount > 30 or skey == true or zkey == true or xkey == true or ckey == true) { _root.fader.play(); _root.fader.dest = 'game'; _root.action = 'setcharacters'; } } }; this.gotoAndStop('p' + (_root.match - 1)); } frame 29 { stop(); reached = true; } frame 59 { stop(); reached = true; } frame 89 { stop(); reached = true; } frame 119 { stop(); reached = true; } frame 149 { stop(); reached = true; } frame 179 { stop(); reached = true; } frame 209 { stop(); reached = true; } frame 239 { stop(); reached = true; } frame 269 { stop(); reached = true; } } instance of movieClip 611 { onClipEvent (load) { addit = 0; } onClipEvent (enterFrame) { addit += 1; if (addit == 20) { stopAllSounds(); _root.gong.play(); } } } movieClip 612 { frame 1 { stop(); } } frame 10 { stopAllSounds(); } instance char of movieClip 541 { onClipEvent (enterFrame) { this.gotoAndStop(_root.player_charnum); } } movieClip 627 { frame 1 { stop(); } } movieClip 628 { instance of movieClip 627 { onClipEvent (enterFrame) { this.gotoAndStop(_root.player_charnum); } } } button 630 { on (press) { _root.fader.play(); _root.fader.dest = 'open'; } } movieClip 635 { frame 1 { stop(); } } instance of movieClip 635 { onClipEvent (enterFrame) { if (_root.player_charnum == 1) { this.gotoAndStop(2); } } } movieClip 638 { frame 1 { stop(); } } instance of movieClip 638 { onClipEvent (enterFrame) { if (_root.player_charnum == 3) { this.gotoAndStop(2); } } } movieClip 640 { frame 1 { stop(); } } instance of movieClip 640 { onClipEvent (enterFrame) { if (_root.player_charnum == 6) { this.gotoAndStop(2); } } } movieClip 643 { frame 1 { stop(); } } instance of movieClip 643 { onClipEvent (enterFrame) { if (_root.player_charnum == 7) { this.gotoAndStop(2); } } } movieClip 646 { frame 1 { stop(); } } instance of movieClip 646 { onClipEvent (enterFrame) { if (_root.player_charnum == 5) { this.gotoAndStop(2); } } } movieClip 649 { frame 1 { stop(); } } instance of movieClip 649 { onClipEvent (enterFrame) { if (_root.player_charnum == 2) { this.gotoAndStop(2); } } } movieClip 652 { frame 1 { stop(); } } instance of movieClip 652 { onClipEvent (enterFrame) { if (_root.player_charnum == 4) { this.gotoAndStop(2); } } } movieClip 655 { frame 1 { stop(); } } instance of movieClip 655 { onClipEvent (enterFrame) { if (_root.player_charnum == 8) { this.gotoAndStop(2); } } } button 663 { on (release) { _root.fader.play(); _root.fader.dest = 'open'; } } button 666 { on (release) { _root.fader.play(); _root.fader.dest = 'open'; } } frame 12 { var jkcount = 0; if (training == true) { gotoAndStop('training'); } else { if (match == 5) { arena = 4; } gotoAndStop('load' + arena); } } frame 12 { function beginfight() { action = 'setcharacters'; trace('begin fight'); ready.play(); maxlife = 500; wins = 0; player_roundswon = 0; enemy_roundswon = 0; roundnum = 1; ropeframe = 1; } function fix_stand() { if (player_life <= 0) { if (enemy_action == 'duck' or enemy_action == 'stand' or enemy_action == 'jump' or enemy_action == 'block' or enemy_action == 'short') { back.enemy.gotoAndStop('stand'); back.enemy.body.gotoAndStop(1); } } else { if (enemy_life <= 0) { if (player_action == 'duck' or player_action == 'stand' or player_action == 'jump' or enemy_action == 'block' or enemy_action == 'short') { back.player.gotoAndStop('stand'); back.player.body.gotoAndStop(1); } } } } function engine() { ++ropeframe; if (ropeframe >= 20) { ropeframe = 1; } if (action == 'fight') { moveback(); character('player', 'enemy'); character('enemy', 'player'); } else { if (action == 'setcharacters') { reset_round_difficulties(); if (player_charnum == undefined) { player_charnum = 1; } if (training != true) { enemy_charnum = _root['match' + match]; } else { enemy_charnum = 9; } player_life = maxlife; enemy_life = maxlife; bars.playerbar.life._width = maxlife; bars.enemybar.life._width = maxlife; back.attachMovie(['fighter' + _root.player_charnum], 'player', 1); player_fbnum = _root.player_charnum; back.player._x = 750; back.player._y = bot; back.attachMovie(['fighter' + _root.enemy_charnum], 'enemy', 2); enemy_fbnum = _root.enemy_charnum; back.enemy._x = 1250; back.enemy._y = bot; back.enemy._xscale = -100; if (training == true) { back.player.swapDepths(back.enemy); } action = 'ready'; } else { if (action == 'ready') { if (ready._currentframe == ready._totalframes) { action = 'setmatch'; } else { ready.play(); } } else { if (action == 'setmatch') { player_action = 'stand'; enemy_action = 'stand'; action = 'fight'; } else { if (action == 'roundover') { fix_stand(); if (enemy_life <= 0) { ++player_roundswon; youwonlost.gotoAndPlay('win'); } else { ++enemy_roundswon; youwonlost.gotoAndPlay('lose'); } action = 'whatsnext'; } else { if (action == 'whatsnext') { fix_stand(); if (youwonlost.completed == true) { if (player_roundswon >= 2) { _root.fader.dest = 'rank'; _root.fader.play(); nextround = true; } else { if (enemy_roundswon >= 2) { if (_root.youwonlost._currentframe == 431) { if (_root.dif_level == 'easy') { _root.youwonlost.gotoAndStop('gameover_easy'); } else { if (_root.dif_level == 'hard') { _root.youwonlost.gotoAndStop('gameover_hard'); } } } } else { _root.fader.dest = 'game' + arena; _root.fader.play(); if (fader._currentframe >= 60) { ++_root.roundnum; removeMovieClip(back.player); removeMovieClip(back.enemy); _root.back._x = -600; ready.gotoAndStop(1); youwonlost.gotoAndStop(1); action = 'setcharacters'; } } } } } } } } } } } function moveback() { if (shakenow != true) { if (back.ytype == 'scroll') { if (player_yy < 300 & back._y - player_yspeed > 0) { back._y -= player_yspeed; } else { back._y = 0; } } else { if (player_yy < 300 & back._y < 200 & back._y - player_yspeed > 0) { back._y -= player_yspeed; } else { if (back._y >= 200 & player_yy >= 300) { back._y -= player_yspeed; } else { if (back._y >= 200 & player_yy < 300) { } else { back._y = 0; } } } } } llim = 75; rlim = 725; bw = -1200; px = back.player._x + back._x; ex = back.enemy._x + back._x; pxx = px + player_xspeed; exx = ex + enemy_xspeed; if (ex > rlim) { back.enemy._x = -back._x + rlim - 40; } if (pxx > llim & pxx < rlim) { back.player._x += player_xspeed; } else { if (pxx <= llim & back._x - player_xspeed < 0) { if (ex - player_xspeed <= rlim) { back.player._x = -back._x + llim; back._x -= player_xspeed; } else { if (ex - player_xspeed > rlim) { frac = ex - rlim; back._x -= frac; back.player._x = -back._x + llim; } } } else { if (pxx >= rlim & back._x - player_xspeed > bw) { if (ex - player_xspeed >= llim) { back.player._x = -back._x + rlim; back._x -= player_xspeed; } else { if (ex - player_xspeed < llim) { frac = ex - llim; back._x -= frac; back.player._x = -back._x + rlim; } } } } } if (exx > llim & exx < rlim) { back.enemy._x += enemy_xspeed; } else { if (exx <= llim) { if (back._x - enemy_xspeed < 0 & px - enemy_xspeed <= rlim) { back.enemy._x = -back._x + llim; back._x -= enemy_xspeed; back.player._x -= enemy_xspeed; } } else { if (exx >= rlim) { if (back._x - enemy_xspeed > bw & px - enemy_xspeed >= llim) { back.enemy._x = -back._x + rlim; back._x -= enemy_xspeed; back.player._x -= enemy_xspeed; } } else {} } } if (back._x > 0) { back._x = 0; } else { if (back._x < -1200) { back._x = -1200; } } if (back.player._x < llim) { back.player._x = llim; } else { if (back.player._x > 1925) { back.player._x = 1925; } } if (back.enemy._x < llim) { back.enemy._x = llim; } else { if (back.enemy._x > 1925) { back.enemy._x = 1925; } } } function unloader(name) { if (name.lastframe == undefined) { name.lastframe = back._currentframe; } if (name.lastframe != back._currentframe) { name.removeMovieClip(); } else { name.lastframe = back._currentframe; } } stop(); fix = 0; upper = 0; } frame 12 { function reset_round_difficulties() { short_add_dif = 0; hard_add_dif = 0; } function ai(name) { if (enemy_nouppercut > 0) { --enemy_nouppercut; if (player_action == 'uppercut') { unblock = false; enemy_action = 'block'; aia = -2; enemy.gotoAndStop('block'); } } if (enemy_nokick > 0 & enemy_nokick < 30) { --enemy_nokick; if (player_action == 'kick') { unblock = false; enemy_action = 'block'; aia = -2; enemy.gotoAndStop('block'); } } else { if (enemy_nokick >= 30) { --enemy_nokick; } } difficulty = match * 9; if (difficulty > 80) { difficulty = 80; } if (training == true) { enemy_action = 'block'; enemy.gotoAndStop('block'); if (name._x < back.player._x) { name._xscale = 100; } else { if (back.enemy._x > back.player._x) { name._xscale = -100; } } } if (enemy_action == 'smallflinch' & back.enemy.body._currentframe >= 13) { trace('small flinch end'); trace('shc ' + player_shorthitcounter); addmore = player_shorthitcounter * 10; if (enemy_action != 'block') { unblock = false; blockit = random(100); trace('2 short block ' + blockit + ' to ' + (blockdifficulty + short_add_dif + addmore)); trace('2 short_add_dif ' + short_add_dif); trace('2 addmore ' + addmore); trace('------------'); } if (blockit < blockdifficulty + short_add_dif + addmore) { trace('BLOCK SUCCESS'); unblock = false; enemy_action = 'block'; back.enemy.gotoAndStop('block'); aia = -2; } } if (training != true & enemy_action != 'smallflinch' & enemy_action != 'bigflinch' & enemy_action != 'fall' & enemy_action != 'harpooned' & enemy_action != 'doved') { dovereaction(name); harpoonreaction(name); enemydefense(name); enemyreactstogettinghit(name); checkforfall(); enemyface(name); if (aia == 0) { if (dis < 100) { enemy_action = 'uppercut'; } else { aia = random(16); } shottry = 0; fixlunge = false; enemy_fixjump = false; } else { if (aia == -1) { if (player_action != 'fall') { aia = 0; } enemyreactstofall(name); } else { if (aia == -2) { if (unblock == true) { --blockercounter; } if (unblock == false or blockercounter > 0) { if (unblock == false) { blockercounter = 9; } enemy_action = 'block'; name.body.nextFrame(); } else { name.body.prevFrame(); if (name.body._currentframe == 1) { enemy_action = 'stand'; aia = 0; } } } else { if (aia == -3) { if (player_lunge != true) { aia = 0; } } else { if (aia == -4) { if (player_action != 'doved') { aia = 0; } } else { if (aia == -5) { if (player_action != 'harpooned') { aia = 0; } } else { if (aia == 1 or aia == 2) { timeout(); if (dis > 275) { movedelay = random(base_enemy_delay - difficulty); moveforward(name); } else { if (movedelay <= 0) { enemy_xspeed = 0; enemy_action = 'short'; } else { enemy_xspeed = 0; --movedelay; } } } else { if (aia == 3 or aia == 4) { timeout(); if (dis > 200) { movedelay = random(base_enemy_delay - difficulty); moveforward(name); } else { if (movedelay <= 0) { enemy_xspeed = 0; enemy_action = 'kick'; } else { enemy_xspeed = 0; --movedelay; } } if (player_action == 'bigflinch' or player_action == 'fall') { aia = 0; } } else { if (aia == 5 or aia == 6) { timeout(); if (dis >= 400) { enemy_action = 'hard'; if (name._x < back.player._x) { enemy_xspeed = 80; fixlunge = true; } else { if (back.enemy._x > back.player._x) { enemy_xspeed = -80; fixlunge = true; } } } else { if (dis < 400 & dis > 250) { if (fixlunge == false) { moveforward(name); } } else { enemy_action = 'hard'; } } if (player_action == 'bigflinch' or player_action == 'fall') { aia = 0; } } else { if (aia == 7) { timeout(); if (dis > 275) { movedelay = random(base_enemy_delay - difficulty); movebackard(name); } else { if (movedelay <= 0) { enemy_xspeed = 0; enemy_action = 'short'; } else { enemy_xspeed = 0; --movedelay; } } if (shorttry == undefined) { shorttry = 0; } } else { if (aia == 8) { timeout(); if (dis > 250) { movedelay = random(base_enemy_delay - difficulty); movebackward(name); } else { if (movedelay <= 0) { enemy_xspeed = 0; enemy_action = 'kick'; } else { enemy_xspeed = 0; --movedelay; } } if (player_action == 'bigflinch' or player_action == 'fall') { aia = 0; } } else { if (aia == 9) { aia = 5; timeout(); if (shottry < 50) { shottry = 50; } if (dis > 300) { movebackward(name); } else { enemy_xspeed = 0; enemy_action = 'hard'; } if (player_action == 'bigflinch' or player_action == 'fall') { aia = 0; } } else { if (aia == 10 or aia == 11) { enemy_xspeed = -maxspeed * 2; if (enemy_action == 'stand' & enemy_fixjump == false) { enemy_action = 'jump'; enemy_fixjump = true; } if (dis < 250 & enemy_jump == 'jumping') { enemy_action = 'jumpkick'; } if (enemy_action != 'jump' & enemy_action != 'jumpkick') { enemy_jump = 'notjumping'; enemy_fixjump = false; aia = 0; } } else { if (aia == 12) { enemy_xspeed = maxspeed * 2; if (enemy_action == 'stand' & enemy_fixjump == false) { enemy_action = 'jump'; enemy_fixjump = true; } if (dis < 250 & enemy_jump == 'jumping') { enemy_action = 'jumpkick'; } if (enemy_action != 'jump' & enemy_action != 'jumpkick') { enemy_jump = 'notjumping'; enemy_fixjump = false; aia = 0; } } else { if (aia >= 13) { if (player_action == 'harpooned') { aia = 0; trace('fireball harpoon out'); } else { if (back.enemy._y < bot - 20) { aia = 0; trace('air fireball ' + back.enemy._y); } else { if (back.enemy.body._currentframe == back.enemy.body._totalframes & enemy_action == 'fireball') { aia = 0; } else { if (dis > 300) { enemy_action = 'fireball'; } else { movebackward(name); } } } } } } } } } } } } } } } } } } } } if (enemy_action == 'duck') { enemy_action = 'stand'; } } function dovereaction(name) { if (player_action == 'doved') { aia = -4; if (dis > 200) { moveforward(name); } else { enemy_action = 'uppercut'; } } } function harpoonreaction(name) { if (player_action == 'harpooned' & back.player.body._currentframe > 5) { aia = -5; if (dis > 200) { moveforward(name); } else { enemy_action = 'uppercut'; } } } function checkforfall() { if (player_action == 'fall' & aia != -1) { fallreaction = random(3); aia = -1; } } function enemyreactstofall(name) { if (enemy_action == 'stand') { if (fallreaction == 0) { enemy_action = 'jump'; back.enemy.gotoAndStop('jump'); if (dis < 500) { if (name._x <= back.player._x) { enemy_xspeed = -maxspeed * 2; } else { if (name._x > back.player._x) { enemy_xspeed = maxspeed * 2; } } } else { fallreaction = 10; } } else { if (fallreaction == 1) { if (dis < 500) { movebackward(name); } else { fallreaction = 10; } } else { if (fallreaction == 2) { if (dis < 100) { movebackward(name); } else { fallreaction = 10; } } } } } } function moveforward(name) { if (walkintoshort != true) { if (name._x < back.player._x) { name._xscale = 100; enemy_xspeed = 7; } else { if (back.enemy._x > back.player._x) { name._xscale = -100; enemy_xspeed = -7; } } } else { enemy_xspeed = 0; } } function movebackward(name) { if (dis < 500 & back.enemy._x + enemy_xspeed > 90 & back.enemy._x + enemy_xspeed < 1910) { if (walkoffset <= 0) { if (name._x < back.player._x) { name._xscale = 100; enemy_xspeed = -7; } else { if (back.enemy._x > back.player._x) { name._xscale = -100; enemy_xspeed = 7; } } } else { --walkoffset; } } else { enemy_xspeed = 0; walkoffset = 20; } } function timeout() { ++shottry; if (shottry > 100) { shottry = 0; aia = 0; } } function enemyreactstogettinghit(name) { if (enemy_action == 'bigflinch' & name.body._currentframe > 33) { bigreaction = 0; if (bigreaction == 0) { enemy_action = 'stand'; enemy_fixjump = false; aia = 12; } } } function enemydefense(name) { if (player_action == 'short' & dis > 250) { walkintoshort = true; ++shorttoomuchfromfar; } else { if (player_action != 'short' & shorttoomuchfromfar > 0) { walkintoshort = false; --shorttoomuchfromfar; } } if (shorttoomuchfromfar >= 60) { if (enemy_action == 'stand' or enemy_action == 'block') { aia = 14; shorttoomuchfromfar; } } blockdifficulty = 10 + difficulty; blockfireball = difficulty + fireballhit; if (player_life <= 0 or enemy_life <= 0) { fireballhit = 0; } if (enemy_action != 'fall' & enemy_action != 'jump' & enemy_action != 'bigflinch' & enemy_action != 'smallflinch' & enemy_action != 'doved') { if (enemy_action == 'stand' or enemy_action == 'block') { if (player_lunge == true) { lungedefend = random(200); if (lungedefend < blockdifficulty) { lungeuppercut = true; } if (lungeuppercut == true & dis < 300) { enemy_action = 'uppercut'; back.enemy.gotoAndStop('uppercut'); aia = -3; } } else { if (lungeuppercut == true) { lungeuppercut = false; } } } } if (dis < 300) { if (player_action == 'short' or player_action == 'kick' or player_action == 'jumpkick' or player_action == 'hard' & player_lunge == false) { if (enemy_action != 'fall' & enemy_action != 'jump' & enemy_action != 'bigflinch' & enemy_action != 'smallflinch' & enemy_action != 'doved') { if (enemy_action == 'stand' or enemy_action == 'block') { if (player_action == 'hard' & player_lunge == false) { trace('trying to block non lunge hard'); } if (player_action == 'short') { if (enemy_action != 'block') { unblock = false; blockit = random(100); trace('short block ' + blockit + ' to ' + (blockdifficulty + short_add_dif)); trace('short_add_dif ' + short_add_dif); } if (blockit < blockdifficulty + short_add_dif) { unblock = false; enemy_action = 'block'; aia = -2; } } else { if (enemy_action != 'block') { unblock = false; blockit = random(100); } if (blockit < blockdifficulty) { unblock = false; enemy_action = 'block'; aia = -2; } } } else { if (enemy_action == 'block') { unblock = true; enemy_action = 'stand'; aia = 0; } } } } } else { if (player_action == 'fireball') { if (enemy_action != 'fall' & enemy_action != 'jump' & enemy_action != 'bigflinch' & enemy_action != 'smallflinch' & enemy_action != 'doved') { if (enemy_action != 'block') { unblock = false; if (match <= 1) { blockit = random(900); trace('m1 ' + blockit); } else { if (match == 2) { blockit = random(600); trace('m2 ' + blockit); } else { blockit = random(200); } } } if (blockit < blockfireball) { unblock = false; enemy_action = 'block'; aia = -2; } } } else { if (unblock == false) { unblock = true; } } } } function enemyface(name) { if (enemy_action == 'stand') { if (name._x < back.player._x) { name._xscale = 100; } else { if (name._x > back.player._x) { name._xscale = -100; } } } } base_enemy_delay = 120; aia = 0; _root.fireballhit_uplev = 20; enemy_nouppercut = 0; enemy_nokick = 0; enemy_fixjump = false; shorttry = 0; fireballhit = 0; shorttoomuchfromfar = 0; } movieClip 672 { frame 1 { stop(); } frame 2 { _quality = 'medium'; } frame 104 { play(); } frame 133 { stop(); _quality = 'low'; } } button 680 { on (release) { _root.fader.dest = 'open'; _root.fader.play(); } } movieClip 686 { } button 687 { on (release) { stopAllSounds(); _root.fader.dest = 'open'; _root.fader.play(); } } button 695 { on (release) { comment_test = ' ' + comment.toLowerCase(); var s1 = comment_test.indexOf(' dick'); var s2 = comment_test.indexOf(' shit'); var s3 = comment_test.indexOf(' fuck'); var s4 = comment_test.indexOf(' penis'); var s5 = comment_test.indexOf(' ass'); var s6 = comment_test.indexOf(' cock'); var s7 = comment_test.indexOf(' mother fucker'); var s8 = comment_test.indexOf(' motherfucker'); var s9 = comment_test.indexOf(' cunt'); var s10 = comment_test.indexOf(' blowjob'); var s11 = comment_test.indexOf(' blow job'); var s12 = comment_test.indexOf(' pussy'); var s13 = comment_test.indexOf(' vagina'); if (s1 != -1 || s2 != -1 || s3 != -1 || s4 != -1 || s5 != -1 || s6 != -1 || s7 != -1 || s8 != -1 || s9 != -1 || s10 != -1 || s11 != -1 || s12 != -1 || s13 != -1) { swear1 = true; talkback = 'please do not type swear words'; } else { swear1 = false; } playername_test2 = ' ' + playername_test.toLowerCase(); var p1 = playername_test2.indexOf(' dick'); var p2 = playername_test2.indexOf(' shit'); var p3 = playername_test2.indexOf(' fuck'); var p4 = playername_test2.indexOf(' penis'); var p5 = playername_test2.indexOf(' ass'); var p6 = playername_test2.indexOf(' cock'); var p7 = playername_test2.indexOf(' mother fucker'); var p8 = playername_test2.indexOf(' motherfucker'); var p9 = playername_test2.indexOf(' cunt'); var p10 = playername_test2.indexOf(' blowjob'); var p11 = playername_test2.indexOf(' blow job'); var p12 = playername_test2.indexOf(' pussy'); var p13 = playername_test2.indexOf(' vagina'); if (p1 != -1 || p2 != -1 || p3 != -1 || p4 != -1 || p5 != -1 || p6 != -1 || p7 != -1 || p8 != -1 || p9 != -1 || p10 != -1 || p11 != -1 || p12 != -1 || p13 != -1) { swear2 = true; talkback = 'please do not type swear words'; } else { if (playername_test == undefined or playername_test == '') { swear2 = true; trace(playername_test); talkback = 'please enter your name'; } else { swear2 = false; } } if (swear1 != true & swear2 != true) { talkback = ''; playername = playername_test; talktalk = comment; high = _root.score; fighter = _root.player_charnum; wins = _root.wins; trace(playername + '|' + high + '|' + talktalk); getURL('fuse_enterscore.php', 'blank', 'POST'); _root.fader.play(); _root.fader.dest = 'open'; } } } button 697 { on (release) { stopAllSounds(); _root.fader.play(); _root.fader.dest = 'submit'; } } movieClip 699 { frame 1 { stop(); completed = false; } frame 2 { _quality = 'medium'; } frame 103 { if (_root.player_life > _root.enemy_life) { winner = _root.player_charnum + 1; } else { winner = _root.enemy_charnum + 1; } _root.snd.winner.gotoAndStop(winner); } frame 135 { if (_root.player_life == 500) { lifebonus = 75000; } else { lifebonus = _root.player_life * 100; } bonus_display = 'Bonus - ' + lifebonus; _root.score += lifebonus; } frame 246 { stop(); completed = true; } frame 247 { _quality = 'medium'; } frame 366 { if (_root.player_life > _root.enemy_life) { winner = _root.player_charnum + 1; } else { winner = _root.enemy_charnum + 1; } _root.snd.winner.gotoAndStop(winner); } frame 431 { stop(); completed = true; } frame 432 { bonus_display = 'Final Score - ' + _root.score; } frame 433 { bonus_display = 'Final Score - ' + _root.score; } frame 434 { stop(); } } movieClip 702 { frame 1 { stop(); } } movieClip 704 { frame 1 { stop(); } } movieClip 706 { frame 1 { stop(); } } movieClip 709 { frame 1 { stop(); } } movieClip 711 { frame 1 { stop(); } } movieClip 713 { frame 1 { stop(); } frame 2 { gotoAndPlay('p1'); } frame 3 { gotoAndPlay('p2'); } frame 4 { gotoAndPlay('p3'); } frame 5 { gotoAndPlay('p4'); } frame 6 { gotoAndPlay('p5'); } frame 7 { gotoAndPlay('p6'); } frame 8 { gotoAndPlay('p7'); } frame 9 { gotoAndPlay('p9'); } frame 12 { gotoAndPlay('p11'); } frame 13 { gotoAndPlay('p12'); } frame 14 { gotoAndPlay('p13'); } frame 15 { gotoAndPlay('p14'); } frame 75 { gotoAndStop(1); } frame 126 { gotoAndStop(1); } frame 192 { gotoAndStop(1); } frame 252 { gotoAndStop(1); } frame 306 { gotoAndStop(1); } frame 359 { gotoAndStop(1); } frame 426 { gotoAndStop(1); } frame 484 { gotoAndStop(1); } frame 542 { gotoAndStop(1); } frame 600 { gotoAndStop(1); } frame 658 { gotoAndStop(1); } frame 716 { gotoAndStop(1); } } movieClip 720 { frame 1 { stop(); } frame 4 { gotoAndStop(1); } frame 7 { gotoAndStop(1); } frame 10 { gotoAndStop(1); } frame 13 { gotoAndStop(1); } frame 16 { gotoAndStop(1); } frame 19 { gotoAndStop(1); } frame 22 { gotoAndStop(1); } frame 25 { gotoAndStop(1); } frame 28 { gotoAndStop(1); } frame 29 { stop(); } frame 31 { gotoAndStop(1); } frame 32 { stop(); } frame 34 { gotoAndStop(1); } frame 37 { gotoAndStop(1); } frame 38 { stop(); } frame 40 { gotoAndStop(1); } } movieClip 722 { frame 1 { stop(); } } movieClip 724 { frame 1 { stop(); } } movieClip 725 { } movieClip 728 { frame 1 { stop(); } } instance of movieClip 728 { onClipEvent (enterFrame) { if (_root.back.player._x < _root.back.enemy._x) { if (_root.rightkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.rightkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } else { if (_root.leftkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.leftkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } } } movieClip 732 { } instance of movieClip 732 { onClipEvent (enterFrame) { total_time = getTimer(); cur_time = total_time - mark_time; if (cur_time > 1000) { mark_time = total_time; this.fp = this._currentframe; a = 45; if ((fp / a) * 100 < 100) { this.afps = (fp / a) * 100; } else { this.afps = 100; } this.gotoAndPlay(1); } _root.gamespeed = int(this.afps); } onClipEvent (load) { mark_time = getTimer(); } } movieClip 753 { frame 12 { stop(); } } movieClip 754 { } movieClip 758 { } movieClip 759 { instance dis of movieClip 758 { onClipEvent (enterFrame) { _root.billdisx = this._x; _root.billdisy = this._y; } } frame 14 { _parent.gotoAndPlay(2); } frame 30 { _parent.gotoAndPlay(2); } frame 47 { _parent.gotoAndPlay(2); } frame 51 { _parent.donehitting = true; stop(); } } movieClip 761 { frame 1 { stop(); } frame 5 { _parent.blood = true; } } movieClip 765 { frame 15 { stop(); } } movieClip 766 fireball1 { frame 1 { onEnterFrame = function () { _root.fireballcode1(this); }; num = 1; } frame 15 { stop(); } frame 39 { action = 'eject'; stop(); } } movieClip 767 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 768 { } movieClip 769 { } movieClip 770 { } movieClip 771 { } movieClip 772 { } movieClip 773 { frame 2 { _root.snd.woom.play(); } frame 21 { stop(); } } movieClip 774 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 38 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 775 { frame 14 { stop(); } } movieClip 776 { frame 1 { play(); } frame 44 { stop(); } } movieClip 777 { frame 4 { _root.snd.woom.play(); } frame 19 { stop(); punch = 'done'; } } movieClip 778 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 781 { } movieClip 799 { frame 4 { if (_parent._name == 'player') { if (_root.leftkey == true or _root.rightkey == true) { } else { _root.player_yspeed = -20; if (_root.back.player._xscale == 100) { _root.player_xspeed = 40; } else { if (_root.back.player._xscale == -100) { _root.player_xspeed = -40; } } gotoAndPlay('jump2'); } } else { if (_parent._name == 'enemy') { if (_root.enemy_xspeed == 0) { gotoAndPlay('jump'); } } } } instance of movieClip 781 { onClipEvent (enterFrame) { if (_root.dis < 200) { _parent.gotoAndPlay('jump'); } } } frame 26 { if (_parent._name == 'player') { _root.player_yspeed = -30; if (_root.player_xspeed > 0) { _root.player_xspeed = 40; } else { if (_root.player_xspeed < 0) { _root.player_xspeed = -40; } } } else { if (_parent._name == 'enemy') { _root.enemy_yspeed = -30; if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } frame 27 { _root.snd.woom.play(); } instance of movieClip 781 { onClipEvent (enterFrame) { if (_parent._parent._name == 'player') { _root.player_yspeed += 2; } else { if (_parent._parent._name == 'enemy') { _root.enemy_yspeed += 2; } } } } } movieClip 800 { frame 12 { shoot = true; } } movieClip 801 { } movieClip 802 { } movieClip 803 { } movieClip 804 { } movieClip 805 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 35 { gotoAndStop('out'); } frame 36 { play(); } frame 54 { stop(); } frame 55 { stop(); } } movieClip 806 fighter1 { frame 1 { stop(); } frame 1 { stop(); } instance of movieClip 799 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 30) { this._alpha += 10; } } } frame 15 { body.gotoAndPlay('doved'); } } movieClip 809 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 812 { } movieClip 813 { } movieClip 814 { frame 7 { stop(); } } movieClip 816 { frame 2 { _root.snd.woom.play(); } frame 25 { stop(); } } movieClip 818 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 66 { fallstatus = 'up'; stop(); } } movieClip 819 { } movieClip 820 { } movieClip 821 { frame 6 { _root.snd.woom.play(); } frame 20 { stop(); punch = 'done'; } } movieClip 822 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 823 { } movieClip 824 { frame 6 { } instance of movieClip 823 { onClipEvent (enterFrame) { if (_root.dis < 300) { if (_parent._parent.me == 'player') { if (_root.rightkey == true or _root.leftkey == true) { _parent.gotoAndPlay('hit'); } } if (_parent._parent.me == 'enemy') { trace('giuliani strike ' + dis); _parent.gotoAndPlay('hit'); } } } } frame 7 { _root.snd.woom.play(); } } movieClip 825 { frame 14 { shoot = true; } frame 56 { stop(); } } movieClip 826 { } movieClip 827 { } movieClip 828 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 33 { gotoAndPlay('out'); } frame 34 { play(); } frame 52 { stop(); } } movieClip 829 fighter5 { frame 1 { stop(); } frame 1 { stop(); } instance of movieClip 824 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 40) { this._alpha += 10; } } } frame 15 { body.gotoAndPlay('doved'); } } movieClip 830 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 831 { } movieClip 832 { } movieClip 834 { } movieClip 835 { frame 2 { _root.snd.woom.play(); } } movieClip 836 { } movieClip 838 { instance chuck of movieClip 836 { onClipEvent (enterFrame) { gotoAndPlay(_root.ropeframe); } } frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 839 { } movieClip 840 { } movieClip 844 { } movieClip 845 { frame 5 { _root.snd.woom.play(); } frame 19 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 20 { stop(); punch = 'done'; } } movieClip 846 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 847 { } movieClip 848 { } movieClip 849 { } movieClip 850 { frame 2 { if (_parent._name == 'player') { if (_root.leftkey == true or _root.rightkey == true) { } else { _root.player_yspeed = -20; if (_root.back.player._xscale == 100) { _root.player_xspeed = 40; } else { if (_root.back.player._xscale == -100) { _root.player_xspeed = -40; } } gotoAndPlay('jump'); } } } instance of movieClip 849 { onClipEvent (enterFrame) { if (_root.dis < 250) { _parent.gotoAndPlay('jump'); } if (_parent._parent._name == 'player') { _root.player_hardspeedoveride = true; if (_root.back.player._xscale == 100) { if (_root.rightkey == true) { _root.player_xspeed = 35; gotoAndPlay('jump'); } else { gotoAndPlay('up'); } } else { if (_root.back.player._xscale == -100) { if (_root.leftkey == true) { _root.player_xspeed = -35; gotoAndPlay('jump'); } else { gotoAndPlay('up'); } } } } else { if (_parent._parent._name == 'enemy') { if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } } frame 31 { if (_parent._name == 'player') { if (_root.back.player._xscale == 100) { if (_root.rightkey == true) { _root.player_yspeed = -35; _root.player_xspeed = 50; } else { _root.player_yspeed = -20; _root.player_xspeed = 40; } } else { if (_root.back.player._xscale == -100) { if (_root.leftkey == true) { _root.player_yspeed = -35; _root.player_xspeed = -50; } else { _root.player_yspeed = -20; _root.player_xspeed = -40; } } } } else { if (_parent._name == 'enemy') { _root.enemy_yspeed = -40; if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } frame 32 { _root.snd.woom.play(); } frame 72 { gotoAndStop('end'); } } movieClip 851 { frame 9 { shoot = true; } } movieClip 854 { } movieClip 856 { } movieClip 858 { } movieClip 859 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 38 { gotoAndStop('out'); } frame 39 { play(); } frame 56 { stop(); } } movieClip 860 fighter3 { frame 1 { stop(); } frame 15 { body.gotoAndPlay('doved'); } instance body of movieClip 859 { } } movieClip 861 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 862 { } movieClip 863 { } movieClip 864 { } movieClip 865 { frame 2 { _root.snd.woom.play(); } } movieClip 866 { } movieClip 867 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 868 { } movieClip 869 { } movieClip 870 { frame 4 { _root.snd.woom.play(); } frame 18 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 19 { stop(); punch = 'done'; } } movieClip 871 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 872 { } movieClip 873 { } movieClip 874 { } movieClip 875 { frame 6 { _root.snd.woom.play(); } instance of movieClip 873 { onClipEvent (enterFrame) { if (_root.dis < 300) { if (_parent._parent.me == 'player') { if (_root.rightkey == true or _root.leftkey == true) { _parent.gotoAndPlay('hit'); } } if (_parent._parent.me == 'enemy') { trace('giuliani strike ' + dis); _parent.gotoAndPlay('hit'); } } } } } movieClip 876 { frame 9 { shoot = true; } } movieClip 877 { } movieClip 878 { } movieClip 879 { } movieClip 880 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 38 { gotoAndStop('out'); } } movieClip 881 fighter2 { frame 1 { stop(); } frame 1 { stop(); } frame 11 { } instance of movieClip 875 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 60) { this._alpha += 10; } } } } movieClip 884 { } movieClip 887 { frame 1 { stop(); } frame 11 { stop(); } frame 12 { stop(); } } movieClip 888 fireball5 { frame 1 { onEnterFrame = function () { _root.fireballcode5(this); }; } instance head1 of movieClip 887 { onClipEvent (enterFrame) { _root.ghead(this); } } instance head2 of movieClip 887 { onClipEvent (enterFrame) { _root.ghead(this); } } instance head3 of movieClip 887 { onClipEvent (enterFrame) { _root.ghead(this); } } } movieClip 894 { } movieClip 895 { } movieClip 896 jail { frame 1 { onEnterFrame = function () { _root.jailcode(this); }; } frame 20 { stop(); harpoonit = true; } frame 21 { reached = true; } } movieClip 897 { } movieClip 899 fireball2 { frame 1 { onEnterFrame = function () { _root.fireballcode2(this); }; } instance of movieClip 897 { onClipEvent (enterFrame) { if (this.hitTest(_root.back[_parent.you].body.hit)) { _root.fireballhit += _root.fireballhit_uplev; _root[_parent.you + '_action'] = 'doved'; _root.back[_parent.you].gotoAndStop('doved'); _root.back[_parent.you].body.gotoAndStop('doved'); _root[_parent.me + '_dovegrab'] = true; } } } frame 3 { _root.dove(me, you); } frame 54 { stop(); } } movieClip 900 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 901 { } movieClip 902 { } movieClip 903 { } movieClip 904 { } movieClip 905 { } movieClip 906 { frame 2 { _root.snd.woom.play(); } } movieClip 907 { } movieClip 908 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 64 { fallstatus = 'up'; stop(); } } movieClip 909 { } movieClip 910 { } movieClip 911 { frame 4 { _root.snd.woom.play(); } frame 18 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 19 { stop(); punch = 'done'; } } movieClip 912 { frame 2 { _root.snd.woom.play(); } } movieClip 913 { } movieClip 914 { } movieClip 915 { } movieClip 917 { frame 1 { _root.player_hardspeedoveride = true; } frame 8 { } frame 8 { stop(); } instance of movieClip 914 { onClipEvent (load) { if (_parent._name == 'body') { action = 'start'; if (_parent._parent._name == 'player') { if (_root.back.player._xscale == 100) { _root.player_xspeed = 33; } else { _root.player_xspeed = -33; } } else { if (_root.back.enemy._xscale == 100) { _root.enemy_xspeed = 33; } else { _root.enemy_xspeed = -33; } } } } onClipEvent (enterFrame) { if (_parent._name == 'body') { if (action == 'start') { if (_parent._parent._name == 'player') { if (_root.pxx > _root.rlim - 5) { trace('outright'); _root.player_xspeed = 7; _parent.play(); } else { if (_root.pxx < _root.llim + 5) { trace('outleft'); _root.player_xspeed = 7; _parent.play(); } } if (_root.back.player._xscale == 100) { if (_root.rightkey == true) { _root.player_xspeed = 23; } else { _root.player_xspeed = 7; _parent.play(); } } else { if (_root.leftkey == true) { _root.player_xspeed = -23; } else { _parent.play(); _root.player_xspeed = -7; } } _root.player_yspeed = 0; if (this.hitTest(_root.back.enemy.body.block) or this.hitTest(_root.back.enemy.body) & _root.enemy_action == 'bigflinch') { trace('blockhit'); _root.player_yspeed = -30; set_xspeed = -_root.player_xspeed; action = 'block'; } } else { if (_root.back.enemy._xscale == 100) { _root.enemy_xspeed = 33; } else { _root.enemy_xspeed = -33; } if (_root.exx > _root.rlim - 5) { trace('e outright'); _root.enemy_xspeed = 7; _parent.play(); } else { if (_root.exx < _root.llim + 5) { trace('e outleft'); _root.enemy_xspeed = 7; _parent.play(); } } _root.enemy_yspeed = 0; if (this.hitTest(_root.back.player.body.block) or this.hitTest(_root.back.player.body) & _root.player_action == 'bigflinch') { trace('blockhit'); _root.enemy_yspeed = -30; set_xspeed = -_root.enemy_xspeed; action = 'block'; } } } else { if (action == 'block') { if (_parent._parent._name == 'player') { _root.player_xspeed = set_xspeed; if (_root.back.player._y + _root.player_yspeed >= _root.bot) { _parent.gotoAndPlay('out'); } } else { _root.enemy_xspeed = set_xspeed; if (_root.back.enemy._y + _root.enemy_yspeed >= _root.bot) { _parent.gotoAndPlay('out'); } } } } } } } instance of movieClip 915 { } } movieClip 918 { frame 17 { shoot = true; _root.shake.play(); } } movieClip 919 { } movieClip 920 { } movieClip 921 { } movieClip 922 { frame 1 { stop(); } frame 9 { gotoAndStop(1); } frame 33 { gotoAndStop('out'); } frame 34 { play(); } frame 54 { stop(); } } movieClip 923 fighter4 { frame 1 { stop(); } frame 1 { stop(); } frame 11 { } } movieClip 924 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 925 { } movieClip 926 { } movieClip 927 { } movieClip 928 { } movieClip 930 { } movieClip 931 { } movieClip 932 { frame 2 { _root.snd.woom.play(); } } movieClip 933 { instance chuck of movieClip 930 { onClipEvent (enterFrame) { gotoAndPlay(_root.ropeframe); } } frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 934 { } movieClip 935 { } movieClip 936 { frame 6 { _root.snd.woom.play(); } frame 19 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 20 { stop(); punch = 'done'; } } movieClip 937 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 938 { } movieClip 939 { } movieClip 940 { } movieClip 941 { frame 2 { if (_parent._name == 'player') { if (_root.leftkey == true or _root.rightkey == true) { } else { _root.player_yspeed = -20; if (_root.back.player._xscale == 100) { _root.player_xspeed = 40; } else { if (_root.back.player._xscale == -100) { _root.player_xspeed = -40; } } gotoAndPlay('jump'); } } } instance of movieClip 940 { onClipEvent (enterFrame) { _root.player_hardspeedoveride = true; if (_root.dis < 250) { trace('ass'); _parent.gotoAndPlay('jump'); } if (_parent._parent._name == 'player') { if (_root.back.player._xscale == 100) { if (_root.rightkey == true) { trace('FT speed: ' + _root.player_xspeed); _root.player_xspeed = 35; gotoAndPlay('jump'); } else { gotoAndPlay('up'); } } else { if (_root.back.player._xscale == -100) { if (_root.leftkey == true) { _root.player_xspeed = -35; gotoAndPlay('jump'); } else { gotoAndPlay('up'); } } } } else { if (_parent._parent._name == 'enemy') { if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } } frame 31 { if (_parent._name == 'player') { if (_root.back.player._xscale == 100) { if (_root.rightkey == true) { _root.player_yspeed = -35; _root.player_xspeed = 50; } else { _root.player_yspeed = -20; _root.player_xspeed = 40; } } else { if (_root.back.player._xscale == -100) { if (_root.leftkey == true) { _root.player_yspeed = -35; _root.player_xspeed = -50; } else { _root.player_yspeed = -20; _root.player_xspeed = -40; } } } } else { if (_parent._name == 'enemy') { _root.enemy_yspeed = -40; if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } frame 32 { _root.snd.woom.play(); } frame 78 { gotoAndStop('end'); } } movieClip 944 { } movieClip 946 { } movieClip 947 { } movieClip 950 { frame 12 { _root.snd.woom.play(); } frame 13 { shoot = true; } frame 66 { gotoAndStop('out'); } frame 76 { stop(); } frame 83 { gotoAndStop('out'); } frame 85 { stop(); } } movieClip 951 { } movieClip 952 { } movieClip 953 { } movieClip 955 { } movieClip 956 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 28 { gotoAndStop('out'); } frame 29 { play(); } frame 46 { stop(); } } movieClip 957 fighter6 { frame 1 { stop(); } frame 15 { body.gotoAndPlay('doved'); } instance body of movieClip 956 { } } movieClip 958 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 959 { } movieClip 960 { } movieClip 961 { } movieClip 962 { } movieClip 963 { frame 2 { _root.snd.woom.play(); } } movieClip 964 { } movieClip 965 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 64 { fallstatus = 'up'; stop(); } } movieClip 966 { } movieClip 967 { } movieClip 968 { frame 2 { _root.snd.woom.play(); } frame 20 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 21 { stop(); punch = 'done'; } } movieClip 969 { } movieClip 970 { } movieClip 972 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 973 { } movieClip 974 { } movieClip 975 { } movieClip 977 { frame 1 { _root.player_hardspeedoveride = true; } frame 7 { if (_parent._name == 'player') { if (_root.leftkey == true or _root.rightkey == true) { } else { _root.player_yspeed = -20; if (_root.back.player._xscale == 100) { _root.player_xspeed = 10; } else { if (_root.back.player._xscale == -100) { _root.player_xspeed = -10; } } gotoAndPlay('jump2'); } } else { if (_parent._name == 'enemy') { if (_root.enemy_xspeed == 0) { gotoAndPlay('jump'); } } } } instance of movieClip 975 { onClipEvent (enterFrame) { if (_root.dis < 200) { _parent.gotoAndPlay('jump'); } } } frame 27 { if (_parent._name == 'player') { _root.player_yspeed = -30; if (_root.player_xspeed > 0) { _root.player_xspeed = 40; } else { if (_root.player_xspeed < 0) { _root.player_xspeed = -40; } } } else { if (_parent._name == 'enemy') { _root.enemy_yspeed = -30; if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } } movieClip 979 { frame 5 { ++_root.fbsn; _root.back.attachMovie('fireball7', 'bomb' + _root.fbsn, 100 + _root.fbsn); _root.back['bomb' + _root.fbsn].me = _parent._name; _root.back['bomb' + _root.fbsn]._xscale = _parent._xscale; if (_parent._xscale == 100) { _root.back['bomb' + _root.fbsn]._x = _parent._x + 150; } else { _root.back['bomb' + _root.fbsn]._x = _parent._x - 150; } } frame 5 { } frame 11 { ++_root.fbsn; _root.back.attachMovie('fireball7', 'bomb' + _root.fbsn, 100 + _root.fbsn); _root.back['bomb' + _root.fbsn].me = _parent._name; _root.back['bomb' + _root.fbsn]._xscale = _parent._xscale; if (_parent._xscale == 100) { _root.back['bomb' + _root.fbsn]._x = _parent._x + 300; } else { _root.back['bomb' + _root.fbsn]._x = _parent._x - 300; } } frame 17 { ++_root.fbsn; _root.back.attachMovie('fireball7', 'bomb' + _root.fbsn, 100 + _root.fbsn); _root.back['bomb' + _root.fbsn].me = _parent._name; _root.back['bomb' + _root.fbsn]._xscale = _parent._xscale; if (_parent._xscale == 100) { _root.back['bomb' + _root.fbsn]._x = _parent._x + 450; } else { _root.back['bomb' + _root.fbsn]._x = _parent._x - 450; } } frame 23 { ++_root.fbsn; _root.back.attachMovie('fireball7', 'bomb' + _root.fbsn, 100 + _root.fbsn); _root.back['bomb' + _root.fbsn].me = _parent._name; _root.back['bomb' + _root.fbsn]._xscale = _parent._xscale; if (_parent._xscale == 100) { _root.back['bomb' + _root.fbsn]._x = _parent._x + 600; } else { _root.back['bomb' + _root.fbsn]._x = _parent._x - 600; } } } movieClip 980 { } movieClip 981 { } movieClip 982 { } movieClip 983 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 41 { gotoAndStop('out'); } frame 42 { play(); } frame 63 { stop(); } } movieClip 984 fighter7 { frame 1 { stop(); } frame 1 { stop(); } frame 11 { } } movieClip 985 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 986 { } movieClip 987 { } movieClip 988 { frame 2 { _root.snd.woom.play(); } } movieClip 989 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 38 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 990 { } movieClip 991 { } movieClip 992 { frame 4 { _root.snd.woom.play(); } frame 19 { stop(); punch = 'done'; } } movieClip 993 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 1014 { frame 4 { if (_parent._name == 'player') { if (Key.isDown(37) or Key.isDown(39)) { } else { _root.player_yspeed = -20; if (_root.back.player._xscale == 100) { _root.player_xspeed = 40; } else { if (_root.back.player._xscale == -100) { _root.player_xspeed = -40; } } gotoAndPlay('jump2'); } } else { if (_parent._name == 'enemy') { if (_root.enemy_xspeed == 0) { gotoAndPlay('jump'); } } } } instance of movieClip 44 { onClipEvent (enterFrame) { if (_root.dis < 200) { _parent.gotoAndPlay('jump'); } } } frame 26 { if (_parent._name == 'player') { _root.player_yspeed = -30; if (_root.player_xspeed > 0) { _root.player_xspeed = 40; } else { if (_root.player_xspeed < 0) { _root.player_xspeed = -40; } } } else { if (_parent._name == 'enemy') { _root.enemy_yspeed = -30; if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } frame 27 { _root.snd.woom.play(); } instance of movieClip 44 { onClipEvent (enterFrame) { if (_parent._parent._name == 'player') { _root.player_yspeed += 2; } else { if (_parent._parent._name == 'enemy') { _root.enemy_yspeed += 2; } } } } } movieClip 1034 { frame 1 { function fireball() { ++_root.fbsn; _root.back.attachMovie('fireball8', 'fb' + _root.fbsn, 100 + _root.fbsn); _root.back['fb' + _root.fbsn].me = _parent._name; _root.back['fb' + _root.fbsn]._xscale = _parent._xscale; if (_parent._xscale == 100) { _root.back['fb' + _root.fbsn]._x = _parent._x + 50; } else { _root.back['fb' + _root.fbsn]._x = _parent._x - 50; } _root.back['fb' + _root.fbsn]._y = _parent._y - 220; } } frame 10 { fireball(); } frame 24 { fireball(); } frame 38 { fireball(); } } movieClip 1035 { } movieClip 1036 { } movieClip 1037 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 35 { gotoAndStop('out'); } frame 36 { play(); } frame 54 { stop(); } frame 55 { stop(); } } movieClip 1038 fighter8 { frame 1 { stop(); } frame 1 { stop(); } instance of movieClip 1014 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 30) { this._alpha += 10; } } } frame 15 { body.gotoAndPlay('doved'); } } movieClip 1041 { } movieClip 1042 { } movieClip 1043 fighter9 { frame 1 { stop(); } frame 1 { stop(); } instance body of movieClip 1042 { } } movieClip 1044 harpooncover { } movieClip 1047 { frame 1 { stop(); } } movieClip 1048 fireball6 { frame 1 { stop(); movecount = 0; disx = 0; action = 'fly'; if (this._xscale == 100) { xspeed = 55; } else { xspeed = -55; } ++_root.fbsn; _root.back.attachMovie('harpooncover', 'hc' + _root.fbsn, 100 + _root.fbsn); unmasker = _root.back['hc' + _root.fbsn]; trace(unmasker); this.setMask(_root.back['hc' + _root.fbsn]); _root.back['hc' + _root.fbsn]._xscale = this._xscale; _root.back['hc' + _root.fbsn]._x = this._x; _root.back['hc' + _root.fbsn]._y = this._y; trace('harpoon ' + me + ', ' + you); onEnterFrame = function () { if (me == undefined or you == undefined) { you = _parent.you; me = _parent.me; } if (action == 'fly') { this._x += xspeed; disx += xspeed; if (this.hit.hitTest(_root.back[you].body.hit) & _root[you + '_jump'] != 'jumping') { _root.snd.hard.play(); if (this._xscale == 100) { this._x = _root.back[you]._x - 100; } else { this._x = _root.back[you]._x + 100; } _root[you + '_action'] = 'harpooned'; _root.back[you].gotoAndStop('harpooned'); _root.back[me].body.gotoAndPlay('reel'); handoffset = _root.back[me].body.hand._x; xstart = unmasker._x; _root.blood(4, 30, me, you); _root.damage(10, you); delayct = 20; action = 'delay'; } else { if (this.hit.hitTest(_root.back[you].body.block)) { _root.snd.block.play(); _root.back[me].body.gotoAndPlay('miss'); this.play(); action = 'blocked'; } else { if (disx > 800) { _root.back[me].body.gotoAndPlay('miss'); action = 'missed'; } } } } else { if (action == 'delay') { if (movecount < 7) { ++movecount; if (this._xscale == 100) { unmasker._x -= 18.5; } else { unmasker._x += 18.5; } trace('delay ' + unmasker._x + ' cf ' + _root.back[me].body._currentframe); } _root[you + '_action'] = 'harpooned'; _root.back[you].gotoAndStop('harpooned'); _root.back[you].body.gotoAndStop(1); if (delayct <= 0) { _root.snd.comehere.play(); action = 'reelin'; } else { --delayct; } } else { if (action == 'reelin') { harpoon.gotoAndStop(2); _root[you + '_action'] = 'harpooned'; _root.back[you].gotoAndStop('harpooned'); _root.back[you].body.gotoAndStop(1); if (_root.dis < 150) { _root.back[me].body.gotoAndPlay('reeled'); action = 'reeled'; } else { if (_root.back[me]._xscale == 100) { this._x -= 30; _root.back[you]._x -= 30; } else { if (_root.back[me]._xscale == -100) { this._x += 30; _root.back[you]._x += 30; } } } } else { if (action == 'reeled') { _root.back[you].body.gotoAndPlay('harpooned'); removeMovieClip(unmasker); removeMovieClip(this); } else { if (action == 'missed') { this._x += xspeed; disx += xspeed; if (disx > 1600) { removeMovieClip(unmasker); removeMovieClip(this); } } else { if (action == 'blocked') { if (this._currentframe >= 21) { removeMovieClip(unmasker); removeMovieClip(this); } } } } } } } }; } frame 25 { gotoAndPlay(_currentframe - 1); } } movieClip 1051 { } movieClip 1052 { frame 14 { stop(); } } movieClip 1056 { } movieClip 1059 { } movieClip 1062 { } movieClip 1063 fireball3 { frame 1 { function frag(name) { if (name.defined == undefined) { name.xspeed = random(60) - 30; name.yspeed = -random(50); name.rotspeed = random(10) - 5; name.defined = true; } name._x += name.xspeed; name._y += name.yspeed; name.yspeed += 2; name._alpha -= 3; name._rotation += name.rotspeed; } } frame 1 { onEnterFrame = function () { _root.fireballcode3(this); }; stop(); } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } frame 37 { action = 'unload'; stop(); } } movieClip 1067 { } movieClip 1069 fireball4 { frame 1 { stop(); onEnterFrame = function () { _root.fireballcode4(this); }; } frame 2 { play(); } frame 18 { stop(); action = 'unload'; } } movieClip 1108 { frame 19 { stop(); } } movieClip 1110 fireball7 { frame 1 { stop(); action = 'fall'; if (me == 'player') { you = 'enemy'; } else { you = 'player'; } trace(this._name + ' ' + me + ' ' + you); onEnterFrame = function () { if (action == 'fall') { this._y += 25; if (this._xscale == 100) { if (this._rotation < 45) { this._rotation += 2; } } else { if (this._rotation > -45) { this._rotation -= 2; } } if (this._y > _root.bot - 50) { this.gotoAndPlay(2); this.action = 'explode'; } else { if (this.hitTest(_root.back[you].body.hit)) { trace('damage'); this.gotoAndPlay(2); this.action = 'explode'; _root.damage(20, you); _root[you + '_action'] = 'fall'; } else { if (this.hitTest(_root.back[you].body.block)) { trace('block'); this.gotoAndPlay(2); this.action = 'explode'; } } } } else { if (action == 'unload') { removeMovieClip(this); } } }; } frame 24 { action = 'unload'; } } movieClip 1113 fireball10 { frame 1 { stop(); stop(); action = 'fall'; if (me == 'player') { you = 'enemy'; } else { you = 'player'; } yspeed = random(10) - 5; onEnterFrame = function () { if (action == 'fall') { this._y += yspeed; if (this._xscale == 100) { this._x += 40; } else { this._x -= 40; } if (this._x > 2200 or this._x < -200) { removeMovieClip(this); } else { if (this.hitTest(_root.back[you].body.hit)) { this.gotoAndPlay(2); this.action = 'explode'; _root.damage(20, you); if (this._xscale == 100) { _root.player_xspeed = 20; } else { _root.player_xspeed = -20; } _root[you + '_action'] = 'fall'; } else { if (this.hitTest(_root.back[you].body.block)) { this.gotoAndPlay(2); if (this._xscale == 100) { _root.player_xspeed = 5; } else { _root.player_xspeed = -5; } this.action = 'explode'; } } } } else { if (action == 'unload') { removeMovieClip(this); } } }; } frame 24 { action = 'unload'; } } movieClip 1116 fireball8 { frame 1 { stop(); stop(); action = 'fall'; if (me == 'player') { you = 'enemy'; } else { you = 'player'; } yspeed = 0; onEnterFrame = function () { if (action == 'fall') { this._y += yspeed; if (this._xscale == 100) { this._x += 40; } else { this._x -= 40; } if (this._x > 2200 or this._x < -200) { removeMovieClip(this); } else { if (this.hitTest(_root.back[you].body.hit)) { this.gotoAndPlay(2); this.action = 'explode'; _root.damage(20, you); if (this._xscale == 100) { _root.player_xspeed = 20; } else { _root.player_xspeed = -20; } _root[you + '_action'] = 'fall'; } else { if (this.hitTest(_root.back[you].body.block)) { this.gotoAndPlay(2); if (this._xscale == 100) { _root.player_xspeed = 5; } else { _root.player_xspeed = -5; } this.action = 'explode'; } } } } else { if (action == 'unload') { removeMovieClip(this); } } }; } frame 24 { action = 'unload'; } } movieClip 1117 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 1118 { } movieClip 1119 { } movieClip 1120 { frame 2 { _root.snd.woom.play(); } } movieClip 1121 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 38 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 1122 { } movieClip 1123 { frame 1 { play(); } frame 44 { play(); } } movieClip 1124 { frame 4 { _root.snd.woom.play(); } frame 19 { stop(); punch = 'done'; } } movieClip 1125 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 1126 { frame 6 { _root.snd.woom.play(); } instance of movieClip 873 { onClipEvent (enterFrame) { if (_root.dis < 300) { if (_parent._parent.me == 'player') { if (_root.rightkey == true or _root.leftkey == true) { _parent.gotoAndPlay('hit'); } } if (_parent._parent.me == 'enemy') { trace('giuliani strike ' + dis); _parent.gotoAndPlay('hit'); } } } } } movieClip 1127 { frame 12 { shoot = true; } } movieClip 1128 { } movieClip 1129 { } movieClip 1130 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 35 { gotoAndStop('out'); } frame 36 { play(); } frame 54 { stop(); } frame 55 { stop(); } } movieClip 1131 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 35 { gotoAndStop('out'); } frame 36 { play(); } frame 54 { stop(); } frame 55 { stop(); } } movieClip 1132 fighter11 { frame 1 { stop(); } frame 1 { stop(); } instance of movieClip 1126 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 30) { this._alpha += 10; } } } frame 15 { body.gotoAndPlay('doved'); } } movieClip 1133 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 1134 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 1135 { } movieClip 1136 { } movieClip 1137 { frame 2 { _root.snd.woom.play(); } } movieClip 1138 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 38 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 1139 { } movieClip 1140 { frame 1 { play(); } frame 44 { play(); } } movieClip 1141 { frame 4 { _root.snd.woom.play(); } frame 17 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 18 { stop(); punch = 'done'; } } movieClip 1142 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 1143 { frame 6 { _root.snd.woom.play(); } instance of movieClip 873 { onClipEvent (enterFrame) { if (_root.dis < 300) { if (_parent._parent.me == 'player') { if (_root.rightkey == true or _root.leftkey == true) { _parent.gotoAndPlay('hit'); } } if (_parent._parent.me == 'enemy') { trace('giuliani strike ' + dis); _parent.gotoAndPlay('hit'); } } } } } movieClip 1145 { frame 7 { shoot = true; } } movieClip 1146 { } movieClip 1147 { } movieClip 1148 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 35 { gotoAndStop('out'); } frame 36 { play(); } frame 54 { stop(); } frame 55 { stop(); } } movieClip 1149 fighter12 { frame 1 { stop(); } frame 1 { stop(); } instance of movieClip 1143 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 30) { this._alpha += 10; } } } frame 15 { body.gotoAndPlay('doved'); } } movieClip 1152 { frame 40 { stop(); } } movieClip 1153 fireball11 { frame 1 { function frag(name) { if (name.defined == undefined) { name.xspeed = random(60) - 30; name.yspeed = -random(50); name.rotspeed = random(10) - 5; name.defined = true; } name._x += name.xspeed; name._y += name.yspeed; name.yspeed += 2; name._alpha -= 3; name._rotation += name.rotspeed; } } frame 1 { stop(); stop(); action = 'fall'; if (me == 'player') { you = 'enemy'; } else { you = 'player'; } yspeed = 0; onEnterFrame = function () { if (action == 'fall') { this._y += yspeed; if (this._xscale == 100) { this._x += 30; } else { this._x -= 30; } if (this._x > 2200 or this._x < -200) { removeMovieClip(this); } else { if (this.hitTest(_root.back[you].body.hit)) { this.gotoAndPlay(2); this.action = 'explode'; _root.damage(20, you); if (this._xscale == 100) { _root.player_xspeed = 20; } else { _root.player_xspeed = -20; } _root[you + '_action'] = 'fall'; } else { if (this.hitTest(_root.back[you].body.block)) { this.gotoAndPlay(2); if (this._xscale == 100) { _root.player_xspeed = 5; } else { _root.player_xspeed = -5; } this.action = 'explode'; } } } } else { if (action == 'unload') { removeMovieClip(this); } } }; } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1056 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1059 { onClipEvent (enterFrame) { _parent.frag(this); } } instance of movieClip 1062 { onClipEvent (enterFrame) { _parent.frag(this); } } frame 37 { action = 'unload'; stop(); } } movieClip 1157 { } movieClip 1158 { } movieClip 1160 { } movieClip 1161 { frame 44 { stop(); removeMovieClip(_parent); } } movieClip 1162 fireball12 { frame 1 { onEnterFrame = function () { this._x = me._x; this._y = me._y - 250; trace(me + ' - ' + me._x); if (this.fb.hit.hitTest(_root.back[you].body.hit)) { _root.damage(20, you); if (this._xscale == 100) { _root[you + '_xspeed'] = 20; } else { _root[you + '_xspeed'] = -20; } _root[you + '_action'] = 'fall'; } else { if (this.fb.hit.hitTest(_root.back[you].body.block)) { if (this._xscale == 100) { _root[you + '_xspeed'] = 5; } else { _root[you + '_xspeed'] = -5; } } } }; } } movieClip 1163 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 1164 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 1165 { } movieClip 1166 { } movieClip 1167 { frame 2 { _root.snd.woom.play(); } } movieClip 1168 { } movieClip 1169 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 64 { fallstatus = 'up'; stop(); } } movieClip 1170 { } movieClip 1171 { } movieClip 1172 { frame 2 { _root.snd.woom.play(); } frame 20 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 21 { stop(); punch = 'done'; } } movieClip 1173 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 1174 { } movieClip 1175 { frame 1 { _root.player_hardspeedoveride = true; } frame 7 { if (_parent._name == 'player') { if (_root.leftkey == true or _root.rightkey == true) { } else { _root.player_yspeed = -20; if (_root.back.player._xscale == 100) { _root.player_xspeed = 10; } else { if (_root.back.player._xscale == -100) { _root.player_xspeed = -10; } } gotoAndPlay('jump2'); } } else { if (_parent._name == 'enemy') { if (_root.enemy_xspeed == 0) { gotoAndPlay('jump'); } } } } instance of movieClip 1174 { onClipEvent (enterFrame) { if (_root.dis < 200) { _parent.gotoAndPlay('jump'); } } } frame 27 { if (_parent._name == 'player') { _root.player_yspeed = -12; if (_root.player_xspeed > 0) { _root.player_xspeed = 40; } else { if (_root.player_xspeed < 0) { _root.player_xspeed = -40; } } } else { if (_parent._name == 'enemy') { _root.enemy_yspeed = -12; if (_root.enemy_xspeed > 0) { _root.enemy_xspeed = 40; } else { if (_root.enemy_xspeed < 0) { _root.enemy_xspeed = -40; } } } } } } movieClip 1179 { frame 1 { function fireball() { ++_root.fbsn; _root.back.attachMovie('fireball8', 'fb' + _root.fbsn, 100 + _root.fbsn); _root.back['fb' + _root.fbsn].me = _parent._name; _root.back['fb' + _root.fbsn]._xscale = _parent._xscale; if (_parent._xscale == 100) { _root.back['fb' + _root.fbsn]._x = _parent._x + 50; } else { _root.back['fb' + _root.fbsn]._x = _parent._x - 50; } _root.back['fb' + _root.fbsn]._y = _parent._y - 205; } } frame 9 { shoot = true; } frame 10 { fireball(); } frame 22 { fireball(); } frame 35 { fireball(); } } movieClip 1180 { } movieClip 1181 { } movieClip 1182 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 41 { gotoAndStop('out'); } frame 42 { play(); } frame 63 { stop(); } } movieClip 1183 fighter14 { frame 1 { stop(); } frame 1 { stop(); } frame 11 { } } movieClip 1184 { frame 1 { stop(); } frame 2 { gotoAndStop(1); } frame 3 { if (walkdir == 'b') { gotoAndStop('walkback'); } else { if (walkdir == 'f') { gotoAndStop('walkfor'); } } } frame 8 { if (walkdir == 'b') { gotoAndStop('loop2'); } } frame 50 { if (walkdir == 'f') { gotoAndStop('loop'); } } frame 54 { play(); } frame 57 { walkdir = ''; gotoAndStop(1); } } movieClip 1185 { frame 31 { gotoAndPlay('loop'); } frame 64 { gotoAndPlay('loop2'); } } movieClip 1186 { } movieClip 1187 { } movieClip 1188 { frame 2 { _root.snd.woom.play(); } } movieClip 1189 { frame 12 { if (fallstatus == 'ground') { play(); } else { gotoAndPlay(_currentframe - 1); } } frame 24 { fallstatus = 'deathtest'; } frame 65 { fallstatus = 'up'; stop(); } } movieClip 1190 { } movieClip 1191 { } movieClip 1192 { frame 4 { _root.snd.woom.play(); } frame 18 { if (_root.ckey == true) { gotoAndPlay(2); } } frame 19 { stop(); punch = 'done'; } } movieClip 1193 { frame 3 { _root.snd.woom.play(); } frame 11 { _root.snd.woom.play(); } } movieClip 1194 { frame 6 { _root.snd.woom.play(); } instance of movieClip 873 { onClipEvent (enterFrame) { if (_root.dis < 300) { if (_parent._parent.me == 'player') { if (_root.rightkey == true or _root.leftkey == true) { _parent.gotoAndPlay('hit'); } } if (_parent._parent.me == 'enemy') { trace('giuliani strike ' + dis); _parent.gotoAndPlay('hit'); } } } } } movieClip 1202 { frame 9 { shoot = true; } } movieClip 1203 { } movieClip 1204 { } movieClip 1205 { frame 1 { stop(); } frame 10 { gotoAndStop(1); } frame 38 { gotoAndStop('out'); } } movieClip 1206 fighter13 { frame 1 { stop(); } frame 1 { stop(); } frame 11 { } instance of movieClip 1194 { onClipEvent (enterFrame) { this.gotoAndStop(_parent.body._currentframe); this._x = _parent.body._x - Math.abs(_root[_parent._name + '_xspeed'] * 2); if (this._alpha < 60) { this._alpha += 10; } } } } movieClip 1209 { frame 1 { stop(); } frame 5 { stop(); } frame 6 { stop(); } } movieClip 1210 fireball13 { frame 1 { onEnterFrame = function () { _root.fireballcodebiden(this); }; } instance head3 of movieClip 1209 { onClipEvent (enterFrame) { _root.bfoot(this); } } instance head2 of movieClip 1209 { onClipEvent (enterFrame) { _root.bfoot(this); } } instance head1 of movieClip 1209 { onClipEvent (enterFrame) { _root.bfoot(this); } } } movieClip 1211 { frame 1 { stop(); } frame 2 { } } movieClip 1213 { } movieClip 1215 { } movieClip 1216 { frame 1 { stop(); } instance of movieClip 1215 { onClipEvent (load) { trace('shakeit'); countup = 10; starty = _root.back._y; shakeit = 'down'; } onClipEvent (enterFrame) { if (shakeit == 'down') { _root.back._y = starty + countup * 8; trace('up ' + _root.back._y); shakeit = 'up'; } else { --countup; _root.back._y = starty; trace('down ' + _root.back._y); shakeit = 'down'; } } } } instance shake of movieClip 1216 { onClipEvent (enterFrame) { if (this._currentframe == 1) { _root.shakenow = false; } else { _root.shakenow = true; } } } frame 13 { ready._visible = false; ready.gotoAndPlay('training'); enemy_charnum = 9; trace('train it'); } frame 13 { beginfight(); onEnterFrame = function () { engine(); }; } movieClip 1222 { } movieClip 1224 { } movieClip 1231 { frame 1 { stop(); } } movieClip 1240 { frame 3 { gotoAndStop(_currentframe + 1 + random(2)); } } movieClip 1241 { frame 1 { stop(); } instance of movieClip 1231 { onClipEvent (load) { this.gotoAndStop(random(4)); } } } movieClip 1258 { } movieClip 1274 { instance hit of movieClip 1258 { onClipEvent (enterFrame) { if (this.hitTest(_level1.player.hit)) { _level1.hurthalf.play(); } } } frame 15 { gotoAndPlay('loop'); } frame 34 { _parent._parent.gotoAndStop(1); } } movieClip 1275 { instance fb of movieClip 1274 { onClipEvent (enterFrame) { if (this.hitTest(_level1.player.hit)) { _level1.hurthalf.play(); } } } frame 34 { stop(); _parent.gotoAndStop(1); } } movieClip 1278 { } movieClip 1279 { frame 17 { stop(); } frame 18 { play(); } frame 28 { _parent._parent.gotoAndStop(1); } } movieClip 1281 { frame 34 { stop(); _parent.gotoAndStop(1); } } movieClip 1283 { } movieClip 1284 { frame 1 { stop(); } frame 22 { stop(); _parent._parent._parent.gotoAndStop(1); } frame 23 { gotoAndStop(_currentframe - 1); } } movieClip 1285 { frame 1 { } frame 13 { stop(); } instance harpoon of movieClip 1284 { onClipEvent (enterFrame) { trace(_parent._currentframe); if (me == undefined or you == undefined) { you = _parent.you; me = _parent.me; } if (action == 'fly') { this._x += xspeed; disx += xspeed; if (this.hit.hitTest(_root.back[you].body.hit) & _root[you + '_jump'] != 'jumping') { _root.snd.hard.play(); _root.snd.comehere.play(); _root[you + '_action'] = 'harpooned'; _root.back[you].gotoAndPlay('harpooned'); _root.back[me].body.gotoAndPlay('reel'); _parent.play(); _root.blood(4, 30, me, you); _root.damage(10, you); delayct = 20; action = 'delay'; } else { if (this.hit.hitTest(_root.back[you].body.block)) { _root.snd.block.play(); _root.back[me].body.gotoAndPlay('miss'); this.play(); action = 'blocked'; } else { if (disx > 800) { _root.back[me].body.gotoAndPlay('miss'); action = 'missed'; } } } } else { if (action == 'delay') { _root[you + '_action'] = 'harpooned'; _root.back[you].gotoAndStop('harpooned'); _root.back[you].body.gotoAndStop(1); if (delayct <= 0) { action = 'reelin'; } else { --delayct; } } else { if (action == 'reelin') { _root[you + '_action'] = 'harpooned'; _root.back[you].gotoAndStop('harpooned'); _root.back[you].body.gotoAndStop(1); if (_root.dis < 150) { _root.back[me].body.gotoAndPlay('reeled'); action = 'reeled'; } else { this._x -= 30; if (_root.back[me]._xscale == 100) { _root.back[you]._x -= 30; } else { if (_root.back[me]._xscale == -100) { _root.back[you]._x += 30; } } } } else { if (action == 'reeled') { _parent._parent.gotoAndStop(1); } else { if (action == 'missed') { this._x += xspeed; disx += xspeed; if (disx > 1600) { _parent._parent.gotoAndStop(1); } } else { if (action == 'blocked') { if (this._currentframe >= 21) { _parent._parent.gotoAndStop(1); } } } } } } } } onClipEvent (load) { xspeed = 55; disx = 0; action = 'fly'; } } frame 21 { stop(); } } movieClip 1286 { frame 35 { stop(); _parent.gotoAndStop(1); } } movieClip 1287 { frame 1 { stop(); } instance en of movieClip 1281 { onClipEvent (enterFrame) { if (this._currentframe != 1) { this.play(); } } } } movieClip 1292 { } movieClip 1293 { frame 1 { stop(); } frame 13 { stop(); } } movieClip 1294 { frame 1 { stop(); shad1._alpha = 50; shad2._alpha = 0; } instance of movieClip 1222 { onClipEvent (load) { this.swapDepths(10001); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1222 { onClipEvent (load) { this.swapDepths(10002); } onClipEvent (enterFrame) { _root.unloader(this); } } instance shad1 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.player._x; this._y = _root.bot; } } instance shad2 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.enemy._x; this._y = _root.bot; } } instance blooddrop of movieClip 1241 { onClipEvent (enterFrame) { _root.bloodmovement(this); } } instance player_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'enemy'; this.en.me = 'player'; } } instance enemy_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'player'; this.en.me = 'enemy'; } } instance dove of movieClip 1293 { onClipEvent (enterFrame) { _root.dove_fly(this, me, you); } } } instance back of movieClip 1294 { } button 1297 { on (press) { gotoAndStop(2); } } button 1299 { on (press) { _root.musicvol = 'off'; stopAllSounds(); gotoAndStop(1); } } movieClip 1301 { frame 1 { stop(); } frame 2 { } } instance of movieClip 1301 { onClipEvent (load) { if (_root.musicvol == 'on') { gotoAndStop(2); } } } movieClip 1306 { frame 56 { stop(); onPress = function () { _root.fader.play(); _root.fader.dest = 'rank'; }; } } instance of movieClip 1306 { onClipEvent (enterFrame) { if (_root.training != true) { loadMovie('', this); } } } movieClip 1309 { } movieClip 1310 { } movieClip 1329 { } movieClip 1330 { } movieClip 1335 { frame 1 { stop(); } } movieClip 1337 { frame 1 { stop(); } } movieClip 1344 { frame 1 { stop(); } } movieClip 1348 { frame 1 { stop(); } } movieClip 1350 { frame 1 { stop(); } } movieClip 1351 { instance playerbar of movieClip 1310 { onClipEvent (load) { startwidth = this._width; } onClipEvent (enterFrame) { curlife = _root.player_life; if (curlife <= 0 & curlife != undefined) { this.life._width = 0; } if (this.life._width > curlife) { dif = this.life._width - curlife; this.life._width -= dif / 25; if (dif < 0.2) { this.life._width = curlife; } } } onClipEvent (mouseDown) { } } instance enemybar of movieClip 1310 { onClipEvent (load) { startwidth = this._width; } onClipEvent (enterFrame) { curlife = _root.enemy_life; if (curlife <= 0 & curlife != undefined) { this.life._width = 0; } if (this.life._width > curlife) { dif = this.life._width - curlife; this.life._width -= dif / 10; if (dif < 0.2) { this.life._width = curlife; } } } onClipEvent (mouseDown) { } } instance of movieClip 1335 { onClipEvent (enterFrame) { this.gotoAndStop(_root.player_charnum); } } instance of movieClip 1337 { onClipEvent (enterFrame) { this.gotoAndStop(_root.enemy_charnum); } } instance of movieClip 1344 { onClipEvent (enterFrame) { this.gotoAndStop(_root.roundnum); } } instance of movieClip 1348 { onClipEvent (enterFrame) { this.gotoAndPlay(_root.player_roundswon + 1); } } instance of movieClip 1350 { onClipEvent (enterFrame) { this.gotoAndPlay(_root.enemy_roundswon + 1); } } } instance bars of movieClip 1351 { onClipEvent (enterFrame) { if (_root.training == true) { this._visible = false; } } } frame 14 { this.createEmptyMovieClip('loader', -6000); loader.onEnterFrame = function () { ifFrameLoaded (15) { gotoAndStop('game1'); delete loader.onEnterFrame; } }; } frame 15 { beginfight(); onEnterFrame = function () { engine(); }; } movieClip 1357 { frame 1 { stop(); } } movieClip 1360 { } movieClip 1363 { frame 8 { _parent.removeMovieClip(); } } movieClip 1364 { frame 1 { stop(); } } movieClip 1365 { frame 1 { shad1._alpha = 80; shad2._alpha = 80; } frame 1 { function rain(name) { if (name._name != 'rain') { if (name.defined == undefined) { name._x = -_root.back._x + random(800); name._y = -150; name._height = random(50) + 20; name._alpha = 50 + random(50); name.action = 'fall'; name.bot = 350 + random(120); name.defined = true; } if (name.action == 'fall') { name._y += 30; if (name._y > name.bot) { name._y = name.bot; name.action = 'hit'; } } else { if (name.action == 'hit') { name.gotoAndStop(2); } } } } rsn = 0; raincount = 0; rainlim = random(3); onEnterFrame = function () { ++raincount; if (raincount > rainlim) { raincount = 0; rainlim = random(6); ++rsn; if (rsn > 100) { rsn = 0; } duplicateMovieClip('rain', 'rain' + rsn, rsn + 10005); } }; } frame 1 { ytype = 'scroll'; } instance of movieClip 1357 { onClipEvent (enterFrame) { this.gotoAndStop(random(40)); this._x = -_parent._x; } onClipEvent (load) { this.swapDepths(10001); } onClipEvent (enterFrame) { _root.unloader(this); } } instance shad1 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.player._x; this._y = _root.bot; } } instance shad2 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.enemy._x; this._y = _root.bot; } } instance blooddrop of movieClip 1241 { onClipEvent (enterFrame) { _root.bloodmovement(this); } } instance player_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'enemy'; this.en.me = 'player'; } } instance enemy_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'player'; this.en.me = 'enemy'; } } instance dove of movieClip 1293 { onClipEvent (enterFrame) { _root.dove_fly(this, me, you); } } instance rain of movieClip 1364 { onClipEvent (enterFrame) { _parent.rain(this); } } } button 1368 { on (press) { gotoAndStop(2); } } button 1370 { on (press) { _root.musicvol = 'off'; stopAllSounds(); gotoAndStop(1); } } movieClip 1372 { frame 1 { stop(); } } instance of movieClip 1372 { onClipEvent (load) { if (_root.musicvol == 'on') { gotoAndStop(2); } } } button 1374 { on (press) { stopAllSounds(); _root.fader.play(); _root.fader.dest = 'open'; } } movieClip 1375 { } instance of movieClip 728 { onClipEvent (enterFrame) { if (_root.back.player._x < _root.back.enemy._x) { if (_root.rightkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.rightkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } else { if (_root.leftkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.leftkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } } } instance of movieClip 732 { onClipEvent (enterFrame) { total_time = getTimer(); cur_time = total_time - mark_time; if (cur_time > 1000) { mark_time = total_time; this.fp = this._currentframe; a = 45; if ((fp / a) * 100 < 100) { this.afps = (fp / a) * 100; } else { this.afps = 100; } this.gotoAndPlay(1); } _root.gamespeed = int(this.afps); } onClipEvent (load) { mark_time = getTimer(); } } frame 16 { this.createEmptyMovieClip('loader', -6000); loader.onEnterFrame = function () { ifFrameLoaded (17) { gotoAndStop('game2'); delete loader.onEnterFrame; } }; } frame 17 { beginfight(); onEnterFrame = function () { engine(); }; } movieClip 1378 { frame 1 { shad1._alpha = 26; shad2._alpha = 26; } frame 1 { delete onEnterFrame; } frame 1 { ytype = 'noscroll'; } instance shad1 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.player._x; this._y = _root.bot; } } instance shad2 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.enemy._x; this._y = _root.bot; } } instance blooddrop of movieClip 1241 { onClipEvent (enterFrame) { _root.bloodmovement(this); } } instance player_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'enemy'; this.en.me = 'player'; } } instance enemy_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'player'; this.en.me = 'enemy'; } } instance dove of movieClip 1293 { onClipEvent (enterFrame) { _root.dove_fly(this, me, you); } } } button 1380 { on (press) { gotoAndStop(2); } } button 1381 { on (press) { _root.musicvol = 'off'; stopAllSounds(); gotoAndStop(1); } } movieClip 1383 { frame 1 { stop(); } } instance of movieClip 1383 { onClipEvent (load) { if (_root.musicvol == 'on') { gotoAndStop(2); } } } instance of movieClip 728 { onClipEvent (enterFrame) { if (_root.back.player._x < _root.back.enemy._x) { if (_root.rightkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.rightkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } else { if (_root.leftkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.leftkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } } } instance of movieClip 732 { onClipEvent (enterFrame) { total_time = getTimer(); cur_time = total_time - mark_time; if (cur_time > 1000) { mark_time = total_time; this.fp = this._currentframe; a = 45; if ((fp / a) * 100 < 100) { this.afps = (fp / a) * 100; } else { this.afps = 100; } this.gotoAndPlay(1); } _root.gamespeed = int(this.afps); } onClipEvent (load) { mark_time = getTimer(); } } frame 18 { this.createEmptyMovieClip('loader', -6000); loader.onEnterFrame = function () { ifFrameLoaded (19) { gotoAndStop('game3'); delete loader.onEnterFrame; } }; } frame 19 { beginfight(); onEnterFrame = function () { engine(); }; } movieClip 1389 { } movieClip 1392 { } movieClip 1393 { frame 1 { shad1._alpha = 100; shad2._alpha = 100; } frame 1 { ytype = 'scroll'; } instance of movieClip 1389 { onClipEvent (load) { this.swapDepths(10001); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1392 { onClipEvent (load) { this.swapDepths(10002); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1389 { onClipEvent (load) { this.swapDepths(10003); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1392 { onClipEvent (load) { this.swapDepths(10004); } onClipEvent (enterFrame) { _root.unloader(this); } } instance shad1 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.player._x; this._y = _root.bot; } } instance shad2 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.enemy._x; this._y = _root.bot; } } instance blooddrop of movieClip 1241 { onClipEvent (enterFrame) { _root.bloodmovement(this); } } instance player_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'enemy'; this.en.me = 'player'; } } instance enemy_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'player'; this.en.me = 'enemy'; } } instance dove of movieClip 1293 { onClipEvent (enterFrame) { _root.dove_fly(this, me, you); } } instance of movieClip 1357 { onClipEvent (enterFrame) { this.gotoAndStop(random(40)); this._x = -_parent._x; } onClipEvent (load) { this.swapDepths(10005); } onClipEvent (enterFrame) { _root.unloader(this); } } } instance of movieClip 1301 { onClipEvent (load) { if (_root.musicvol == 'on') { gotoAndStop(2); } } } instance of movieClip 728 { onClipEvent (enterFrame) { if (_root.back.player._x < _root.back.enemy._x) { if (_root.rightkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.rightkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } else { if (_root.leftkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.leftkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } } } instance of movieClip 732 { onClipEvent (enterFrame) { total_time = getTimer(); cur_time = total_time - mark_time; if (cur_time > 1000) { mark_time = total_time; this.fp = this._currentframe; a = 45; if ((fp / a) * 100 < 100) { this.afps = (fp / a) * 100; } else { this.afps = 100; } this.gotoAndPlay(1); } _root.gamespeed = int(this.afps); } onClipEvent (load) { mark_time = getTimer(); } } frame 20 { this.createEmptyMovieClip('loader', -6000); loader.onEnterFrame = function () { ifFrameLoaded (21) { gotoAndStop('game4'); delete loader.onEnterFrame; } }; } frame 21 { bot = 405; beginfight(); onEnterFrame = function () { engine(); }; } movieClip 1401 { } movieClip 1406 { } movieClip 1408 { } movieClip 1409 { frame 1 { shad1._alpha = 100; shad2._alpha = 100; } frame 1 { ytype = 'noscroll'; } instance of movieClip 1408 { onClipEvent (load) { this.swapDepths(10001); } onClipEvent (enterFrame) { _root.unloader(this); } } instance shad1 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.player._x; this._y = _root.bot; } } instance shad2 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.enemy._x; this._y = _root.bot; } } instance blooddrop of movieClip 1241 { onClipEvent (enterFrame) { _root.bloodmovement(this); } } instance player_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'enemy'; this.en.me = 'player'; } } instance enemy_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'player'; this.en.me = 'enemy'; } } instance dove of movieClip 1293 { onClipEvent (enterFrame) { _root.dove_fly(this, me, you); } } } instance of movieClip 1372 { onClipEvent (load) { if (_root.musicvol == 'on') { gotoAndStop(2); } } } instance of movieClip 728 { onClipEvent (enterFrame) { if (_root.back.player._x < _root.back.enemy._x) { if (_root.rightkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.rightkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } else { if (_root.leftkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.leftkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } } } instance of movieClip 732 { onClipEvent (enterFrame) { total_time = getTimer(); cur_time = total_time - mark_time; if (cur_time > 1000) { mark_time = total_time; this.fp = this._currentframe; a = 45; if ((fp / a) * 100 < 100) { this.afps = (fp / a) * 100; } else { this.afps = 100; } this.gotoAndPlay(1); } _root.gamespeed = int(this.afps); } onClipEvent (load) { mark_time = getTimer(); } } frame 22 { this.createEmptyMovieClip('loader', -6000); loader.onEnterFrame = function () { ifFrameLoaded (23) { gotoAndStop('game5'); delete loader.onEnterFrame; } }; } frame 23 { bot = 425; beginfight(); onEnterFrame = function () { engine(); }; } movieClip 1415 { } movieClip 1418 { } movieClip 1419 { frame 1 { shad1._alpha = 100; shad2._alpha = 100; } frame 1 { ytype = 'noscroll'; } instance of movieClip 1415 { onClipEvent (load) { this.swapDepths(10002); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1418 { onClipEvent (load) { this.swapDepths(10001); } onClipEvent (enterFrame) { _root.unloader(this); } } instance shad1 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.player._x; this._y = _root.bot; } } instance shad2 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.enemy._x; this._y = _root.bot; } } instance blooddrop of movieClip 1241 { onClipEvent (enterFrame) { _root.bloodmovement(this); } } instance player_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'enemy'; this.en.me = 'player'; } } instance enemy_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'player'; this.en.me = 'enemy'; } } instance dove of movieClip 1293 { onClipEvent (enterFrame) { _root.dove_fly(this, me, you); } } } instance of movieClip 1301 { onClipEvent (load) { if (_root.musicvol == 'on') { gotoAndStop(2); } } } instance of movieClip 728 { onClipEvent (enterFrame) { if (_root.back.player._x < _root.back.enemy._x) { if (_root.rightkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.rightkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } else { if (_root.leftkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.leftkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } } } instance of movieClip 732 { onClipEvent (enterFrame) { total_time = getTimer(); cur_time = total_time - mark_time; if (cur_time > 1000) { mark_time = total_time; this.fp = this._currentframe; a = 45; if ((fp / a) * 100 < 100) { this.afps = (fp / a) * 100; } else { this.afps = 100; } this.gotoAndPlay(1); } _root.gamespeed = int(this.afps); } onClipEvent (load) { mark_time = getTimer(); } } frame 24 { this.createEmptyMovieClip('loader', -6000); loader.onEnterFrame = function () { ifFrameLoaded (25) { gotoAndStop('game6'); delete loader.onEnterFrame; } }; } frame 25 { beginfight(); onEnterFrame = function () { engine(); }; } movieClip 1425 { } movieClip 1428 { } movieClip 1429 { frame 1 { shad1._alpha = 30; shad2._alpha = 30; } frame 1 { ytype = 'scroll'; } instance of movieClip 1425 { onClipEvent (load) { this.swapDepths(10001); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1428 { onClipEvent (load) { this.swapDepths(10002); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1425 { onClipEvent (load) { this.swapDepths(10003); } onClipEvent (enterFrame) { _root.unloader(this); } } instance of movieClip 1428 { onClipEvent (load) { this.swapDepths(10004); } onClipEvent (enterFrame) { _root.unloader(this); } } instance shad1 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.player._x; this._y = _root.bot; } } instance shad2 of movieClip 1224 { onClipEvent (enterFrame) { this._x = _parent.enemy._x; this._y = _root.bot; } } instance blooddrop of movieClip 1241 { onClipEvent (enterFrame) { _root.bloodmovement(this); } } instance player_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'enemy'; this.en.me = 'player'; } } instance enemy_fireball of movieClip 1287 { onClipEvent (enterFrame) { this.en.you = 'player'; this.en.me = 'enemy'; } } instance dove of movieClip 1293 { onClipEvent (enterFrame) { _root.dove_fly(this, me, you); } } } instance of movieClip 1383 { onClipEvent (load) { if (_root.musicvol == 'on') { gotoAndStop(2); } } } instance of movieClip 728 { onClipEvent (enterFrame) { if (_root.back.player._x < _root.back.enemy._x) { if (_root.rightkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.rightkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } else { if (_root.leftkey == true) { this.play(); if (firstkeyup == true) { secondkeyup = true; } else { secondkeyup = false; } } if (_root.ckey == true & secondkeyup == true & this._currentframe > 1) { _root.fb_seq = true; trace('fb'); secondkeyup = false; firstkeyup = false; } if (this._currentframe > 1) { if (_root.leftkey == false) { firstkeyup = true; } } else { _root.fb_seq = false; secondkeyup = false; firstkeyup = false; } } } } instance of movieClip 732 { onClipEvent (enterFrame) { total_time = getTimer(); cur_time = total_time - mark_time; if (cur_time > 1000) { mark_time = total_time; this.fp = this._currentframe; a = 45; if ((fp / a) * 100 < 100) { this.afps = (fp / a) * 100; } else { this.afps = 100; } this.gotoAndPlay(1); } _root.gamespeed = int(this.afps); } onClipEvent (load) { mark_time = getTimer(); } }




http://swfchan.com/10/49223/info.shtml
Created: 28/4 -2019 10:03:37 Last modified: 28/4 -2019 10:03:37 Server time: 25/04 -2024 00:30:05