Jump to content


Photo
- - - - -

Mame 0117 patches


  • This topic is locked This topic is locked
35 replies to this topic

#1 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 22 July 2007 - 04:11 PM

I have written a little program that can create patches for Mame executables.

These patches need to be applied to the official Mame releases from mame.net namely either...

1. mame0117b.exe - Windows command line version of MAME 0.117
2. mame0117b_i686.exe - Windows command line version (Pentium Pro optimized) of MAME 0.117.

You need to extract the patch into your Mame folder using the appropriate patch for your version of Mame and run APPLYPATCH.BAT.

If all goes well it should give no error message.

If you are interested in the program I wrote to create the patches, you can read more about it here. I'm not going to be creating patches for other versions of Mame so maybe someone else who can compile Mame might like to provide patches for those.

DISCLAIMER: These are only patches, not Mame executables.

#2 emphatic

emphatic

    Proud contributor to the GameEx community

  • Member
  • PipPipPipPipPipPipPip
  • 868 posts
  • Gender:Male
  • Location:Sweden
  • Interests:My family<br />Arcade games<br />Television<br />Movies<br />Music

Posted 22 July 2007 - 04:53 PM

Wow, that is very cool!

Is it possible to modify the patches to work with other MAME builds as well? Such as MAME32Plus! or MAME32FX?

Emph
Posted Image

#3 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 22 July 2007 - 08:14 PM

I have written a little program that can create patches for Mame executables.

These patches need to be applied to the official Mame releases from mame.net namely either...

1. mame0117b.exe - Windows command line version of MAME 0.117
2. mame0117b_i686.exe - Windows command line version (Pentium Pro optimized) of MAME 0.117.

You need to extract the patch into your Mame folder using the appropriate patch for your version of Mame and run APPLYPATCH.BAT.

If all goes well it should give no error message.

If you are interested in the program I wrote to create the patches, you can read more about it here

DISCLAIMER: These are only patches, not Mame executables.

I wanted to do this since they took the -Skip_Disclaimer away. I've read if you downloaded the source they provide you could comment out The code that brings it up. And compile your own... I'am not to sure if its somthing I can grasp.

I too use mame plus and am couirus if it works....Perhaps I'll live dangerously and try it.
EDIT...Well it seems Headkaze posted a pic of patcherFE on the link he made over on arcade controls..It apears he patching mame plus by the looks of the EXE...
2nd Edit...The patcher Pic on the other page isnt the same as whats attached here..Mamepp.exe does not work.

I can see it now...All the requests headkaze is going to get to make patches for every version of mame.

Its a great program. I however cannot take advange of it

Many people will find it usefull Headkaze you are the man ;)
You must defeat Sheng Long to stand a chance

#4 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 22 July 2007 - 08:23 PM

Wow, that is very cool!

Is it possible to modify the patches to work with other MAME builds as well? Such as MAME32Plus! or MAME32FX?

Emph


The patches only work with the exe they are created from. So if you wanted to patch Mame32Plus! or Mame32Fx you would have to create separate patches for those. I've released the tool to make the patches, so maybe others will be willing to compile them and host the patches somewhere.

#5 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 22 July 2007 - 08:33 PM

The patches only work with the exe they are created from. So if you wanted to patch Mame32Plus! or Mame32Fx you would have to create separate patches for those. I've released the tool to make the patches, so maybe others will be willing to compile them and host the patches somewhere.

I would love to help...Can you point me in the right direction I downloaded the file you attached to this thread..Do I need anything else..A little instruction would help.
You must defeat Sheng Long to stand a chance

#6 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 22 July 2007 - 09:00 PM

Well if you don't know how to compile Mame you can't really help.

Let me try to explain what a patch is, and how it works.

1. First I download both the binary executable and source code of a version of Mame I want to patch
2. I then edit the source code so that it skips disclaimer and dosn't show loading screens. I then compile this new version.
3. Now I run my patcher program, pointing the source file to the original binary executable, and the patched file to my custom compiled version.
4. It then spits out a patch file along with the files necessary to apply the patch.
5. I post the patch online, and other people can download the same Mame binary I did in step one and apply my patch to convert that file into the one I compiled in step 2.

So although I've made it easy to make patches, you still need someone to create the patch and host it somewhere. I'm sorry guys but I don't want to take up the task of patching and compiling every version of Mame. Hopefully some kind soul who can compile Mame will be willing to take on the task. I dont mind creating patches with the basic command line version of Mame because that's the version I run and I compile it anyway.

#7 BillyB

BillyB

    Lurker

  • Member
  • PipPip
  • 18 posts

Posted 22 July 2007 - 10:13 PM

If anyone needs help compiling MAME, check out Mr. Do's step-by-step instructions. It's nice to not have to rely on someone else to get the latest "u" release. Now I can just do it myself.

http://www.mameworld...do/compile.html

#8 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 22 July 2007 - 11:47 PM

If someone is willing to compile and host patches I can also give instructions on what source to modify to remove the disclaimer and loading screens.

#9 emphatic

emphatic

    Proud contributor to the GameEx community

  • Member
  • PipPipPipPipPipPipPip
  • 868 posts
  • Gender:Male
  • Location:Sweden
  • Interests:My family<br />Arcade games<br />Television<br />Movies<br />Music

Posted 23 July 2007 - 05:00 AM

But, GameEx's functionality for sending keys is still working, right? Check out my feature suggestion in the thread where you do that:

Feature description in short: Totally hide loading process for MAME games.

Now that GameEx has functionality for sending keys to MAME only when needed (skip disclaimer), how does that work exactly? Does GameEx 'sense' when there's a dialog window open in MAME? If that's so, could it be possible for GameEx to completely hide all the "loading", "decoding" and such messages until the game itself is loaded? As the game is loaded, GameEx could either display a black screen or a "initializing game" screen instead. Or perhaps some artwork from that game?





Emph
Posted Image

#10 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 23 July 2007 - 05:39 AM

Don't know what happened there, but my reply disappeared.

I was just saying that how GameEx skips disclaimer may not work in the newer versions of Mame. They have changed the way keyboard input works. It's not a simple matter of showing a blank screen while Mame loads, Windows just doesn't work like that I'm afraid.

#11 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 23 July 2007 - 06:51 PM

Well if you don't know how to compile Mame you can't really help.

Let me try to explain what a patch is, and how it works.

1. First I download both the binary executable and source code of a version of Mame I want to patch
2. I then edit the source code so that it skips disclaimer and dosn't show loading screens. I then compile this new version.
3. Now I run my patcher program, pointing the source file to the original binary executable, and the patched file to my custom compiled version.
4. It then spits out a patch file along with the files necessary to apply the patch.
5. I post the patch online, and other people can download the same Mame binary I did in step one and apply my patch to convert that file into the one I compiled in step 2.

So although I've made it easy to make patches, you still need someone to create the patch and host it somewhere. I'm sorry guys but I don't want to take up the task of patching and compiling every version of Mame. Hopefully some kind soul who can compile Mame will be willing to take on the task. I dont mind creating patches with the basic command line version of Mame because that's the version I run and I compile it anyway.


I think I got it....What exactly do you edit to make those screens go away?
You must defeat Sheng Long to stand a chance

#12 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 24 July 2007 - 01:44 AM

Headkaze,
I have all the compile tools, Mame Binary and source.
Do I need a DIFF file now to apply? Or what file do I edit..And what exacly am I looking for?

Any help is greatly appreciated. If I'am successfull I will post a patch for MAME32 plus build 117
You must defeat Sheng Long to stand a chance

#13 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 24 July 2007 - 02:43 AM

Okay here are the lines of code you need to modify to remove disclaimer / loading screens.

The file you need to edit is the src\emu\ui.c file.

1. Add the following line in "int ui_display_startup_screens(int first_time, int show_disclaimer)"

show_gameinfo = show_warnings = show_disclaimer = FALSE; // Add this line

/* disable everything if we are using -str */
if (!first_time || (str > 0 && str < 60*5))
	show_gameinfo = show_warnings = show_disclaimer = FALSE;


2. in "void ui_update_and_render(void)" comment out the following line (add "//" to the start of the line)

//ui_draw_text_box("Updating Artwork...", JUSTIFY_CENTER, 0.5f, 0.5f, messagebox_backcolor);

3. Also comment out the following line:
static UINT32 handler_messagebox(UINT32 state)
{
	//ui_draw_text_box(messagebox_text, JUSTIFY_LEFT, 0.5f, 0.5f, messagebox_backcolor);
	return 0;
}


#14 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 24 July 2007 - 02:56 AM

Okay here are the lines of code you need to modify to remove disclaimer / loading screens.

The file you need to edit is the src\emu\ui.c file.

1. Add the following line in "int ui_display_startup_screens(int first_time, int show_disclaimer)"

show_gameinfo = show_warnings = show_disclaimer = FALSE; // Add this line

/* disable everything if we are using -str */
if (!first_time || (str > 0 && str < 60*5))
	show_gameinfo = show_warnings = show_disclaimer = FALSE;
2. in "void ui_update_and_render(void)" comment out the following line (add "//" to the start of the line)

//ui_draw_text_box("Updating Artwork...", JUSTIFY_CENTER, 0.5f, 0.5f, messagebox_backcolor);

3. Also comment out the following line:
static UINT32 handler_messagebox(UINT32 state)
{
	//ui_draw_text_box(messagebox_text, JUSTIFY_LEFT, 0.5f, 0.5f, messagebox_backcolor);
	return 0;
}


Thanks Headkaze....I feel a little intimidated I must admit..My palms are swetty....Here we go
You must defeat Sheng Long to stand a chance

#15 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 28 July 2007 - 01:44 AM

I am very close to compiling mame32plus.

I can get rid of the decompress and loading screens. but game info and disclaimer still showup.

I am attaching my ui.c

I know Im missing somthing to do with the first part.. commenting out existing lines is easy

Attached Files

  • Attached File  ui.zip   17.71KB   9 downloads

You must defeat Sheng Long to stand a chance

#16 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 28 July 2007 - 01:57 AM

Close but not quite :)

You have to insert that whole line of code and thats it. I'll give a larger snippet of code for you to see...

int ui_display_startup_screens(int first_time, int show_disclaimer)
{
#ifdef MESS
	const int maxstate = 4;
#else
	const int maxstate = 3;
#endif
	int str = options_get_int(mame_options(), OPTION_SECONDS_TO_RUN);
	int show_gameinfo = !options_get_bool(mame_options(), OPTION_SKIP_GAMEINFO);
	int show_warnings = TRUE;
	int state;

	show_gameinfo = show_warnings = show_disclaimer = FALSE; // <--- this line is added

	/* disable everything if we are using -str */
	if (!first_time || (str > 0 && str < 60*5))
		show_gameinfo = show_warnings = show_disclaimer = FALSE;

	/* initialize the on-screen display system */
	slider_init();
	...


#17 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 28 July 2007 - 02:09 AM

Close but not quite :)

You have to insert that whole line of code and thats it. I'll give a larger snippet of code for you to see...

int ui_display_startup_screens(int first_time, int show_disclaimer)
{
#ifdef MESS
	const int maxstate = 4;
#else
	const int maxstate = 3;
#endif
	int str = options_get_int(mame_options(), OPTION_SECONDS_TO_RUN);
	int show_gameinfo = !options_get_bool(mame_options(), OPTION_SKIP_GAMEINFO);
	int show_warnings = TRUE;
	int state;

	show_gameinfo = show_warnings = show_disclaimer = FALSE; // <--- this line is added

	/* disable everything if we are using -str */
	if (!first_time || (str > 0 && str < 60*5))
		show_gameinfo = show_warnings = show_disclaimer = FALSE;

	/* initialize the on-screen display system */
	slider_init();
	...



Aww shit....Thanks.... I can smell a new patch right around the corner
:lol:
You must defeat Sheng Long to stand a chance

#18 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 28 July 2007 - 02:51 AM

Finally,
A very big thankyou to headkaze for all his help. Here is a patch for MAME32PLUS 117

Have fun.


Download removed for a couple min
*It appears that it doesnt matter if I replace the EXE Im looking into the mameplib.dll*

Ill upload the whole exe if I have to
You must defeat Sheng Long to stand a chance

#19 headkaze

headkaze

    GameEx God (Top Rank)

  • GameEx Author
  • PipPipPipPipPipPipPip
  • 4549 posts
  • Gender:Male

Posted 28 July 2007 - 03:10 AM

You don't replace the exe! You need to patch the original exe with the one you just compiled. This is all done in PatcherFE you don't copy over the exe with anything. Please don't upload the Mame exe here it's too large (and wouldn't look good either), that's the whole point of the patcher.

I've created a MamePlus patch for you but I was hoping you could figure it out. If you can't I can post it instead.

Remeber in PatcherFE

Source File == Original mamep.exe you downloaded from http://mame.emu-zone.org/ (GCC Binary 0.117)
Patched File == Your compiled mamep.exe with the changes you made to the source
Output File == The zip file it creates (patch)

#20 Brian Hoffman

Brian Hoffman

    GameEx God (Top Rank)

  • Elite Member
  • PipPipPipPipPipPipPip
  • 3864 posts
  • Gender:Male
  • Location:SoCal

Posted 28 July 2007 - 03:20 AM

Its not That I cant figure it out. :(

I thought mame pluses EXE is MAMEP.exe I pointed to the source (the official one I downloaded)
I pointed to the one I compiled (which was tested and works..Again thaks very much)
and I created the out put file...All worked good

When I tried using the patch I created It said It patched successfully but I still got the loading screens..
My only conclusion is I patched the wrong EXE. I tried using the mamepgui exe and still no luck.

I am not uploading to Toms server I am uploading to mega upload. Ill send you a link and you can tell me what the heck is going on.

It is okay I will also post the link here.
You must defeat Sheng Long to stand a chance




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users