Who is skilled with the modvlc plugin?

Started by MisterN, November 01, 2012, 04:26:55 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

MisterN

I need help with that. I made a process called cutscene();

process cutscene(string moviefile);
private
    string fname;
    int time=0, delay=30, timend=300;
begin
    z = -100;
    x = 160; y = 120;
   
    fname = moviefile;
   
    dump_type=complete_dump;
    restore_type=complete_restore;
   
    graph = video_play(fname, 320, 240);
   
    while(! video_is_playing()) // Wait for the video to actually start
        FRAME;
    end;
   
    loop
        if(timer[0] > time+delay)
            if(key(_space))
                video_pause();
                time = timer[0];
            end
        end
        if(timend>0)
            timend--;
        else
            signal(id,s_kill);
        end
    frame;end
end


I cannot get the process to successfully load the movie file (it is named "test.mov", it is in a folder called "FILES"). unless from the get go it is loaded in main. Now I tried an experiment here by having some early code in the main process do this:


ChDir("FILES\");
say(CD());
ChDir("..\");
say(CD());


now if I add
cutscene("test.mov");
between lines 2 and 3, I will get this error

if I add it after line 4 and do
cutscene("FILES\test.mov");
somehow it will work. this is so puzzling, but I cant really do this kinda code when my engine has its directory set to "FILES" at all times except when loading a sound effect, song, background, or level. I even tried putting a folder in "FILES" and I tried different folders, even a "MOVIES" folder, still didn't work. This is just odd

is this some error? Thanks. I am using the dll example included in bennupack as a tutorial.

EDIT: if I do it in a process, i will get the error
werg