SCNKEY
isn't suitable for games that require multiple simultaneous key input. It's stateless and simply returns 'the' key that is pressed now — i.e. if two are pressed, it'll tell you only one, and officially makes no guarantee as to which. The best you could do is consider a key still pressed until SCNKEY
reports either that something else is pressed or that nothing is, but it'd be even odds as to whether a second simultaneous keypress is ignored or replaces the first.
If your program doesn't fit the orthodoxy of there only ever being 'the' key that is pressed, you'll have to hit the hardware yourself. Codebase64 offers some example code; my summary version is (having set up the CIA correctly, though it'll likely be appropriately configured already):
- write a byte to DC00 which contains a 0 for each row that you want simultaneously to scan;
- read a byte from DC01 and check the top four bits to find out which keys of those on the selected rows were pressed.
A generic routine would need to test each row individually to avoid shadowing — suppose you asked to read rows 4 and 5 at the same time by storing 0s to DC00 in bits 3 and 4, and the result you got back had the top bit clear, you wouldn't know whether v or n or both were pressed, only that at least one of them is.
See the very bottom of the same link as above for a table of the rows and columns on an English-language keyboard; they're the result of the physical key layout so other languages will vary as much as their keyboards do. If you're writing a game and you're more interested in the layout of the keys than their symbols then you needn't worry about the language.