Post subject: Famtasia fix - 240 line
Active player (276)
Joined: 4/20/2004
Posts: 219
Location: Japan,Tokyo
I am Japanese and i speak poor English. Famtasia screen end has run out. VirtuaNES,NNNester have 240lines option bat Famtasia not If there are those who can do, Please hack it into running at 240lines
Editor, Active player (297)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
It would be nice if Famtasia displayed the full 240 lines instead of 224. I don't know if it is possible to hack it to do that, but if it is, it would be good. - More details in movies - Some glitches in Rockman2 would be easier to abuse if one sees what's happening in the bottom of the screen.
Active player (411)
Joined: 3/16/2004
Posts: 2623
Location: America, Québec
Yeah it will be nice.
Joined: 4/15/2004
Posts: 81
Location: Swe- Krstd
Bisqwit wrote:
It would be nice if Famtasia displayed the full 240 lines instead of 224. I don't know if it is possible to hack it to do that, but if it is, it would be good. - More details in movies - Some glitches in Rockman2 would be easier to abuse if one sees what's happening in the bottom of the screen.
abusing is wrong.. haven't your mother told you xD
// ZtanZ
Joined: 4/11/2004
Posts: 155
Location: Fairfax, VA, USA
We're in luck. It turns out that Famtasia was emulating the full 240 scanlines; it simply wasn't displaying them. Thus, the patch was rather simple. You can apply this patch directly on top of the 60-fps patched version. It's possible that I've missed a few spots in the patch, since the rendering routines are very spread out and there are a lot of rendering options in Famtasia. I'd like people to let me know if they find a configuration that isn't showing the full 240 scanlines.
#include <stdio.h>
#include <stdlib.h>
int main(void)
{
    FILE *fp = fopen("FAMTASIA.EXE", "rb+");
    if(!fp) { perror("FAMTASIA.EXE"); return -1; }
    fseek(fp, 0x1ff0d,SEEK_SET); fwrite("\xf0", 1,1, fp);
    fseek(fp, 0x1f352,SEEK_SET); fwrite("\xf0", 1,1, fp);
    fseek(fp, 0x1f2e6,SEEK_SET); fwrite("\xf0", 1,1, fp);
    fseek(fp, 0x1f389,SEEK_SET); fwrite("\xef", 1,1, fp);  /*fix*/
    fseek(fp, 0x1f2f1,SEEK_SET); fwrite("\xf0", 1,1, fp);
    fseek(fp, 0x1f34e,SEEK_SET); fwrite("\x3d", 1,1, fp);
    fseek(fp, 0x1f2e2,SEEK_SET); fwrite("\x3d", 1,1, fp);
    fseek(fp, 0x1ff31,SEEK_SET); fwrite("\xe0", 1,1, fp);  /*fix*/
    fseek(fp, 0x46920,SEEK_SET); fwrite("\x10", 1,1, fp);
    puts("done");
    fclose(fp);
    return 0;
}
Edit: Just noticed and fixed a small visual glitch
Former player
Joined: 3/17/2004
Posts: 78
Location: Finland
THANK YOU very much
Post subject: Re: Famtasia fix - 240 line
Joined: 3/22/2004
Posts: 95
finalfighter wrote:
If there are those who can do, Please hack it into running at 240lines
「60FPSハック」は、できないと思いました。 「240ラインハックもできません」って思うが、デバッガを作って、何でもできる、ね。 Thanks again for the patch, blip. :)
Active player (411)
Joined: 3/16/2004
Posts: 2623
Location: America, Québec
Well it's for *nix is someone able to share the Famtasia patched version 2?
Joined: 4/11/2004
Posts: 155
Location: Fairfax, VA, USA
Phil wrote:
Well it's for *nix is someone able to share the Famtasia patched version 2?
If you're feeling brave you can try reading the code for clues on what to do in the hex editor. For example, the line:
    fseek(fp, 0x1f352,SEEK_SET); fwrite("\xf0", 1,1, fp);
Means: "Set the byte at offset $1f352 to f0"
Active player (411)
Joined: 3/16/2004
Posts: 2623
Location: America, Québec
ok thx for the hint
Former player
Joined: 3/13/2004
Posts: 1118
Location: Kansai, JAPAN
So, since we've been passing around the 60fps version of Famtasia, can someone hack and distribute the new 60fps/240 line Famtasia? Anyone?
Do Not Talk About Feitclub http://www.feitclub.com
Former player
Joined: 3/9/2004
Posts: 484
Location: ­­
http://babyamy.tripod.com/grinto/famtasia24060.zip (copy this address, rather than clicking it) Hopefully I got it right this time! Choose one of the default window sizes to update it to the new resolution. It doesn't work in fullscreen though, unfortunately.
Joined: 4/11/2004
Posts: 155
Location: Fairfax, VA, USA
I just edited my post and updated the patch to fix a visual glitch. Sorry, I was probably a bit hasty... I'll look into fixing fullscreen next.
Joined: 3/22/2004
Posts: 95
[edited] It works fine at 1x... *snip* And now it works fine at 2x... But 3x is still glitched, it seems.
Former player
Joined: 3/9/2004
Posts: 484
Location: ­­
I've updated the zip with blip's fixes.
Active player (411)
Joined: 3/16/2004
Posts: 2623
Location: America, Québec
I'm waiting for a final release then patch it since I have some problems with some games.BTW you're doing a nice job Blip. P.S. We'll be pleased if someone can correct that stupid speed problem.Thx
Former player
Joined: 3/13/2004
Posts: 1118
Location: Kansai, JAPAN
At this point the 240 version cuts off the top of every game I try, regardless of window size.
Do Not Talk About Feitclub http://www.feitclub.com
Post subject: DVD player
Joined: 4/11/2004
Posts: 155
Location: Fairfax, VA, USA
New patch. Supersedes the previous 240-scanlines patch.
#include <stdio.h>
#include <stdlib.h>
int main(void)
{
	struct
	{
		unsigned long offset;
		unsigned char before;
		unsigned char after;
	} patch[]=
	{
		{ 0x1ff0d, 0xe0, 0xf0 }, { 0x1f352, 0xe0, 0xf0 }, { 0x1f2e6, 0xe0, 0xf0 },
		{ 0x1f389, 0xe0, 0xef }, { 0x1f2f1, 0xe0, 0xf0 }, { 0x1f34e, 0x45, 0x3d },
		{ 0x1f2e2, 0x45, 0x3d }, { 0x1ff31, 0xc0, 0xe0 }, { 0x46920, 0x20, 0x10 },
		{ 0x1f5cd, 0xe0, 0xf0 }, { 0x1f5d8, 0x45, 0x3d }, { 0x1f617, 0xe0, 0xf0 },
		{ 0x1f60c, 0xe0, 0xf0 }, { 0x1f608, 0x45, 0x3d }, { 0x1f1ad, 0x45, 0x3d },
		{ 0x1f1b2, 0x38, 0x3c }, { 0x1f6e0, 0xe0, 0xf0 }, { 0x1f6dc, 0x45, 0x3d },
		{ 0x1f71d, 0xe0, 0xf0 }, { 0x1f460, 0xe0, 0xf0 }, { 0x1f478, 0xe0, 0xf0 },
		{ 0,0,0 },
	};

	FILE *fp = fopen("FAMTASIA.EXE", "rb+");
	if(!fp) { perror("FAMTASIA.EXE"); return -1; }

	int i;
	for(i=0; patch[i].offset; ++i)
	{
		fseek(fp, patch[i].offset, SEEK_SET);
		fwrite(&patch[i].after, 1, 1, fp);
	}

	return 0;
}
This adds fullscreen support. You might notice that the very top scanline has been cut off and an extra one placed at the bottom of the screen -- this is apparently a glitch in Famtasia's emulation. For some reason the x3 magnification is uneven -- not all the pixels are uniform in size -- but I'm not going to worry about it too much right now. :) I'm sorry that I released the previous version before fullscreen support was added. I dont know why it slipped my mind...
Former player
Joined: 3/8/2004
Posts: 1107
Blip, do you think you would be able to hack Famtasia in such a way that would let allow you to redo early parts of a video without having to redo the whole thing?
Former player
Joined: 3/30/2004
Posts: 1354
Location: Heather's imagination
Michael Fried wrote:
Blip, do you think you would be able to hack Famtasia in such a way that would let allow you to redo early parts of a video without having to redo the whole thing?
That's impossible to do, just so you know.
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, Active player (297)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
Michael Fried wrote:
Blip, do you think you would be able to hack Famtasia in such a way that would let allow you to redo early parts of a video without having to redo the whole thing?
Remember causality 'n' consequence. If you really feel adventurous, make a backup copy of your fmv file, then start recording from the earlier position and finish when you're done, and copypaste the rest of the backup file to the end of your now truncated fmv file. All in a binary-safe editor of course.
Joined: 4/11/2004
Posts: 155
Location: Fairfax, VA, USA
Boco wrote:
Michael Fried wrote:
Blip, do you think you would be able to hack Famtasia in such a way that would let allow you to redo early parts of a video without having to redo the whole thing?
That's impossible to do, just so you know.
Actually, I can think of a way to do it. You could embed save states in the movie file. I'd like to see it done just because it'd be a great tool for perfecting time attacks. But it arguably crosses the line to cheating since the movie files are no longer just controller input. It'd be an awful lot of work to hack into Famtasia. VirtuaNES would be more doable since they already have savestates in their movie files... but still not likely to happen I'm afraid. :/
Editor, Active player (297)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
I don't like to see it done.
Former player
Joined: 3/9/2004
Posts: 484
Location: ­­
I've updated the Famtasia executable with the current changes. http://babyamy.tripod.com/grinto/famtasia24060.zip (remember to copy, not click!)
Post subject: Re: DVD player
Editor, Active player (297)
Joined: 3/8/2004
Posts: 7469
Location: Arzareth
blip, thank you very much. You're a genius :) I didn't test this new patch very thoroughly yet, but it seems to work. I just hope it doesn't overflow some buffer or anything :)