Posted: Tue Dec 05, 2006 6:01 pm
OK, I have finished checking for 3rd update.
http://zetubou.mine.nu/timer/file/bomber31853_d5.zip
http://zetubou.mine.nu/timer/file/bomber31853_d5.zip
Memory altering cheats for emulators
http://www.mamecheat.co.uk/forums/
I've got the file and the password, thanksShimaPong wrote:OK, I have finished checking for 3rd update.
http://zetubou.mine.nu/timer/file/bomber31853_d5.zip
How does it work ? Which bit of the option field is it ? I have serious doubt with this code :* code loading:
- Ignored to load old format code by default. If you need to
load, choose "Load Old Format" item in Options menu.
But in the future, it should be merged into new format.
Code: Select all
/* ----- convert the old code to the new format ----- */
if(TEST_FIELD(cheatOptions, LoadOldFormat))
//type = ConvertOldCode(oldCode, oldCPU, &data, &extendData);
continue;
Last thing : please NEVER remove the possibility to still use the old format as I REALLY need it !Cheat Engine Commands:
These special cheat lines are used to set global preferences for the cheat engine. They follow this format:
:_command:[ data ]
The lower byte of the data field stores the command, and the remaining bytes store data for the command. Here is a list of the commands:
0x00 disable help boxes (once I add them)
0x01 use old-style cheat search box (now redundant)
0x02 use new-style cheat search box
0x03 don't print labels in new-style search menu
0x04 auto-save cheats on exit
So, if you wanted to use the old-style cheat box, you would add this line to your cheat.dat:
:_command:00000001
As you choose. If I can divide source file, I don't hope others.Stephh wrote:I'm not sure that cheat.txt will be added to official documentation files ... IMO, it should be best distributed with Pugsy's cheat.dat file ... What do you think about that ?
Sorry, the dust has remained. It's hard for me to figure out many modification completely in "BIG" file.Stephh wrote:How does it work ? Which bit of the option field is it ? I have serious doubt with this code
Yes, I don't fix divided information right now.Stephh wrote:BTW, in cheat.txt, the comments seem wrong
Please give me an idea to manage current "BIG" cheat source file !Stephh wrote:Last thing : please NEVER remove the possibility to still use the old format as I REALLY need it !
Now that MAME 0.111 is out, could you please send me an update cheat.c file that fixes the bug and which is up-to-date ? IMO, it hasn't changed, so you shall only need to fix what's wrong ... And if you've made some new changes, don't forget to include an updated cheatnew.txt file ... TIA ...ShimaPong wrote:Sorry, the dust has remained. It's hard for me to figure out many modification completely in "BIG" file.Stephh wrote:How does it work ? Which bit of the option field is it ? I have serious doubt with this code
Remove "//" to work old format loading. Other fix will be unneeded.
I know the file is big, but cheats are only tolerated (because some of them - even if we spend time in checking them - are still buggy and cause bugs that shall not be reported on MAME Testers board) ... So, I'm not sure that some Devs would be happy to split cheat.c in multiple files ...Please give me an idea to manage current "BIG" cheat source file !Stephh wrote:Last thing : please NEVER remove the possibility to still use the old format as I REALLY need it !
After arrangements are finalized.could you please send me an update cheat.c file that fixes the bug and which is up-to-date ?
Current database has the same material as cheat.txt. I think divide it from the database too because also the database is big.As for cheat.txt, the file will be distributed by Pugsy
Main problem is that I don't know how to divide source file because it needs to fix other files which is not associated with cheat core directly.Anyway, how many parts do you need ?
OK, I will wait ... I'm going on holidays in about 10 days, so I'd be very happy if you could send me something before (remember that I need to make some preliminary tests before I submit the file(s) to MAME Team) ...ShimaPong wrote:After arrangements are finalized.could you please send me an update cheat.c file that fixes the bug and which is up-to-date ?
Don't remove the ConvertOldCode function, tell me the way you want to use it (use an option or try old format if cheat line doesn't match the new one), and I'll fix that if you have troubles with it ...But I don't use and understand old format so that if the cheat engine has a trouble, I may be unable to resolve an issue.
IIRC, most of the blahblah at the begining of Pugsy's cheat.dat file is a copy of what is at the begining of cheat.c ... So if you have sort of "header" named cheat.txt, I think you could remove the text in it from both cheat.dat and cheat.c (wait for Pugsy's confirm though) ...Current database has the same material as cheat.txt. I think divide it from the database too because also the database is big.As for cheat.txt, the file will be distributed by Pugsy
I agree that cheat.c as dependencies, but not that much ... I'll try to compile a version without the cheat engine and see which files need to be changed ... Then I'll post a list here as fast as possible, and we'll see what needs to be done when I come back in mid-January ...Main problem is that I don't know how to divide source file because it needs to fix other files which is not associated with cheat core directly.Anyway, how many parts do you need ?
So I hope you to do if you will.
PLEASE send me what you have then, so I can have a look before I go on holidays ...ShimaPong wrote:Now stop updating and checking the cheat engine ...
Sorry... I make an effort before you go on holidays though I don't know when you go.Stephh wrote:so I can have a look before I go on holidays ...
I leave on next Thursday (21st of December) ...ShimaPong wrote:Sorry... I make an effort before you go on holidays though I don't know when you go.Stephh wrote:so I can have a look before I go on holidays ...
I've only had a quick look at your changes and there seems to be a little error with the LoadOldFormat and Debug options in SelectOptions function :ShimaPong wrote:3rd Update Plus.
http://zetubou.mine.nu/timer/file/bomber32453_d5.zip
Code: Select all
case kMenu_LoadOldFormat:
if(TEST_FIELD(cheatOptions, Debug))
TOGGLE_MASK_FIELD(cheatOptions, LoadOldFormat);
break;
Code: Select all
case kMenu_LoadOldFormat:
if(TEST_FIELD(cheatOptions, LoadOldFormat))
TOGGLE_MASK_FIELD(cheatOptions, LoadOldFormat);
break;
case kMenu_Debug:
if(TEST_FIELD(cheatOptions, Debug))
TOGGLE_MASK_FIELD(cheatOptions, Debug);
break;
Sorry, it's not bug. I have forgotten to explain it.Stephh wrote:If you agree with this, I change the cheat.c file, then I submit it to MAME Team
I understand your point of view, but I don't have time at the moment to allow such thing, so I submitted your file with these changes :ShimaPong wrote:Sorry, it's not bug. I have forgotten to explain it.
Debug option is for cheat engine developer so that I intend to forbid changing by end-user easily.
Developer needs to edit command code directly on the text editor and can confirm debug ON/OFF on the Options menu.
I made that point before, and I can't manage old format so that "Load Old Format" is one of Debug items.
But if you feel troublesome, fix with your idea and send.
Code: Select all
case kMenu_LoadOldFormat:
TOGGLE_MASK_FIELD(cheatOptions, LoadOldFormat);
break;
case kMenu_Debug:
TOGGLE_MASK_FIELD(cheatOptions, Debug);
break;
I don't understand why you say, "search function seems to be broken".Stephh wrote:The most important thing is that the (classic ?) search function seems to be broken somewhere : I can't even not find lives for a game such as 'bonzeadv' as the result is always 0 when I "continue" search ! Isn't there a problem with the "backup" data ?
Also I don't know why the cheat engine doesn't load old format.Stephh wrote:The "load old format" option doesn't seem to work correctly as the old cheats now seem to be always loaded ... It's a good news that old format is still supported, but the option should do something ...
...? Please more easy English.Stephh wrote:Once all this is fixed, I'll ask you to stop further development on this file (what else do you need anyway ?) as the cheat.c file needs special work and a huge rewrite, not to add new stuff, but to have a source file which is "compatible" with all the other ones in MAME ...
I also get 0 results for advanced and classic mode in 0.111u2, I tried it on a few games including asterix. There's also no option to select which memory areas to search.ShimaPong wrote:I don't understand why you say, "search function seems to be broken".Stephh wrote:The most important thing is that the (classic ?) search function seems to be broken somewhere : I can't even not find lives for a game such as 'bonzeadv' as the result is always 0 when I "continue" search ! Isn't there a problem with the "backup" data ?
Because the search function works on my MAME 0.111u2.
Please more report.
I found the bug that affects the "classic" and "advanced" search ("minimum" was working correctly) : you ALWAYS initialised the search, thus the 0 results ...ShimaPong wrote:I don't understand why you say, "search function seems to be broken".Stephh wrote:The most important thing is that the (classic ?) search function seems to be broken somewhere : I can't even not find lives for a game such as 'bonzeadv' as the result is always 0 when I "continue" search ! Isn't there a problem with the "backup" data ?
Because the search function works on my MAME 0.111u2.
Please more report.
Code: Select all
diff -Nru old/cheat.c src/cheat.c
--- old/cheat.c 2007-01-06 12:06:56.000000000 +0100
+++ src/cheat.c 2007-01-09 17:58:12.000000000 +0100
@@ -5668,8 +5668,9 @@
if(doSearch)
{
- /* ----- initialize search ----- */
- InitializeNewSearch(search);
+ if(!doneSaveMemory)
+ /* ----- initialize search ----- */
+ InitializeNewSearch(search);
if( (sel == kMenu_ValueEqual) || (sel == kMenu_ValueNearTo) || doneSaveMemory)
{
@@ -6117,8 +6118,9 @@
break;
case kMenu_DoSearch:
- /* ----- initialize search ----- */
- InitializeNewSearch(search);
+ if(!doneMemorySave)
+ /* ----- initialize search ----- */
+ InitializeNewSearch(search);
if((!kSearchOperandNeedsInit[search->lhs] && !kSearchOperandNeedsInit[search->rhs]) || doneMemorySave)
{
You don't get it : now the cheat engine ALWAYS loads the old format ... More investigation is needed before I submit anything ...Also I don't know why the cheat engine doesn't load old format.Stephh wrote:The "load old format" option doesn't seem to work correctly as the old cheats now seem to be always loaded ... It's a good news that old format is still supported, but the option should do something ...
Over and over again I say, I don't use and can't understand old format so that I don't know the cause.
The cheat.c file has to be rewritten to use the same "conventions" as the other files and move out of it what shoudn't really be there ... So I won't accept any new source file once MAME 0.111u3 is out ... This will give you time to work on the cheats and fix Pugsy's "mistakes" ......? Please more easy English.Stephh wrote:Once all this is fixed, I'll ask you to stop further development on this file (what else do you need anyway ?) as the cheat.c file needs special work and a huge rewrite, not to add new stuff, but to have a source file which is "compatible" with all the other ones in MAME ...
OK and sorry.Stephh wrote: found the bug that affects the "classic" and "advanced" search ("minimum" was working correctly) : you ALWAYS initialised the search, thus the 0 results ...
"convention" ?Stephh wrote:The cheat.c file has to be rewritten to use the same "conventions" as the other files