Dolphin, the GameCube and Wii emulator - Forums

Full Version: NTSC/JP Xenoblade 60fps and other mods
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Weird, I just tried the OP code again and now it didn't happen. And yeah, with the OP code I don't get the weird lags in battle that I was getting with the beta code. Huh.

The thing is, the pause bug seems to be random... Sometimes it happens, sometimes it doesn't. My Dolphin build is 5.0-6106, will update to the latest. Also I don't think it was my computer causing these lags with the beta code, since I have a i7 6700k at 4.4 GHz
If you could try the beta code with line:
044CD248 C042CF74 //Effect fix
deleted, and report back on any changes in lag, that would help me out.
(01-04-2018, 02:10 AM)One More Try Wrote: [ -> ]If you could try the beta code with line:
044CD248 C042CF74 //Effect fix
deleted, and report back on any changes in lag, that would help me out.
Yep, the lag is gone by doing that.
(12-21-2017, 07:51 PM)One More Try Wrote: [ -> ]Heya! Not much changed with that code I posted and what I ended with before - it is after the trig lookup.  I just went frame by frame with my code and didn't notice any bugs with camera switching. I would need a video or screenshot with my code running to look into it.  I'm not sure about the characters, as the bug happens outside the trig calcs and angle setup area.  It would either require following the code from the initial counter, which seems like an ordeal, or finding the memory for a buggy character and trying to follow read/writes for it, which may or may not work out.  Also, if you haven't fiddled with Symbols, you might want to. It makes it easier to jump around the code and whatnot. Older versions (5.0-3819) lets you tag single lines of code (right click -> add function then Symbols -> save symbol map).

With the new skill effect bug, I'll probably record the intro movies and every character skill and compare with my fix, to make sure nothing is breaking. It'll take awhile to get that done.

/edit I wrote a value finder. You probably want to use it during 30fps. I'll probably find the buggy soldier memory in a few minutes with this, but not sure I can follow it to the bug.
movie value finder: (Show Spoiler)

/edit2 Ok, I figured out the location bug. I had to crack open the game code in a text editor and do a regex for " psq_st.*qr3 ", which is how they round off the counter to see if it has a fractional component. I found each one and deleted it in game, until the game bugged out. There weren't that many to test, but I had trouble confirming what that code did until I adapted the soldier finder code to that area.  In the end it's: 803e0c94 and below.  The game sets asset locations here, but it's a bit tricky because it only does one value at a time and not x/y/z.  I'm not even sure most things have y or z components, it seems they manage to make it 1 dimensional for many things.  ANYWAY, the bug is that it appears to re-use models that have gone off-screen, by changing their location to a place they need a new model to appear. Since the code averages locations for fractional frames, the model only moves halfway to its new location, which puts it in the wrong place for one buggy frame.  The fix will be to detect large variations in location and skip averaging if it is too large, and hopefully nothing moves across the screen too fast, or I'll have to do something more complex.

Buggy memory breakpoints: Range from 92753564 to 927536a8 during soldier intro movie, running from the hill to the sniping/scope part.

The other bug that I thought was easy, is more complicated. With Mechonis' fingers disappearing for a frame and also affecting stationary/dead soldiers being displayed. I don't think I need to look for where the bug occurs though.

/edit I've been back at work on the main code. Tweaking a few things. Probably be a few more days before I post a new update.

Hmm. I can't get your code to break on camera switches anymore either, so I might've just derped there. It also seems that I just so happened to pick a few buggy switches with mine, and most actually work okay. Whoops :p

That value finder code should be useful when I look at this again, since I was doing basically that process manually already lol.

As for the location bug... while different, it's still fairly similar in practice to what I described. Interpolation assumes continuous movement, so getting this working despite that should prove tricky. You seem to know this already, but the easy fix will only work if every movement that's for a model moving to act as a 'new' model is bigger than all standard movements. (Though I suppose if we can find a value that only leaves a few models breaking, exception cases could theoretically be hard-coded...)
I'm not getting anywhere on a lag-free Melia effect fix. She's unique because the effect is set when you prep the spell, not when you cast it. As far as I can tell, it assumes the effect code will run in one(?) frame and then changes the memory in a different section of code. 60fps means things take twice as many frames to run, and forcing it back to 1 frame fixes it, but lags the game. I'm not sure if it lags due to Melia's effect or many other things being affected by the fix.

I don't think it's natural lag. It could be a mismatch with the rest of the code in that section which follows 60fps values. I can't change everything though.

For movies, I don't think fixing model locations will lead to many/any bugs. There are still other 1-frame bugs that I don't know about.

/edit Instead of adding 0.5 to the skill effect counter check (was 0.0), I instead subtracted 0.5 from the counter when it is initially set. It seems to be more compatible and less laggy this way. I don't think it'll break 30fps movies, because it only counts in whole numbers and checks for less than or equal tp zero. Hoping this works out. I need to test thoroughly.
The boss battle force field is a moving texture. It's bugged to move at 1/4th the speed it should. Unlike other moving textures, it uses the global speed factor to decrease its speed for 60fps, but it gets hit with it twice, making it 0.25 speed when the moving texture code is not acting on it. Then the moving texture code halves the speed again to 0.125. It should just be 0.5. It'll take some work to figure out the correct way to fix it. I don't know if there are times it should slow down normally. I'll do that after getting the current fixes finalized and updated.

I was trying to figure out why a boss battle is so laggy, but this doesn't appear to make the lag worse.
Main Post and wiki updated with new code. Can someone test Japanese version's Melia and make sure her fire spell makes the correct effect? I can't find a save with Melia.

/edit I will start posting test fixes on the main page. The only fixes I have are for stuff most people won't even notice and there's a chance they'll break something.

/edit2 Maybe Xeno movie discussion needs it's own post. It's so extensive. Anyway, the Mechonis finger bug happens with memory breakpoint: 926fe438. A bug with a soldier running away after the snipe shot is at 92767de4. The code block starts at 803e0fd4. It loads and converts R6 and R6 + 4 to floats. One problem is that it only loads two digits of the memory value., which is something like a counter, so when it hits FF it can reset to 00 and the difference between the two cause a bug. It seems to just not be formatted right since it's for 30fps movies.
DONT USE Movie dev code fix: (Show Spoiler)
/edit May have to modify the comparisons, but these seem to mostly fix stuff. The second block of code could probably be more robust. Not sure the first one can be anything more than a difference check. I noticed these trigger quite a bit during the load screen... not sure if that impacts anything.

Brushing up on my general register maths, I think we have something better now: (Show Spoiler)
This code compares the current frame, next frame, and previous frame to find buggy values. The one issue might be Location 2's code at the start of a new counter/section. Probably no big deal. Can modify the comparisons to make the allowed differences wider or narrower.

brtmn0

The game freezes except from the sound using this code, it freezes at random moments and can even happen on loading screens. I have tried switching to the beta code but that doesn't seem to fix the issue.
I'm using 6x IR, the 4x IR bloom code, fullscreen borderless window, v-sync.
can anyone help me with this?
What beta code? I didn't post a beta. Does it freeze without the Bloom code? Are you using CPU overclock in the config menu?

brtmn0

(02-17-2018, 10:42 AM)One More Try Wrote: [ -> ]What beta code? I didn't post a beta. Does it freeze without the Bloom code?  Are you using CPU overclock in the config menu?
(01-01-2018, 07:03 PM)One More Try Wrote: [ -> ]I had to mess with the basic timing stuff, so here's a new English beta code:
ENG 60fps beta: (Show Spoiler)


Changes: Melia skill effect fix. Loading screens use 30fps speed multi to fix some bugs. Movies use 30fps speed multi. Possible bugs: wrong speed multi during gameplay.
/edit Not enough speed checks. More have been added.  The trouble is that the code that writes the speed values doesn't t run often enough, but I think I got it worked out.



I'm sorry, I found that the issue wasn't the code itself but using the code with a modded version of xenoblade, using the mod in this thread https://forums.dolphin-emu.org/Thread-xenoblade-chronicles-hd-expansion-pack and the 60 fps code together made the random freezes happen.
also quoted the comment where you posted a beta code.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31