Action for video cutscene after switching scene causes new scene to flash on screen momentarily before cutscene plays!

  • #1, by F_KalMonday, 20. February 2017, 23:53 7 years ago
    The title says it all:
    I'm triggering a Scene Change via an action. As soon as the screen fades out, I call a cutscene movie file.

    (The idea is that I wish to see the fadout effect, then the movie clip, then fade in back into the new scene.)

    But Apparently the new scene first renders (displaying on the monitor for a few milliseconds) and then gives control back to the action to execute the next block (play video).
    For now I tried setting the Scene Brightness into 0% before the Change, and reiinstating it back to 100% after the movie has played and it works. It works because the screen was already black after the fade out completed.

    But I wonder if there is some other more proper way of doing it: Some way of loading a scene, but not rendering it perhaps? Or maybe creating a completely black scene with no character/objects as a canvas for the video? 

    Thanks,
    Fotis 

    Forum Fan

    107 Posts


  • #2, by afrlmeTuesday, 21. February 2017, 00:18 7 years ago
    You could force the scene brightness to 0 until video finishes playing then fade in scene brightness after.

    execute a script >
    game.CurrentScene:to(0, {SceneBrightness = 0})

    play video and wait (whatever)
    execute a script >
    game.CurrentScene:to(600, {SceneBrightness = 100})


    wink

    Imperator

    7278 Posts

  • #3, by F_KalTuesday, 21. February 2017, 16:29 7 years ago
    thank you @ARFLme! Pretty much what I thought!
    I didn't know the to shorthand, but now that I do... boy oh boy! 

    For those who stumble on this thread here and here are some older threads that explain a bit more about to!

    Back in my example, now that I know how to call fade-in/fade-out manually I could also:

    1. slowly fade out by setting brightness to 0 for the current scene
    2. set next scene's brightness to 0
    3. play video
    4. load next scene
    5. fade in by setting brightness to 100

    Forum Fan

    107 Posts

  • #4, by afrlmeTuesday, 21. February 2017, 18:36 7 years ago
    Before to() function Simon created a startTween() function. I think it was called something along those lines. Anyway, it wasn't very easy to use or understand. The to() tweening function on the other hand is really easy to use & you can affect multiple data structure fields belonging to the linked Visionaire Object (VisOBJ) inside of the same to() function. You can affect almost any data structure field that contains an integer, float or point value.

    Imperator

    7278 Posts

  • #5, by F_KalTuesday, 21. February 2017, 20:22 7 years ago
    Thanks @AFRLme, as always very helpful!

    Forum Fan

    107 Posts