Posts for nitsuja


Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
I think he edited the image or the source that generated it, I see: "Posted: 2005-04-01 08:35:55 Post subject: Record from snapshot." on the post. I thought this forum always used a certain time zone for its times, but even if not, I don't live that many time zones away from BoltR. (The actual movie file he posted does in fact show what he intended it to show, and I know I definitely didn't allow the CRC to be as long as 4 digits.)
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
I knew I would be, but I'm really confused as to what's going on (in what's actually in the movie). Was it luck manipulation to see the guy in the desert? How did you warp to the town like that? What did the repeated casts of atlas do exactly and what was the game-over for?
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
I have an idea: Someone should make 1 movie that beats 2 completely different games with the same exact input. It'd be an impressive accomplishment, depending on which 2 games were chosen. Oh, about whatever the topic is, I really like FFT but I second FFTA being a good idea to time attack for now (currently closer to being possible). It too has crazy luck manipulation possibilities, probably moreso actually.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Oh good, something else to fix. Wait... somehow I don't believe you... might this have something to do with today's date?
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Here's another version: http://nvdata.pilif.ch/VBA-rerecording-new4.zip I tried fixing the video skew and un-offsetting the sound offset, but right now I can only guess that these work as intended. (For when you're not recording, any delay is probably due to latency in emulating DirectSound or something. I've never experienced a sound delay that could be noticed when listening at 100% speed, and of the few frames of delay there are, I think some/most of that is really supposed to be there. EDIT: OK, perhaps I'm wrong about that, I just tried Shanedudddy's version instead of the official version and noticed the sound delay of 6 frames or so is gone, I'll take another look at what changes he made... EDIT2: On further investigation, the only reason you could hear sound effects at exactly the right frame before was because the sound kept playing in a loop on frame advance. There is no way around the fact that the sound that plays from a sound buffer must be delayed by the sound buffer length, which is currently about 6 frames. I could make the buffer length configurable, however, so making it shorter would reduce sound latency, but for now that's not necessary, it can't affect the AVI anyway.) Also, in case you still wanted to know this: The sound is always 44100 Hz, 16-bit, Stereo. And I just verified that VBA emulates all games at 60 fps.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Bag of Magic Food wrote:
Well, whenever I need to transfer a file between computers without a disk handy, I just E-mail it to myself as an attachment. And if it won't accept .smv attachments, you could try renaming or zipping it.
For some reason, e-mailing stuff to myself never works too well when I don't have an internet connection... (Although I guess it's still a valid suggestion seeing as there are usually other locations that one could access the internet through besides work and home.)
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Mr. Kelly R. Flewin wrote:
And there's not many showy attacks that could be done... so could you elaborate so we'll know exactly what you mean?
Oh, well if you watch Sleepz's run, there's a lot of stuff done purely for entertainment that wasn't done here... throwing something and jumping off a wall, dancing on top of the weapon, juggling weapons off the wall as they bounce back and forth alternating hitting the enemy very rapidly, tricking enemies into thwacking each other as you go by, etc. If the waits are too short, even just backing up a bit so it looks like you have more momentum when attacking might look better. I liked how you sometimes pick up guys and use them as weapons though, but when they take a long time to die afterward it seems awkward.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
quietkane wrote:
I've been recording with (U) v1.0. I haven't noticed any "garbage text" aside from stray spaces in conversations. Since each character of text takes exactly 1 frame to display and I've only seen two such extra characters, I'm not going to change the version until either 1) I notice a serious bug.
I think there is a serious graphical bug later in the game at a water temple or something like that... It's a short place you just have to walk through but the graphics make no sense at all. Nothing people that've played through the US version haven't seen before.
quietkane wrote:
As an answer to how far along I've gotten, I've cleared the Alunze dungeon, (the 3rd dungeon in the game) but the movie's de-synching at the entrance to the cave at Sudeltan. ... If I can't get it to synch again I'm going to be very pissed.
Uh-oh... what emulator version are you using, and what are your settings?
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Is that question just about the 12-byte character array (oh, well if not, the following also applies to the "Info" section too)? Yes, it's 1 byte of ASCII per character (left to right in the file), taken directly from the ROM. z is 122, ä is 228 (and the other character you asked about just shows up as a box for me). The 4-byte game code is also parsed as ASCII when it's displayed, but it's treated as an integer otherwise. (These are only used by the emulator to show if ROMs mismatch, there's no title information good enough to pull out of the file directly to get the game name or ROM filename.) I noticed in the code you posted, it always outputs to test0.avi even if you tell it at the commandline to output it somewhere else, I changed this but you changed it back in version 2, so was this the desired behaviour? Do you know of anything (that works in Windows) that can display the uncompressed AVI frames that are outputted? It looks like you're printing some AVI header information, but I can't find any video player that recognizes the format. I'm also not sure if the color format is correct, you said you assume 16-bit color but there are a lot of variations of how 15/16-bit color can be stored. About the slowdown, I don't know whether it's a problem, but I wouldn't know how to fix it if it was. I doubt it's as simple as them accidentally setting a clock frequency variable too low.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Oh, that... I thought that was a problem with earlier versions of VBA overestimating the processor, since it was changed to that a version or two ago.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Unnecessary lag? I don't think any of the changes that still need to be made involve changing the timing of the game. If you mean the sound lag, that's just DirectSound lagging in playing the sound that's already being emulated with the correct timing, and that wouldn't even go into an AVI (because the raw sound is outputted directly and combined with the video later, no waiting for something to play it. The only problem now is I'm not sure how to verify that the output is correct so the video output is messed up (currently reading the "Converting *** to AVI" pages to see if anything there helps with that.) As for the frame rate, I can't find any indication that the emulator uses anything but 60 fps for all games.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Hmm... it is at a higher difficulty than Sleepz's run, but it's obvious when watching it that it could be faster (I could be wrong but it really looks like it), and the tactics used are much less entertaining and don't look as perfectly executed (getting hit by something you threw looks especially bad, even if it doesn't waste time, and a lot of the time spent waiting could probably have been used for starting up a showy attack or something).
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
OK, I figured there will be problems as I don't know how to test whether the output is correct - I don't know what you use to read the raw data in and convert it to AVI but it would help if I was able to do that to see if the output makes sense. I'll see if I can find any of these problems at the moment, though. About the sound lagging, that's because of the "Synchronize Emulation Speed" option that causes emulation speed to wait for the sound to play for its buffer length so it can proceed at a speed that lets the sound play perfectly smoothly. Even official versions do this. (Setting the throttle to something else than 100% used to disable synchronize which is probably why you didn't notice it happening before.) It's not related because he was most likely using -synchronize 0 when recording. (EDIT: err, actually it is related, he was just talking about playback, I didn't read carefully enough. This is how the emulator behaves normally, I don't know how to fix it besides turning off synchronize which has even worse side-effects.) (another EDIT: I just found why the frame size would be screwed up, I thought I was passing the exact pixel data that was being passed to the AVI output, but I missed that it was calling another helper function to strip off black pixels and convert the bit depth first. It doesn't appear to be 4 pixels though, it looks to be 2 on the right and 1 on the top, from the code.)
Post subject: GBX games to do
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Maybe this was already brought up and lost in the "Other Games" section, but it seems like there should be a topic for suggesting what Game Boy Whatever games would make good time attacks. Here's some I'd like to see:
  • Super Monkey Ball Jr. - like a fast-paced 3D Marble Madness, could do a run of Expert mode in less than 10 minutes
  • Elevator Action - a run of the New game, would be short and fast-paced, and pretty varied with some effort
  • Pocket Bomberman - Normal Game
  • Kuru Kuru Kururin - timed skill-based getting-propeller-thing-through-a-maze game
  • Sonic Advance 1/2
  • Final Fantasy Tactics Advance - sure you can easily play for 100+ hours, but I think it can be done without doing any side-quests or leveling trips, which would make it pretty short
  • Sword of Mana
  • Mario & Luigi
  • Kingdom Hearts Chain of Memories
  • Super Mario Advance - I think there are enough significant differences to make the run different and worth watching
And of course:
  • All the Zelda games (Link's Awakening (and DX), Oracle of Ages/Seasons, The Minish Cap)
  • All the Metroid games (II, Zero, Fusion)
  • All the Mega Man games (regular ones, Zero ones, maybe Battle Network)
  • All the Castlevania games
  • Anything but Pokemon
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
SGB games are 256x224 with the border, or 160x144 without the border. SNES games can have anywhere between 224 and 240 pixels of height, but I don't think SGB games ever make use of more than 224 (or if they do then VBA never emulates that). Besides that everything looks right. Some games have data for GBC, SGB, and GB systems in them, but typically such games should be recorded for GBC, or SGB if that's not available, with GB being the last choice. In general there's no reason such games should behave the same for all 3 systems although that's probably intended most of the time. Anyway, if you're going to group anything together it should probably be those 3 systems, but I think it'd be better to have the individual system shown.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
TheAxeMan wrote:
[checks "make recent on load"] Wow, thanks! Oh one more thing, I started using the read-only on/off switch, this is great! I can't say how many times using FCEU I've had to replay movie readonly-savestate-replay writeable. This make things much easier. However, after working on Mario Land I hit "stop playing movie" instead of "stop recording movie." It stopped but didn't save my progress (luckily for me it was just a matter of loading a save) Anyway, not sure what the behavior should be, but it would be annoying to lose progress like this.
I should mention something about "make recent on load", currently it's implemented by immediately saving everytime you load, so if you load a state while the movie isn't active and that option is on, it will no longer be a movie snapshot. I'll post another update that only does it if a movie's active (and maybe fixes something else wrong with it too). "Stop Playing Movie" and "Stop Recording Movie" both call the exact same code, actually, so that's a bug if it didn't save. I'll see why the menu thought it was in playback mode, maybe that has to do with it.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
I didn't realize there were multiple versions of the GBA BIOS file, are they both good ones? Usually saying it uses a BIOS file is enough, and VBA will display a checksum mismatch if it isn't. And there's always the possibility of using the emulator's built-in one, which people seem to prefer doing anyway. In previous versions of VBA some games had weird graphics/sound glitches when not using the BIOS, but I think its accuracy has improved a lot.
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
OK, I added -audiolog and -videolog flags that use the nesvideos-piece code. http://nvdata.pilif.ch/VBA-rerecording-new3.zip Here's a sample command that outputs raw video data from a run: VBA-rerecording -rom "Roms\Mega Man 5 (U) [S][!].sgb" -play "Mega Man 5 (U) [S][!].vbm" 1 -frameskip 0 -hideborder 0 -synchronize 0 -throttle 1000 -videolog "mm5.video" -frameskip 0 is to make sure all frames get in the video. (It can/should be set higher when not outputting video.) -synchronize 0 tells it to NOT limit the playing speed to the normal sound-playing speed. (For normal viewing, use synchronize 1 instead.) -throttle 1000 tells it to run at 1000% speed, or as fast as the computer can handle, whichever is lower (probably the latter). Must also have -synchronize 0 or this won't work right... (For normal viewing, use throttle 100 instead.) -hideborder 0 tells it to include the SGB border. You can set to 1 if you don't want the border in the movie, or if only outputting audio. Ignored for non-SGB games. More info: You can do -audiolog and -videolog at the same time (into separate files), but at least for me this is very slow compared to doing them at different times. You can use -quitAfter to make the application automatically quit when the frame counter hits a certain number, so you don't have to be there to shut it down if you know how many frames you want to output. (It still works if it's higher than the number of frames in the movie.) The frame counter can be viewed by hitting ".", by default. It (and any other messages) will not go into the video output. If this was a GBA game that was played with a BIOS, you could use -bios to specify your GBA BIOS location. I'm not sure if you want to require the 5-second GBA "Nintendo" logo be at the start of all GBA runs. I'm guessing not (it's part of the BIOS, not the game itself) but it's still an option when making runs just in case. I think the application still needs MFC71.dll and msvcr71.dll to run. (These are both publicly available files, if you don't have them already.)
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Well, all the "desired" ones are done already. What exactly do you mean by raw audio and video data? Currently there is the option to export to an uncompressed WAV audio file and to an AVI with no compression codec (or with a codec and sound for that matter), but I'm not sure if these count. If not, it shouldn't be too hard to add some code that outputs the raw video/audio data... do you want the formatting information (width, height, depth) to be part of the file in some format I define, or outputted elsewhere? Also, about Wine, are there any features of Windows that don't emulate properly in Wine that I should avoid? (And I don't know what OS you'll be using but it should be compatible with Win98 and up.)
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Uploaded a new version that hopefully takes care of all the problems (and feature requests). Let me know how the Win98 compatibility is and what DLL's it complains about now, especially. http://nvdata.pilif.ch/VBA-rerecording-new2.zip
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Bag of Magic Food wrote:
Ooh, I found another bug. You know the Select+Start+A+B reset code that many games have? Well, in the first and third Mega Man games (any version), using that code causes VisualBoyAdvance to freeze completely. I don't know of any other games that have this problem, but I'll tell you if I find any.
Wow, this sounds completely ridiculous, but I just tried it and it does happen. Trying to fix it now... (In other news I think I've just fixed all the other problems, they were mostly stupid little problems of forgetting to define something or moving a line of code to the wrong place, I'll try to fix this one before uploading a new version though.)
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
I didn't realize it was possible to get away with still using Win98 these days. The best I can do for testing that is to turn on the Windows 98 "compatibility mode", but it still brings up the regular WinXP browse dialogs even then. When I turn off the Windows XP "visual themes" though, it freezes on startup, and so does the official version and all other versions of VBA. What I can do is try putting up a few different builds with various attempts to fix it, and see if any of them work for the people using Win98. (But, I can't work on this anymore for a little while. In the meantime, people on WinXP can continue making runs; at least so far, nobody's reported any problems with synchronization/timing/etc. that would necessitate modifying the movie format.)
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
About read-only, can you give steps to duplicate this? I use it a lot and it works for me so far. (And in any case, just because it wasn't saved doesn't mean your progress is lost, just open the movie in non-read-only and load the last state you saved and it'll add it all back into the movie.)
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
Bag of Magic Food wrote:
There seems to be a flaw in the use of borders during movies: VBA uses the border settings for the previously played movie rather than the current one. So if you watch a SGB movie immediately after watching a GB or GBC movie, it won't show the border unless you turn it on yourself; and if you watch a GB or GBC movie immediately after watching a SGB movie, there'll be a useless black border, even if you never turned it on.
Hmm, you're right. This was working but then I had to fix something else (VBA handles borders really strangely so it would pause and resize the window several seconds into the movie unless it's overridden in a certain way), so I just have to, uh, fix the fix. Maybe I should add a "no border" checkbox to the play movie screen while I'm at it?
Emulator Coder, Experienced Forum User, Published Author, Skilled player (1301)
Joined: 12/21/2004
Posts: 2687
One time you get hit isn't followed by walking through anything while you're invincible, did getting hit do something like push you onto the next screen earlier than normal? I know the ladders and mist part can't be done any better, unless there's some way to move up faster. Getting hit knocks you down 1 or even 2 screens before you regain control, and the invincibility period is too short to use a hit from anything else to go through them.