教你做一个Flash的时钟

imbatman 分享 时间: 收藏本文

【简介】感谢网友“imbatman”参与投稿,以下是小编精心整理的教你做一个Flash的时钟(共5篇),供大家阅读参考。

篇1:教你做一个Flash的时钟

时钟

最终效果

第一步:打开Flash

第二步:首先把表盘画好(做的好看就行,比如我的^-^)

第三步:做三个影片剪辑,名称分别是 shizhen 、 fenzhen 、 miaozhen (自已随便,就画三条线就行了,注意粗细长短要有分别), 把三个表针底端对齐,并都指向12点,

第四步:在第一祯里写上如下AS(不明白回去看看帮助):

_root.onEnterFrame. = function {

var mydate = new Date();

setProperty(“ shizhen ”, _rotation, mydate.getHours()*30+mydate.getMinutes()*0.5);

setProperty(“ fenzhen ”, _rotation, mydate.getMinutes()*6);

setProperty(“ miaozhen ”, _rotation, mydate.getSeconds()*6);

};

第五步:反复修改,做个有个性的,

源文件下载

来源:我闪网

篇2:Flash AS创作:实时时钟

时钟

这两天做了一个实时的时钟~ 发上来和大家分享一下!

点击这里下载源文件

newDate = new Date();

newDate.month = newDate.getMonth()+1;

DateTextField =

newDate.getFullYear()+“-”+ newDate.month +“-”+ newDate.getDate();

now_hours = newDate.getHours();

if(length(now_hours)<2){

now_hours = “0” + now_hours;

}

now_minutes = newDate.getMinutes();

if(length(now_minutes)<2){

now_minutes = “0” + now_minutes;

}

now_seconds = newDate.getSeconds();

if(length(now_seconds)<2){

now_seconds = “0” + now_seconds;

}

TimeTextField =

now_hours +“:”+ now_minutes +“:”+ now_seconds;

_root.second._rotation = newDate.getSeconds()*6;

_root.minute._rotation = newDate.getMinutes()*6 + newDate.getSeconds()*(1/10);;

_root.hour._rotation = newDate.getHours()*30 + newDate.getMinutes()*(1/2);

原文件传上来,想要学的朋友可以下栽去看看

篇3:教你学做一个小齿轮

本文由www.jcwcn.com 中国教程网火眠原创, 此信息

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=“点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小”;}“ border=0>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=”点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小“;}” border=0>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=“点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小”;}“ border=0>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=”点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小“;}” border=0>

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=“点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小”;}“ border=0>

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=”点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小“;}” border=0>

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=“点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小”;}“ border=0>

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=”点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小“;}” border=0>

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=“点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小”;}“ border=0>

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=”点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小“;}” border=0>

screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt=“点击在新窗口查看全图nCTRL 鼠标滚轮放大或缩小”;}“ border=0>

篇4: 教你如何制作生成Flash木马程序

在网站上观看Flash动画,接收到“好友”发来的一张Flash贺卡,甚至于一个QQ魔法表情,一不留神就中了一个木马!Flash动画木马可以说是无处不在,攻击威力和覆盖面极其广,

教你如何制作生成Flash木马程序

。许多朋友一定想了解Flash木马的原理,想知道攻击者是如何在SWF中插入木马的呢?我们应该怎么样来防范Flash木马呢?

一、制作Flash动画木马的准备

Flash动画木马的原理,是在网页中显示或本地直接播放Flash动画木马时,让Flash自动打开一个网址,而该网址就是我们预先制作好的一个木马网页。也就是说,在制作网页木马前,我们首先需要制作好一个网页木马,并将它放置到某个网站上去。

另外,我们还需要准备一个比较吸引人的Flash动画文件“MM热舞.swf”,以及Flash动画反编译工具“闪客精灵”,编辑工具Macromedia Flash MX。

二、最原始的Flash木马

现在虽然有了许多各种各样的Flash动画木马制作工具,但是为了了解Flash动画木马的最基本原理,有必要从头开始用最原始的方法制作一个Flash木马。

步骤一:反编译SWF动画

首先我们需要将要插入网页木马的Flash动画文件“MM热舞.swf”,反编译成可编辑的.fla格式。运行“闪客精灵”,点击菜单“文件”→“快速打开”命令,指定“MM热舞.swf”文件将其导入,

然后点击工具栏上的“导出FLA”命令,将动画导出为“MM热舞.fla”文件。

步骤二:插入网页木马代码

然后运行Flash动画编辑器Macromedia Flash MX,点击菜单“文件”→“打开”,调入刚才保存的fla文件。展开界面下方的“动作/帧”栏,再展开“动作”→“浏览器/网络”项,点击其中的“getURL”命令,在右边窗口中的“URL”里面输入我们的网页木马地址;窗口方式为“_blank”;“变量”设置为“使用GET方式发送”,在下方的代码窗口中将出现“getURL(”网页木马地址“, ”_blank“, ”GET“);”。

步骤三:生成Flash木马

设置完毕后保存文件,并点击菜单“文件”→“发布”命令,将动画重新导出为SWF格式。用IE浏览器打开刚才生成的Flash动画木马,可以看到随着Flash动画打开播放时,自动弹出一个浏览器窗口,里面将会显示我们的木马网页。

三、简简单单生成Flash木马

上面插入木马的过程比较麻烦,下面我们介绍一个简单的方法,也正是这些简单的工具使得Flash木马在网上随处可见。

运行SWF木马插入器,点击界面中的“选择”按钮,浏览指定要插入木马的SWF文件;在“插入代码”中输入木马网页的地址;切记不要勾选下面的“只解压”项。设置完毕后,点击“给我插”按钮,程序提示开始插入木马网页。显示成功信息后,关闭程序,用IE打开生成的动画,可以看到自动跳转到木马网页去了。

[1] [2] 下一页

篇5:教你做一个乐观的人

Life certainly has its fair share of ups and downs, but if you tend to focus too much on the negative, it can affect everything you do. By seeing the glass as half full, you'll not only make your day-to-day experiences more enjoyable, but also improve your health (a recent Harvard study found that optimists have lower blood pressure levels, heart disease rates and more). Luckily you're not doomed to a life of glum and gloom―you can actually change your outlook for the better. Read on for nine easy ways to stay on the brighter side of life.

1. Acknowledge what you're grateful for. 学会对生活感恩

One very important component of optimism is gratitude. In fact, a 2003 study published in the Journal of Personality and Social Psychologyfound that there is a strong connection between a grateful attitude and a heightened sense of well-being. Appreciate all the positives in your life by starting a gratitude journal in order to remember what you're thankful for. ”I carry a small notebook in my purse and jot down moments of good in my life,“ says veteran broadcast journalist Deborah Norville, author of Thank You Power. ”When I look back at the entries, seeing the words rekindles the good feelings that prompted me to enter them in the first place.“ By remembering the pleasant things in your life, you can actually turn a negative attitude around.

2. Fake happiness until you feel it. 在失意的时候伪装快乐

Feeling down? Instead of moping around waiting for the universe to throw you a bone, try acting like you're happy―even if you aren't. ”The brain can be influenced top down and bottom up to make changes,“ says Mark C. Brown, PhD, psychologist and author of the upcoming Live Like aWindow, Work Like a Mirror. He explains that a genuine smile and a forced smile will cause the same chemical reactions in your brain, so you can actually fool your mind into feeling better by making it react chemically as if things were going well. ”So act in an optimistic way―smile, laugh, tell a joke or reassure yourself that everything is good―even if you don't feel it.“

3. Evaluate the good in your life. 每天写几件你生活中的乐事

It's easy to focus on the bad events when they occur, looking at them from all angles in order to find out what went wrong. However, doing the opposite actually helps you become more optimistic. In 2005, Martin Seligman, PhD, a psychology professor at the University of Pennsylvania, published a study in which he asked a group of people to complete the ”Three Good Things“ exercise. Every night for six months, participants wrote down three things that went well that day, along with explanations for why they happened. At the end of the study the participants were happier and less depressed than when they started. The idea is that by forcing yourself to think about why good things occur―”My presentation at work went well because I spent a lot of time preparing for it“―you'll start to see your life in a more positive way, helping you to be more optimistic about your future.

4. Be mindful of your surroundings. 将注意力集中在你的生活中正在发生的事上,别为过去忧伤,也别为将来担心

You don't have to break out the love beads or enroll in a yoga class to practice mindfulness; it simply means being aware of what's going on around you as well as what you're thinking. ”Often, things that sap our positive outlook and energy are either remnants from the past or worries about the future,“ says motivational speaker and happiness expert Valerie Sheppard. ”Being present with what is, rather than what was or what might be, helps us feel confident and cheerful in the here-and-now.“ But how do you do it? Rather than trying to change the way you feel because it's ”bad,“ simply acknowledge it and move on. So, instead of thinking ”I feel so stressed out and need to stop right now,“ think, ”I feel stressed out and that's OK.“ Or, try focusing on something in your immediate surroundings, whether that's your breathing or the pretty scenery outside your office window. By focusing your attention on something else, this will stop you from feeling badly about, well, feeling badly.

5. Turn off the news… …and turn on something more uplifting, like the National Geographic Channel. 少看新闻,多看看《人与自然》之类的节目

Though you may think that vigilantly keeping up with the latest events is simply informing you, it may also be bringing you down. ”The more we immerse ourselves in doom-and-gloom sermons, the more we succumb to their energy,“ says Sheppard. ”Trade in the things that raise your fear and frustration for alternatives that elevate your hopefulness and inspiration.“

6. Counter every negative with apositive. 不顺的时候多想想生活中的好时光

Every time you stumble upon a roadblock, challenge yourself to think of something good that's happening as well. ”People tend to think in an either-or way: If you're stuck in traffic, then everything else must be going horribly too,“ says Anne Parker, a wellness counselor at Miraval Resort &Spa in Tucson, Arizona. By blowing negative events out of proportion, you're setting yourself up for feeling down all day. ”Instead, acknowledge that you're stuck in traffic, but also bring to mind something good, like the beautiful scenery outside the window, the interesting radio show you’re listening to or a hug from your child that morning.“ That way, you'll get in the habit of forbidding negative circumstances from blanketing your whole day, and you'll learn to see them as just one small part of an otherwise good day.

7. Focus on small goals instead of big ones. 多为自己制定一些易实现的短期目标,努力实现它们

Pledging to lose 20 pounds or run a marathon seem like goals that will lead to happiness, except that people have a tendency to beat themselves up if they struggle to obtain them. ”It's our natural tendency to focus on what we haven't accomplished instead of what we have,“ says Parker. Major life goals take time to achieve, so by focusing on not having accomplished them yet, you will start to feel down on yourself-and may even end up throwing in the towel, causing your outlook on life to worsen. However, if you focus on the small milestones that occur along the way, you will feel positive about your progress, which will give you the momentum to keep going. ”If your goal is to lose 20 pounds, know that you have to do it one pound at a time. Instead of beating yourself up for still being overweight, despite weeks of dieting and exercise, congratulate yourself for dropping three pounds.“

8. Help someone in need. 帮助需要帮助的人

Want to give your attitude a boost? Try making someone else's day better. A report by UnitedHealthcare and VolunteerMatch found that volunteers are 72% more likely to characterize themselves as optimistic compared with non-volunteers. Plus, 89% of volunteers say that volunteering has improved their sense of well-being, and 92% say that it enriches their sense of purpose in life. Find a way to give back near you by visiting VolunteerMatch.org or the Volunteers of America website.

9. Decide to be happy every day. 下定决心开心度过每一天

Many of us don't think about needing to have a positive outlook when things are going well―it's only when we're stressed out or in a foul mood that we wish we could press the ”optimism button.“ But, according to Dr. Brown, the ideal moment to make a conscious decision to be happy is at the start of your day. ”Each morning, while you're still in bed, say and repeat statements like, 'This is going to be a good day' or 'I’m looking forward to this day because…' The best time to do this is when you're relaxed and your mind is unencumbered by concerns or anxiety." By beginning your morning on the right foot, you can program your mind to be more optimistic all day long.

相关专题 教你做一个