Explanation
Comments in assembly 6502 are used to state what a variable does or anything that you normaly use a comment for in other programming languages.
How to use comments
It is very easy to use comments in assembly here is an example:
; This is an assembly 6502 comment
Why do assembly 6502 comments exist
Assembly 6502 comments exist because if you breakdown and explain your code with them your future-self will remember what the code was for and thank your past-self.
Does assembly 6502 support multi-line comments
Assembly 6502 only supports line comments not multi-line comments because it was running on software typicaly under 64 KB
Can you pause a single line of code with assembly 6502 comments
You can "pause" a single line of code with nes comments by using the ; at the start, ; in assembly means "Start this comment only for this line"
If you do this your code line turns into a comment so it wont run
However remove the ; and your code runs again
Do assembly 6502 comments be treated the same in modern coding languages
Because 6502 assembly is limited to line comments in modern coding languages they usualy ignore comments just like assembly 6502.
Assembly 6502 comments are treated the same in modern coding languages however the NES can only handle so many comments before a Memory Overload
Notes
NOTE: The NES is different than the SNES in assembly.
Top comments (0)