Skip to content

CTR physics accuracy and fixing architecture differences on PC - #48

Open
kkv0n wants to merge 12 commits into
CTR-tools:masterfrom
kkv0n:asm-equivalent
Open

CTR physics accuracy and fixing architecture differences on PC#48
kkv0n wants to merge 12 commits into
CTR-tools:masterfrom
kkv0n:asm-equivalent

Conversation

@kkv0n

@kkv0n kkv0n commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

So i did noticed some gameplay behavior on native felt different than playing on PS1 so i made a comparison against PS1 assembly searching for any difference on code or architecture that can be causing this like bugs or UB, MIPS CPU is not exactly like a PC after all, well i checked against the whole COLL, Vehicle (except VehTalk because i'm lazy lol), CAM, PlayLevel, GAMEPAD and 226 render overlay with the intention of finding any small hint about what is wrong in main gameplay flow, i found interesting stuff like a bug where some sub quads weren't rendering properly on certain cam angles, this was fixed on 226 on this PR, i also did a huge benchmark script for GTE, used psyq 4.4 source (ctr was built on that), psx-spx, sony official GTE manual and mednafen emulator source code to compare all possible results and find any UB or wrong logic present on the GTE implementation, when doing this an silent bug showed up where some instances somewhat far away (still visible on vistree) were rendering on screen if you were on certain world positions, turns out there was a unimplemented psx behavior where certain polygons aren't draw, check native gpu to see the fix, another of the bugs fixed there was one where the kart landing wasn't making the kart to bounce properly, that's mostly what this PR is for

PD: i also did checked the delta Timing increment (Timer.c), and some small changes on warpball and UI code related to wrong sign (the sign / size thing being something that also required changed headers) and a wrong assumption that ghosts / warpball icons on minimap used CRASH_BLUE instead of WHITE, verified by retail assembly.

  • this PR is part 1, is fine to be merged but in the incoming days i'll also do this against MATH, PROC, Vector and other important functions related to physics

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant