Skip to content

Proposing Core changes to YTPlaybackFix - #2

Open
AppropriateNet2928 wants to merge 22 commits into
Mark02-2012:mainfrom
AppropriateNet2928:patch-1
Open

Proposing Core changes to YTPlaybackFix#2
AppropriateNet2928 wants to merge 22 commits into
Mark02-2012:mainfrom
AppropriateNet2928:patch-1

Conversation

@AppropriateNet2928

@AppropriateNet2928 AppropriateNet2928 commented Aug 5, 2026

Copy link
Copy Markdown

I have modified the Tweak.xm to have:

  1. Modified some variables and modified the hook of YTPlayerViewController for better seekToTime method; The hook was modified like this:
  • The currentVideoMediaTime part received an complete write up to keep two time variables synchronized, gTime is currentVideoMediaTime, meaning the time that the video is at and gSavedTime is gTime. Therefore, gSavedTime is the exact time that the video received the error, and then to return currentVideoMediaTime;

  • The seekToTime part received a small modification, it just made gSavedTime equal to gTime so we can later use seekToTime like this: seekToTime:gSavedTime, meaning that u seek to the time that the video received the error.

  1. An simpler anti-loop logic:

The old anti-loop logic was kinda sus and screamed that it may break at any time, so therefore I removed it and added an simpler anti-loop logic instead, with a simple BOOL variable that has the role to stop the retry logic when it is not needed and to start it when it is needed.

This logic is simpler and has the highest chances of a pozitive result :))

  1. Some small modification throughout the code to use the new variables instead of the old ones;

The gBurstCount variable was removed due to it being part of the old anti-loop logic :))

Mark02-2012 and others added 22 commits June 25, 2026 10:16
Updated version and improved description for clarity.
Added a burst count to track consecutive error recoveries in the YTPlayerViewController. Adjusted retry logic to handle rapid error occurrences more effectively.
Added emergency check flag to manage retry logic more effectively.
Fixed compilation errors by adding missing includes, correcting bracket mismatches, and adding comments.
Removed dependency on mobilesubstrate.
Updated README to clarify playback issue fixes and release information.
…s :))

I have modified the time variables, remade the anti logic thing to be more efficient, removed a useless variable and made the seekToTime logic to be more exact and focused on seeking to the exact time that the error started.
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.

2 participants