毕业论文 论文提纲 论文写作 公文范例 教育论文 教育学论文 师范教育 学术论文     论文指导*
                     
 
   
   
   
   
           
 

当前位置:课件115学培吧(kj115.com)→flash网侠教程(助你成为顶尖课件高手)→系列文章

 
 
标题:导入电影的控制
 
展示台

文章来源 作者:admin 密码:admin 整理:湖北金鹰

◇网侠教程栏目简介
    提供FLASH侠客教程和网页制作侠客教程,高手进阶教程。
    浏览过这些资源的还浏览过经典教程图文教程游戏开发教程等相关资源。

---------------

湖北金鹰课件吧

论文相关服务
 

 

1,禁止导入电影,写在第一桢上
_root._name  =  "nn";
this.onEnterFrame  =  function()  {
if  (this._name  !=  "nn"    _root.getDepth()  !=  -16384)  {
this.unloadMovie();
}
};
2,只能导入,不能直接播放
_root.onLoad  =  function()  {
if  (this._level  ==  _level0    _parent  ==  undefined)  {
loadMovieNum("",  0);
}
};
3,导入完毕,控制电影属性,设导入电影剪辑mc中
_root.onEnterframe=function(){
if(mc._width!=0){
所设属性
}
}
4,使导入的图片在一定大小
onClipEvent  (load)  { 
this._width=288; 
this._height=209; 
if(this._width>288    this._height>209){ 
scalew=this._width/288; 
scaleh=this._height/209; 
if  (scalew>scaleh){ 
this._height=288/this._width*this._height; 
this._width=288; 
}else{ 
this._width=209/this._height*this._width; 
this._height=209; 
} 
} 
5,导入的电影无限循环播放
var  jilu
function  xh()  {
if  (mc._width  !=  0)  {
if  (mc._currentframe  ==  jilu)  {
_root.mc.gotoAndPlay(mc._currentframe+1);
}
jilu  =  mc._currentframe;
}
if  (mc._currentframe>=mc._totalframes)  {
mc.gotoAndPlay(1);
}
}
on  (press)  {
setInterval(_root.xh,  1000/12);
}
6,电影  的快进
var  nn
function  kuai()  {
if  (mc._width  !=  0  &&  mc._currentframe<mc._totalframes)  {
nn  =  Math.floor(mc._totalframes/200);
mc.gotoAndStop(mc._currentframe+nn);
if  ((mc._totalframes-mc._currentframe)<nn)  {
mc.gotoAndStop(mc._totalframes);

}
}
on  (press)  {
setInterval(_root.kuai,  1000/12);
}
7,导入mp3的淡隐,淡出
file://soundin
function  soundin()  {
sound1  =  setInterval(soundcontrol,  30,  true);
}
file://soundout
var  yy
function  soundout()  {
yy=1
sound1  =  setInterval(soundcontrol,  30,  false);
}
file://soundcontrol
var  sounding
function  soundcontrol(gg)  {
if  (mysound.getVolume()>0  &&  gg  ==  false  &&  yy  ==  1)  {
mysound.setVolume((mysound.getVolume()-1));
}  else  if  (mysound.getVolume()<=0  &&  gg  ==  false  &&  yy  ==  1)  {
sounding  =  mysound.position;
mysound.stop();
clearInterval(sound1);
}
}
if  (mysound.getVolume()<100  &&  gg  ==  true  &&  yy  ==  0)  {
mysound.setVolume((mysound.getVolume()+1));
}  else  if  (mysound.getVolume()  ==  100  &&  gg  ==  true  &&  yy  ==  0)  {
clearInterval(sound1);
}
}
8,随机导入
Array.prototype.get  =  function()  {
var  h1  =  this.slice(0,  -1);
var  i1  =  random(h1.length);
var  xx  =  h1[i1];
this.splice(i1,  1);
this.push(xx);
return  xx;
};
hh  =  ["mc1.swf",  "mc2.swf",  "mc3.swf",  "mc4.swf",  "mc5.swf",  "mc6.swf"];
mymc  =  hh.get();
loadMovieNum(mymc,  1);

 

 
课件115学培吧(湖北金鹰)欢迎您!永久免费服务网址:http://www.kj115.com
   
 

学员众多的FLASH课件学习基地,成万免费FLASH课件制作教程在线学习,还有免费内容课件教程、视频教程、课件技巧、课件探讨、课件欣赏、课件展示、实用教程、课件界面、课件脚本、课件游戏、课件下载、课件封面、课文内容图片、课文人物图片库、课件素材、图片素材、声音素材、动物素材、背景图片、背景资料、背景边框、课件顶栏图片素材、Dreamweaver教程、Dreamweaver网页课件教程、软件下载。承接学习和培训,承接课件订制,课件修改等所有课件相关服务。
本站主要业务:┃flash课件制作视频教程培训┃承接全国竞赛flash课件┃论文代写代发┃代办课件国家级获奖证书┃
联系:QQ:444860709 手机:13339817386


 
 

业务办理
鄂ICP备08005724号