Post subject: Troubles with .fmv with 2 ACTIVE players
Joined: 1/1/2022
Posts: 1716
Hi! My brother and I just finished a speed run of Snow Bros. We clicked on both Controllers in Record Data. We did the whole thing, took about 2 hours. When we tried to watch it: the player 2 wasn't moving!!!!! I really don't understand what happened... Maybe it's because one player used the keyboard and the other one used a controller??? Anyways, please answer me... I hope that there's a way to recover the "lost" player 2.... Thanks!!
Former player
Joined: 3/8/2004
Posts: 152
Location: Australia
It is because the player 2 wasn't activated in recording. Go to the "movie's" options and activate the 2nd controller (i think it will say: use controller? 1,2,3,4), but i tell you, if you are using VirtuaNES emulator, you lost the movie :)
G1MM3 4 BR34|C!
Joined: 1/1/2022
Posts: 1716
Hmmmm... I SAID that I activated them. Right before recording, it says: Record Data, and you can click player 1 and 2. I did that. I also tried to make a short movie right before making the big one, and it worked. But on the big one, that's another story. BTW, I'm using Famtasia, not VirtuaNES
Former player
Joined: 3/8/2004
Posts: 1107
If it only took 2 hours then what's the problem? For some games that are very long and hard it can take a total of over 24 hours, probably spread out over a couple of weeks, so be glad you weren't making a speed run like that. Losing 24 hours of work would be really upsetting. Anyway, if you don't want that to happen again in the future, I recommend stopping and then continuing at least once every half hour to make sure the fmv didn't get messed up.
Active player (410)
Joined: 3/16/2004
Posts: 2623
Location: America, Québec
MAybe the second player is playing with a joypad.I have test it with my joypad and for unknown reason nothing was logged(I'm doing Battletoads).So just play with the keyboard and there will be no problem.
Joined: 1/1/2022
Posts: 1716
The player 2 was playing with a controller, a joypad if you prefer. We can't play both on the same keyboard, it would be impossible to make all the cool moves we made... The only problem is that I don't want to live another 2 hours of fights with my brother. It's like: "NO you f*ckhead!! You kill THAT guy!!" Oh well, I guess I'll have to endure him again, only if there's a way to record joypad motions. Btw, speaking of "pausing" and "resuming" production, is there a way to stop recording, close Famtasia, come back later, re-open Famtasia, then continue my .fmv? I'm working on Bucky O'Hare, and I need to take a break...
Editor, Active player (296)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
> Oh well, I guess I'll have to endure him again, > only if there's a way to record joypad motions. I have no experience in using joypads, but I would suggest disabling the keyboard controls for the second player, leaving the joypad as the only choice - maybe it would work. > Btw, speaking of "pausing" and "resuming" production, is there > a way to stop recording, close Famtasia, come back later, > re-open Famtasia, then continue my .fmv? I'm working > on Bucky O'Hare, and I need to take a break... This has been discussed here before.
Joined: 1/1/2022
Posts: 1716
Woot!! Thanks a lot!! BTW, I retried with both keyboard and joypad, I made tests on both players (Keyboard on 1, Joypad on 2 and Joypad on 1, Keyboard on 2) but again, only the player using the keybord works.... I need to find a way to make my joypad "recordable", cause 2 players/brothers on one keyboard is rough.......
Former player
Joined: 3/21/2004
Posts: 32
Location: the Netherlands
You could try using a PS2 keyboard and a USB keyboard or 2 USB keyboards(i think...). Just make sure you sort out who's in control of what keys before you start. :-P
Joined: 1/1/2022
Posts: 1716
I'm using a PS2 Keyboard and a GamePort Joypad... Maybe using a USB joypad will solve the problem... Hmmm... I'll do some tests tonight with both USB joypad and keyboard at the same time... 2 keyboards wouldn't solve the problem, because my brother sucks with a keyboard! So I have to find a way to make a joypad AND a keyboard work in 2 players mode!!! The only thing I wanna know: Is there a way to repair my .fmv so that player 2 becomes active...?
Joined: 1/1/2022
Posts: 1716
Nevermind, I found a way to play with my keyboard AND my gamepad, and recording works!!!!!!!!!!!!!!!!! Thank you! Now I know how to resume my recording when I'm tired!
Editor, Active player (296)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
DJ_FozzBozz wrote:
Nevermind, I found a way to play with my keyboard AND my gamepad, and recording works!!!!!!!!!!!!!!!!!
You shared the problem with us - why not share the solution too?
Joined: 1/1/2022
Posts: 1716
Of course, sorry I got a little excited with that, I forgot to post the solution...!! First, let's say that Player 1 is using the keyboard and that Player 2 is using the GamePort controller (in my computer, my GamePort Joypad is Joystick1 and my USB Joypad is Joystick2). You click on Config, Key, then Pad Assignment. Then you put thew options like that: Pad1: Keyboard: Keyboard1 Joystick: NONE Ext.Pad1: Keyboard: Keyboard1 Joystick: NONE Pad2: Keyboard: Keyboard2 Joystick: Joystick1 (since I'm using the GamePort joypad) Ext.Pad2: Keyboard: Keyboard2 Joystick: Joystick1 I don't know why, but I don't have a second keyboard. But when I select Keyboard2 and Joystick1 for Player 2, it works like a charm. I don't know for the USB joypads... I think that the only thing you'd have to change is Joystick1 to Joystick2
Active player (410)
Joined: 3/16/2004
Posts: 2623
Location: America, Québec
Well Thx now it will be more easier to finish Battletoads.
Former player
Joined: 4/5/2004
Posts: 40
Location: Denmark
DJ_FozzBozz wrote:
Btw, speaking of "pausing" and "resuming" production, is there a way to stop recording, close Famtasia, come back later, re-open Famtasia, then continue my .fmv? I'm working on Bucky O'Hare, and I need to take a break...
I am working on bucky o' hare. Don't steall it. :P But there is something weird wrong with my computer, sometimes it just reboot in a middle of me watching a movie. :( Do you know any bugs or glitchs there would be useful for a speedrun / time-attack? Seems a bit dull atm tho. I have the first run of it, but I need to re-record it again. What is your time for it?
Skilled player (1402)
Joined: 5/31/2004
Posts: 1821
There is no way to activate the second controller in recording after you started making your fmv with only one controller? (starting a new fmv with 2 players, and copying the fmv I already made onto the new fmv with a binary editor doesn't seem to work)
Editor, Reviewer, Experienced player (969)
Joined: 4/17/2004
Posts: 3107
Location: Sweden
>There is no way to activate the second controller in recording after you started making your fmv with only one controller? Quite possibly there is. But 2:nd player won't be moving up until the point where the demo ends. >(starting a new fmv with 2 players, and copying the fmv I already made onto the new fmv with a binary editor doesn't seem to work) Probably because 2 players has double the amount of data per frame. Hopefully someone of the coding geniuses here can help you.
Editor, Active player (296)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
The movie file would have to be converted to allow the second controller. I could do that. So what are you doing? You started playing a game as 1p but later decided that you're going to need the 2nd player too? Then restart it and play it as 2p from the very beginning. It will probably look better.
Editor, Reviewer, Experienced player (969)
Joined: 4/17/2004
Posts: 3107
Location: Sweden
>Then restart it and play it as 2p from the very beginning. It will probably look better. Depends... if Baxter made a video but realized he needed to press UP+A on the second controller after a while, it would be nice to correct that instead of remaking the whole video. Perhaps Baxter should give us some more info on his problem before we (I) jump to conclusions.
Skilled player (1402)
Joined: 5/31/2004
Posts: 1821
I wasn't trying to make a new speedrun or anything, but I felt like playing Zelda, and why not record it? The fastest I could finish the menu-screen in by playing on 5% speed was 141 frames (this is the point where you see the first line of map you can walk on). I was wondering how fast the sleepzteam speedrun did this, and it appeared to be 132 frames. A version played by Michael Fried did it in 129 frames. Both where done using a binary editor, but looking at this, I found a way to do it in 126 frames. After this I continued playing, and after having the first half minute done, I watched it and noticed the 'pause-up-B'-trick didn't work when I rewatched it. Then I saw this thread and knew what the problem was (the 2nd controller wasn't active), so I asked here if it could be turned on afterwards (that's about all the info there is). The problem is I somehow can't get through the menu-screen untill that point in 126 frames if the 2nd controller is activated (it's like it reacts slower, e.g. it accepts 40 00 40 00 40 with only one controller active, but when the second controller is also active 40 00 00 00 40 00 00 00 40 seems to be the fastest possible) (although the sleepzteam somehow does it slightly faster than this using 2 controllers).
Editor, Active player (296)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
This C++ program will read a FMV file and output a FMV file that has at least two active controllers. Warning: Untested. I don't know which order the bytes are in the FMV (fds, p1,p2 or p2,p1,fds or something else).
#include <cstdio>
 
using namespace std;

typedef unsigned long uint32;
typedef unsigned short uint16;
typedef unsigned char uint8;

int main(void)
{   
    FILE *i = fopen("gradius.fmv",       "rb"); /* put here your input file /
    FILE *o = fopen("gradius.fmv-fixed", "wb"); /* put here your output file */
    
    uint8 Header[144];
    
    fseek(i,0,SEEK_END);
    unsigned LENGTH = (ftell(i) - sizeof(Header));

    rewind(i);
    fread(Header,144,1,i);
     
    uint8 oldmask = Header[5];
    const uint8 newmask = oldmask | 0xC0;
    Header[5] = newmask;
    
    unsigned bytes_per_frame = 0;
    if(oldmask & 0x20) ++bytes_per_frame;//fds 
    if(oldmask & 0x40) ++bytes_per_frame;//p2
    if(oldmask & 0x80) ++bytes_per_frame;//p1

    uint32 nframes = LENGTH / bytes_per_frame; 
    
    fwrite(Header,144,1,o);
    
    for(uint32 f=0; f<nframes; ++f)
    {
        uint8 d;
        
        // p1
        d=0;  
        if(oldmask & 0x80) fread(&d, 1, 1, i);
        if(newmask & 0x80) fwrite(&d, 1, 1, o);
        
        // p2
        d=0;
        if(oldmask & 0x40) fread(&d, 1, 1, i);
        if(newmask & 0x40) fwrite(&d, 1, 1, o);
        
        // fds
        d=0;
        if(oldmask & 0x20) fread(&d, 1, 1, i);
        if(newmask & 0x20) fwrite(&d, 1, 1, o);
    }
    
    fclose(i);
    fclose(o);
}
EDIT: Of course it must fwrite to output (o), not input (i).
Skilled player (1402)
Joined: 5/31/2004
Posts: 1821
Thx, I'll give it a try. /edit It just doesn't seem to work with 2 controllers activated, it reads 40 00 40 as 40 40 40. I got it with two controllers up to 132 frames now, which is just as fast as the sleepzteam run.
Former player
Joined: 3/30/2004
Posts: 1354
Location: Heather's imagination
Baxter wrote:
(it's like it reacts slower, e.g. it accepts 40 00 40 00 40 with only one controller active, but when the second controller is also active 40 00 00 00 40 00 00 00 40 seems to be the fastest possible)
This is perfectly true. It's because each controller takes a byte per frame. So the first example was 40, 00, 40, 00, 40 and the second is 4000, 0000, 4000, 0000, 40(00). They're the same time.
someone is out there who will like you. take off your mask so they can find you faster. I support the new Nekketsu Kouha Kunio-kun.
Editor, Reviewer, Experienced player (969)
Joined: 4/17/2004
Posts: 3107
Location: Sweden
Just because there is more data per frame doesn't mean that there should be more frames, does it? I don't get it.
Former player
Joined: 3/19/2004
Posts: 710
Location: USA
No, it just means there is more bytes. An nes controller has 8 buttons. Conviniently, 2^8 equals 256, the size of one byte. Thus every possible conbination of button presses for one frame can be saved in one byte. However, once you have 2 controllers, it is impossible to save all the data in one byte per frame. So, 2 must be used. So, that program should make every other byte after the header 0x00, meaning that no button is pressed. I imagine that the way that it works is that each bit in the byte corresponds to one button. A value of 1 means it is pressed, 0 means it is not pressed.