適用於 Adobe® Flash® Platform 的 ActionScript® 3.0 參考
首頁  |  隱藏套件和類別清單 |  套件  |  類別  |  新增內容  |  索引  |  附錄  |  為什麼顯示英文?
篩選: 從伺服器擷取資料...
從伺服器擷取資料...
fl.ik 

IKMover  - AS3 Flash

套件fl.ik
類別public class IKMover
繼承IKMover Inheritance EventDispatcher Inheritance Object

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

IKMover 類別會起始並控制骨架的反向運動 (IK) 移動。除非 IKMover 物件判斷出已建立的 IKArmature 限制導致無法到達目標點,或者移動超過已建立的 timeLimititerationLimitdistanceLimit 值,否則請使用 IKMover 類別將 IKJoint 物件移至目標點。

相關 API 元素



公用屬性
 屬性定義自
 Inheritedconstructor : Object
類別物件的參照或是特定物件實體的建構函數。
Object
  distanceLimit : Number
IK 引擎每次循環應該移動的最大距離 (以像素為單位)。
IKMover
  iterationLimit : int
指定 IK 引擎對每次移動所執行的最大循環次數。
IKMover
  limitByDistance : Boolean
指定超過 distanceLimit 值之後,IK 引擎是否會結束移動。
IKMover
  limitByIteration : Boolean
指定超過 iterationLimit 值之後,IK 引擎是否會結束移動。
IKMover
  limitByTime : Boolean
指定超過指定的 timeLimit 之後,IK 引擎是否會結束移動。
IKMover
  stepCount : int
[唯讀] IK 移動的循環次數。
IKMover
  timeLimit : int
指定 IK 引擎會執行移動的最大時間 (以毫秒為單位)。
IKMover
公用方法
 方法定義自
  
IKMover(endEffector:IKJoint, targetIn:Point)
IKMover 物件的建構函式。
IKMover
 Inherited
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
會在 EventDispatcher 物件註冊事件偵聽程式,以便讓偵聽程式收到事件的通知。
EventDispatcher
 Inherited
會將事件傳送到事件流程。
EventDispatcher
 Inherited
會檢查 EventDispatcher 物件是否有對特定的事件類型註冊偵聽程式。
EventDispatcher
 Inherited
指出物件是否有已定義的指定屬性。
Object
 Inherited
指出 Object 類別的實體是否位於指定為參數的物件原型鏈中。
Object
  
moveTo(targetIn:Point):*
將相關聯的 IKJoint 物件移至目標點,並根據其 IK 限制更新所有相關的 IKJoint 物件。
IKMover
 Inherited
指出指定的屬性是否存在,以及是否可列舉。
Object
 Inherited
removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
會從 EventDispatcher 物件移除偵聽程式。
EventDispatcher
 Inherited
為迴圈作業設定動態屬性的可用性。
Object
 Inherited
傳回代表此物件的字串,根據地區特定慣例進行格式化。
Object
 Inherited
會傳回指定之物件的字串形式。
Object
 Inherited
會傳回指定之物件的基本值。
Object
 Inherited
檢查此 EventDispatcher 物件是否已註冊事件偵聽程式,或者此物件的任何祖系已為特定事件類型註冊事件偵聽程式。
EventDispatcher
事件
 事件 摘要 定義自
 Inherited[廣播事件] 當 Flash Player 或 AIR 應用程式取得作業系統焦點並成為作用中時傳送。EventDispatcher
 Inherited[廣播事件] 當 Flash Player 或 AIR 應用程式失去作業系統焦點並成為非作用中時傳送。EventDispatcher
屬性詳細資訊

distanceLimit

屬性
distanceLimit:Number

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

IK 引擎每次循環應該移動的最大距離 (以像素為單位)。這個值會計算成歐幾里得距離:

sqrt(dx*dx + dy*dy)



實作
    public function get distanceLimit():Number
    public function set distanceLimit(value:Number):void

相關 API 元素

iterationLimit

屬性 
iterationLimit:int

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

指定 IK 引擎對每次移動所執行的最大循環次數。若要使用 iterationLimit 值,limitByIteration 屬性必須設定為 true。如果 limitByIteration 屬性為 true,IK 引擎就會執行指定的循環次數,或直到 IKJoint 物件到達目標點為止。如果此類別的所有 "limitBy..." 屬性為 false,則 IK 引擎會採取一個步驟。如果有任何 "limitBy" 屬性為 true,則 IK 引擎會繼續處理,直到達到該判斷條件的限制,或者 end-effector 位在目標處為止。



實作
    public function get iterationLimit():int
    public function set iterationLimit(value:int):void

相關 API 元素

limitByDistance

屬性 
limitByDistance:Boolean

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

指定超過 distanceLimit 值之後,IK 引擎是否會結束移動。



實作
    public function get limitByDistance():Boolean
    public function set limitByDistance(value:Boolean):void

相關 API 元素

limitByIteration

屬性 
limitByIteration:Boolean

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

指定超過 iterationLimit 值之後,IK 引擎是否會結束移動。



實作
    public function get limitByIteration():Boolean
    public function set limitByIteration(value:Boolean):void

相關 API 元素

limitByTime

屬性 
limitByTime:Boolean

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

指定超過指定的 timeLimit 之後,IK 引擎是否會結束移動。



實作
    public function get limitByTime():Boolean
    public function set limitByTime(value:Boolean):void

相關 API 元素

stepCount

屬性 
stepCount:int  [唯讀]

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

IK 移動的循環次數。



實作
    public function get stepCount():int

timeLimit

屬性 
timeLimit:int

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

指定 IK 引擎會執行移動的最大時間 (以毫秒為單位)。若要使用 timeLimit 值,limitByTime 屬性必須設定為 true。如果 limitByTime 屬性為 true,IK 引擎就會執行指定的毫秒數,或直到 IKJoint 物件到達目標點為止。如果此類別的所有 "limitBy..." 屬性為 false,則 IK 引擎會採取一個步驟。如果有任何 "limitBy" 屬性為 true,則 IK 引擎會繼續處理,直到達到該判斷條件的限制,或者 end-effector 位在目標處為止。



實作
    public function get timeLimit():int
    public function set timeLimit(value:int):void

相關 API 元素

建構函式詳細資料

IKMover

()建構函式
public function IKMover(endEffector:IKJoint, targetIn:Point)

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

IKMover 物件的建構函式。如果是形狀 IKArmature 物件,建構函數會忽略 targetIn 點參數。

參數
endEffector:IKJoint — 要移動的 IKJoint 物件。
 
targetIn:Point — 移動的開始座標。這個點類似於 Flash 編寫工具中位於舞台上的點,可讓您按一下屬於 IKArmature 物件一部分的元件 (不一定在關節上)、移動此元件,然後根據針對 IKArmature 物件所建立的限制移動 IKArmature 物件。

例如,您有腿和腳,而且想要從腳指頭來移動腳。如果您在腳指頭上指定 targetIn 點,您可以從該點來移動腳。否則,您必須在腳指頭建立元件,將腳指頭連接到骨塊,然後才可以移動腳。

方法詳細資訊

moveTo

()方法
public function moveTo(targetIn:Point):*

語言版本: ActionScript 3.0
產品版本: Flash CS4
執行階段版本: Flash Player 10, AIR 1.5

將相關聯的 IKJoint 物件移至目標點,並根據其 IK 限制更新所有相關的 IKJoint 物件。除非 IKMover 物件判斷出已建立的 IKArmature 限制導致無法到達目標點,或者移動超過已建立的 timeLimititerationLimitdistanceLimit 值,否則 IKMover 物件就會將 IKJoint 物件移至目標點。

參數

targetIn:Point — 目標點的座標

傳回值
*




[ X ]為什麼顯示英文?
「ActionScript 3.0 參考」的內容是以英文顯示

並非所有「ActionScript 3.0 參考」的內容都翻譯為所有語言。當語言元素未翻譯時,就會以英文顯示。例如,ga.controls.HelpBox 類別並沒有翻譯為任何語言。因此在參考的繁體中文版本中,ga.controls.HelpBox 類別就會以英文顯示。