Newpunch visual coin progress

shows a cute progress bar behind your coin count thing

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         Newpunch visual coin progress
// @namespace    https://greatest.deepsurf.us/en/scripts/369744-newpunch-visual-coin-progress
// @version      1.04
// @description  shows a cute progress bar behind your coin count thing
// @author       0xbbadbeef(Exploderguy)
// @match        https://forum.facepunch.com/*
// @grant        none
// @require      http://code.jquery.com/jquery-1.12.4.min.js
// ==/UserScript==

(function() {
    var coinElement = $("a[href='/user/shop']");

    if (!coinElement.length) return;

    var strProgress = coinElement.prop("title");
    var numProgress = strProgress.substr(strProgress.length - 3);

    //awfully dark/white/whatever
    var useColour = ($("div#toolbar").css("background-color") == "rgb(87, 33, 33)") ? "#6d5414" : "#a9b1bc";

    coinElement.prepend("<div id='coinProgress'></div>");
    $("div#coinProgress").css({
        "height" : numProgress,
        "background-color" : useColour,
        "position" : "absolute",
        "bottom" : "0px",
        "width" : "100%",
        "border-top": "1px solid black",
        "border-top-style" : "dashed",
        "z-index": "-1"
    })
    coinElement.css({
        "border" : "1px solid black"
    });
})();