For the “Noting down FreeRAM” part, it did note that some empty RAM may be multiple bytes long, but it forgot to mention that in patches, a define of freeram may span multiple bytes. For example, on my
Directional quake there is a define
!Freeram_DirQuake_Layer1XDisplacement that takes 2 bytes, that is- it will take whatever RAM it is AND the byte right after. Using the default example, it was at RAM
$60 which means
$60 and
$61 will be used. For more than 2 bytes, the ending byte address location is
StartingAddr + (NumberOfBytesNeeded - 1). If you are noting multi-byte freeram, it's best to label out each address being used by the define, using the previously mentioned example, you would write down
$60, $61 or
$7E0060, $7E0061 so that you can CTRL+F to know if that address is used.
I made
a tool that deals with finding RAM that is currently unused. It automates the task of checking for what RAM is used by SMW and ASM resource (along with checking for currently free and resources that conflicted with). And you only have to enter what starting address, and the number of bytes or ending address, which means noting the RAM usage is much simpler. Even more so with the other tool in the pack,
Ram_AutoAssigner.html, after giving a list of empty RAMs and the list of needed bytes, will output a list of defines with their given RAM address that you can copy and paste to the ASM files.
Also, it's possible that patches that uses freeram are only used in specific situations or specific game modes, and is not needed to keep its value across multiple game modes, and are often reusable without issues. For example, if $60 is used for my screen scrolling pipes (level only), that is certainly not used during the overworld, thus an ASM resource relating to the overworld border can safely use $60.
It also forgot to mention that not only patches uses freeram, any ASM resource types can use freeram. And they too can end up using the same RAM as another type of ASM resource (such as a patch using $60 and a block also using $60) and cause glitches, if it wasn't used for the
same purpose.
Also typo:
Originally posted by LeodAlso note how a lot of addresses are multiply bytes in length
You mean multiple.
Give thanks to RPG hacker for working on Asar.