Announcement

Collapse
No announcement yet.

Create a simple menu in any NES game.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Create a simple menu in any NES game.

    Hello people!!!.
    The other day I was thinking in a way to select some values in game without the need of "just press the X button to increment / decrement it by one" method. So I tought "Why not making a menu?". The problem here is that I have no idea where to start, but I have some ideas about it:
    Lets say I want to select any BGM in the game. And there's 50 songs. So If I use the "press a button" method (now I can do it in any game) it would be very annoying. So If I can select the music from a menu then It would be much nicer.
    The game I'm currently working now is Captain Tsubasa 2. I've not found all of the BGM values, surelly they're not 50, It was just an example.
    I have lots of free space to use to write te new routine in to it.
    So I just need to redirect the game to it. The select button isn't used for anything in the game, so I can press the select button to display the menu, then select what I want.
    I've polished my 6502 ASM skills, I can write some easy routines, like poking values in ram or compare values to get a desired effect. Also I'm using the 50 opcode (BVC) a lot when I need a branch to be allways executed. It works nicely. Ugetab kindly gave me a routine for poking stats some time ago, I've used it lots of times with some modifications. It helped me greatly to reduce the number of bytes needed for the routine. (Thanks again Ugetab). Pugsy had teached me some amazing tricks too. Thanks to both of them ( and lots of another users like VisitntX, I have learned and improved a lot ).
    -sorry for the off topic-
    The problems is that this one is too difficult for me. I don't know how to do it. I don't want to do nothing earth shaking, just a menu that displays hex numbers that can be explored with the D-Pad and select the desired value with any button.
    Thanks in advance. I'll appreciate any advice or help that you can give me. And example routine will be a lot helpfull, because I don't know how to make it. Also, the question is chasing me: its possible to do this?. Or it need massive rom hacking and reprogramming?.
    Thanks a lot.
    Whipon.

  • #2
    This gets into supplying font data, putting it to VRAM, altering the display, calling the correct init and play routines, putting in or using a keypad 'constant' and 'non-constant' button press readout, and to be honest, I've seen just such a setup for the Gameboy. It's about 470 bytes of data to hold everything needed, and can be shortened marginally if fonts aren't added.

    If you want to do it the easy way, skip the display and code in the Up and Down arrows to go to previous and next tracks. I don't know where you intend to use this coding, but I suspect you intended to put it into the existing game data somewhere. The 'press a button' method can be used with qualifiers like left and right for 10 songs in 2 directions, up and down for 1 song in 2 directions. I don't need that though, because NSFs do the work of song selection, and FCEUXD will play them back just fine. A Power Pak can also be used to play them on the hardware, now that someone's put together a mapper and convertor for NSF files.
    This reality is mine. Go hallucinate your own.

    Comment


    • #3
      Thanks a lot Ugetab!!!

      I want to use it not only for selecting music, that was an example, but to select anything. For example in an RPG you have 99 items to choose along the game. Instead of edit the inventory by PAR codes, or using the "press a button" method to increment or decrement a certain RAM address by one, you press the select button, then a list of hexadecimal numbers shows up (from 0 to 63), then you scroll through it. It can be done from up to down, from left to right, or any way you find comfortable. In this case a good place can be when you open the inventory, you select an slot, then you press the select button, then you choose an item from the menu, then that item appears in your inventory.
      But, I don't know how to write a short routine nor a long one to do this. I know you're very skilled in 6502 assembly, Ugetab. I'll be very glad and gratefull If you can give me an example routine, or just a link to it, because I really need an example to start the job. Actually I can't do it. Thats because I asked for help . Reading your info It seems its simple to do, I just need the routine n_n.
      Can you please, help me with it?. Or maybe point me to a NES game to copy the routine from it. I don't want any fancy font. I Just need to see the hex numbers and be able to scroll through them and to select them. Not descriptions nor names for the items (that would help a lot, but don't know if displaying item names instead of numbers will complicate the job a lot).
      Well, thanks a lot for your advices, Ugetab. I hope you can help me with this one too. It can help a lot of people too. You know, with this one, I can do lots of cool things with any NES game .
      Thanks again.
      whipon.

      Comment


      • #4
        n.n

        Well, another alternative would be create not a menĂº, but a box with just one or 2 items in it. Then you can press up or down to scroll up or down two more items. That way you'll use less screen space. Also you can use the game fonts and the routine used in the menu to indentify the items. But I lack the knowledge to put these ideas in practice. I need someone more skilled than me to lend me a hand. Just an example to imitate and perfectionate.
        Thanks in advance guys, and sorry Ugetab for ask so many things from you, its just you're the most skilled person I know when one talks about 6502.
        Whipon ^^
        Last edited by Whipon; 11-10-2008, 03:23:31 PM.

        Comment

        Working...
        X