学マスダイススレ発見君一号 (ブックマークレット)

  • 1二次元好きの匿名さん25/01/26(日) 10:22:36

    機能:
    - ホーム(category13)ページにてダイススレを視覚化!
    - 過去ログ一覧(kakolog13)ページにて過去ログのスレッドをフィルターしてダイススレのみ表示!
    - あにまん掲示板様にご迷惑を(できるだけ)かけません!(ホールページでは、キャッシュを使用し、過去ログ一覧にアクセスする際は7秒ほどの間隔を開けています。)

    使い方はホスト規制に引っかからないようにするため一定間隔で投稿します。

  • 2二次元好きの匿名さん25/01/26(日) 10:25:16

    1. 以下のブックマークレットをコピー


    ブックマークレット始め


    javascript:(async()=>{const t=70,e=[{r:[52,116,54,27,29,31,21,44,50,44,90,114,47,66,57,90,125,124,63,54,102,134,132,80,55,83,60,102,110,101,118,189,201,243,248,262,226,337,408,411],g:[0,3,6,7,15,28,25,36,52,58,54,69,48,68,69,71,121,183,90,89,120,256,160,100,118,175,94,152,173,105,211,131,136,169,110,268,293,389,341,307],b:[121,44,18,15,25,31,27,45,40,37,61,41,51,83,137,120,148,140,99,156,194,172,148,102,137,155,91,108,103,106,129,246,162,107,111,164,215,252,328,431]},{r:[5,18,30,34,25,33,36,43,47,33,53,45,62,85,84,95,85,82,64,64,74,56,85,87,89,105,89,125,135,180,205,199,207,213,227,363,297,354,349,438],g:[3,9,42,33,29,37,32,45,38,36,48,38,48,73,73,74,78,96,104,105,114,81,89,101,117,167,128,172,182,161,181,133,224,214,234,367,305,300,235,354],b:[10,16,29,27,38,48,39,42,33,34,47,44,61,57,78,96,88,138,121,143,172,142,176,137,142,151,153,177,184,165,164,159,157,151,160,206,187,294,240,394]}];

  • 3二次元好きの匿名さん25/01/26(日) 10:28:22

    async function r(r){try{const a=await async function(e){return new Promise(((r,a)=>{const n=document.createElement("canvas"),o=n.getContext("2d");if(!o)return void a(new Error("Could not get canvas context"));let c=e.naturalWidth,i=e.naturalHeight;if(c>t||i>t){const e=c/i;Math.max(c,i)===c?(c=t,i=Math.round(t/e)):(i=t,c=Math.round(t*e))}n.width=c,n.height=i,o.drawImage(e,0,0,c,i),r(o.getImageData(0,0,c,i))}))}(r),n=await async function(t){const e={r:new Array(40).fill(0),g:new Array(40).fill(0),b:new Array(40).fill(0)},r=t.data;for(let t=0;t<r.length;t+=4)e.r[Math.floor(r[t]/6.4)]++,e.g[Math.floor(r[t+1]/6.4)]++,e.b[Math.floor(r[t+2]/6.4)]++;return e}(a);return(await Promise.all(e.map((async t=>await async function(t,e){let r=0,a=0;for(const n of["r","g","b"])for(let o=0;o<40;o++)r+=Math.abs(t[n][o]-e[n][o]),a+=t[n][o]+e[n][o];return 1-r/a}(n,t))))).reduce(((t,e)=>t+e),0)/e.length}catch(t){return console.error("Error comparing images:",t),0}}

  • 4二次元好きの匿名さん25/01/26(日) 10:31:51

    const a=Array.from(document.querySelectorAll(".card"));if(await Promise.all(a.map((async t=>{const e=t.querySelector("img");if(!e)return;const a=t.textContent||"",n=(10*await r(e))**2/100;t.style.opacity=String(a.includes("🎲")||n>.72?1:n)}))),document.location.pathname.startsWith("/kakolog13")){if(window.diceThreadsSearcher&&"number"==typeof window.diceThreadsSearcher)return void clearInterval(window.diceThreadsSearcher);let t=1;document.location.pathname.startsWith("/kakolog13/page:")&&(t=parseInt(document.location.pathname.split(":")[1]));let e=document;const a=document.querySelector(".list-group");if(!a)return;window.diceThreadsSearcher=setInterval((async()=>{const n=Array.from(e.querySelectorAll(".list-group-item"));for(const t of n){const e=document.createElement("img");if(!e)continue;const n=t.textContent||"";e.onload=async()=>{const o=(10*await r(e))**2/100;t.style.display=String(n.includes("🎲")||o>.72?"block":"none"),o>.72&&a.appendChild(t)},

  • 5二次元好きの匿名さん25/01/26(日) 10:34:07

    e.onerror=()=>{console.error("Error loading image:",e.src)};const o=t.querySelector("div")?.style["background-image"];o&&(e.src=o.split('"')[1])}t++;try{const r=await fetch(`/kakolog13/page:${t}`);if(!r.ok)throw new Error(`Failed to fetch page ${t}: ${r.status} ${r.statusText}`);const a=await r.text();e=(new DOMParser).parseFromString(a,"text/html")}catch(t){console.error("Error fetching next page:",t),clearInterval(window.diceThreadsSearcher)}}),7e3)}})();


    ブックマークレット終わり

  • 6二次元好きの匿名さん25/01/26(日) 10:36:20

    これの逆なら欲しい

  • 7二次元好きの匿名さん25/01/26(日) 10:37:06

    2. ブックマークレットをブックマークに登録

    3. ホームページを開いている時か学マスの過去ログを開いている時にブックマークレットをクリック

    4. 完了!


    やったね!


    Q. ウイルスは含まれていないの?

    A. もちろん含まれおりません。圧縮前のソースコードをみたい方は

    GakuMasDiceThreadSearch-kun - Pastebin.comPastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.pastebin.com

    をご覧ください。


    Q. 誰得?

    A. 俺得

  • 8二次元好きの匿名さん25/01/26(日) 10:40:16

    >>6

    つまり学マスダイススレ除外する機能ということでしょうか?それならばすぐに作成できますよ!

  • 9二次元好きの匿名さん25/01/26(日) 10:46:49
  • 10二次元好きの匿名さん25/01/26(日) 11:23:59

    何か要望とかあったらなんでも言ってください。時間があったら作るかもです。

オススメ

このスレッドは過去ログ倉庫に格納されています