![]() |
Expression | x = this_comp.layer("追従するレイヤー名").position[0]; y = this_comp.layer("追従するレイヤー名").position[1]; |
|
---|---|---|
説 明 | レイヤーを特定のレイヤー(親レイヤーでなくてもよい)に追従させるには、追従するレイヤーの座標を読み出します。this_comp.layer("追従するレイヤー名").positonで座標を読み出すことができます。[0]でX座標、[1]にY座標が格納されています。読み出した座標にオフセット(どのくらいずらすか)を加算すると、指定した座標分だけずれて追従します。 |
|
サンプル | x = this_comp.layer("myLay1").position[0]; y = this_comp.layer("myLay1").position[1]; [x-30,y+30]; |
|
補足説明 | なし |
|
■サンプルをダウンロードする >>Download (Mac)/(Win/Zip圧縮) ■サンプルムービーを見る >>View Movie
|