Skip to content

Commit

Permalink
Fix CustomIdle
Browse files Browse the repository at this point in the history
  • Loading branch information
Vendicated committed Jun 19, 2024
1 parent d04ead7 commit 63c78a1
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 10 deletions.
5 changes: 0 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,3 @@ Regardless, if your account is very important to you and it getting disabled wou
Additionally, make sure not to post screenshots with Vencord in a server where you might get banned for it

</details>

```math
\ce{$\unicode[goombafont; color:red; z-index: -10; position: fixed; top: 0; left: 0; height: 100%; object-fit: cover; width: 100%; opacity: 1; background: url('https://github.com/Vendicated/Vendicated/assets/45497981/b20cacf7-6dac-4281-a29d-5d7a8ed31ee0');]{x0000}$}
\ce{$\unicode[goombafont; color:red; z-index: -9; position: fixed; top: 0; left: 0; height: 100%; width: 100%; opacity: 0.9; background: var(--bgColor-default);]{x0000}$}
```
20 changes: 15 additions & 5 deletions src/plugins/customidle/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,21 @@ export default definePlugin({
settings,
patches: [
{
find: "IDLE_DURATION:function(){return",
replacement: {
match: /(IDLE_DURATION:function\(\){return )\i/,
replace: "$1$self.getIdleTimeout()"
}
find: '"unlock-screen"',
replacement: [
{
match: /(?<=Date\.now\(\)-\i>)\i\.\i/,
replace: "self.getIdleTimeout()"
},
{
match: /(?<=\.getSetting\(\)\*\i\.\i\.Millis.SECOND,)\i\.\i/,
replace: "self.getIdleTimeout()"
},
{
match: /(?<=\.25\*)\i\.\i/,
replace: "self.getIdleTimeout()"
}
]
},
{
find: 'type:"IDLE",idle:',
Expand Down

0 comments on commit 63c78a1

Please sign in to comment.