freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

flashmx基礎(chǔ)之十-資料下載頁(yè)

2024-09-29 21:25本頁(yè)面

【導(dǎo)讀】字體、字號(hào)及顏色;前差不多的大小。//創(chuàng)建一個(gè)空白的背景影片剪輯。上方畫一個(gè)矩形,將某一對(duì)象的所有屬性設(shè)定或調(diào)用集中在一起。參數(shù)Thckness、rgb、alpha表示線的粗。將畫筆移到指定的(x,y)位置;行漸變處理,效果如圖所示。basic,第1個(gè)關(guān)鍵幀后加入一個(gè)關(guān)鍵幀,整個(gè)動(dòng)畫只有兩個(gè)關(guān)鍵幀。//設(shè)置產(chǎn)生一個(gè)字符串,用于下一條語(yǔ)句中。

  

【正文】 區(qū)域。 摘星星 8. 選中“遮罩層”圖層,執(zhí)行“修改 → 圖層”命令,彈出 “圖層屬性”對(duì)話框,選擇“遮罩層”單選按鈕,圖層設(shè)置效果如圖所示。 摘星星 9. 選中“瓢蟲”圖層,執(zhí)行“修改” → “圖層”命令,彈出圖層屬性對(duì)話框,選擇“被遮罩”單選按鈕,如圖所示。 摘星星 ,將“隕石”、“星星”、“背景” 3個(gè)圖層的圖層屬性也設(shè)置為“被遮罩”。 “文字”圖層,在場(chǎng)景內(nèi)的右下角添加一個(gè)文本框,輸入漢字“能量”。設(shè)置字體為方正水拄簡(jiǎn)體,字號(hào)為 12,文字顏色為黑色。在旁邊添加一個(gè)變量名為“ energy‖的動(dòng)態(tài)文本框,表示能量的多少。 摘星星 2個(gè)文本框,分別輸入漢字“第”、“關(guān)”,設(shè)置字體,字號(hào)為 12,文字顏色為黑色。兩文字中間留一空格,在兩文字中間添加一個(gè)變量名為“ lev‖的動(dòng)態(tài)文本框,表示“第幾關(guān)”。 摘星星 ,具體設(shè)置如圖所示。 。 摘星星 ? Action指令設(shè)置: 1. 單擊“動(dòng)作”圖層第 1幀,打開(kāi)動(dòng)作面板,輸入代碼。 // 初始化變量 stonenum = 10。 starnum = 5。 lev = 1。 energy = 100。 findingstar = 0。 // 定義自動(dòng)生成石頭函數(shù) function createstone(n) { while (nstarnum) { duplicateMovieClip(ne, stone+n, n)。 _root[stone+n]._x = int(()*400)。 _root[stone+n]._y = int(()*200)。 _root[stone+n]._alpha = 50。 mxy = int(()*100+50)。 _root[stone+n]._xscale = mxy。 摘星星 _root[stone+n]._yscale = mxy。 n。 } } function deletestone(p) { while (pstarnum) { trace(p)。 removeMovieClip(_root[stone+p])。 p。 } } // 定義自動(dòng)生成星星函數(shù) function createstar(m) { while (m=1) { duplicateMovieClip(r, star+m, m)。 _root[star+m]._x = int(()*400)。 _root[star+m]._y = int(()*200)。 mxy = int(()*100+60)。 _root[star+m]._xscale = mxy。 摘星星 _root[star+m]._yscale = mxy。 m。 } } createstone(stonenum+starnum)。 createstar(starnum)。 = function() { var x。 // 游戲結(jié)束 if (energy=0) { gotoAndStop(2)。 } // 游戲過(guò)關(guān) if (findingstar == starnum) { findingstar = 0。 lev++。 stonenum++。 createstone(stonenum+starnum)。 createstar(starnum)。 } 摘星星 // 檢測(cè)碰撞 x = stonenum+starnum。 while (xstarnum) { if ((_root[stone+x])) { energy。 } x。 } x = starnum。 while (x=1) { if ((_root[star+x])) { removeMovieClip(_root[star+x])。 energy = energy+20。 findingstar++。 } x。 } }。 stop()。 摘星星 ?說(shuō)明:在 FlashMX中檢測(cè)兩個(gè)對(duì)象是否相互碰撞,最簡(jiǎn)單的方法就是使用 hitTest函數(shù)。 ?語(yǔ)法: (target) ?myMovieClip:表示源電影剪輯素材實(shí)例名稱。 ?Target:表示目標(biāo)電影剪輯素材實(shí)例名稱。 摘星星 ?該函數(shù)還可以檢測(cè)電影剪輯素材與一個(gè)坐標(biāo)點(diǎn)是否碰撞。 ?語(yǔ)法: (x, y, shapeFlag) ?myMovieClip:表示源電影剪輯素材實(shí)例名稱。 ?x:表示場(chǎng)景的 x坐標(biāo)值。 ?y:表示場(chǎng)景的 y坐標(biāo)值。 ?shapeFlag:一個(gè) Boolean變量,值可以為true或 false。 摘星星 2. 選中“動(dòng)作”圖層第 2幀,按 F6插入關(guān)鍵幀,打開(kāi)“動(dòng)作”面板,輸入指令如下: deletestone(stonenum+starnum)。 stop()。 摘星星 3. 單擊“瓢蟲”圖層,選中“瓢蟲”電影剪輯素材,打開(kāi)動(dòng)作面板,輸入動(dòng)作代碼 : onClipEvent (load) { // declare and set initial variables thrust = 1。 decay = .97。 maxSpeed = 4。 } onClipEvent (enterFrame) { // rotate right or left if (()) { _rotation += 10。 } if (()) { _rotation = 10。 } if (()) { // calculate speed and trajectory based on rotation 摘星星 xSpeed += thrust* Math .sin (_rotation* ())。 ySpeed += thrust* (_rotation* ())。 = 1。 } else { // deccelerate when Up Arrow key is released xSpeed *= decay。 ySpeed *= decay。 = 0。 } // maintain speed limit speed = ((xSpeed* xSpeed)+(ySpeed*ySpeed))。 if (speedmaxSpeed) { xSpeed *= maxSpeed/speed。 ySpeed *= maxSpeed/speed。 } // move beetle based on calculations above _y = ySpeed。 _x += xSpeed。 // loop to opposite side of the stage when the beetle travels offscreen 摘星星 if (_y0) { _y = 232。 } if (_y232) { _y = 0。 } if (_x0) { _x = 465。 } if (_x465) { _x = 0。 } } 4. 將庫(kù)窗口中的“再來(lái)一次”按鈕元件拖到“動(dòng)作”圖層第 2幀,放在場(chǎng)景的正中央,打開(kāi)動(dòng)作面板,輸入如下動(dòng)作代碼: on (release) { gotoAndStop(1)。 } 摘星星 ?至此本游戲制作完成,使用Ctrl+Enter快捷組合鍵運(yùn)行游戲。 ?本例使用了游戲中最常用的碰撞檢測(cè)技術(shù),在 Flash MX中我們可以使用hitTest函數(shù)來(lái)檢測(cè)兩個(gè)對(duì)象是否相互碰撞,例如:在射擊游戲中標(biāo)準(zhǔn)器與被射擊對(duì)象之間的碰撞,拼圖游戲中圖塊與移動(dòng)區(qū)域的碰撞。
點(diǎn)擊復(fù)制文檔內(nèi)容
教學(xué)課件相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1