Help Understanding Atmosphere Cheat File Commands

  • Thread starter Thread starter Styper
  • Start date Start date
  • Views Views 826
  • Replies Replies 1

Styper

New Member
Newbie
Joined
Feb 12, 2025
Messages
1
Reaction score
0
Trophies
0
Age
42
XP
54
Country
Brazil
Hello!

I'm trying to wrap my head around creating cheats in Atmosphere, but I don't understand it fully how some commands are supposed to work.

This is a simple cheat in Pokémon Sword that will add a Master Ball to the first Poké Ball bag slot, and an Ultra ball to the second slot:
Code:
[Poké Balls x999]
04100000 45067B88 01F38001
04100000 45067B8C 01F38002

The item values and quantity are 01F38001 and 01F38002, and the memory regions for the bag slots are 45067B88 and 45067B8C (which is shifted 4 bytes from the first address).
I wanted to see if I could add the starting address to a register, and then just offset 4 bytes with each new item, but it doesn't seem to work:
Code:
[Poké Balls x999]
580F0000 45067B88
780F0000 00000000
640F0000 00000000 01F38001
780F0000 00000004
640F0000 00000000 01F38002

Can someone help me or maybe point me to a tutorial?
 
Did you read this?

https://github.com/Atmosphere-NX/Atmosphere/blob/master/docs/features/cheats.md

1. This is not how 0x5 command works, you are supposed to use 0x4 command
2. You are adding 0, useless
3. 0x6 opcode doesn't accept offsets, addresses must be direct. You must redesign cheat to utilize 0xA opcode

INI:
[Poké Balls x999]
400F0000 00000000 45067B88
400E0000 00000000 01F38001
A4EF1310
400E0000 00000000 01F38002
A4EF1310

And disclaimer: using offset relative to heap start is a bad approach since any exefs mod may disrupt alignment which will render both cheats useless, the same reason why this cheat may not work on emu (or if you are doing this for emu, may not work on other emu or real hardware)
 
Last edited by masagrator,

Site & Scene News

Popular threads in this forum