Anyway, the new stuff is great (even if I haven't found time to check how it was coded)It was too late for u5, and I don't like to include big scary changes in a non-u release. It will be in u1.
Steph from The Ultimate Patchers
Anyway, the new stuff is great (even if I haven't found time to check how it was coded)It was too late for u5, and I don't like to include big scary changes in a non-u release. It will be in u1.
It's simple bug.stephh wrote:What was the bug ?
Code: Select all
if(ShiftKeyPressed()) // Pressed Shift Key
{
if(input_ui_pressed(IPT_UI_ADD_CHEAT)) // shift + add = insert new watchpoint
{
AddWatchBefore(sel);
}
if(input_ui_pressed(IPT_UI_DELETE_CHEAT)) // shift + delete = delete selected watchpoint
{
DeleteWatchAt(sel);
}
}
else // Not. So the following functions are available if NOT PRESSED SHIFT KEY
if(input_ui_pressed(IPT_UI_SAVE_CHEAT))
{
if(watch) // save = save selected watchpoint as watchpoint code to the database
{
CheatEntry entry;
memset(&entry, 0, sizeof(CheatEntry));
SetupCheatFromWatchAsWatch(&entry, watch);
SaveCheat(&entry);
DisposeCheat(&entry);
}
}
if(input_ui_pressed(IPT_UI_ADD_CHEAT))
{
if(watch)
{
if(ShiftKeyPressed()) // shift (???) + add = add selcted code as watchpoint code to cheat list
{
CheatEntry * entry = GetNewCheat();
DisposeCheat(entry);
SetupCheatFromWatchAsWatch(entry, watch);
}
else // add = add selected code as cheat code to cheat list
{
AddCheatFromWatch(watch);
}
}
}
Sorry, I have not explained about it.stephh wrote:I don't know what you changed (it seems to be related to the new '_command' options), but cheats in old format (like in MY cheat databases) can't be loaded anymore
Code: Select all
else
{
#ifdef MESS
if(!MatchesCRCTable(crc))
continue;
#endif
continue; <--- DELETE THIS LINE !
// convert the old code to the new format
type = ConvertOldCode(oldCode, oldCPU, &data, &extendData);
}
}
Code: Select all
MSB LSB
33222222 22221111 11111100 00000000
10987654 32109876 54321098 76543210
-------- -------- -------- ---x---- load old format code
Code: Select all
if(ControlKeyPressed())
{
if((entry->flags & kCheatFlag_HasActivationKey1) || (entry->flags & kCheatFlag_HasActivationKey2))
{
SaveCheat(entry, sel, 1); // save activation key
ui_popup_time(1, "activation key saved");
}
else
ui_popup_time(1, "no activation key");
}
Code: Select all
if(input_ui_pressed(IPT_UI_SAVE_CHEAT))
Code: Select all
if(ControlKeyPressed())
{
if(input_ui_pressed(IPT_UI_SAVE_CHEAT)) // ctrl + save = save activation key
{
if((entry->flags & kCheatFlag_HasActivationKey1) || (entry->flags & kCheatFlag_HasActivationKey2))
{
SaveCheat(entry, sel, 1);
ui_popup_time(1, "activation key saved");
}
else
ui_popup_time(1, "no activation key");
}
}
I suppose the spacing wouldn't be needed as long as you can tell which one you're one when it's highlighted. Below is as best of an example I can give. Normally the bytes on the left side of the screen are NOT highlighted. This is what I meant....ShimaPong wrote:Sorry, I can't imagine your idea.
Do you want to see selected item fairly with hilight or space in the watchpoint list menu ? (...why ?)
Anyway I can't understand unless you give a concrete example...
Please wait a few days. I need to check source file and document.Stephh wrote:Shimapong, could you please give me a link (and password) to your updated cheat.c file (as well as cheatnew.txt) ?
Code: Select all
xxx----- -------- -------- -------- type
000 = standard memory write
001 = memory region
010 = write handler mapped memory
011 = custom
100 = relative address (CPU)
101 = direct program space write
110 = cheatscript (unmounted now)
111 = unused
Code: Select all
:pengo:A0800000:4C2B:00000000:FFFFFFFF:Invincibility
Code: Select all
:sonicbom:A0800000:00361A:00000060:FFFFFFFF:Invincibility - Player
:sonicbom:A0810000:00377A:00000060:FFFFFFFF:Invincibility - Player (2/5):1st = Enemy, 2nd = Fire
:sonicbom:A0810000:004786:00000060:FFFFFFFF:Invincibility - Player (3/5):Large Enemy (Stage 5)
:sonicbom:A0810000:009E5A:00000060:FFFFFFFF:Invincibility - Player (4/5):Electronic Line (Stage 4)
:sonicbom:A0810000:0122BE:00000060:FFFFFFFF:Invincibility - Player (5/5):Explosion (Stage 2)
:sonicbom:A0800000:0037DA:00000060:FFFFFFFF:Invincibility - Side Fighter
Code: Select all
:s_fzone:A0D00000:248E:000037C9:FFFFFFFF:Invincibility
:s_fzone:A0810000:24BC:00000037:FFFFFFFF:Invincibility (2/2):1st = Object, 2nd = Base
Code: Select all
:aurailj:A0800000:0041C2:00000060:FFFFFFFF:Invincibility
:aurailj:A0810000:004636:00000060:FFFFFFFF:Invincibility (2/8):1st = Mine (3D Stage) 2nd = Enemy (3D Stage)
:aurailj:A0810000:004AD4:00000060:FFFFFFFF:Invincibility (3/8):Missile (3D Stage)
:aurailj:A0810000:004B18:00000060:FFFFFFFF:Invincibility (4/8):Fire (3D Stage)
:aurailj:A0810000:00E5FC:00000060:FFFFFFFF:Invincibility (5/8):Enemy (2D Stage)
:aurailj:A0810000:00E693:00000010:FFFFFFFF:Invincibility (6/8):Fire (2D Stage) [bsr $e6a6 -> $e6a4 (rts)]
:aurailj:A0810000:014822:00000060:FFFFFFFF:Invincibility (7/8):Round 9 Boss
:aurailj:A0810000:02A693:00000064:FFFFFFFF:Invincibility (8/8):Round 16 Boss [$ea66 -> $ea64 (rts)]
Code: Select all
:shangon3:A0800000:007150:00000060:FFFFFFFF:Invincibility
:shangon3:A0810000:0076F8:00000060:FFFFFFFF:Invincibility (2/2):1st = Obstacle, 2nd = Bike
:shangon3:A0800000:008162:00000060:FFFFFFFF:No Slowing Down on Off Road
:shangon3:A0800000:006489:00000000:FFFFFFFF:Always Ready Turbo
Code: Select all
:manhatan:A0800000:9A70:00000020:FFFFFFFF:Invincibility - Player
:manhatan:A0810000:9AE2:00000039:FFFFFFFF:Invincibility - Player (2/3):1st = Fire, 2nd = Enemy
:manhatan:A0810000:9B3F:00000020:FFFFFFFF:Invincibility - Player (3/3):Car
:manhatan:A0800000:98E1:00000039:FFFFFFFF:Invincibility - Hostage
Code: Select all
;s_fzon2j:60000000:00000:00000000:00000000:----- Invinciblity : 1st = Scenery (Boss), 2nd-13th = Objects [banked ROM] -----
:s_fzon2j:A0800000:013AE:0000007D:FFFFFFFF:Invincibility
:s_fzon2j:39A10000:2FADB:00BF90C3:FFFFFFFF:Invincibility (02/13):BADB - jp $BF90
:s_fzon2j:39B10000:2FF90:00C0A03A:FFFFFFFF:Invincibility (03/13):BF90 - ld a,($C0A0)
:s_fzon2j:39B10000:2FF93:173007FE:FFFFFFFF:Invincibility (04/13):BF93 - cp $07 / BF95 - jr nc,$BFAE
:s_fzon2j:39A10000:2FF97:00007EFD:FFFFFFFF:Invincibility (05/13):BF97 - ld a,(iy+$00)
:s_fzon2j:39B10000:2FF9A:112805FE:FFFFFFFF:Invincibility (06/13):BF9A - cp $05 / BF9C - jr z,$BFAF
:s_fzon2j:39B10000:2FF9E:0D280DFE:FFFFFFFF:Invincibility (07/13):BF9E - cp $0D / BFA0 - jr z,$BFAF
:s_fzon2j:39B10000:2FFA2:093808FE:FFFFFFFF:Invincibility (08/13):BFA2 - cp $08 / BFA4 - jr c,$BFAF
:s_fzon2j:39B10000:2FFA6:043811FE:FFFFFFFF:Invincibility (09/13):BFA6 - cp $11 / BFA8 - jr c,$BFAE
:s_fzon2j:39910000:2FFAA:000015FE:FFFFFFFF:Invincibility (10/13):BFAA - cp $15
:s_fzon2j:39A10000:2FFAC:00C90138:FFFFFFFF:Invincibility (11/13):BFAC - jr c,$BFA4 / BFAE - ret [No Hit - Enemy/Fire]
:s_fzon2j:39B10000:2FFAF:FE02CBDD:FFFFFFFF:Invincibility (12/13):BFAF - set 7,(ix+$02) [Hit - Item/Warp/Shop]
:s_fzon2j:39A10000:2FFB3:00BADFC3:FFFFFFFF:Invincibility (13/13):BFB3 - jp $BADF
;s_fzon2j:60000000:00000:00000000:00000000:----- Starting Round Selection : 2nd-7th = in banked ROM -----
:s_fzon2j:39800300:1FE62:00000006:FFFFFFFF:Select Starting Round [Incomplete]:Can't select final round
:s_fzon2j:A0A10000:01CFC:00BE60CD:FFFFFFFF:Select Starting Round [Incomplete] (2/7):1CFC - call $BE60
:s_fzon2j:39910000:1FE60:00003EF5:FFFFFFFF:Select Starting Round [Incomplete] (3/7):BE60 - push af / BE61 - ld a,$xx [xx = starting round]
:s_fzon2j:39A10000:1FE63:00C0A032:FFFFFFFF:Select Starting Round [Incomplete] (4/7):BE63 - ld ($C0A0),a [main]
:s_fzon2j:39A10000:1FE66:00C0A232:FFFFFFFF:Select Starting Round [Incomplete] (5/7):BE66 - ld ($C0A2),a [display]
:s_fzon2j:39B10000:1FE69:C0A332F1:FFFFFFFF:Select Starting Round [Incomplete] (6/7):BE69 - pop af / BE6A - ld ($C0A3),a
:s_fzon2j:39810000:1FE6D:000000C9:FFFFFFFF:Select Starting Round [Incomplete] (7/7):BE6D - ret
Code: Select all
:shinobi1:A0800000:003F8A:00000060:FFFFFFFF:Invincibility
Code: Select all
;s_astrow:60000000:0000:00000000:00000000:----- Invincibility : 1st-4th = Objects, 5th-8th = Boss -----
:s_astrow:A0900000:1A7D:00001CE0:FFFFFFFF:Invincibility
:s_astrow:A0A10000:1CE0:00007EFD:FFFFFFFF:Invincibility (2/8):1A70 - call $1CE0 / 1CE0 - ld a,(iy+$00)
:s_astrow:A0B10000:1CE3:033013FE:FFFFFFFF:Invincibility (3/8):1CE3 - cp $13 / 1CE5 - jr nc,$1CEA
:s_astrow:A0B10000:1CE7:C91A88CD:FFFFFFFF:Invincibility (4/8):1CE7 - call $1A88 / 1CEA - ret
:s_astrow:A0A10000:2535:001CEBCD:FFFFFFFF:Invincibility (5/8):2535 - call $1CEB
:s_astrow:A0A10000:1CEB:00007EDD:FFFFFFFF:Invincibility (6/8):1CEB - ld a,(ix+$00)
:s_astrow:A0B10000:1CEE:012001FE:FFFFFFFF:Invincibility (7/8):1CEE - cp $01 / 1CF0 - jr nz,$1CF3
:s_astrow:A0910000:1CF2:0000C9AF:FFFFFFFF:Invincibility (8/8):1CF2 - xor a / 1CF3 - ret