- // ==UserScript==
- // @name Gartic IO Node Mode Menu
- // @namespace http://tampermonkey.net/
- // @version 2025-03-07
- // @description Tries to cheat by changing the codes of the game
- // @author anonimbiri
- // @license MIT
- // @match https://gartic.io/*
- // @icon https://www.google.com/s2/favicons?sz=64&domain=gartic.io
- // @run-at document-start
- // @grant none
- // ==/UserScript==
-
- Node.prototype.appendChild = new Proxy(Node.prototype.appendChild, {
- apply: function(target, thisArg, argumentsList) {
- const node = argumentsList[0];
- if (node.nodeName.toLowerCase() === 'script' && node.src && node.src.includes('room')) {
- console.log('Hedef script algılandı:', node.src);
- fetch(node.src)
- .then(response => response.text())
- .then(scriptContent => {
- let modifiedContent = scriptContent
- .replace(
- 'r.created||c?Rt("input",{type:"text",name:"chat",className:"mousetrap",autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",value:i,placeholder:this._lang.chatHere,maxLength:100,enterKeyHint:"send",onChange:this.handleText,ref:this._ref}):Rt("input",{type:"text",name:"chat",className:"mousetrap",autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",value:this._lang.loginChat,maxLength:100,ref:this._ref,disabled:!0})',
- 'Rt("input",{type:"text",name:"chat",className:"mousetrap",autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",value:i,placeholder:this._lang.chatHere,maxLength:100,enterKeyHint:"send",onChange:this.handleText,ref:this._ref})'
- )
- .replace(
- 'this._timerAtivo=setInterval((function(){Date.now()-e._ativo>15e4&&(O(Object(f.a)(n.prototype),"emit",e).call(e,"avisoInativo"),e._ativo=Date.now())}),1e3)',
- 'this._timerAtivo=setInterval((function(){Date.now()-e._ativo>15e4&&e.active()}),1e3)'
- )
- .replace(
- 'e.unlock()}',
- 'e.unlock();window.game=e;setInterval(()=>{window.game=e},1000);e.on("votekick",(t,i,o)=>{if(i.id===e.me.id){e.votekick(t.id,true);}});}'
- );
- let blob = new Blob([modifiedContent], { type: 'application/javascript' });
- let blobUrl = URL.createObjectURL(blob);
- node.src = blobUrl;
- node.textContent = '';
- return target.apply(thisArg, [node]);
- })
- .catch(error => {
- console.error('Failed to fetch/modify script:', error);
- return target.apply(thisArg, argumentsList);
- });
- return node;
- }
- return target.apply(thisArg, argumentsList);
- }
- });
-
- // Inject HTML
- const cheatMenuHTML = `
- <div class="cheat-menu" id="cheatMenu">
- <h2>Cheat Menu</h2>
- <div class="checkbox-container">
- <input type="checkbox" id="autoGuess">
- <label for="autoGuess">Auto Guess</label>
- </div>
- <div class="input-container" id="autoGuessSpeedContainer" style="display: none;">
- <div class="slider-label">Auto Guess Speed</div>
- <div class="custom-slider">
- <input type="range" id="autoGuessSpeed" min="100" max="5000" value="1000" step="100">
- <div class="slider-track"></div>
- <span id="speedValue">1s</span>
- </div>
- </div>
- <div class="checkbox-container">
- <input type="checkbox" id="customLoad">
- <label for="customLoad">Use Custom Word List</label>
- </div>
- <div class="input-container" id="loadWordListContainer" style="display: none;">
- <label for="wordList">Load Custom Word List</label>
- <input type="file" id="wordList" accept=".txt">
- </div>
- <div class="input-container">
- <input type="text" id="guessPattern" placeholder="Enter pattern (e.g., ___e___)">
- </div>
- <div class="hit-list" id="hitList">
- <div class="message">No matches found</div>
- </div>
- <div class="credit">Made by Anonimbiri</div>
- </div>
- `;
-
- // Inject CSS
- const style = document.createElement('style');
- style.textContent = `
- @font-face {
- font-family: 'Nunito';
- src: url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;700;900&display=swap');
- }
-
- .cheat-menu {
- position: absolute;
- top: 20px;
- right: 20px;
- width: 250px;
- background: rgba(30, 30, 47, 0.9);
- backdrop-filter: blur(10px);
- border-radius: 15px;
- box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
- padding: 20px;
- display: flex;
- flex-direction: column;
- gap: 15px;
- color: #fff;
- user-select: none;
- cursor: move;
- z-index: 1000;
- }
-
- .cheat-menu.dragging {
- opacity: 0.8;
- transition: opacity 0.2s;
- }
-
- .cheat-menu h2 {
- margin: 0 0 10px;
- font-size: 20px;
- font-weight: 900;
- color: #ff69b4;
- text-transform: uppercase;
- letter-spacing: 1px;
- }
-
- .checkbox-container {
- display: flex;
- align-items: center;
- gap: 10px;
- margin: 5px 0;
- }
-
- .checkbox-container input[type="checkbox"] {
- appearance: none;
- width: 20px;
- height: 20px;
- background: #2a2a4a;
- border: 2px solid #ff69b4;
- border-radius: 5px;
- cursor: pointer;
- transition: all 0.3s ease;
- }
-
- .checkbox-container input[type="checkbox"]:checked {
- background: #ff69b4;
- border-color: #ff69b4;
- position: relative;
- }
-
- .checkbox-container input[type="checkbox"]:checked::after {
- content: "✔";
- position: absolute;
- top: 50%;
- left: 50%;
- transform: translate(-50%, -50%);
- color: #1e1e2f;
- font-size: 14px;
- }
-
- .checkbox-container label {
- font-size: 14px;
- color: #a5e2fe;
- }
-
- .input-container {
- display: flex;
- flex-direction: column;
- gap: 10px;
- }
-
- .input-container input[type="file"] {
- display: none;
- }
-
- .input-container label {
- background: #ff69b4;
- padding: 8px 15px;
- border-radius: 10px;
- text-align: center;
- font-size: 14px;
- color: #1e1e2f;
- cursor: pointer;
- transition: background 0.3s ease;
- }
-
- .input-container label:hover {
- background: #ff85c0;
- }
-
- .input-container input[type="text"] {
- background: #2a2a4a;
- border: 2px solid #ff69b4;
- border-radius: 5px;
- padding: 8px;
- color: #a5e2fe;
- font-size: 14px;
- }
-
- .slider-label {
- font-size: 14px;
- color: #a5e2fe;
- text-align: left;
- font-weight: 700;
- letter-spacing: 0.5px;
- text-transform: uppercase;
- margin-bottom: 5px;
- }
-
- .custom-slider {
- position: relative;
- width: 100%;
- height: 20px;
- }
-
- .custom-slider input[type="range"] {
- -webkit-appearance: none;
- width: 100%;
- height: 8px;
- background: transparent;
- position: absolute;
- top: 6px;
- left: 0;
- z-index: 2;
- cursor: pointer;
- }
-
- .custom-slider .slider-track {
- position: absolute;
- top: 8px;
- left: 0;
- width: 100%;
- height: 4px;
- background: linear-gradient(to right, #ff69b4 0%, #ff69b4 var(--slider-progress, 20%), #2a2a4a var(--slider-progress, 20%), #2a2a4a 100%);
- border-radius: 2px;
- z-index: 1;
- }
-
- .custom-slider input[type="range"]::-webkit-slider-thumb {
- -webkit-appearance: none;
- width: 16px;
- height: 16px;
- background: #ff69b4;
- border-radius: 50%;
- border: 2px solid #1e1e2f;
- box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
- cursor: pointer;
- transition: transform 0.2s ease, background 0.2s ease;
- }
-
- .custom-slider input[type="range"]::-webkit-slider-thumb:hover {
- background: #ff85c0;
- transform: scale(1.2);
- }
-
- .custom-slider input[type="range"]::-webkit-slider-thumb:active {
- background: #ff4d94;
- }
-
- .custom-slider #speedValue {
- position: absolute;
- top: 24px;
- left: 50%;
- transform: translateX(-50%);
- font-size: 12px;
- color: #a5e2fe;
- background: rgba(42, 42, 74, 0.8);
- padding: 2px 8px;
- border-radius: 10px;
- z-index: 2;
- }
-
- .hit-list {
- max-height: 200px;
- overflow-y: auto;
- display: flex;
- flex-direction: column;
- gap: 8px;
- padding-right: 5px;
- }
-
- .hit-list::-webkit-scrollbar {
- width: 6px;
- }
-
- .hit-list::-webkit-scrollbar-thumb {
- background: #ff69b4;
- border-radius: 10px;
- }
-
- .hit-list button {
- background: rgba(165, 226, 254, 0.2);
- border: none;
- padding: 10px;
- border-radius: 8px;
- color: #a5e2fe;
- font-size: 14px;
- cursor: pointer;
- transition: all 0.3s ease;
- text-align: left;
- position: relative;
- }
-
- .hit-list button:hover:not(.tried) {
- background: rgba(165, 226, 254, 0.4);
- transform: translateX(5px);
- }
-
- .hit-list button:active:not(.tried) {
- background: #ff69b4;
- color: #1e1e2f;
- }
-
- .hit-list button.tried {
- background: rgba(255, 105, 180, 0.3);
- color: #ffccd5;
- order: 1;
- opacity: 0.85;
- }
-
- .hit-list button.tried:hover {
- background: rgba(255, 105, 180, 0.5);
- transform: none;
- }
-
- .hit-list button.tried:active {
- background: #ff69b4;
- color: #1e1e2f;
- }
-
- .hit-list button.tried::after {
- content: "✓";
- position: absolute;
- right: 10px;
- top: 50%;
- transform: translateY(-50%);
- font-size: 12px;
- color: #ffccd5;
- }
-
- .tried-label {
- font-size: 12px;
- color: #ff69b4;
- text-transform: uppercase;
- letter-spacing: 1px;
- text-align: center;
- padding: 5px 0;
- background: rgba(30, 30, 47, 0.8);
- border-radius: 5px;
- margin: 8px 0;
- order: 0;
- pointer-events: none;
- }
-
- .message {
- font-size: 14px;
- color: #a5e2fe;
- text-align: center;
- padding: 10px;
- background: rgba(42, 42, 74, 0.5);
- border-radius: 8px;
- }
-
- .credit {
- font-size: 10px;
- color: #a5e2fe;
- text-align: center;
- margin-top: 10px;
- opacity: 0.7;
- }
- `;
- document.head.appendChild(style);
-
- // Add the cheat menu to the body
- document.body.insertAdjacentHTML('beforeend', cheatMenuHTML);
-
- // JavaScript functionality
- const cheatMenu = document.getElementById('cheatMenu');
- const hitList = document.getElementById('hitList');
- let isDragging = false;
- let initialX, initialY;
- let xOffset = 0;
- let yOffset = 0;
- let triedLabelAdded = false;
- let wordList = {
- "General (en)": [],
- "General (tr)": [
- "avukat",
- "kahve",
- "bebek arabası",
- "pervane",
- "berber",
- "hortum",
- "su aygırı",
- "bileklik",
- "kedi",
- "jilet",
- "karpuz",
- "uçmak",
- "buzdolabı",
- "tornavida",
- "bomba",
- "spor",
- "patlıcan",
- "yengeç",
- "bilek",
- "kart",
- "mendil",
- "oyuncak bebek",
- "dönme dolap",
- "araba",
- "terlik",
- "yeşil elma",
- "yanak",
- "mikrofon",
- "sel",
- "balerin",
- "bezelye",
- "kumsal",
- "bant",
- "orman",
- "solucan",
- "kadeh",
- "serçe",
- "vurmak",
- "kibrit kutusu",
- "tekerlek",
- "şırınga",
- "öğretmen",
- "uçak",
- "tiyatro",
- "kukla",
- "ada",
- "bıyık",
- "yağ",
- "kule",
- "yaz",
- "bira",
- "evlenmek",
- "fön makinesi",
- "uydu",
- "deli",
- "kaşık",
- "çaydanlık",
- "varil",
- "dolmuş",
- "vaşak",
- "savcı",
- "kaset",
- "düşmek",
- "hostes",
- "mercek",
- "ayı",
- "polen",
- "muhasebeci",
- "tartışmak",
- "cerrah",
- "çoban",
- "çekirdek",
- "ceylan",
- "duş",
- "tuğla",
- "kene",
- "çirkin",
- "kolsuz",
- "mantar",
- "okumak",
- "kanarya",
- "uğur böceği",
- "gece",
- "çekirge",
- "meteor",
- "bulaşık makinesi",
- "ayakkabı",
- "şempanze",
- "kepçe",
- "armut",
- "ahır",
- "kask",
- "kömür",
- "kafatası",
- "kuaför",
- "silgi",
- "okyanus",
- "kasa",
- "nohut",
- "fil",
- "arı",
- "kaşar",
- "şoför",
- "paten",
- "bakkal",
- "oyuncu",
- "basamak",
- "tembel hayvan",
- "elbise",
- "dinazor",
- "duvar",
- "menemen",
- "testere",
- "güvercin",
- "kurabiye",
- "domates",
- "öğretmek",
- "deniz anası",
- "el feneri",
- "boya fırçası",
- "ekler",
- "aşık olmak",
- "şömine",
- "hasta",
- "ren geyiği",
- "dönmek",
- "anahtarlık",
- "saat",
- "kapı",
- "dana",
- "ketçap",
- "sıcak çikolata",
- "boks",
- "çöp",
- "sörf",
- "savaşmak",
- "oyun konsolu",
- "peynir",
- "rende",
- "yalamak",
- "tencere",
- "ağaç",
- "yoğurt",
- "yosun",
- "fotoğraf makinesi",
- "manken",
- "canavar",
- "sucuklu yumurta",
- "boynuz",
- "halat",
- "içli köfte",
- "paraşüt",
- "kupa",
- "yonca",
- "mektup",
- "daire",
- "gözyaşı",
- "baston",
- "çekiç",
- "elmas",
- "ders çalışmak",
- "waffle",
- "kibrit",
- "alkışlamak",
- "inci",
- "imam bayıldı",
- "zeytinyağı",
- "ayran",
- "dondurmacı",
- "su samuru",
- "çiftçi",
- "saman",
- "tabut",
- "çarşaf",
- "yüzme havuzu",
- "kaldırım",
- "sümüklü böcek",
- "omuz",
- "kardan adam",
- "hırka",
- "gemi",
- "karga",
- "flüt",
- "havlu",
- "fındık",
- "yakmak",
- "pirinç",
- "sedye",
- "anten",
- "salam",
- "panter",
- "çığ",
- "baca",
- "itfaiyeci",
- "cep",
- "kemik",
- "ceket",
- "köpük",
- "yamuk",
- "sinema",
- "kivi",
- "temizlikçi",
- "çadır",
- "yokuş",
- "bok böceği",
- "köpek",
- "cep telefonu",
- "bayılmak",
- "pastırma",
- "dümen",
- "dalmak",
- "tünel",
- "tereyağı",
- "derin",
- "eşek",
- "sihirbaz",
- "zengin",
- "denizaltı",
- "dalga",
- "altın",
- "sirk",
- "market",
- "papaz",
- "beton",
- "elma",
- "aramak",
- "bilye",
- "gazete",
- "dalgıç",
- "odun",
- "beklemek",
- "klavye",
- "pelerin",
- "bayrak",
- "güvenlik",
- "sarma",
- "kakao",
- "fener",
- "nar",
- "şeftali",
- "çiğ köfte",
- "tarak",
- "dondurma",
- "bardak",
- "terzi",
- "çivi",
- "karnıbahar",
- "dolap",
- "et",
- "lastik",
- "saksı",
- "hemşire",
- "şelale",
- "kanca",
- "helikopter",
- "beşik",
- "ekmek",
- "kırlangıç",
- "köpek balığı",
- "ilaç",
- "tamir etmek",
- "gardırop",
- "bisiklet",
- "tırtıl",
- "pancar",
- "taze fasulye",
- "salça",
- "toz",
- "çay",
- "sülük",
- "balyoz",
- "nehir",
- "volkan",
- "kalkmak",
- "yumuşakça",
- "tavla",
- "horoz",
- "atlamak",
- "ıslak",
- "çapa",
- "taç",
- "kravat",
- "dikmek",
- "buğday",
- "dolma",
- "sabun",
- "trafik",
- "çek",
- "eczacı",
- "hindistan cevizi",
- "kavanoz",
- "kağıt",
- "böcek",
- "göbek",
- "patlamış mısır",
- "komidin",
- "gülmek",
- "bilezik",
- "lokum",
- "gün",
- "tablo",
- "aşçı",
- "kürek",
- "güzel",
- "bowling",
- "şef",
- "almak",
- "donmak",
- "votka",
- "pelikan",
- "cumhurbaşkanı",
- "ruj",
- "şahin",
- "casus",
- "adana kebap",
- "parfüm",
- "otobüs",
- "çıngırak",
- "termometre",
- "bitki",
- "bağırmak",
- "battaniye",
- "tilki",
- "pire",
- "oyuncak",
- "dürbün",
- "mıknatıs",
- "papağan",
- "boncuk",
- "kılıç balığı",
- "gökkuşağı",
- "muhabbet kuşu",
- "elektrikçi",
- "işçi",
- "cadde",
- "kaptan",
- "laptop",
- "atlet",
- "ayakkabıcı",
- "kabak",
- "eczane",
- "mandalina",
- "raket",
- "kalorifer",
- "koşmak",
- "gergedan",
- "kitaplık",
- "dirsek",
- "büyümek",
- "dambıl",
- "kaz",
- "kase",
- "göl",
- "kazmak",
- "masa",
- "ambulans",
- "pençe",
- "tesbih",
- "ayva",
- "kaçmak",
- "vatoz",
- "krampon",
- "etiket",
- "bukalemun",
- "cips",
- "yorgun",
- "sivrisinek",
- "gazeteci",
- "prens",
- "kaymak",
- "öpmek",
- "istiridye",
- "heykel",
- "doktor",
- "hediye",
- "mangal",
- "patates",
- "yılanbalığı",
- "taşımak",
- "bakteri",
- "fırın",
- "kafe",
- "ateş",
- "demirci",
- "şimşek",
- "sarışın",
- "gece lambası",
- "arı kovanı",
- "simit",
- "golf",
- "sallamak",
- "mağaza",
- "çerçeve",
- "sıkmak",
- "dökmek",
- "güneş gözlüğü",
- "dudak",
- "tüfek",
- "tatmak",
- "yıkamak",
- "nane",
- "dizlik",
- "biftek",
- "mimar",
- "oda",
- "salon",
- "çilingir",
- "lazanya",
- "kayak",
- "içmek",
- "ahtapot",
- "pist",
- "robot",
- "akrep",
- "tel",
- "omlet",
- "diken",
- "televizyon",
- "sokak",
- "tuz",
- "balık",
- "avize",
- "portakal suyu",
- "denizci",
- "değirmen",
- "tutulma",
- "şampanya",
- "kasiyer",
- "kestane",
- "maydanoz",
- "büyükanne",
- "kanat",
- "yarasa",
- "tavan",
- "bağlamak",
- "pati",
- "polis",
- "kalemtraş",
- "kaydırak",
- "baharat",
- "kahvaltı",
- "pirana",
- "lamba",
- "yazar",
- "leğen",
- "steteskop",
- "ateş böceği",
- "orak",
- "domuz",
- "boksör",
- "şair",
- "deniz atı",
- "kış",
- "kimyager",
- "bit",
- "vampir",
- "cüce",
- "pazarcı",
- "bina",
- "mide",
- "ananas",
- "ressam",
- "siren",
- "çikolata",
- "zırh",
- "greyfurt",
- "noel",
- "jet",
- "yaban arısı",
- "kutu",
- "kanguru",
- "uçurtma",
- "timsah",
- "kafa",
- "baykuş",
- "fare",
- "fok balığı",
- "yelpaze",
- "prenses",
- "künefe",
- "tantuni",
- "helva",
- "yağmur",
- "tutmak",
- "diz",
- "kameraman",
- "çorap",
- "üzgün",
- "salyangoz",
- "balkon",
- "asit",
- "geçmek",
- "kavurma",
- "bilgisayar mühendisi",
- "korkuluk",
- "kumanda",
- "bankacı",
- "direksiyon",
- "toprak",
- "viski",
- "memur",
- "panda",
- "patates kızartması",
- "sigara böreği",
- "havalimanı",
- "konuşmak",
- "tarla",
- "deney tüpü",
- "yemek yapmak",
- "kütüphane",
- "fabrika",
- "lale",
- "korna",
- "dansçı",
- "yemek",
- "küpe",
- "bikini",
- "kunduz",
- "kano",
- "ağaçkakan",
- "ornitorenk",
- "tuzak",
- "kazanmak",
- "bar",
- "boyamak",
- "tekne",
- "bez",
- "okçu",
- "lahmacun",
- "kesmek",
- "kök",
- "flamingo",
- "dilenci",
- "fermuar",
- "kamyon",
- "kahverengi",
- "yol",
- "kumpir",
- "hamburger",
- "katır",
- "tıklamak",
- "sehpa",
- "vagon",
- "basketbolcu",
- "rimel",
- "makyaj",
- "gazoz",
- "gül",
- "bağırsak",
- "satır",
- "dinlemek",
- "kısır",
- "hayalet",
- "duymak",
- "sprey",
- "küp",
- "tırpan",
- "burun",
- "koç",
- "havalanmak",
- "tuvalet",
- "geyik",
- "süt",
- "sütlaç",
- "atom",
- "ütü",
- "stadyum",
- "okul",
- "sincap",
- "otel",
- "mirket",
- "saksafon",
- "taksi",
- "far",
- "yıldız",
- "tavşan",
- "kusmak",
- "zarf",
- "öksürmek",
- "komedyen",
- "hap",
- "şerit",
- "beyin",
- "dans etmek",
- "çilek",
- "koala",
- "askılık",
- "erkek kardeş",
- "haç",
- "hazine",
- "bırakmak",
- "şarkıcı",
- "lolipop",
- "tırmık",
- "akvaryum",
- "tarantula",
- "huni",
- "gözlük",
- "bamya",
- "kurdele",
- "girmek",
- "gözleme",
- "zehir",
- "kulak",
- "otopark",
- "kokarca",
- "kapak",
- "kaybetmek",
- "kafes",
- "yorgan",
- "jaguar",
- "hakim",
- "ikizler",
- "defter",
- "çanta",
- "süpürge",
- "parti",
- "antilop",
- "oğul",
- "zaman",
- "şapka",
- "davul",
- "sünger",
- "balıkçı",
- "porsuk",
- "abajur",
- "masa tenisi",
- "çizgi",
- "uçurum",
- "nugget",
- "leopar",
- "dövme",
- "katil balina",
- "bale",
- "kuru fasulye",
- "kuyruk",
- "pantolon",
- "tırmanmak",
- "bluz",
- "kraliçe",
- "meyve suyu",
- "monitör",
- "aslan",
- "kıvırcık",
- "şok",
- "çatı",
- "saray",
- "mühendis",
- "kırkayak",
- "ampul",
- "yılan",
- "karıncayiyen",
- "yatmak",
- "musluk",
- "müdür",
- "mercimek çorbası",
- "gömlek",
- "deprem",
- "tarçın",
- "sürmek",
- "geçit",
- "sepet",
- "turşu",
- "rakun",
- "muz",
- "çıkarmak",
- "pizzacı",
- "koklamak",
- "şeker",
- "şort",
- "trafik ışığı",
- "daktilo",
- "hamster",
- "kiremit",
- "yat",
- "terlemek",
- "öğrenci",
- "ev",
- "çöp kutusu",
- "krep",
- "el",
- "iskelet",
- "pipo",
- "köfte",
- "sürünmek",
- "topuklu ayakkabı",
- "müzisyen",
- "çene",
- "börek",
- "cam",
- "dedektif",
- "kulübe",
- "zurna",
- "çiçekçi",
- "tahta",
- "dergi",
- "pastacı",
- "puding",
- "kokoreç",
- "arkadaş",
- "tebeşir",
- "kulaklık",
- "yazıcı",
- "melek",
- "kalp",
- "oturak",
- "ısı",
- "gölet",
- "madeni para",
- "su",
- "ıspanak",
- "ekran",
- "şövalye",
- "balon",
- "papatya",
- "ocak",
- "açmak",
- "göstermek",
- "parmak",
- "balkabağı",
- "bıldırcın",
- "ördek",
- "bebek bezi",
- "biber",
- "puma",
- "yaprak",
- "emlakçı",
- "sosisli",
- "koş",
- "kırtasiyeci",
- "oy sandığı",
- "çocuk",
- "oklava",
- "posta kutusu",
- "silmek",
- "nargile",
- "oyun oynamak",
- "sırtlan",
- "çamaşır makinesi",
- "dart",
- "kütüphaneci",
- "martı",
- "sarılmak",
- "sıcak",
- "su böreği",
- "kabul etmek",
- "pipet",
- "yüzme",
- "patlamak",
- "tıpa",
- "köstebek",
- "halı",
- "sevmek",
- "limon",
- "direk",
- "kalemlik",
- "çimen",
- "kaza",
- "kaktüs",
- "deniz",
- "midye",
- "palmiye",
- "çizme",
- "bakıcı",
- "fotoğrafçı",
- "saç",
- "ay",
- "metro",
- "güçlü",
- "salata",
- "küvet",
- "lemur",
- "yapıştırmak",
- "sandalye",
- "bal",
- "park",
- "kiraz",
- "evlilik",
- "sandık",
- "kırık",
- "tepsi",
- "açacak",
- "etek",
- "kumru",
- "marangoz",
- "sakız",
- "ranza",
- "düşünmek",
- "erik",
- "basketbol",
- "fotoğraf çekmek",
- "sulamak",
- "demlik",
- "temizlemek",
- "ağız",
- "pencere",
- "harita",
- "kasırga",
- "ejderha",
- "hamsi",
- "karnıyarık",
- "kolye",
- "çam ağacı",
- "bilim adamı",
- "evren",
- "tavus kuşu",
- "köprü",
- "kum",
- "youtuber",
- "şurup",
- "kilise",
- "teleskop",
- "deniz yıldızı",
- "abaküs",
- "kapı kolu",
- "balina",
- "paket",
- "meşale",
- "külot",
- "eldiven",
- "modem",
- "sandviç",
- "zayıf",
- "motorsiklet",
- "suşi",
- "tramvay",
- "piyano",
- "kablo",
- "kirpi",
- "kelebek",
- "kasap",
- "penguen",
- "barmen",
- "aile",
- "garson",
- "ayak",
- "kurbağa",
- "fasulye",
- "peygamber devesi",
- "telefon",
- "tırnak",
- "mızrak",
- "tost makinesi",
- "raf",
- "kel",
- "poğaça",
- "karanfil",
- "dadı",
- "kanepe",
- "pirzola",
- "bulgur pilavı",
- "kaplan",
- "pırasa",
- "mürekkep",
- "taş",
- "kurtarmak",
- "sinek",
- "sakal",
- "yastık",
- "anne",
- "hurma",
- "mezarlık",
- "duman",
- "kamp",
- "satmak",
- "postacı",
- "brokoli",
- "hastane",
- "kürdan",
- "salatalık",
- "merdiven",
- "maske",
- "dokunmak",
- "spiker",
- "şöför",
- "mayonez",
- "çorba",
- "kabuk",
- "fincan",
- "sırt",
- "kıta",
- "oduncu",
- "tamirci",
- "izlemek",
- "çakal",
- "kırmak",
- "kostüm",
- "termos",
- "sırt çantası",
- "çakmak",
- "yatak",
- "kuzu",
- "soğuk",
- "palyaço",
- "kaburga",
- "şemsiye",
- "kereviz",
- "yüz",
- "dövüşmek",
- "ödemek"
- ],
- "Custom": []
- };
- const autoGuessCheckbox = document.getElementById('autoGuess');
- const autoGuessSpeedContainer = document.getElementById('autoGuessSpeedContainer');
- const autoGuessSpeed = document.getElementById('autoGuessSpeed');
- const speedValue = document.getElementById('speedValue');
- let autoGuessInterval = null;
-
- // Draggable functionality
- cheatMenu.addEventListener('mousedown', startDragging);
- document.addEventListener('mousemove', drag);
- document.addEventListener('mouseup', stopDragging);
-
- function startDragging(e) {
- if (e.target.tagName !== 'INPUT' && e.target.tagName !== 'BUTTON') {
- initialX = e.clientX - xOffset;
- initialY = e.clientY - yOffset;
- isDragging = true;
- cheatMenu.classList.add('dragging');
- }
- }
-
- function drag(e) {
- if (isDragging) {
- e.preventDefault();
- const currentX = e.clientX - initialX;
- const currentY = e.clientY - initialY;
- xOffset = currentX;
- yOffset = currentY;
- setTranslate(currentX, currentY, cheatMenu);
- }
- }
-
- function setTranslate(xPos, yPos, el) {
- el.style.transform = `translate(${xPos}px, ${yPos}px)`;
- }
-
- function stopDragging() {
- isDragging = false;
- cheatMenu.classList.remove('dragging');
- }
-
- // Show/hide Auto Guess Speed slider and start/stop auto guessing
- autoGuessCheckbox.addEventListener('change', (e) => {
- autoGuessSpeedContainer.style.display = e.target.checked ? 'flex' : 'none';
- if (!e.target.checked) {
- stopAutoGuess();
- }
- });
-
- // Update speed display and slider track when slider changes
- autoGuessSpeed.addEventListener('input', (e) => {
- const speed = e.target.value;
- const min = parseInt(e.target.min);
- const max = parseInt(e.target.max);
- const progress = ((speed - min) / (max - min)) * 100;
- e.target.parentElement.querySelector('.slider-track').style.setProperty('--slider-progress', `${progress}%`);
- speedValue.textContent = speed >= 1000 ? `${speed / 1000}s` : `${speed}ms`;
- if (autoGuessCheckbox.checked) {
- stopAutoGuess();
- startAutoGuess();
- }
- });
-
- // Initial speed display and slider track
- const initialSpeed = autoGuessSpeed.value;
- const minSpeed = parseInt(autoGuessSpeed.min);
- const maxSpeed = parseInt(autoGuessSpeed.max);
- const initialProgress = ((initialSpeed - minSpeed) / (maxSpeed - minSpeed)) * 100;
- autoGuessSpeed.parentElement.querySelector('.slider-track').style.setProperty('--slider-progress', `${initialProgress}%`);
- speedValue.textContent = initialSpeed >= 1000 ? `${initialSpeed / 1000}s` : `${initialSpeed}ms`;
-
- // Auto Guess functionality
- function startAutoGuess() {
- if (!autoGuessCheckbox.checked) return;
- stopAutoGuess();
- const speed = parseInt(autoGuessSpeed.value);
- autoGuessInterval = setInterval(() => {
- const buttons = hitList.querySelectorAll('button:not(.tried)');
- if (buttons.length > 0 && window.game && window.game._socket) {
- const word = buttons[0].textContent;
- buttons[0].classList.add('tried');
- window.game._socket.emit(13, window.game._codigo, word);
-
- if (!triedLabelAdded && hitList.querySelectorAll('button.tried').length === 1) {
- const triedLabel = document.createElement('div');
- triedLabel.classList.add('tried-label');
- triedLabel.textContent = 'Tried Words';
- hitList.appendChild(triedLabel);
- triedLabelAdded = true;
- }
- hitList.appendChild(buttons[0]);
- }
- }, speed);
- }
-
- function stopAutoGuess() {
- if (autoGuessInterval) {
- clearInterval(autoGuessInterval);
- autoGuessInterval = null;
- }
- }
-
- // Mark buttons as tried
- hitList.addEventListener('click', (e) => {
- if (e.target.tagName === 'BUTTON' && !e.target.classList.contains('tried')) {
- const button = e.target;
- button.classList.add('tried');
-
- if (!triedLabelAdded && hitList.querySelectorAll('button.tried').length === 1) {
- const triedLabel = document.createElement('div');
- triedLabel.classList.add('tried-label');
- triedLabel.textContent = 'Tried Words';
- hitList.appendChild(triedLabel);
- triedLabelAdded = true;
- }
-
- window.game._socket.emit(13, window.game._codigo, button.textContent);
- hitList.appendChild(button);
- }
- });
-
- // Custom Load Word List checkbox toggle
- const customLoadCheckbox = document.getElementById('customLoad');
- const loadWordListContainer = document.getElementById('loadWordListContainer');
- customLoadCheckbox.addEventListener('change', (e) => {
- loadWordListContainer.style.display = e.target.checked ? 'flex' : 'none';
- updateHitList(guessPatternInput.value.trim()); // Update hit list based on current pattern
- });
-
- // Handle file upload and add words to wordList.custom
- const fileInput = document.getElementById('wordList');
- fileInput.addEventListener('change', (e) => {
- const file = e.target.files[0];
- if (file) {
- const reader = new FileReader();
- reader.onload = function(event) {
- const text = event.target.result;
- wordList["Custom"] = text.split('\n').map(word => word.trim()).filter(word => word.length > 0);
- alert(`Loaded ${wordList["Custom"].length} words into custom list from ${file.name}`);
- updateHitList(guessPatternInput.value.trim());
- };
- reader.readAsText(file);
- }
- });
-
- // Auto guess functionality
- const guessPatternInput = document.getElementById('guessPattern');
- guessPatternInput.addEventListener('input', (e) => {
- const pattern = e.target.value.trim();
- updateHitList(pattern);
- });
-
- function updateHitList(pattern) {
- hitList.innerHTML = '';
- const activeList = customLoadCheckbox.checked || !window.game || !window.game._dadosSala || !window.game._dadosSala.tema
- ? wordList["Custom"]
- : wordList[window.game._dadosSala.tema] || [];
-
- if (!pattern) {
- if (activeList.length === 0) {
- const message = document.createElement('div');
- message.classList.add('message');
- message.textContent = customLoadCheckbox.checked ? 'Load a custom word list first' : 'No words available for this theme';
- hitList.appendChild(message);
- } else {
- activeList.forEach(word => {
- const button = document.createElement('button');
- button.textContent = word;
- hitList.appendChild(button);
- });
- }
- return;
- }
-
- const regexPattern = pattern
- .split('')
- .map(char => (char === '_' ? '.' : char))
- .join('')
- .replace(/ /g, '');
- const regex = new RegExp(`^${regexPattern}$`, 'u');
- const matches = activeList.filter(word => regex.test(word));
-
- if (matches.length === 0) {
- const message = document.createElement('div');
- message.classList.add('message');
- message.textContent = 'No matches found';
- hitList.appendChild(message);
- } else {
- matches.forEach(word => {
- const button = document.createElement('button');
- button.textContent = word;
- hitList.appendChild(button);
- });
- }
- }
-
- // Socket event integration
- const checkGame = setInterval(() => {
- if (window.game && window.game._socket) {
- clearInterval(checkGame);
- window.game._socket.on(30, (hint, hintNumber) => {
- hint = String(hint).replace(/,/g, '');
- guessPatternInput.value = hint;
- updateHitList(hint); // Update hit list with new hint
- if (autoGuessCheckbox.checked) {
- startAutoGuess();
- }
- });
- window.game._socket.on(19, (roundNumber, isGameOver) => {
- guessPatternInput.value = '';
- stopAutoGuess();
- updateHitList(''); // Clear hit list when round ends
- });
- }
- }, 100);