Skip to content
This repository has been archived by the owner on May 14, 2024. It is now read-only.

Commit

Permalink
Bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefanuk12 committed Aug 22, 2022
1 parent b2c461b commit 9532641
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 4 deletions.
17 changes: 16 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,17 @@
# RoPro Patcher
This automatically patches the [RoPro](https://chrome.google.com/webstore/detail/ropro-enhance-your-roblox/adbacgifemdbhdkfppmeilbgppmhaobf?hl=en-GB) extension for you, allowing you to have `pro_tier` for free.
This automatically patches the [RoPro](https://chrome.google.com/webstore/detail/ropro-enhance-your-roblox/adbacgifemdbhdkfppmeilbgppmhaobf?hl=en-GB) extension for you, allowing you to have `pro_tier` for free.

## Firefox
This currently does not support Firefox but it easily can be done manually.

- Go to where your extension is installed, usually at `%appdata%\Mozilla\Firefox\Profiles` followed by your profile name (the most recently modified folder) and finally into `extensions`.
- From there, find the RoPro file - for me it is named `{fbfda72b-073a-4a24-9e87-6d472b69b66f}.xpi`.
- Now, change the `.xpi` extension to `.zip` and extract.
- Next, apply the custom path patch to it.
- Rezip the file and change the extension back to `.xpi`.
- Make sure to override the old extension.

## NOTE
Chrome (and possibly other browsers) have a feature that checks the hash of the extension. This means that it will flag as corrupted. Therefore, you will have to download the extension, patch it with a custom path and use developer mode to load an unpacked extension.

- an exception to this rule is Opera GX
6 changes: 3 additions & 3 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ fn patch(path: PathBuf) {
// Finding the things to patch
background_contents = background_contents.replace("subscription = await getStorage(\"rpSubscription\")", "subscription = \"pro_tier\"");
background_contents = background_contents.replace("subscription = data", "data = \"pro_tier\"; subscription = data");
background_contents = background_contents.replace("getStorage('rpSubscription')", "\"pro_tier\"");
background_contents = background_contents.replace("getStorage('rpSubscription')", "new Promise(resolve => resolve(\"pro_tier\"))");
background_contents = background_contents.replace("await getStorage(\"rpSubscription\")", "\"pro_tier\"");
background_contents = background_contents.replace("setStorage(\"rpSubscription\", xhr.getResponseHeader(\"ropro-subscription-tier\"))", "setStorage(\"rpSubscription\", \"pro_tier\"");
background_contents = background_contents.replace("setStorage(\"rpSubscription\", subscriptionLevel", "setStorage(\"rpSubscription\", \"pro_tier\"");
background_contents = background_contents.replace("setStorage(\"rpSubscription\", xhr.getResponseHeader(\"ropro-subscription-tier\"))", "setStorage(\"rpSubscription\", \"pro_tier\")");
background_contents = background_contents.replace("setStorage(\"rpSubscription\", subscriptionLevel)", "setStorage(\"rpSubscription\", \"pro_tier\")");

// Write our changes
fs::write(background.clone(), background_contents).expect("Unable to write file contents (background.js)");
Expand Down

0 comments on commit 9532641

Please sign in to comment.