[Coco] MAME/MESS - HOW TO ENABLE THE "CHEAT"/"CHEAT FINDER" MENU OPTIONS & HOW TO MAKE A CHEAT FILE!

Steven Wallis stevenw890 at gmail.com
Sun May 31 17:05:09 EDT 2020


(YOU NEED TO DO THE FIRST SECTION BELOW TO USE MY 3 MAME/MESS CHEAT FILES
FROM THE LAST EMAIL!)
(THE OTHER INFO IS EVERYTHING I KNOW ABOUT MAKING/USING MAME/MESS CHEATS;
EXCEPT FOR USING DEBUG.)



HOW TO ENABLE THE "CHEAT"/"CHEAT FINDER" MENU OPTIONS:
------------------------------------------------------
To find cheats use the newest version of MAME/MESS.

1. For MAMEUI64:  Click "Options", "Default System Options", click the
     "Misc" tab, click "Enable cheats" (it may be on the "Debug" tab),
     click "Ok".  Exit MAMEUI64.
   For MAME Command-Line:  Edit "MAME\ini\mame.ini".  Change "cheat 0"
     to "cheat 1".

2. To get to the standard MAME UI, from a Command Prompt type:
   (For MAME Command-Line substitute "mame" for "mameui64".)
   "mameui64 ___empty"       (Note the 3 underscores.)

3. Double-click the "Plugins" option (above "Exit").  Double-click the
   "Cheat plugin" and the "Cheat finder helper library" so they are
   both ON.  Double-click "Return to previous menu".  Exit MAME.


When you want to use the Cheat Finder, start MAME with one of these:
  (For MAME Command-Line substitute "mame" for "mameui64".)
  "mameui64"   (Goes to the UI like normal), or
  "mameui64 ___empty"   (Goes into the standard MAME UI), or
  "mameui64 -debug -cheat romname"   (Goes directly into game/computer
        system with the debugger on; turning debugger on is optional).

When you press [ScrlLock], [Tab], you should see the first "Cheat"
menu.  If you go into "Plugin Options" you should see the second
"Cheat" menu & the "Cheat Finder" menu!


NOTE: For either "Cheat" menu to have anything in it when running
computer systems (not games), you have to use one of my cheat files,
or make one or more cheats (well there are a few out there, but not many).
  The user cheats get saved to "\MAME\cheat\systemname_cheatname.json".
To use them, rename them to "systemname.json"; i.e. if it is
"ti99_4a_Infinite Lives.json" rename it to "ti99_4a.json".
Then when you run the computer system again it will be in the "Plugin
Options", "Cheat" menu (the second "Cheat" menu not the first!).
  You can also convert them to .xml format.  To do this, see the
"To Make A Cheat File From The Above Result" section below.  Then they
will be in the first and second "Cheat" menus.




TO MAKE A "TARG" INFINITE LIVES CHEAT (USING BUILT-IN CHEAT FINDER):
--------------------------------------------------------------------
To find cheats use the newest version of MAME/MESS.


Start the game and press [P] to pause it.


Press [Tab], go to "Plugin Options", then "Cheat Finder".
Set "Pause Mode" to "Manual" (Automatic doesn't seem to work right for
  computer systems; maybe for games it does).
Point to "Start new search" and press [Enter].

Unpause the game and lose a life, then pause the game again.


Select "Save current #2".

Select "Left operand = Current"  (Currently using the 2nd one)
Select "Operator lt"
Select "Right operand 1"
Select "Value 1"   (To search for an unknown amount change use "Any".)
Point to "Compare" and press [Enter].
- Basically you are saying search for memory addresses where the
  current memory snapshot (2) is less than the first memory snapshot
  (1) by 1 (Value 1).

NOTE: The "Left operand = Current" and "Right operand = ?" will
automatically increment when you do the "Save current #?" memory state;
so only change them if you need to.

Unpause the game and lose a life, then pause the game again.


Select "Save current #3".

Select "Left operand = Current"  (Currently 3)
Select "Right operand = 2"  (Should now be 2)
Point to "Compare" and press [Enter].


[This process can be repeated to get the # of search results down...]


On the bottom of the screen you will notice "Match block = All", if you
press [Left] and [Right] on that it will cycle through some
possibilities under each "Block".

By default it will have "Test" next to each one, just press [Enter] on
each one you think it may be and it will add that cheat to the "Cheat"
menu.
(If it gives you an error it may be because that cheat address is
already in the cheat list.)

Test  = Adds the line to the "Cheat" menu to test (it won't save it).
Write = Allows you to save it and name it, saves it to cheat.simple
        (the user's cheats file).
Watch = Displays the contents during play.

You can then just enable that cheat in the "Cheat" menu to see if you
have found the Lives location by enabling the cheats one by one and
losing a life and seeing if the number of lives decreases.
(The correct address for the Targ lives is 00C1.)


NOTE1: "Operand" is a mathematical object upon which an operator acts.
For example, in the expression 1×2, the multiplication operator acts
upon the operands 1 and 2.

NOTE2: "Operator" can be one of the following:
"lt"  = "Left less than right, Value is difference". (Default)
"gt"  = "Left greater than right, Value is difference".
"eq"  = "Left equal to right".
"ne"  = "Left not equal to right, Value is difference".
"beq" = "Left equal to right with bitmask".
"bne" = "Left not equal to right with bitmask".
"ltv" = "Left less than Value".
"gtv" = "Left greater than Value".
"eqv" = "Left equal to Value".
"nev" = "Left not equal to Value".

NOTE3: "Data Format" can be "u8" (default), "s8", "little u16",
"big u16", "little s16", "big s16", "little u32", "big u32",
"little s32", "big s32", "little u64", "big u64", "little s64",
"big s64".

NOTE4: "BCD" is Binary Coded Decimal (default="Off").
  Simply, 0x09 incremented by one is equal to 0x10 instead of 0x0F.
Just using the decimal numbers from hex to make it easier to read.
Multipart cheats take the name of the first part of the cheat.  Hence
you can append (2/2) etc. to subsequent parts without worry of it
showing up in the menu.
  A simple example from a cheating perspective:
If you have a Timer that starts at "99" this can be represented by
non-BCD 0x63 (99 decimal, 63 hex) or it can be represented in BCD as
0x99 (99 hex, 153 decimal).  BCD is actually really common for things
like Time and Scores.
Don't worry about it for searching as long as you don't use a -1 search
when it goes from 90 seconds to 89 seconds (or similar cases 70 to 69
etc).


To Make A Cheat File From The Above Result:
===========================================
1. Paste the following text into "\MAME\cheat\romname.xml".
2. Change the description to whatever you want.
3. Change "000701A1" to whatever your cheat result was.
   If you only have the "\MAME\cheat\romname.json" file, change the
   number to hex format.
   NOTE: To convert from "CoCo 3" to "CoCo 1-2" memory format, try
   changing the first four numbers "0007" to "0000" (if the first four
   are not "0007" this won't work).
4. Change "03" to the amount you want the memory location to be set to.
For more info see "MAME - Documentation.pdf".


<mamecheat version="1">


    <cheat desc="Donkey King-Infinite Lives">

    <script state="run">
      <action>maincpu.pb at 000701A1=03</action>
    </script>

    </cheat>


</mamecheat>


More information about the Coco mailing list