safe LMB hold-to-skip cutscenes and multiple images with crossfade
This commit is contained in:
1 parent
fe01a5d1b2
commit
0a073243ad
16 files changed
+801
-58
No files matched your search
@@ -0,0 +1,290 @@
|
||||
{
|
||||
"dialogues": [
|
||||
{
|
||||
"id": "test_cutscene_skip_hold_dialogue",
|
||||
"start": "cutscene_start",
|
||||
"nodes": [
|
||||
{
|
||||
"id": "cutscene_start",
|
||||
"type": "CutsceneStart",
|
||||
"cutsceneId": "test_cutscene_skip_hold_01",
|
||||
"next": "end_1"
|
||||
},
|
||||
{
|
||||
"id": "end_1",
|
||||
"type": "End"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "test_cutscene_images_hardcut_dialogue",
|
||||
"start": "cutscene_start",
|
||||
"nodes": [
|
||||
{
|
||||
"id": "cutscene_start",
|
||||
"type": "CutsceneStart",
|
||||
"cutsceneId": "test_cutscene_images_hardcut_01",
|
||||
"next": "end_1"
|
||||
},
|
||||
{
|
||||
"id": "end_1",
|
||||
"type": "End"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "test_cutscene_images_crossfade_dialogue",
|
||||
"start": "cutscene_start",
|
||||
"nodes": [
|
||||
{
|
||||
"id": "cutscene_start",
|
||||
"type": "CutsceneStart",
|
||||
"cutsceneId": "test_cutscene_images_crossfade_01",
|
||||
"next": "end_1"
|
||||
},
|
||||
{
|
||||
"id": "end_1",
|
||||
"type": "End"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "test_cutscene_images_silent_dialogue",
|
||||
"start": "cutscene_start",
|
||||
"nodes": [
|
||||
{
|
||||
"id": "cutscene_start",
|
||||
"type": "CutsceneStart",
|
||||
"cutsceneId": "test_cutscene_images_silent_01",
|
||||
"next": "end_1"
|
||||
},
|
||||
{
|
||||
"id": "end_1",
|
||||
"type": "End"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"cutscenes": [
|
||||
{
|
||||
"id": "test_cutscene_skip_hold_01",
|
||||
"background": "resources/first_cutscene.png",
|
||||
"skippable": true,
|
||||
"durationMs": 12000,
|
||||
"cameraTrack": [
|
||||
{
|
||||
"durationMs": 3000,
|
||||
"from": { "anchor": "Center", "zoom": 1.0, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "TopLeft", "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
},
|
||||
{
|
||||
"durationMs": 3000,
|
||||
"from": { "anchor": "TopLeft", "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "TopRight", "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
},
|
||||
{
|
||||
"durationMs": 3000,
|
||||
"from": { "anchor": "TopRight", "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "BottomRight", "zoom": 1.65, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInCubic"
|
||||
},
|
||||
{
|
||||
"durationMs": 3000,
|
||||
"from": { "anchor": "BottomRight", "zoom": 1.65, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "BottomLeft", "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
}
|
||||
],
|
||||
"lines": [
|
||||
{
|
||||
"speaker": "Narrator",
|
||||
"portrait": "",
|
||||
"text": "This cutscene is long enough to test hold-to-skip.",
|
||||
"durationMs": 2600
|
||||
},
|
||||
{
|
||||
"speaker": "Narrator",
|
||||
"portrait": "",
|
||||
"text": "A normal click must not skip it.",
|
||||
"durationMs": 2600
|
||||
},
|
||||
{
|
||||
"speaker": "Ghost",
|
||||
"portrait": "resources/ghost_avatar.png",
|
||||
"text": "Only the skip button with hold should work.",
|
||||
"durationMs": 2600
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "test_cutscene_images_hardcut_01",
|
||||
"background": "resources/first_cutscene.png",
|
||||
"skippable": true,
|
||||
"durationMs": 9000,
|
||||
"cameraTrack": [
|
||||
{
|
||||
"durationMs": 4500,
|
||||
"from": { "anchor": "Center", "zoom": 1.0, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "TopLeft", "zoom": 1.35, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
},
|
||||
{
|
||||
"durationMs": 4500,
|
||||
"from": { "anchor": "TopLeft", "zoom": 1.35, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "BottomRight", "zoom": 1.55, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
}
|
||||
],
|
||||
"images": [
|
||||
{
|
||||
"path": "resources/first_cutscene.png",
|
||||
"startMs": 0,
|
||||
"endMs": 4500,
|
||||
"fadeInMs": 0,
|
||||
"fadeOutMs": 0
|
||||
},
|
||||
{
|
||||
"path": "resources/second_cutscene.png",
|
||||
"startMs": 4500,
|
||||
"endMs": 9000,
|
||||
"fadeInMs": 0,
|
||||
"fadeOutMs": 0
|
||||
}
|
||||
],
|
||||
"lines": [
|
||||
{
|
||||
"speaker": "Narrator",
|
||||
"portrait": "",
|
||||
"text": "First image should switch sharply to the second one.",
|
||||
"durationMs": 2800
|
||||
},
|
||||
{
|
||||
"speaker": "Narrator",
|
||||
"portrait": "",
|
||||
"text": "No fade should be visible here.",
|
||||
"durationMs": 2800
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "test_cutscene_images_crossfade_01",
|
||||
"background": "resources/first_cutscene.png",
|
||||
"skippable": true,
|
||||
"durationMs": 10000,
|
||||
"cameraTrack": [
|
||||
{
|
||||
"durationMs": 2500,
|
||||
"from": { "anchor": "Center", "zoom": 1.0, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "Custom", "centerX": 0.35, "centerY": 0.30, "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutQuad"
|
||||
},
|
||||
{
|
||||
"durationMs": 2500,
|
||||
"from": { "anchor": "Custom", "centerX": 0.35, "centerY": 0.30, "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "Custom", "centerX": 0.70, "centerY": 0.32, "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"easing": "EaseOutCubic"
|
||||
},
|
||||
{
|
||||
"durationMs": 2500,
|
||||
"from": { "anchor": "Custom", "centerX": 0.70, "centerY": 0.32, "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "BottomRight", "zoom": 1.70, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInCubic"
|
||||
},
|
||||
{
|
||||
"durationMs": 2500,
|
||||
"from": { "anchor": "BottomRight", "zoom": 1.70, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "BottomLeft", "zoom": 1.55, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
}
|
||||
],
|
||||
"images": [
|
||||
{
|
||||
"path": "resources/first_cutscene.png",
|
||||
"startMs": 0,
|
||||
"endMs": 6000,
|
||||
"fadeInMs": 0,
|
||||
"fadeOutMs": 0
|
||||
},
|
||||
{
|
||||
"path": "resources/second_cutscene.png",
|
||||
"startMs": 4500,
|
||||
"endMs": 10000,
|
||||
"fadeInMs": 1500,
|
||||
"fadeOutMs": 0
|
||||
}
|
||||
],
|
||||
"lines": [
|
||||
{
|
||||
"speaker": "Narrator",
|
||||
"portrait": "",
|
||||
"text": "The second image should fade over the first one.",
|
||||
"durationMs": 2600
|
||||
},
|
||||
{
|
||||
"speaker": "Ghost",
|
||||
"portrait": "resources/ghost_avatar.png",
|
||||
"text": "This test checks overlap and alpha blending.",
|
||||
"durationMs": 2600
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "test_cutscene_images_silent_01",
|
||||
"background": "resources/first_cutscene.png",
|
||||
"skippable": true,
|
||||
"durationMs": 11000,
|
||||
"cameraTrack": [
|
||||
{
|
||||
"durationMs": 2500,
|
||||
"from": { "anchor": "Center", "zoom": 1.0, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "TopLeft", "zoom": 1.35, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
},
|
||||
{
|
||||
"durationMs": 3000,
|
||||
"from": { "anchor": "TopLeft", "zoom": 1.35, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "TopRight", "zoom": 1.35, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutSine"
|
||||
},
|
||||
{
|
||||
"durationMs": 3000,
|
||||
"from": { "anchor": "TopRight", "zoom": 1.35, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "BottomRight", "zoom": 1.55, "rotationDeg": 0.0 },
|
||||
"easing": "EaseOutCubic"
|
||||
},
|
||||
{
|
||||
"durationMs": 2500,
|
||||
"from": { "anchor": "BottomRight", "zoom": 1.55, "rotationDeg": 0.0 },
|
||||
"to": { "anchor": "BottomLeft", "zoom": 1.45, "rotationDeg": 0.0 },
|
||||
"easing": "EaseInOutQuad"
|
||||
}
|
||||
],
|
||||
"images": [
|
||||
{
|
||||
"path": "resources/first_cutscene.png",
|
||||
"startMs": 0,
|
||||
"endMs": 3500,
|
||||
"fadeInMs": 0,
|
||||
"fadeOutMs": 800
|
||||
},
|
||||
{
|
||||
"path": "resources/second_cutscene.png",
|
||||
"startMs": 3000,
|
||||
"endMs": 7500,
|
||||
"fadeInMs": 800,
|
||||
"fadeOutMs": 1000
|
||||
},
|
||||
{
|
||||
"path": "resources/loading.png",
|
||||
"startMs": 7000,
|
||||
"endMs": 11000,
|
||||
"fadeInMs": 1000,
|
||||
"fadeOutMs": 0
|
||||
}
|
||||
],
|
||||
"lines": []
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in new issue
Block a user