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

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

chat bot in development process..swf

This is the info page for
Flash #142953

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


Text
<p align="left"></p>

ActionScript [AS3]

Section 1
//MainTimeline (videoplayer_fla.MainTimeline) package videoplayer_fla { import flash.events.*; import flash.display.*; import flash.media.*; import flash.net.*; import flash.utils.*; import adobe.utils.*; import flash.accessibility.*; import flash.errors.*; import flash.external.*; import flash.filters.*; import flash.geom.*; import flash.printing.*; import flash.profiler.*; import flash.sampler.*; import flash.system.*; import flash.text.*; import flash.ui.*; import flash.xml.*; public dynamic class MainTimeline extends MovieClip { public const BUFFER_TIME:Number = 8; public const DEFAULT_VOLUME:Number = 0.6; public const DISPLAY_TIMER_UPDATE_DELAY:int = 10; public const SMOOTHING:Boolean = true; public var mcVideoControls:MovieClip; public var vidDisplay:Video; public var bolLoaded:Boolean; public var bolVolumeScrub:Boolean; public var bolProgressScrub:Boolean; public var intLastVolume:Number; public var ncConnection:NetConnection; public var nsStream:NetStream; public var objInfo:Object; public var strSource:String; public var tmrDisplay:Timer; public function MainTimeline(){ addFrameScript(0, frame1); } public function initVideoPlayer():void{ mcVideoControls.btnUnmute.visible = false; mcVideoControls.btnPause.visible = false; mcVideoControls.mcProgressFill.mcFillRed.width = 1; mcVideoControls.mcProgressFill.mcFillGrey.width = 1; stage.addEventListener(MouseEvent.MOUSE_UP, mouseReleased); mcVideoControls.btnPause.addEventListener(MouseEvent.CLICK, pauseClicked); mcVideoControls.btnPlay.addEventListener(MouseEvent.CLICK, playClicked); mcVideoControls.btnStop.addEventListener(MouseEvent.CLICK, stopClicked); mcVideoControls.btnMute.addEventListener(MouseEvent.CLICK, muteClicked); mcVideoControls.btnUnmute.addEventListener(MouseEvent.CLICK, unmuteClicked); mcVideoControls.mcVolumeScrubber.btnVolumeScrubber.addEventListener(MouseEvent.MOUSE_DOWN, volumeScrubberClicked); mcVideoControls.mcProgressScrubber.btnProgressScrubber.addEventListener(MouseEvent.MOUSE_DOWN, progressScrubberClicked); tmrDisplay = new Timer(DISPLAY_TIMER_UPDATE_DELAY); tmrDisplay.addEventListener(TimerEvent.TIMER, updateDisplay); ncConnection = new NetConnection(); ncConnection.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler); ncConnection.connect(null); nsStream = new NetStream(ncConnection); nsStream.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler); nsStream.client = this; nsStream.bufferTime = BUFFER_TIME; vidDisplay.attachNetStream(nsStream); vidDisplay.smoothing = SMOOTHING; mcVideoControls.mcVolumeScrubber.x = ((52 * DEFAULT_VOLUME) + 341); mcVideoControls.mcVolumeFill.mcFillRed.width = ((mcVideoControls.mcVolumeScrubber.x - 394) + 52); setVolume(DEFAULT_VOLUME); } public function playClicked(_arg1:MouseEvent):void{ if (!bolLoaded){ nsStream.play(strSource); bolLoaded = true; } else { nsStream.resume(); }; vidDisplay.visible = true; mcVideoControls.btnPause.visible = true; mcVideoControls.btnPlay.visible = false; } public function pauseClicked(_arg1:MouseEvent):void{ nsStream.pause(); mcVideoControls.btnPause.visible = false; mcVideoControls.btnPlay.visible = true; } public function stopClicked(_arg1:MouseEvent):void{ stopVideoPlayer(); } public function muteClicked(_arg1:MouseEvent):void{ setVolume(0); mcVideoControls.mcVolumeScrubber.x = 341; mcVideoControls.mcVolumeFill.mcFillRed.width = 1; } public function unmuteClicked(_arg1:MouseEvent):void{ setVolume(intLastVolume); mcVideoControls.mcVolumeScrubber.x = ((53 * intLastVolume) + 341); mcVideoControls.mcVolumeFill.mcFillRed.width = ((mcVideoControls.mcVolumeScrubber.x - 394) + 53); } public function volumeScrubberClicked(_arg1:MouseEvent):void{ bolVolumeScrub = true; mcVideoControls.mcVolumeScrubber.startDrag(false, new Rectangle(341, 19, 53, 0)); } public function progressScrubberClicked(_arg1:MouseEvent):void{ bolProgressScrub = true; mcVideoControls.mcProgressScrubber.startDrag(false, new Rectangle(0, 2, 432, 0)); } public function mouseReleased(_arg1:MouseEvent):void{ bolVolumeScrub = false; bolProgressScrub = false; mcVideoControls.mcProgressScrubber.stopDrag(); mcVideoControls.mcVolumeScrubber.stopDrag(); mcVideoControls.mcProgressFill.mcFillRed.width = (mcVideoControls.mcProgressScrubber.x + 5); mcVideoControls.mcVolumeFill.mcFillRed.width = ((mcVideoControls.mcVolumeScrubber.x - 394) + 53); if (((mcVideoControls.mcVolumeScrubber.x - 341) / 53) > 0){ intLastVolume = ((mcVideoControls.mcVolumeScrubber.x - 341) / 53); }; } public function updateDisplay(_arg1:TimerEvent):void{ if (bolProgressScrub){ nsStream.seek(Math.round(((mcVideoControls.mcProgressScrubber.x * objInfo.duration) / 432))); } else { mcVideoControls.mcProgressScrubber.x = ((nsStream.time * 432) / objInfo.duration); }; mcVideoControls.lblTimeDuration.htmlText = ((("<font color='#ffffff'>" + formatTime(nsStream.time)) + "</font> / ") + formatTime(objInfo.duration)); mcVideoControls.mcProgressFill.mcFillRed.width = (mcVideoControls.mcProgressScrubber.x + 5); mcVideoControls.mcProgressFill.mcFillGrey.width = ((nsStream.bytesLoaded * 438) / nsStream.bytesTotal); if (bolVolumeScrub){ setVolume(((mcVideoControls.mcVolumeScrubber.x - 341) / 53)); mcVideoControls.mcVolumeFill.mcFillRed.width = ((mcVideoControls.mcVolumeScrubber.x - 394) + 53); }; } public function onMetaData(_arg1:Object):void{ objInfo = _arg1; tmrDisplay.start(); } public function netStatusHandler(_arg1:NetStatusEvent):void{ switch (_arg1.info.code){ case "NetStream.Play.StreamNotFound": trace(("Stream not found: " + strSource)); break; case "NetStream.Play.Stop": stopVideoPlayer(); break; }; } public function stopVideoPlayer():void{ nsStream.pause(); nsStream.seek(0); vidDisplay.visible = false; mcVideoControls.btnPause.visible = false; mcVideoControls.btnPlay.visible = true; } public function setVolume(_arg1:Number=0):void{ var _local2:* = new SoundTransform(_arg1); nsStream.soundTransform = _local2; if (_arg1 > 0){ mcVideoControls.btnMute.visible = true; mcVideoControls.btnUnmute.visible = false; } else { mcVideoControls.btnMute.visible = false; mcVideoControls.btnUnmute.visible = true; }; } public function formatTime(_arg1:int):String{ var _local2:int = Math.round(_arg1); var _local3:int; if (_local2 > 0){ while (_local2 > 59) { _local3++; _local2 = (_local2 - 60); }; return (String(((((((_local3 < 10)) ? "0" : "" + _local3) + ":") + ((_local2 < 10)) ? "0" : "") + _local2))); } else { }; return (!NULL!); } function frame1(){ bolLoaded = false; bolVolumeScrub = false; bolProgressScrub = false; intLastVolume = DEFAULT_VOLUME; strSource = "http://www.mtpixel.com/demo.mp4"; initVideoPlayer(); } } }//package videoplayer_fla

Library Items

Symbol 1 GraphicUsed by:36
Symbol 2 GraphicUsed by:6 10 14 20 24
Symbol 3 GraphicUsed by:6
Symbol 4 GraphicUsed by:6
Symbol 5 GraphicUsed by:6
Symbol 6 ButtonUses:2 3 4 5Used by:36
Symbol 7 GraphicUsed by:10
Symbol 8 GraphicUsed by:10
Symbol 9 GraphicUsed by:10
Symbol 10 ButtonUses:2 7 8 9Used by:36
Symbol 11 GraphicUsed by:14
Symbol 12 GraphicUsed by:14
Symbol 13 GraphicUsed by:14
Symbol 14 ButtonUses:2 11 12 13Used by:36
Symbol 15 FontUsed by:16
Symbol 16 EditableTextUses:15Used by:36
Symbol 17 GraphicUsed by:20
Symbol 18 GraphicUsed by:20
Symbol 19 GraphicUsed by:20
Symbol 20 ButtonUses:2 17 18 19Used by:36
Symbol 21 GraphicUsed by:24
Symbol 22 GraphicUsed by:24
Symbol 23 GraphicUsed by:24
Symbol 24 ButtonUses:2 21 22 23Used by:36
Symbol 25 GraphicUsed by:26
Symbol 26 MovieClipUses:25Used by:29
Symbol 27 GraphicUsed by:28
Symbol 28 MovieClipUses:27Used by:29
Symbol 29 MovieClipUses:26 28Used by:36
Symbol 30 GraphicUsed by:33
Symbol 31 GraphicUsed by:33
Symbol 32 GraphicUsed by:33
Symbol 33 ButtonUses:30 31 32Used by:34 35
Symbol 34 MovieClipUses:33Used by:36
Symbol 35 MovieClipUses:33Used by:36
Symbol 36 MovieClipUses:1 6 10 14 16 20 24 29 34 35Used by:Timeline
Symbol 37 VideoUsed by:Timeline

Instance Names

"mcVideoControls"Frame 1Symbol 36 MovieClip
"vidDisplay"Frame 1Symbol 37 Video
"mcFillGrey"Symbol 29 MovieClip Frame 1Symbol 26 MovieClip
"mcFillRed"Symbol 29 MovieClip Frame 1Symbol 28 MovieClip
"btnVolumeScrubber"Symbol 34 MovieClip Frame 1Symbol 33 Button
"btnProgressScrubber"Symbol 35 MovieClip Frame 1Symbol 33 Button
"btnPause"Symbol 36 MovieClip Frame 1Symbol 6 Button
"btnPlay"Symbol 36 MovieClip Frame 1Symbol 10 Button
"btnStop"Symbol 36 MovieClip Frame 1Symbol 14 Button
"lblTimeDuration"Symbol 36 MovieClip Frame 1Symbol 16 EditableText
"btnUnmute"Symbol 36 MovieClip Frame 1Symbol 20 Button
"btnMute"Symbol 36 MovieClip Frame 1Symbol 24 Button
"mcVolumeFill"Symbol 36 MovieClip Frame 1Symbol 29 MovieClip
"mcProgressFill"Symbol 36 MovieClip Frame 1Symbol 29 MovieClip
"mcVolumeScrubber"Symbol 36 MovieClip Frame 1Symbol 34 MovieClip
"mcProgressScrubber"Symbol 36 MovieClip Frame 1Symbol 35 MovieClip

Special Tags

FileAttributes (69)Timeline Frame 1Access local files only, Metadata not present, AS3.




http://swfchan.com/29/142953/info.shtml
Created: 27/10 -2018 13:25:00 Last modified: 27/10 -2018 13:25:00 Server time: 22/12 -2024 09:06:05