Hacker News new | ask | show | jobs
by epcoa 967 days ago
I highly doubt there was a readily available C compiler for the 6502 in the 1980s. In any case the idea that developers were widely using C pre N64 is bull. Even in the SNES era it was the minority.
1 comments

I believe Hudson had a C compiler back then... if not, go check out a hexdump of some Koei games (Nobunaga's Ambition 2 comes to mind), you'll see text strings with the %s token... pretty sure those would only come from C.
So a handful of non graphically intense RPGs from a relatively obscure/cult publisher doesn't really contradict minority though. That particular game was released in early 1990, relatively late into the life of the NES and not exactly a first party title. By 80s, I meant more coincident with the release of the system.

> you'll see text strings with the %s token... pretty sure those would only come from C.

There is nothing inherent in % escaped substitutions that unequivocally implies C. You could pretty easily write an asm port of a basic printf function if one wanted to reuse previously translated strings. Not saying C wasn't used for the NES port of this title, but this by itself isn't as strong a clue as implied.

> You could pretty easily write an asm port of a basic printf function if one wanted to reuse previously translated strings.

In fact, the function for printf used to be implemented in assembly on Unix. In this link, the actual implementation is in doprnt.s, and the function printf (in printf.c) just passes its arguments to the function _doprnt. In V6 Unix, it was the same for scanf, but V7 seems to have replaced it with a C implementation.

http://tuhs.org/cgi-bin/utree.pl?file=V7/usr/src/libc/stdio