ergoproxysum Posted June 17, 2014 Share Posted June 17, 2014 I'm working on using the z64_tables hack by spinout(182). Has anyone here ever used it? I looked at the source long enough to figure out it's use in python (I couldn't use any patchers with it) and have successfully extracted/ripped the tables. However, when it comes time to reinsert the tables, they seem to insert properly, however, it hits an infinite loop on launch in PJ64. If I byteswap and fix crc it doesn't seem to help, just changes the error message in PJ64. Has anyone here ever used it successfully? My reason to use it is I want to max out the number of scenes, be able to insert (relatively) as much as I want. I'm new to Zelda64 modding, but not to programming. Perhaps I've missed something elementary. Thanks for any help you can offer. Link to comment Share on other sites More sharing options...
Jason777 Posted June 17, 2014 Share Posted June 17, 2014 What errors are you getting exactly? I've never used the actual hack but you must be referring the python script for inserting updated tables. The actual hack itself was written in C and compiled with Galatea's branch of GCC (which targets the MIPS architecture). Link to comment Share on other sites More sharing options...
Three_Pendants Posted June 17, 2014 Share Posted June 17, 2014 Hmm... have you tried Nemu64? It may have been designed for that possibly. Link to comment Share on other sites More sharing options...
ergoproxysum Posted June 17, 2014 Author Share Posted June 17, 2014 Thanks Jason777 for the reply. It says that the rom is stuck in an infinite loop, nothing more. You sound spot on (and more knowledgeable than me) about the python script. I'm using the ZELOOTMA.n64 and I've tried the .v64. Should I be doing something with the extracted table .bin files? is there a tool I can edit them with? Notepad certainly isn't much use. Three_Pendants, I'll definitely try out Nemu64. I won't be able to for a few hours but if that's what does it I'll report back. In general, I'm just using the rip command, then trying to do the write right after. I was just testing. If I do manage to get it to work, how can I specify more scenes? Would that be done with the .bin file before going ahead and rewriting with the write command? Link to comment Share on other sites More sharing options...
ergoproxysum Posted June 17, 2014 Author Share Posted June 17, 2014 Just ran it in Nemu64 "Error: Too many commands executed. Stopping dlist processing" Looks like it's running, just a black screen though. I've tried examining the python in the script, and while I generally see what it's doing I don't know enough to diagnose the issue. I'm sure others have been successful where I haven't. Link to comment Share on other sites More sharing options...
Jason777 Posted June 18, 2014 Share Posted June 18, 2014 I am sure you already tried this, but have you applied the BPS patch? Also, it may be a typo but you should be using ZELOOTMA.Z64 Link to comment Share on other sites More sharing options...
mzxrules Posted June 18, 2014 Share Posted June 18, 2014 To explain Jason's comment further, he's suggesting that the byte-order of the rom file is not correct. Rom's with the .z64 extension are typically (but possibly not always) in Big Endian order, which is the native byte-order of the game. You can easily tell if the rom isn't in Big Endian order by opening it up in a hex editor since there's a string of text that should read THE LEGEND OF ZELDA near the start of the rom. As for the mod itself, I haven't tried it out myself but from what I understand spinout didn't factor in the save format in the hack, so any scene past 101 may either not store permanent scene flags, or go past the allotted space for permanent scene flags and interfere with other "global" flags Link to comment Share on other sites More sharing options...
ergoproxysum Posted June 18, 2014 Author Share Posted June 18, 2014 @Jason777 @mzxrules Thanks so much for your help, I appreciate it. I've only been able to find the n64 and v64 varieties, are either one of those the same as the z64 format? That may very well be the root of the issue. I've searched online and found nothing but those two, not much luck on the z64. I know no one can discuss rom sources here, so I'll just have to keep looking. --- As for the BPS patch, I thought that that was an alternative to using the python script manually. Should I patch that before or after running the script/writing new tables? When I try the patch it fails, which again, may be the result of using a n64 or v64 rom over a z64 one. That Endian info is very informative. Link to comment Share on other sites More sharing options...
Jason777 Posted June 18, 2014 Share Posted June 18, 2014 From what I understand, the BPS patch is what actually patches game code to implement the hack. The Python script is just for inserting modified tables that are to be used with the hack. If you need help patching your ROM, I would recommend asking xDaniel. Also, check your private messages. Link to comment Share on other sites More sharing options...
haddockd Posted June 18, 2014 Share Posted June 18, 2014 Check your PM ergoproxysum Link to comment Share on other sites More sharing options...
ergoproxysum Posted June 18, 2014 Author Share Posted June 18, 2014 Wow, I must've checked 5 or 6 roms. It's too bad there's no good documentation on this one. It seems everything to be learned has been through help on here or by looking at the raw python. From what I can tell with the help of others the process is: Patch with the BPS File > Export tables using the "rip" command > Modify tables to your liking > Inject tables using the "write" command The BPS file keeps failing, which from some research, I've learned failing is caused by very little but the ROM not matching the checksum of what was used by spinout to make the patch. Perhaps he already had a hack or two in place, or maybe an obscure revision of the rom? I haven't been able to find a good way to bypass the checksum. I even resorted to scoping out spinout's Youtube channel to try and get a glimpse of his working directory, however, he seems to name them z.z64, most likely for quick command-line use. Either way, that filename wasn't much help. Does anyone know of a BPS Patcher that can bypass the checksum check? When I eventually get this sorted out I'll compare the fully edited rom vs. a stock one and make my own patch to make life easier for anyone who may find themselves in my position down the road. I'll be sure to make that patch available on here. Link to comment Share on other sites More sharing options...
Jason777 Posted June 18, 2014 Share Posted June 18, 2014 I recommend talking to xDaniel because he apparently got the patch working. He probably has the correct ROM to use. Link to comment Share on other sites More sharing options...
spinout Posted June 19, 2014 Share Posted June 19, 2014 Hi, The BPS patch is not needed. If you are having patching issues, you can use a big-endian ROM and the python script, by executing it as so: $ ls rom_update.py z64_tables_bin.bin $ python rom_update.py rip ZELOOTMA.z64 $ ls rom_update.py actor_table.bin scene_table.bin object_table.bin exit_table.bin auxillary_data.bin z64_tables_bin.bin $ python rom_update.py write ZELOOTMA.z64 (ls statement used to list files only - you only need z64_tables_bin.bin, the rest of the hack can be applied from the python script) Glad to hear someone is using this! I'll try and check back in again soon. Link to comment Share on other sites More sharing options...
ergoproxysum Posted June 19, 2014 Author Share Posted June 19, 2014 Hi Spinout! So happy to meet you after obsessing on your project for the past week. It seems to be a great hack, if it works I don't see why anyone wouldn't use it. I've done that exact process dozens of times, but I'll try it again using a fresh extract of your software and be sure it's a big-endian rom. Link to comment Share on other sites More sharing options...
ergoproxysum Posted June 19, 2014 Author Share Posted June 19, 2014 Ok, I tried that out again from scratch with a clean rom. I emptied the directory of everything but the ZELOOTMA.z64, rom_update.py and z64_tables_bin.bin I ran the rip function (no console message) and got the same output again as your example (except no auxillary_data.bin file was generated). When I ran the write, it seemed to run ok, here is an image showing the output: http://i.imgur.com/HesKxpL.png it gave the "permanent loop" error in modern project 64. In Nemu 64 (I noticed you used this in a few videos) I got "Error: Too many commands executed. Stopping dlist processing". So I started up GZRT to verify the checksum, found it was wrong and hit "Fix". I then made sure it was two green lights in GZRT before continuing. I then loaded it in PJ64 and it by all appearances is running, but just gives a black screen. Loading again in Nemu64 gives the same result as above. any bread crumbs in there where you can see I went wrong? I have noticed that you're using a unix-based OS and I'm not, however, I got the exact version of python you recommend so there shouldn't be any differences. Link to comment Share on other sites More sharing options...
Jason777 Posted June 19, 2014 Share Posted June 19, 2014 With PJ64 you would have to reinput all the ROM settings. Link to comment Share on other sites More sharing options...
ergoproxysum Posted June 21, 2014 Author Share Posted June 21, 2014 Foolish me! I didn't reinput the rom settings from online after doing the hack. Makes a lot of sense (it doesn't recognize the checksum in pJ64 I'm guessing). It boots fine now, all that's left is to add more entries to the scene table. Do I just define a higher number at map injection? Or is there something I need to do with the .bin file? Thanks for all of your help so far, feels like a light at the end of the tunnel here. Link to comment Share on other sites More sharing options...
spinout Posted July 2, 2014 Share Posted July 2, 2014 Just add data at the end of the extracted tables, and reinsert. You're going to have to fix your checksum/rom settings each time. Sorry for the inconvenience. Link to comment Share on other sites More sharing options...
Recommended Posts