UserScript | 🐵 Some messy oil monkey scripts for personal use~ | Video Game library

 by   XIU2 JavaScript Version: Current License: GPL-3.0

kandi X-RAY | UserScript Summary

kandi X-RAY | UserScript Summary

UserScript is a JavaScript library typically used in Gaming, Video Game applications. UserScript has no bugs, it has no vulnerabilities, it has a Strong Copyleft License and it has medium support. You can download it from GitHub.

🐵 Some messy oil monkey scripts for personal use~
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              UserScript has a medium active ecosystem.
              It has 5725 star(s) with 512 fork(s). There are 62 watchers for this library.
              OutlinedDot
              It had no major release in the last 6 months.
              There are 14 open issues and 301 have been closed. On average issues are closed in 5 days. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of UserScript is current.

            kandi-Quality Quality

              UserScript has 0 bugs and 0 code smells.

            kandi-Security Security

              UserScript has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              UserScript code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              UserScript is licensed under the GPL-3.0 License. This license is Strong Copyleft.
              Strong Copyleft licenses enforce sharing, and you can use them when creating open source projects.

            kandi-Reuse Reuse

              UserScript releases are not available. You will need to build from source code and install.

            Top functions reviewed by kandi - BETA

            kandi has reviewed UserScript and discovered the below as its top functions. This is intended to give you an instant insight into UserScript implemented functionality, and help decide if they suit your requirements.
            • Sets the DBCite properties of the database .
            • start of Dite list
            • process the list of pages
            • Jump to collapsed menu item when selection is resized .
            • Clear the search .
            • Set custom rules
            • Copy all files
            • Initialize a new Shower .
            • inserts an iframe
            • Block for block type .
            Get all kandi verified functions for this library.

            UserScript Key Features

            No Key Features are available at this moment for UserScript.

            UserScript Examples and Code Snippets

            No Code Snippets are available at this moment for UserScript.

            Community Discussions

            QUESTION

            Kill refresh script onclick
            Asked 2022-Mar-26 at 06:00

            I'm trying to write a very simple auto-refreshing userscript that immediately stops refreshing when the page is clicked anywhere. I have absolutely no coding experience so help would be greatly appreciated.

            ...

            ANSWER

            Answered 2022-Mar-26 at 05:57
            (function() {
                'use strict';
            
                var didClick = false;
                var interval = Math.floor(Math.random() * 4000);
            
                function refresh() {
                    var timeout = setTimeout(function() {
                        if (didClick) {
                            return;
                        }
                        location.reload();
                    }, interval);
            
                    document.addEventListener('click', function clickHandler() {
                        if (!didClick) {
                            didClick = true;
                            clearTimeout(timeout);
                        }
                        document.removeEventListener('click', clickHandler);
                    });
               }
            
                window.onload = function() {
                    refresh();
                };
            })();
            

            Source https://stackoverflow.com/questions/71567456

            QUESTION

            Fire "data-ng-change" programatically or another way to change value of input on website using Angular JS
            Asked 2022-Mar-16 at 17:20

            I am writing a userscript and unfortunately the website uses Angular JS which I don't know.

            There is code:

            ...

            ANSWER

            Answered 2022-Mar-16 at 17:20

            If someone will look for the same thing, I solved it this way:

            Source https://stackoverflow.com/questions/70997192

            QUESTION

            Tampermonkey - Script not running on Todoist
            Asked 2022-Feb-24 at 11:05

            I want to write a user script for Todoist, but - even though the URL matches - the script is not running on the Todoist but on every other webpage.

            Even the simplest example won't run.

            ...

            ANSWER

            Answered 2022-Feb-24 at 11:05

            Switched to the Plugin Violentmonkey" and it worked. I still don't know what the issue is. But it is solved for me.

            Source https://stackoverflow.com/questions/71237745

            QUESTION

            CORS preflight requests working with jQuery AJAX, but failing with native XmlHttpRequests in Firefox
            Asked 2022-Feb-15 at 03:10

            This question is based on an issue I had before but never managed to resolve.

            I'm running an userscript via FireMonkey which regulary sends requests to my backend server, those using CORS since they are cross-domain. For testing purposes my response headers are currently set very loosely backend-side:

            ...

            ANSWER

            Answered 2022-Feb-15 at 00:42

            After some more research I finally found out that this is actually a firefox-related issue with userscripts: https://bugzilla.mozilla.org/show_bug.cgi?id=1715249

            Source https://stackoverflow.com/questions/71105014

            QUESTION

            async wait for element to load in so i can find it with jquery
            Asked 2022-Feb-09 at 15:54

            i don't really understand async. i have a function like this:

            ...

            ANSWER

            Answered 2022-Feb-09 at 15:54
            function getTeam() {
                let sir = new Promise((res, rej) => {
                const teamsGrid = $('[class*="teamsgrid"]').find("p");
                    const firstTeam = $(teamsGrid[0]).text();
                    if (firstTeam != '') {
                      clearInterval(sir);
                      res(firstTeam.trim());
                    }
                });
                return sir();
            }
            

            Source https://stackoverflow.com/questions/71051680

            QUESTION

            userscript for getting rid of annoying notifications counter on title of pages like Facebook, Linkedin, etc
            Asked 2022-Feb-02 at 09:09

            I am trying to do a userscript rid of annoying notifications counter on title of pages like Facebook, Linkedin, etc.

            Firstly I tried to use the extension "Rename Tab Title" https://chrome.google.com/webstore/detail/rename-tab-title/kppndhfiaenbiioipolacicknfmdcdep with my configuration described in the Support tab of that page, in the comment of user Sérgio Loureiro. But had no success.

            What I mean is the "(1) " thing before the page title, that will be rendered on the respective tab. In this case I was doing it for the Vivaldi browser, that supports user script from the base, without any extension. I think this is also available for other browsers via tampermonkey or greasemonkey.

            An example:

            So I wrote an *.user.js file with the contents:

            ...

            ANSWER

            Answered 2022-Jan-29 at 22:14

            I think I have succeeded, following @double-beep's advice of watching not only for characterData.

            This is the script I have now. I also had to make a .match check before the replace, because some sites were becoming unresponsive.

            Source https://stackoverflow.com/questions/70908925

            QUESTION

            If true return a string else return another string
            Asked 2022-Jan-28 at 08:24

            Code contains errors: Uncaught SyntaxError: Unexpected token 'if' at undefined:18:22

            When uploading to greasyfork I've got that error. The javascript file is:

            ...

            ANSWER

            Answered 2022-Jan-28 at 07:38

            Conditional (ternary) operator may help:mynew.innerHTML = (!(myhtml == null)) ? myhtml : 'A random ' + tobuild + '.';

            Source https://stackoverflow.com/questions/70890179

            QUESTION

            Is it possible to turn off all CSS animations in Chrome?
            Asked 2022-Jan-18 at 22:00

            I have a weird issue where if I play an animation on one of my 3 monitors, YouTube videos on any other monitor crashes. I did fix this by disabling hardware acceleration in chrome://flags, but a new update in Chrome recently made the issue come back, and I haven't found a way to fix it yet. Animations occur on places like Facebook ("Someone is typing a comment...") or basically any website with a animation-duration CSS property on something (spinners are probably the most used form of animations I guess).

            I can verify this simply by placing this CSS on any page:

            ...

            ANSWER

            Answered 2022-Jan-18 at 21:59

            Allow me to answer my own question. Setting animation-duration to 0s !important seems to be working. However, I added animation-play-state: paused for good measure as well.

            I made an userscript, and found that it doesn't target the Shadow DOM, so I have to traverse through every element, check if it's a shadow root, and then add the CSS. Since elements can be added to a page dynamically, I decided to do this every second. So far I cannot see a performance difference, even on pages with a lot of elements.

            Install TamperMonkey (Chrome) or GreaseMonkey (Firefox) to use this:

            Source https://stackoverflow.com/questions/70762198

            QUESTION

            WebGL textures from YouTube video frames
            Asked 2022-Jan-08 at 15:24

            I'm using the technique described here (code, demo) for using video frames as WebGL textures, and the simple scene (just showing the image in 2D, rather than a 3D rotating cube) from here.

            The goal is a Tampermonkey userscript (with WebGL shaders, i.e. video effects) for YouTube.

            The canvas is filled grey due to gl.clearColor(0.5,0.5,0.5,1). But the next lines of code, which should draw the frame from the video, have no visible effect. What part might be wrong? There are no errors.

            I tried to shorten the code before posting, but apparently even simple WebGL scenes require a lot of boilerplate code.

            ...

            ANSWER

            Answered 2022-Jan-08 at 15:24

            Edit: As it has been pointed out, first two sections of this answer are completely wrong.

            TLDR: This might not be feasible without a backend server first fetching the video data.

            If you check the MDN tutorial you followed, the video object passed to texImage2D is actually an MP4 video. However, in your script, the video object you have access to (document.getElementsByTagName("video")[0]) is just a DOM object. You don't have the actual video data. And it is not easy to get access to that for YouTube. The YouTube player do not fetch the video data in one shot, rather the YouTube streaming server makes sure to stream chunks of the video. I am not absolutely sure on this, but I think it'll be very difficult to work around this if your goal is to have a real time video effects. I found some discussion on this (link1, link2) which might help.

            That being said, there are some issues in your code from WebGL perspective. Ideally the code you have should be showing a blue rectangle as that is the texture data you are creating, instead of the initial glClearColor color. And after the video starts to play, it should switch to the video texture (which will show as black due to the issue I have explained above).

            I think it is due to the way you had setup your position data and doing clip space calculation in the shader. That can be skipped to directly send normalized device coordinate position data. Here is the updated code, with some cleaning up to make it shorter, which behaves as expected:

            Source https://stackoverflow.com/questions/70627240

            QUESTION

            Canvas added to YouTube is not visible
            Asked 2022-Jan-06 at 02:35

            I'm following the WebGL tutorial from MDN (code, demo (black rectangle)) to create a WebGL canvas.

            The goal is a userscript (with WebGL shaders, i.e. video effects) for YouTube. So I opened a YouTube video page and put the code below (from the link above) into the JavaScript console. The canvas got created, but it is invisible.

            The canvas inherits a lot of CSS from YouTube by default. Am I overlooking some CSS properties that make it invisible? What to look out for in such cases? It should be black.

            ...

            ANSWER

            Answered 2022-Jan-04 at 02:19

            Your canvas is there, but it's not on-top. Set some additional CSS for positioning. For example:

            Source https://stackoverflow.com/questions/70573336

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install UserScript

            You can download it from GitHub.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/XIU2/UserScript.git

          • CLI

            gh repo clone XIU2/UserScript

          • sshUrl

            git@github.com:XIU2/UserScript.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular Video Game Libraries

            Proton

            by ValveSoftware

            ArchiSteamFarm

            by JustArchiNET

            MinecraftForge

            by MinecraftForge

            byte-buddy

            by raphw

            nes

            by fogleman

            Try Top Libraries by XIU2

            TileTool

            by XIU2C#

            Shell

            by XIU2Shell

            SNIProxy

            by XIU2Go