Greasy Fork

Greasy Fork is available in English.

Force DGG Kick Embed

Forces the destiny.gg bigscreen to embed his Kick.com stream.

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @license      GPL3
// @name         Force DGG Kick Embed
// @version      1.0.0
// @description  Forces the destiny.gg bigscreen to embed his Kick.com stream.
// @author       mynameisben (original code by Seb3thehacker)
// @match        https://www.destiny.gg/bigscreen
// @grant        none
// @namespace http://greasyfork.icu/en/users/1127844-mynameisben
// ==/UserScript==

(function() {
    'use strict';

    // URL to whatever embed you want to force.
    var embedUrl = 'https://player.kick.com/destiny'; // Replace "channelname" with the desired Twitch channel or video

    // Create an <iframe> element
    var iframeElement = document.createElement('iframe');
    iframeElement.src = embedUrl;
    iframeElement.width = '100%';
    iframeElement.height = '100%';
    iframeElement.frameBorder = '0';
    iframeElement.allowFullscreen = true;

    // Find the <div> element with the id "embed"
    var embedDiv = document.getElementById('embed');

    // Append the <iframe> element to the <div> element
    if (embedDiv) {
        embedDiv.appendChild(iframeElement);
    }

    var offlineTextElement = document.getElementById('offline-text');

    // Remove the offline text element, allows you to click play.
    if (offlineTextElement) {
        offlineTextElement.remove();
    }

    // Remove the stream-block div
    var streamBlockElement = document.getElementById('stream-block');
    if (streamBlockElement) {
        streamBlockElement.remove();
    }
})();