//讓字彈移動並漸漸縮小,射中後讓泡泡消失 function bulletMove(event:Event): void { if (event.target.scaleX > 0.3) { //一次縮小10% event.target.scaleX = event.target.scaleX - 0.1; event.target.scaleY = event.target.scaleY - 0.1; } else { event.target.parent.removeChild(event.target); event.target.removeEventListener(Event.ENTER_FRAME, bulletMove); // 檢查泡泡 var deadBubble:Object=shotCheck(event.target as MovieClip); if (deadBubble != null) { deadBubble.removeEventListener(Event.ENTER_FRAME, onFramePlaying); bubbleArea.removeChild(deadBubble as MovieClip); } } }