Current Local Date

Shows current date in a slim overlay

Bu betiği kurabilmeniz için Tampermonkey, Greasemonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Violentmonkey gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

Bu betiği kurabilmeniz için Tampermonkey ya da Userscripts gibi bir kullanıcı betiği eklentisini kurmanız gerekmektedir.

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

Bu komut dosyasını yüklemek için bir kullanıcı komut dosyası yöneticisi uzantısı yüklemeniz gerekecek.

(Zaten bir kullanıcı komut dosyası yöneticim var, kurmama izin verin!)

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.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Zateb bir user-style yöneticim var, yükleyeyim!)

// ==UserScript==
// @name         Current Local Date
// @version      1.5
// @description  Shows current date in a slim overlay
// @author       You
// @match        *://deadshot.io/*
// @grant        none
// @license MIT
// @namespace https://greasyfork.org/users/1527574
// ==/UserScript==

(function() {
    'use strict';


    const overlayStyle = `
    #metricOverlay {
        position: fixed;
        top: 7px;  /* 7 pixels from top */
        left: 7px; /* 7 pixels from left */
        background: rgba(0, 0, 0, 0.6);
        padding: 7px 12px;
        border-radius: 6px;
        color: #fff;
        border: 2px solid #fff;  /* White border */
        z-index: 100000;
        font-size: 15px;
        white-space: nowrap;
        display: flex;
        flex-direction: column;
        visibility: hidden; /* Start hidden */
    }`;

    const styleElement = document.createElement("style");
    styleElement.type = "text/css";
    styleElement.innerText = overlayStyle;
    document.head.appendChild(styleElement);

    const metricOverlay = document.createElement('div');
    metricOverlay.id = 'metricOverlay';
    metricOverlay.innerText = 'Initializing metrics...';
    document.body.appendChild(metricOverlay);


    setInterval(() => {
        const currentDate = new Date().toLocaleDateString();
        metricOverlay.innerHTML = `Date: ${currentDate}`;

        // Make the overlay visible after the first update
        metricOverlay.style.visibility = 'visible';
    }, 1800000);

    // Run the update immediately on load
    const initialDate = new Date().toLocaleDateString();
    metricOverlay.innerHTML = `Date: ${initialDate}`;
    metricOverlay.style.visibility = 'visible';

})();