Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert native cheat codes to the RetroArch format #1360

Open
eadmaster opened this issue May 8, 2023 · 11 comments
Open

Convert native cheat codes to the RetroArch format #1360

eadmaster opened this issue May 8, 2023 · 11 comments

Comments

@eadmaster
Copy link
Contributor

eadmaster commented May 8, 2023

There a lot of cores currently that only support cheats in the RetroArch format, while this repo only provides codes in Native format (e.g. GameShark):

This creates confusion among users, who assume cheat support is missing in these cores, while it is not the case actually: libretro/beetle-pce-fast-libretro#93 libretro/beetle-saturn-libretro#5

So i've made this quick and dirty script to convert the cheat tables format:
https://github.com/eadmaster/dotfiles/blob/main/bin/chtnative2retroarch.py

It's still missing support for encrypted/conditional/increment/activator codes, but i've found it's already working well in most cases.

Possibly it can be merged into the scraper script, to have the cheat tables converted automatically after download.

@chelnov5
Copy link

chelnov5 commented Sep 9, 2024

Sir it's just a simple python script file. Most of us don't know how to use it. It would have been better if you had made a guide or tutorial instead of leaving it to us how to figure it out.

@eadmaster
Copy link
Contributor Author

eadmaster commented Sep 9, 2024

https://www.almabetter.com/bytes/articles/how-to-run-python-script

example usage:

python chtnative2retroarch.py "18 Wheeler (Japanese).cht" "18 Wheeler (Japanese) (converted).cht" dc

@RobLoach
Copy link
Member

RobLoach commented Sep 9, 2024

Nice work, @eadmaster. Do you think it would be worth having the duplicate scripts hosted in this repository? Suffixed by "(RetroArch)" or something?

@chelnov5
Copy link

chelnov5 commented Sep 9, 2024

Sorry butI'm getting this error, and do original file have to be in .cht format as gamehacking has no download option for download sadly. I've attached snaps for both error and original cheat file

cheats

Code

@eadmaster
Copy link
Contributor Author

@chelnov5 : Download the script in raw mode, you saved the html page.

@RobLoach : it would make sense for the supported systems: sat, n64, dc, ps1, pce(cd)

@chelnov5
Copy link

chelnov5 commented Sep 10, 2024

@chelnov5 : Download the script in raw mode, you saved the html page.

@RobLoach : it would make sense for the supported systems: sat, n64, dc, ps1, pce(cd)

Thanks now it worked. Now I'll check the codes in game.

@FunkyTable
Copy link

I'm trying to get the symphony of the night saturn cheat codes to work, but I'm not having any luck. I changed this file extension from "cht" to "txt" so I could upload it here. When I run the python script, it says all of the formats of the cheat codes are unsupported.

It would be awesome if you could look into this, as this is a very popular game.

Akumajou Dracula X - Gekka no Yasoukyoku (Japan) (2M).txt

@FunkyTable
Copy link

It doesn't work on the Beetle Saturn emulator even though this is the cht file in Retroarch.

@FunkyTable
Copy link

GitHub
https://github.com › libretro › blob
Saturn/Castlevania - Symphony of the Night (GameShark).cht at master

@eadmaster
Copy link
Contributor Author

eadmaster commented Nov 17, 2024

replace all "+" plus signs with spaces in this file , then:

$ chtnative2retroarch.py Castlevania\ -\ Symphony\ of\ the\ Night\ \(GameShark\).cht Castlevania\ -\ Symphony\ of\ the\ Night\ \(GameShark\)2.cht ss

output:
Castlevania - Symphony of the Night (GameShark)2.cht.zip

If you download a cht table from here there is no need to replace the plus signs.

@BooBerry
Copy link

Would it be possible to get it to convert cheats for the Sega CD too? Primarily trying to get ones that use Word RAM and PRG RAM working with RetroArch (Genesis Plus GX). As-is they currently don't work with the core, so trying to convert to RA native cheats.

This is a example: https://gamehacking.org/game/85288

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants