Steam Game Page - Add Links To Game Trailer & Gameplay (Search On Piped and without commentaries)

This script is a fork of CoopCoding's script. It has custom features like searching on piped instead of youtube, searching on Searx, and tries to bring gameplay videos without youtuber's commentaries. It also adds two links for piracy. Fuck Steam and corpos making money with our personal data.

目前為 2023-02-27 提交的版本,檢視 最新版本

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         Steam Game Page - Add Links To Game Trailer & Gameplay (Search On Piped and without commentaries)
// @namespace    coop
// @version      1.0
// @description  This script is a fork of CoopCoding's script. It has custom features like searching on piped instead of youtube, searching on Searx, and tries to bring gameplay videos without youtuber's commentaries. It also adds two links for piracy. Fuck Steam and corpos making money with our personal data.
// @author       You
// @match        http://store.steampowered.com/app/*
// @match        https://store.steampowered.com/app/*
// @grant        none
// @license MIT
// ==/UserScript==

const gameName = document.querySelector('.apphub_AppName').textContent.trim()

const breadcrumbsContainer = document.querySelector('.breadcrumbs')

breadcrumbsContainer.setAttribute('style', `
display: flex;
justify-content: space-around;
`)

const metaLinksContainer = document.createElement('div')
metaLinksContainer.setAttribute('style', `
display: flex;
justify-content: space-around;
width: 420px;
`)

const gogSearchLink = document.createElement('a')
gogSearchLink.href = 'https://searx.tiekoetter.com/search?q=site%3Agog-games.com+' + gameName
gogSearchLink.textContent = 'Pirate on GoG-games.com'
gogSearchLink.setAttribute('target', '_blank')

const steamripSearchLink = document.createElement('a')
steamripSearchLink.href = 'https://searx.tiekoetter.com/search?q=site%3Asteamrip.com+' + gameName
steamripSearchLink.textContent = 'Pirate on SteamRip.com'
steamripSearchLink.setAttribute('target', '_blank')

const ytTrailerSearchLink = document.createElement('a')
ytTrailerSearchLink.href = 'https://piped.video/results?search_query=' + encodeURIComponent(gameName) + ' trailer'
ytTrailerSearchLink.textContent = 'Trailers'
ytTrailerSearchLink.setAttribute('target', '_blank')


const ytGameplaySearchLink = document.createElement('a')
ytGameplaySearchLink.href = 'https://piped.video/results?search_query=' + encodeURIComponent(gameName) + ' gameplay no commentary'
ytGameplaySearchLink.textContent = 'Gameplay'
ytGameplaySearchLink.setAttribute('target', '_blank')

metaLinksContainer.appendChild(gogSearchLink)
metaLinksContainer.appendChild(steamripSearchLink)
metaLinksContainer.appendChild(ytTrailerSearchLink)
metaLinksContainer.appendChild(ytGameplaySearchLink)

breadcrumbsContainer.appendChild(metaLinksContainer)