A small problem with a LDA opcode

Are you new to 6502, NES, or even programming in general? Post any of your questions here. Remember - the only dumb question is the question that remains unasked.

Moderator: Moderators

User avatar
Bregalad
Posts: 8056
Joined: Fri Nov 12, 2004 2:49 pm
Location: Divonne-les-bains, France

Re: A small problem with a LDA opcode

Post by Bregalad »

Why do you insist using a shitty broken nesasm when you could use another tool instead ?
User avatar
Sumez
Posts: 919
Joined: Thu Sep 15, 2016 6:29 am
Location: Denmark (PAL)

Re: A small problem with a LDA opcode

Post by Sumez »

Also, as a more basic solution - since "LDA $xxxx,Y" doesn't support ZP addressing mode either, why not just use a different area of RAM for this purpose? As far as I can tell, that would circumvent the supposed bug, and still work as intended with the same amount of CPU cycles?

I agree though - I don't see any reason to even use NESASM in the first place, but I have little experience with anything other than CA65 which I have come to become a great fan of, so maybe I'm missing out of NESASM features I don't even know anything about?
User avatar
rainwarrior
Posts: 8734
Joined: Sun Jan 22, 2012 12:03 pm
Location: Canada
Contact:

Re: A small problem with a LDA opcode

Post by rainwarrior »

The feature you're missing is that OP is learning by modifying an existing project that was already written in NESASM. :P
kuja killer
Posts: 130
Joined: Mon May 25, 2009 2:20 pm

Re: A small problem with a LDA opcode

Post by kuja killer »

https://pastebin.com/nsp241uQ

This is one of puresabe's files from Rockman 4 Minus Inifnity that i use. (i dont know how any of this stuff would be translated to other assemblers, so i dont touch it, thats why i only use nesasm personally, to be honest)

I most frequently use all the branch-jump/jsr/rts ones, and i really love the "LONG_CALL" jsr, for example :)
User avatar
gauauu
Posts: 779
Joined: Sat Jan 09, 2016 9:21 pm
Location: Central Illinois, USA
Contact:

Re: A small problem with a LDA opcode

Post by gauauu »

Bregalad wrote:Why do you insist using a shitty broken nesasm when you could use another tool instead ?
This kind of tone is what drives newcomers away from this site.
User avatar
Zutano
Posts: 38
Joined: Tue Apr 04, 2017 1:22 pm
Location: Ohio, USA
Contact:

Re: A small problem with a LDA opcode

Post by Zutano »

kuja killer wrote:i dont have a clue how they would be made to work with ASM6 or whatever.
Shiru's famitone2 library comes with a program to convert nesasm code to asm6 and ca65, it's called "nesasmc".
It's specifically designed to convert the famitone2 library itself, but you might be able to modify it to your own use-case (famitone2 includes the source for nesasmc).
https://shiru.untergrund.net/code.shtml

...Or you could try rolling your own code converter in something like Python.
http://zutanogames.com/ <-- my dev blog
User avatar
Sumez
Posts: 919
Joined: Thu Sep 15, 2016 6:29 am
Location: Denmark (PAL)

Re: A small problem with a LDA opcode

Post by Sumez »

I actually had to make a few changes to the CA65 version of famitone2 to make it work properly - mostly related to symbols that were defined inside code that was ignored as a result of other symbols. I figured something like this was the culprit. :P
Post Reply