アニメ

アニメは、animeタグを使ってレイヤーベースのアニメーションを再生する機能です。

アニメファイル

アニメファイルは、レイヤー変換のシーケンスを記述するテキストファイルです。

シーケンス

メッセージボックスを1秒で右へ100px移動するには、アニメファイルに次のシーケンスを記述します。

# ブロックはアニメーションのシーケンスを表します。
# ブロック名は任意で、動作には影響しません。
move {
    # レイヤー指定子です。
    layer: msg;

    # 時刻指定子です。(秒単位)
    start: 0.0;
    end: 1.0;

    # 開始位置指定子です。'r0' は相対値 '0' を意味します。
    from-x: r0;
    from-y: r0;

    # 開始アルファ指定子です。
    from-a: 255;

    # 終了位置指定子です。'r100' は相対値 '100' を意味します。
    to-x: r100;
    to-y: r0;

    # 終了アルファ指定子です。
    to-a: 255;
}

レイヤー構造

次に示すのは、下から上への順に並べたレイヤー構造です。

レイヤー名説明
bg背景
bg22つ目の背景(シームレススクロール用)
efb1背面エフェクト1
efb2背面エフェクト2
efb3背面エフェクト3
efb4背面エフェクト4
chb奥中央のキャラクター
chb-eye奥中央のキャラクター
chb-lip奥中央のキャラクター
chl左のキャラクター
chl-eye左のキャラクター
chl-lip左のキャラクター
chlc左中央のキャラクター
chlc-eye左中央のキャラクター
chlc-lip左中央のキャラクター
chr右のキャラクター
chr-eye右のキャラクター
chr-lip右のキャラクター
chrc右中央のキャラクター
chrc-eye右中央のキャラクター
chrc-lip右中央のキャラクター
eff1前面エフェクト1
eff2前面エフェクト2
eff3前面エフェクト3
eff4前面エフェクト4
msgboxメッセージボックス
namebox名前ボックス
choose1-idle選択肢ボックス1(待機)
choose1-hover選択肢ボックス1(ホバー)
choose2-idle選択肢ボックス2(待機)
choose2-hover選択肢ボックス2(ホバー)
choose3-idle選択肢ボックス3(待機)
choose3-hover選択肢ボックス3(ホバー)
choose4-idle選択肢ボックス4(待機)
choose4-hover選択肢ボックス4(ホバー)
choose5-idle選択肢ボックス5(待機)
choose5-hover選択肢ボックス5(ホバー)
choose6-idle選択肢ボックス6(待機)
choose6-hover選択肢ボックス6(ホバー)
choose7-idle選択肢ボックス7(待機)
choose7-hover選択肢ボックス7(ホバー)
choose8-idle選択肢ボックス8(待機)
choose8-hover選択肢ボックス8(ホバー)
chfキャラクターの顔
chf-eyeキャラクターの顔
chf-lipキャラクターの顔
clickクリックアニメーション
autoオートモードバナー
skipスキップモードバナー
text1テキストレイヤー1
text2テキストレイヤー2
text3テキストレイヤー3
text4テキストレイヤー4
text5テキストレイヤー5
text6テキストレイヤー6
text7テキストレイヤー7
text8テキストレイヤー8
gui-button-1GUIボタンID 1
gui-button-2GUIボタンID 2
gui-button-3GUIボタンID 3
gui-button-4GUIボタンID 4
gui-button-5GUIボタンID 5
gui-button-6GUIボタンID 6
gui-button-7GUIボタンID 7
gui-button-8GUIボタンID 8
gui-button-9GUIボタンID 9
gui-button-10GUIボタンID 10
gui-button-11GUIボタンID 11
gui-button-12GUIボタンID 12
gui-button-13GUIボタンID 13
gui-button-14GUIボタンID 14
gui-button-15GUIボタンID 15
gui-button-16GUIボタンID 16
gui-button-17GUIボタンID 17
gui-button-18GUIボタンID 18
gui-button-19GUIボタンID 19
gui-button-20GUIボタンID 20
gui-button-21GUIボタンID 21
gui-button-22GUIボタンID 22
gui-button-23GUIボタンID 23
gui-button-24GUIボタンID 24
gui-button-25GUIボタンID 25
gui-button-26GUIボタンID 26
gui-button-27GUIボタンID 27
gui-button-28GUIボタンID 28
gui-button-29GUIボタンID 29
gui-button-30GUIボタンID 30
gui-button-31GUIボタンID 31
gui-button-32GUIボタンID 32

拡大縮小と回転

# `effect1` レイヤーを3秒で2.0倍に拡大し、360度回転します。
test1 {
    layer: effect1;
 
    start: 0.0;
    end: 3.0;

    from-x: 0;
    from-y: 400;
    from-a: 255;

    to-x: 0;
    to-y: 400;
    to-a: 255;

    # 拡大縮小と回転の原点
    center-x: 600;
    center-y: 100;

    # 拡大縮小率
    from-scale-x: 1.0;
    from-scale-y: 1.0;
    to-scale-x: 2.0;
    to-scale-y: 2.0;
 
    # 回転(+ は右、- は左)
    from-rotate: 0.0;
    to-rotate: -360;
}

# 逆方向。
test2 {
    layer: effect1;

    start: 3.0;
    end: 6.0;

    from-x: 0;
    from-y: 400;
    from-a: 255;

    to-x: 0;
    to-y: 400;
    to-a: 255;

    center-x: 600;
    center-y: 100;

    from-scale-x: 2.0;
    to-scale-x: 1.0;

    from-scale-y: 2.0;
    to-scale-y: 1.0;

    from-rotate: -360;
    to-rotate: 0;
}