Crazy games button

A always visible button to open crazy games it is on the bottom left.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

Bạn sẽ cần cài đặt một tiện ích mở rộng như Tampermonkey hoặc Violentmonkey để cài đặt kịch bản này.

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

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

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

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

(Tôi đã có Trình quản lý tập lệnh người dùng, hãy cài đặt nó!)

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.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name         Crazy games button
// @namespace    Violentmonkey Scripts
// @version      1.2
// @description  A always visible button to open crazy games it is on the bottom left.
// @match        *://*/*
// @grant        none
// ==/UserScript==

(function () {
    'use strict';

    const GAME_URL = 'https://www.crazygames.com/game/tunnel-rush';

    // Maak knop
    const button = document.createElement('div');
    button.innerText = '🎮';
    Object.assign(button.style, {
        position: 'fixed',
        bottom: '20px',
        left: '20px',
        zIndex: '99999',
        backgroundColor: '#111',
        color: '#fff',
        padding: '10px 14px',
        borderRadius: '8px',
        fontSize: '14px',
        fontFamily: 'Arial, sans-serif',
        cursor: 'pointer',
        boxShadow: '0 2px 10px rgba(0,0,0,0.5)',
        userSelect: 'none',
    });
    document.body.appendChild(button);

    // Klik → open popup
    button.addEventListener('click', () => {
        window.open(GAME_URL, '_blank', 'width=1000,height=700');
    });
})();