Scepheo, that's perfect, thank you!
As I write to the screen with gui.text, is there any way to make the locations relative so that if I change the resolution of the emulator they stay put?
Just a quick announcement:
I will be streaming at http://www.twitch.tv/weatherton today (Saturday) at 2pm EST to demonstrate some interesting findings and tools in the game, if you're interested. The topics I plan to discuss are:
00'00"00 Laps. How can you get them?
Mario Kart 64 Item probabilities
Course Ghost Behavior (after third lap)
Ghost analysis (driving style / efficiency)
Xenos slide. How does it work and is it TAS only?
Mario Kart 64 Automatic Transmission / Dashboard
PAL / NTSC Conversion Demo
I discovered a faster shortcut on Banshee Boardwalk:
Link to video
I'm not sure how to capture at a higher resolution in BizHawk than what the movie was created in so, unfortunately this is only 320x240 :(
Thanks to Peter Greenwood (micro500) here at TASVideos, I was able to sync the input from two different Weathertenko TAS movie files on my actual N64 console. This is the first time the skip has ever been achieved on console and it verifies that it is technically possible. Now someone just needs to actually do it unassisted :)
Link to video
Joined: 3/18/2006
Posts: 971
Location: Great Britain
Weatherton, do you still need help with item-related mechanics?
I was thinking of firing up a debugger and seeing if I could learn anything of interest.
antd, yes, Sully (who has posted some on the topic on other parts of these boards) has done some debugging of the game and some specifically related to items. However, I still have no way to predict the items I will get without trying every frame. Having an indicator of which item I would get would save me many many rerecords.
If you are willing and able to help, I can dig up some of the details we know so far.
P.S. A quick note, I'm just finishing up the second lap of Toad's Turnpike and making good progress on the run now :)
I've been trying to do the same thing, by the way. SeanSullivan86 (whom I assume to be the aforementioned Sully) has send me some helpful information. It pretty much comes down to predicting the outcome of the rng now, which he says is located at 802B7E34.
That number [0, 99], together with your position, is used to pull the item you'll get from a table located at 0x1A7A90, which has eight sets (for each position) of 100 items (rng).
Scepheo, yes Sean Sullivan is the Sully I was referring to. When you say "together with your position" are you referring to X, Y an Z coordinates? Last night I had a strange discovering while trying to manipulate an item while towing another item (meaning I could not hit Z to choose the item). I couldn't change which item I received (it kept being a green shell when I wanted a mushroom) no matter how I changed my control stick input. However, when I changed the frame that I initiated a slide on (i.e. when I jumped) the outcome changed as well. Based on that (granted, it's a single sample) the item seed seemed to depend somewhat on jumping. Not sure what to make of that.
I am familiar with the 100 byte lookup tables. I guess what I need is a Lua script that tells me which number I would receive if I hit Z on that frame. How close are you to being able to say that?
Joined: 3/18/2006
Posts: 971
Location: Great Britain
I've only spent a short time looking though, so I can't say anything for certain. I can see the item lookup table and it is dependent on position, as in whether the player is in 1st, 2nd, 3rd, etc.
The routine I'm looking at is like this:
If it works like other games, that means the rng draws from a fixed sequence of numbers, gets poked some number of times every frame, and gets poked some additional times when you slide, probably related to the dust puffs.
So what you actually need is a count of how many rng numbers you are consuming during the item spin, the 'nearby' numbers in the sequence when the item pops, and a list of which actions consume how many numbers.
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
telnet: Unable to connect to remote host
No, I meant position in the race (1st place, 2nd place...).
Yes, that's what I've been trying to do. Can't say I'm really close though, I haven't had much time and it appears the rng is unlike any I know.
I don't think it does. It appears to use "random" data left on the stack and in registers by previous function calls. That means that jumping (and sliding) affect the outcome, but only because they cause specific function calls.
None. The item spin just loops through all possible items in order. There appears to be very little in the game that depends on the rng, which is probably why the existing one is so odd: it'd probably be noticeable otherwise (same sequences of items).
I've only spent very little time so far, but this is definitely not correct. At least over a hundred numbers are generated every single frame in a race.
Really, what for? I can't say my N64 ASM is all that good (too many registers to keep track of), and I'm having a hard time working with the available N64 debugging tools, so you're probably right. I'd love to help figure this stuff out, but I'm afraid I can't really be of any help at this point...
All kinds of graphical effects, like what you see behind your cart, enemy AI, and I don't know what else. I've spent very little time, like I've said. But it's a lot per frame, and that kind of makes it look to me like predicting an RNG roll several frames ahead might not be feasible. Drifiting and all that should influence the RNG because it'll pull a different amount of numbers for graphical effects.
I was able to change the camera with c^ for the first five races with no desync (I originally played zoomed in but switched to zoomed out when I found out it produces less lag on the real console) . So I think not.
I'm guessing it was muted due to my playing music while I TAS. I may need to figure out a headphone solution. I'm not too pleased with the new Twitch policies muting sound and deleting past broadcasts after two weeks...