Jump to content
VisualBoyAdvance-M
mudlord

n64input source code

Recommended Posts

Thanks.

 

Since I am not sure whether to inline-comment onto your source code directly I figured maybe it would be better to keep posts to the forum here.

 

I thought you might want to know that, according to Nintendo, page 0 is reserved by the Controller Pak file system for basically just the device's serial identification number. As they put, each Controller Pak is assigned a unique serial ID, so when the operating system's SI interface accesses the controller RAM and sees that the serial number was changed since the last time the device was accessed, most Nintendo 64 games should consider this as an error, since mempak-switching is not supported by most games.

 

So your aValidCodes[] and aCode[] arrays are mostly based on particular Nintendo serial IDs assigned to someone's Controller Pak (particularly zilmar's, I think, since N-Rage copied those byte values off of Project64's mempak handle it would seem, while other emulators write their own mempak handle).

 

So as a small efficiency plus to handling mempak reformats, what you might do is either reverse your own Controller Pak device that you own to find what its serial number is (i.e., which bytes are stored in page 0) or, what I would do personally, is just set all the serial number bytes to NULL/0x00, since emulating the Controller Pak is just creating a virtual Controller Pak file that was not manufactured by Nintendo.

Share this post


Link to post
Share on other sites

Nice idea.

I hope to fix rumble support and stuff for Majora's Mask, then fix the issue you described, then this plugin is complete. :)

Share this post


Link to post
Share on other sites

Yeah looks pretty clean elsewhere, either that or just XInput API stuff I know nothing about lol.

 

I've been spending a lot of time on a Controller Pak memory handler application to support a bunch of stuff, so some technical questions about the page addressing purposes do arise. Things that are never really explained anywhere because Nintendo only documents what game programmers should know.

 

Anyway, what sorts of things in Majora's Mask were you hoping to fix? I had no idea that it had controller issues.

Share this post


Link to post
Share on other sites

i used to think the controller would vibrate as the mask passes offscreen

 

Well, it's the only relative theory I could think of.

 

For as long as I've loved that game I have never known it to use the rumble pak, but I really don't see why mudlord's plugin could be the source of freezing at a part of the game where button strokes are not necessarily sent (the spinning mask animation).

 

This is certainly not being specific, but who knows; maybe there is some fault in the plugin. I know my little 4-KB keyboard-only plugin had no stability issues with this game xD.

Share this post


Link to post
Share on other sites

iconoclast: still got the source?

good because i removed it from github because of no response.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×