Preparing a Vis. project... (Catyph)

  • #60, by afrlmeWednesday, 05. March 2014, 19:26 11 years ago
    Would need to be the .ved & resource files. I'm not sure about how the subtitles work for .mkv videos. I assume it selects based on current active game language. You would be better off asking David how it works.

    P.S: in the upcoming release you will be able to assign independent active languages for text & speech output. So the player could leave speech in vo format & view subtitles in another language or vice versa.

    Imperator

    7278 Posts


  • #61, by Simon_ASATuesday, 22. April 2014, 15:10 10 years ago
    Hey AFRLme (or someone else!), do you think there's a way to keep an animation in memory during several scenes ?

    You tried a demo of Catyph, so you probably see what I mean when I talk of the rain : it is a PNG sequence that is played in loop in all the scenes of the first region. The problem is that it is reloaded in memory everytime the player moves in the game, which makes the game become suddenly slow when it plays the transition video.

    I had first thought of preloading the rain animation with the action "preload animation", when the player clicks to move to another screen. But it is very very long to script this for each screen.
    So maybe there is a possibility to keep it in memory in a more global way ? Any ideas ? smile

    Great Poster

    321 Posts

  • #62, by afrlmeTuesday, 22. April 2014, 16:00 10 years ago
    You could add the animation to an interface? you would only need to preload it the first time you enter one of the scenes with the rain & unload it again when no longer needed. You could use/set a condition to check if it's already preloaded or not before executing the preload action - or you can check/set preloaded state of a linked animation via Lua with the VAnimationPreloaded data structure entry. Something along the lines of...
    -- add to at begin of scene action inside of an execute a script action.
    local anim = getObject("Animations[animation_name]")
    if not anim:getBool(VAnimationPreloaded) then
     anim:setValue(VAnimationPreloaded, true)
    end
    

    Also if you want to save memory/loading time then you could make the rain animation about half or quarter of the size of the default game resolution & then scale it up with a bit of Lua script as needed. It will make the animation slightly blurred, but it shouldn't really matter for something like rain?
    -- animation has to be active (currently on scene or preloaded)
    getObject("ActiveAnimations[animation_name]"):setValue(VAnimationSize, 200) -- double animation size
    


    Hope this helps somewhat? smile

    Imperator

    7278 Posts

  • #63, by Simon_ASAWednesday, 23. April 2014, 15:37 10 years ago
    Thanks, yes it helps a lot ! The idea of the interface is very good, I would have never thought of it while it's quite simple. However, is it possible to create several interfaces for each animation I need ? (rain, snow, etc). I think it's possible, but the true question is : how can I call them one by one? If I create these different interfaces all as Miscellaneous class, then I can use the action Show/Hide interface (class Miscellaneous), but how will Visionaire know which is the one I want to display ?
    I'm not sure it's well explained.... If it's not possible I'll try with the code you give above.

    Also if you want to save memory/loading time then you could make the rain animation about half or quarter of the size

    That's what I'm doing already. It was your idea at the beginning grin And it's great.

    Great Poster

    321 Posts

  • #64, by afrlmeWednesday, 23. April 2014, 15:47 10 years ago
    You can actually create additional classes. You used to be able to create them via the explorer tool but it doesn't seem to be working correctly for some reason in the current beta. But it is still possible to create new classes manually by opening up the .ved file inside of a text editor & typing them in.

    Check this thread here: http://www.visionaire-studio.net/forum/thread/add-gameinterf...

    Imperator

    7278 Posts

  • #65, by Simon_ASAThursday, 24. April 2014, 14:51 10 years ago
    This is perfect! Exactly what I am looking for. You're the best!

    Great Poster

    321 Posts

  • #66, by afrlmeThursday, 24. April 2014, 15:02 10 years ago
    No problem, just remember to make a backup of your .ved file before manually editing it with a text editor. Always better to be safe than sorry, eh!?

    Imperator

    7278 Posts