Alright, so this should work based on my understanding and other similar examples I have tried.
If I have a table that is simply this:
DataTable:
.db $0A, $0B, $0C, $0D
...and, want to call and store the appropriate value...
LDY $02
LDA DataTable,y
STA someAddress
...shouldn't the value $0C now be stored in someAddress?
And if I want to store a value to a higher address...
LDY $00
LDA DataTable,y
STA someAddress+2
...shouldn't the value $0A now be stored in the address that is two more from someAddress?
If I'm missing something, please let me know. Thanks!
If I have a table that is simply this:
Code:
DataTable:
.db $0A, $0B, $0C, $0D
...and, want to call and store the appropriate value...
Code:
LDY $02
LDA DataTable,y
STA someAddress
...shouldn't the value $0C now be stored in someAddress?
And if I want to store a value to a higher address...
Code:
LDY $00
LDA DataTable,y
STA someAddress+2
...shouldn't the value $0A now be stored in the address that is two more from someAddress?
If I'm missing something, please let me know. Thanks!