🤖 Robot Question / Réponse (IA)

  • Auteur de la discussion ZZZ
  • Date de début
ZZZ
Passionné
Messages
1 400
Fofocoins
7 662
Personnalisation du groupe
Personnalisation pseudo
JavaScript:
// ==UserScript==
// @name         Craftnite.io cheat
// @namespace    http://tampermonkey.net/
// @version      1.3
// @description  try to take over the world!
// @author       You
// @match        https://craftnite.io/
// @icon         https://www.google.com/s2/favicons?sz=64&domain=craftnite.io
// @grant        none
// ==/UserScript==

(function () {
    "use strict";
    var spam_msg = '';
    var spam_lock = 'False';
    var chat_opened = false;
    var spam_count = 0;
    var displayInput = true;
    var getSpamInput = '';
    var SpamInput = document.createElement("input");
    var ValidButton1 = document.createElement("button");
    var divClass = document.createElement('div');
    var ExplainText2 = document.createElement('p');
    var discordLink = document.createElement('a');
    var cheatKick = ''
    document.getElementById("craftnite-io_300x250").remove();
    document.getElementById("cross-promo").remove();
    var FlyEnabled = false
    var BedrockEnabled = false
    divClass.style.display = 'block';
    divClass.id = "MyDIV";
    document.body.appendChild(divClass);
    function changeColorAtHover(button, color, returncolor) {
        $(document).ready(function () {
            $(button).hover(function () {
                $(button).css('background', color);
            },
                function () {
                    $(button).css('background', returncolor);
                });
        });
    }
    function modifyHTML() {
        ValidButton1.innerHTML = "valid"
        ExplainText2.innerHTML = "To spam, you must activate the spam button and then hold the 'enter' key for as long as you want.<br /><br />This script was made by Raylazzz and was published by Raylazzz, so for those who would like to use it, please respect me in the game, at least in recognition of my work. 😂<br /><br /><br />new update :<br /><br>The bedrock-cheat, useful to go under the bedrock :<br />To use it, you must, first, activate the option 'En / Disable bedrock cheat' then, go to the level of the bedrock. Here you can press Shift to go down and then Space to go up. To stabilize yourself, you must press Shift and then Space once.<br /><br />Thank you for being so many to use my cheat and if you want new features, send me a message on my discord :<br /><br />"
        ExplainText2.style = "font-family: Madera; font-size: 13px; background-color: black; width: 300px; top: 0px; right: 15px; color: white; border-radius: 15px; border-color: black; padding: 15px; position: absolute; z-index: 100;"
        discordLink.href = "https://discord.com/channels/1020394306265153576/1020394306265153579";
        discordLink.style = "color: darkcyan; overflow-wrap: break-word; cursor: pointer; }";
        discordLink.innerHTML = "https://discord.com/channels/1020394306265153576/1020394306265153579";
        discordLink.target = "blank";
        SpamInput.className = 'Spam input';
        SpamInput.placeholder = "Spam message...";
        SpamInput.addEventListener('keydown', function (e) {
            if (e.key != "Backspace") e.preventDefault();
            if (e.key.length == 1) SpamInput.value += e.key;
        });
        ValidButton1.style = "color: white; top:15px;left:230px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        SpamInput.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;border-radius: 15px 15px 15px 15px;";
        ValidButton1.onclick = "myFunction()";
        ValidButton1.style.backgroundColor = "white";
        changeColorAtHover(ValidButton1, '#05d1ff', 'black');
        ValidButton1.style.backgroundColor = "black";
        document.getElementById('MyDIV').appendChild(ExplainText2);
        ExplainText2.appendChild(discordLink);
        ExplainText2.innerHTML += "<br /><br />Enjoy the cheat !!";
        document.getElementById('MyDIV').appendChild(SpamInput);
        document.getElementById('MyDIV').appendChild(ValidButton1);
        document.getElementById('MyDIV').removeChild(SpamInput);
        getSpamInput = SpamInput.value;
        spam_msg = getSpamInput;
        console.log(getSpamInput);
        displayInput = false;
        ValidButton1.innerHTML = "change spam message"
        ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        ValidButton1.style.backgroundColor = "black";
    }
    function HTMLButtonSpam() {
        ValidButton1.onclick = function () {
            if (displayInput == true) {
                document.getElementById('MyDIV').removeChild(SpamInput);
                getSpamInput = SpamInput.value;
                if (getSpamInput.slice(0, 1) != '/') {
                    spam_msg = getSpamInput;
                } else {
                    cheatKick = getSpamInput.slice(1, getSpamInput.length)
                    console.log(cheatKick);
                }
                displayInput = false;
                ValidButton1.innerHTML = "change spam message"
                ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
                ValidButton1.style.backgroundColor = "white";
            } else if (displayInput == false) {
                ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:240px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
                document.getElementById('MyDIV').appendChild(SpamInput);
                ValidButton1.innerHTML = "submit"
                document.getElementById('MyDIV').appendChild(ValidButton1);
                displayInput = true;
            }
        };
    }
    function keyboardManagement() {
        document.onkeydown = function (m) {
            if (m.key == "Enter") {
                if (chat_opened == false) {
                    chat_opened = true;
                } else if (chat_opened == true) {
                    chat_opened = false;
                }
                if (spam_lock == 'True') {
                    var elt = document.querySelector('input');
                    elt.value = '' + spam_count + ' ' + spam_msg;
                } else {
                    null;
                }
            }
            if (cheatKick == playerName) {
                alert(playerName + ', you were kicked of the game. Reason : Abusing cheat.');
                window.close();
            }
            if (chat_opened == true) {
                spam_count++
            }
            if (FlyEnabled == true) {
                G.CONFIG.a143 = 100
            } else if (FlyEnabled == false) {
                G.CONFIG.a143 = 0
            }
            if (BedrockEnabled == true) {
                if (m.key == " ") G.CONFIG.environmentOceanFloorHeight = 260;
                if (m.key == "Shift") {
                    G.CONFIG.environmentOceanFloorHeight = -10000;
                } else {
                    G.CONFIG.environmentOceanFloorHeight = 260;
                }
            } else if (BedrockEnabled == false) {
                G.CONFIG.environmentOceanFloorHeight = 260
            }
        }
    }
    function HTMLlabels() {
        var HTMLLabelsButton1 = document.createElement('button');
        var HTMLLabelsButton1Checked = false
        HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✖';
        HTMLLabelsButton1.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:75px; left:15px; position:absolute; z-index:99999; padding:15px; cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton1, '#05d1ff', 'black');
        HTMLLabelsButton1.onclick = function () {
            if (HTMLLabelsButton1Checked == true) {
                changeColorAtHover(HTMLLabelsButton1, '#05d1ff', "black");
                HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✖';
                G.CONFIG.a143 = 0
                FlyEnabled = false
                HTMLLabelsButton1Checked = false;
            } else if (HTMLLabelsButton1Checked == false) {
                changeColorAtHover(HTMLLabelsButton1, '#05d1ff', '#05d1ff');
                HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✔';
                G.CONFIG.a143 = 100
                FlyEnabled = true
                HTMLLabelsButton1Checked = true;
            }
        }

        var HTMLLabelsButton5 = document.createElement('button');
        var HTMLLabelsButton5Checked = false
        HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✖';
        HTMLLabelsButton5.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:195px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton5, '#05d1ff', 'black');
        HTMLLabelsButton5.onclick = function () {
            if (HTMLLabelsButton5Checked == true) {
                changeColorAtHover(HTMLLabelsButton5, '#05d1ff', "black");
                HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✖';
                G.CONFIG.environmentOceanFloorHeight = 260
                BedrockEnabled = false
                HTMLLabelsButton5Checked = false;
            } else if (HTMLLabelsButton5Checked == false) {
                changeColorAtHover(HTMLLabelsButton5, '#05d1ff', '#05d1ff');
                HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✔';
                G.CONFIG.environmentOceanFloorHeight = 0
                BedrockEnabled = true
                HTMLLabelsButton5Checked = true;
            }
        }
        document.getElementById('MyDIV').appendChild(HTMLLabelsButton5);


        document.getElementById('MyDIV').appendChild(HTMLLabelsButton1);
        var HTMLLabelsButton2 = document.createElement('button');
        var HTMLLabelsButton2Checked = false
        HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✖';
        HTMLLabelsButton2.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:135px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton2, '#05d1ff', 'black');
        HTMLLabelsButton2.onclick = function () {
            spam_count = 0;
            if (HTMLLabelsButton2Checked == true) {
                changeColorAtHover(HTMLLabelsButton2, '#05d1ff', 'black');
                HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✖';
                HTMLLabelsButton2Checked = false;
            } else if (HTMLLabelsButton2Checked == false) {
                changeColorAtHover(HTMLLabelsButton2, '#05d1ff', '#05d1ff');
                HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✔';
                HTMLLabelsButton2Checked = true;
            }
            if (spam_lock == 'True') {
                spam_lock = 'False';
            } else if (spam_lock == 'False') {
                spam_lock = 'True';
            }
        }
        document.getElementById('MyDIV').appendChild(HTMLLabelsButton2);
    }
    function hideButtonsButton() {
        var HTMLLabelsButton3 = document.createElement('button');
        var HTMLLabelsButton3Checked = false
        HTMLLabelsButton3.innerHTML = '⬅';
        HTMLLabelsButton3.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:320px;height: 100px ;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        HTMLLabelsButton3.onclick = function () {
            if (HTMLLabelsButton3Checked == true) {
                divClass.style.display = 'block';
                changeColorAtHover(HTMLLabelsButton3, '#05d1ff', 'black');
                HTMLLabelsButton3.innerHTML = '⬅';
                HTMLLabelsButton3Checked = false
            } else if (HTMLLabelsButton3Checked == false) {
                divClass.style.display = 'none';
                changeColorAtHover(HTMLLabelsButton3, '#05d1ff', '#05d1ff');
                HTMLLabelsButton3.innerHTML = '➡';
                HTMLLabelsButton3Checked = true
            }
        }
        document.body.appendChild(HTMLLabelsButton3);

    }
    modifyHTML();
    HTMLlabels();
    HTMLButtonSpam();
    hideButtonsButton();
    keyboardManagement();
})();

J'ai ce code, comment faire pour que tous le texte du div "document.getElementById('MyDIV')", à la sélection, aient une autre couleur que cet éternel bleu ennuyeux?
 
Fofobot 🤖
Assistant virtuel
Donateur 🤲
Messages
3 009
Fofocoins
62 845
JavaScript:
// ==UserScript==
// @name         Craftnite.io cheat
// @namespace    http://tampermonkey.net/
// @version      1.3
// @description  try to take over the world!
// @author       You
// @match        https://craftnite.io/
// @icon         https://www.google.com/s2/favicons?sz=64&domain=craftnite.io
// @grant        none
// ==/UserScript==

(function () {
    "use strict";
    var spam_msg = '';
    var spam_lock = 'False';
    var chat_opened = false;
    var spam_count = 0;
    var displayInput = true;
    var getSpamInput = '';
    var SpamInput = document.createElement("input");
    var ValidButton1 = document.createElement("button");
    var divClass = document.createElement('div');
    var ExplainText2 = document.createElement('p');
    var discordLink = document.createElement('a');
    var cheatKick = ''
    document.getElementById("craftnite-io_300x250").remove();
    document.getElementById("cross-promo").remove();
    var FlyEnabled = false
    var BedrockEnabled = false
    divClass.style.display = 'block';
    divClass.id = "MyDIV";
    document.body.appendChild(divClass);
    function changeColorAtHover(button, color, returncolor) {
        $(document).ready(function () {
            $(button).hover(function () {
                $(button).css('background', color);
            },
                function () {
                    $(button).css('background', returncolor);
                });
        });
    }
    function modifyHTML() {
        ValidButton1.innerHTML = "valid"
        ExplainText2.innerHTML = "To spam, you must activate the spam button and then hold the 'enter' key for as long as you want.<br /><br />This script was made by Raylazzz and was published by Raylazzz, so for those who would like to use it, please respect me in the game, at least in recognition of my work. 😂<br /><br /><br />new update :<br /><br>The bedrock-cheat, useful to go under the bedrock :<br />To use it, you must, first, activate the option 'En / Disable bedrock cheat' then, go to the level of the bedrock. Here you can press Shift to go down and then Space to go up. To stabilize yourself, you must press Shift and then Space once.<br /><br />Thank you for being so many to use my cheat and if you want new features, send me a message on my discord :<br /><br />"
        ExplainText2.style = "font-family: Madera; font-size: 13px; background-color: black; width: 300px; top: 0px; right: 15px; color: white; border-radius: 15px; border-color: black; padding: 15px; position: absolute; z-index: 100;"
        discordLink.href = "https://discord.com/channels/1020394306265153576/1020394306265153579";
        discordLink.style = "color: darkcyan; overflow-wrap: break-word; cursor: pointer; }";
        discordLink.innerHTML = "https://discord.com/channels/1020394306265153576/1020394306265153579";
        discordLink.target = "blank";
        SpamInput.className = 'Spam input';
        SpamInput.placeholder = "Spam message...";
        SpamInput.addEventListener('keydown', function (e) {
            if (e.key != "Backspace") e.preventDefault();
            if (e.key.length == 1) SpamInput.value += e.key;
        });
        ValidButton1.style = "color: white; top:15px;left:230px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        SpamInput.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;border-radius: 15px 15px 15px 15px;";
        ValidButton1.onclick = "myFunction()";
        ValidButton1.style.backgroundColor = "white";
        changeColorAtHover(ValidButton1, '#05d1ff', 'black');
        ValidButton1.style.backgroundColor = "black";
        document.getElementById('MyDIV').appendChild(ExplainText2);
        ExplainText2.appendChild(discordLink);
        ExplainText2.innerHTML += "<br /><br />Enjoy the cheat !!";
        document.getElementById('MyDIV').appendChild(SpamInput);
        document.getElementById('MyDIV').appendChild(ValidButton1);
        document.getElementById('MyDIV').removeChild(SpamInput);
        getSpamInput = SpamInput.value;
        spam_msg = getSpamInput;
        console.log(getSpamInput);
        displayInput = false;
        ValidButton1.innerHTML = "change spam message"
        ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        ValidButton1.style.backgroundColor = "black";
    }
    function HTMLButtonSpam() {
        ValidButton1.onclick = function () {
            if (displayInput == true) {
                document.getElementById('MyDIV').removeChild(SpamInput);
                getSpamInput = SpamInput.value;
                if (getSpamInput.slice(0, 1) != '/') {
                    spam_msg = getSpamInput;
                } else {
                    cheatKick = getSpamInput.slice(1, getSpamInput.length)
                    console.log(cheatKick);
                }
                displayInput = false;
                ValidButton1.innerHTML = "change spam message"
                ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
                ValidButton1.style.backgroundColor = "white";
            } else if (displayInput == false) {
                ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:240px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
                document.getElementById('MyDIV').appendChild(SpamInput);
                ValidButton1.innerHTML = "submit"
                document.getElementById('MyDIV').appendChild(ValidButton1);
                displayInput = true;
            }
        };
    }
    function keyboardManagement() {
        document.onkeydown = function (m) {
            if (m.key == "Enter") {
                if (chat_opened == false) {
                    chat_opened = true;
                } else if (chat_opened == true) {
                    chat_opened = false;
                }
                if (spam_lock == 'True') {
                    var elt = document.querySelector('input');
                    elt.value = '' + spam_count + ' ' + spam_msg;
                } else {
                    null;
                }
            }
            if (cheatKick == playerName) {
                alert(playerName + ', you were kicked of the game. Reason : Abusing cheat.');
                window.close();
            }
            if (chat_opened == true) {
                spam_count++
            }
            if (FlyEnabled == true) {
                G.CONFIG.a143 = 100
            } else if (FlyEnabled == false) {
                G.CONFIG.a143 = 0
            }
            if (BedrockEnabled == true) {
                if (m.key == " ") G.CONFIG.environmentOceanFloorHeight = 260;
                if (m.key == "Shift") {
                    G.CONFIG.environmentOceanFloorHeight = -10000;
                } else {
                    G.CONFIG.environmentOceanFloorHeight = 260;
                }
            } else if (BedrockEnabled == false) {
                G.CONFIG.environmentOceanFloorHeight = 260
            }
        }
    }
    function HTMLlabels() {
        var HTMLLabelsButton1 = document.createElement('button');
        var HTMLLabelsButton1Checked = false
        HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✖';
        HTMLLabelsButton1.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:75px; left:15px; position:absolute; z-index:99999; padding:15px; cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton1, '#05d1ff', 'black');
        HTMLLabelsButton1.onclick = function () {
            if (HTMLLabelsButton1Checked == true) {
                changeColorAtHover(HTMLLabelsButton1, '#05d1ff', "black");
                HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✖';
                G.CONFIG.a143 = 0
                FlyEnabled = false
                HTMLLabelsButton1Checked = false;
            } else if (HTMLLabelsButton1Checked == false) {
                changeColorAtHover(HTMLLabelsButton1, '#05d1ff', '#05d1ff');
                HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✔';
                G.CONFIG.a143 = 100
                FlyEnabled = true
                HTMLLabelsButton1Checked = true;
            }
        }

        var HTMLLabelsButton5 = document.createElement('button');
        var HTMLLabelsButton5Checked = false
        HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✖';
        HTMLLabelsButton5.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:195px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton5, '#05d1ff', 'black');
        HTMLLabelsButton5.onclick = function () {
            if (HTMLLabelsButton5Checked == true) {
                changeColorAtHover(HTMLLabelsButton5, '#05d1ff', "black");
                HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✖';
                G.CONFIG.environmentOceanFloorHeight = 260
                BedrockEnabled = false
                HTMLLabelsButton5Checked = false;
            } else if (HTMLLabelsButton5Checked == false) {
                changeColorAtHover(HTMLLabelsButton5, '#05d1ff', '#05d1ff');
                HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✔';
                G.CONFIG.environmentOceanFloorHeight = 0
                BedrockEnabled = true
                HTMLLabelsButton5Checked = true;
            }
        }
        document.getElementById('MyDIV').appendChild(HTMLLabelsButton5);


        document.getElementById('MyDIV').appendChild(HTMLLabelsButton1);
        var HTMLLabelsButton2 = document.createElement('button');
        var HTMLLabelsButton2Checked = false
        HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✖';
        HTMLLabelsButton2.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:135px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton2, '#05d1ff', 'black');
        HTMLLabelsButton2.onclick = function () {
            spam_count = 0;
            if (HTMLLabelsButton2Checked == true) {
                changeColorAtHover(HTMLLabelsButton2, '#05d1ff', 'black');
                HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✖';
                HTMLLabelsButton2Checked = false;
            } else if (HTMLLabelsButton2Checked == false) {
                changeColorAtHover(HTMLLabelsButton2, '#05d1ff', '#05d1ff');
                HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✔';
                HTMLLabelsButton2Checked = true;
            }
            if (spam_lock == 'True') {
                spam_lock = 'False';
            } else if (spam_lock == 'False') {
                spam_lock = 'True';
            }
        }
        document.getElementById('MyDIV').appendChild(HTMLLabelsButton2);
    }
    function hideButtonsButton() {
        var HTMLLabelsButton3 = document.createElement('button');
        var HTMLLabelsButton3Checked = false
        HTMLLabelsButton3.innerHTML = '⬅';
        HTMLLabelsButton3.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:320px;height: 100px ;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        HTMLLabelsButton3.onclick = function () {
            if (HTMLLabelsButton3Checked == true) {
                divClass.style.display = 'block';
                changeColorAtHover(HTMLLabelsButton3, '#05d1ff', 'black');
                HTMLLabelsButton3.innerHTML = '⬅';
                HTMLLabelsButton3Checked = false
            } else if (HTMLLabelsButton3Checked == false) {
                divClass.style.display = 'none';
                changeColorAtHover(HTMLLabelsButton3, '#05d1ff', '#05d1ff');
                HTMLLabelsButton3.innerHTML = '➡';
                HTMLLabelsButton3Checked = true
            }
        }
        document.body.appendChild(HTMLLabelsButton3);

    }
    modifyHTML();
    HTMLlabels();
    HTMLButtonSpam();
    hideButtonsButton();
    keyboardManagement();
})();

J'ai ce code, comment faire pour que tous le texte du div "document.getElementById('MyDIV')", à la sélection, aient une autre couleur que cet éternel bleu ennuyeux?
Pour changer la couleur du texte du div `document.getElementById('MyDIV')`, vous pouvez ajouter la propriété `color` à son style CSS. Par exemple, pour mettre le texte en blanc, vous pouvez ajouter la ligne suivante :

```javascript
document.getElementById('MyDIV').style.color = 'white';
```

Placer cette ligne de code dans la fonction `modifyHTML()` permettra de changer la couleur du texte dès que le div est créé.
 
ZZZ
Passionné
Messages
1 400
Fofocoins
7 662
Personnalisation du groupe
Personnalisation pseudo
JavaScript:
// ==UserScript==
// @name         Craftnite.io cheat
// @namespace    http://tampermonkey.net/
// @version      1.3
// @description  try to take over the world!
// @author       You
// @match        https://craftnite.io/
// @icon         https://www.google.com/s2/favicons?sz=64&domain=craftnite.io
// @grant        none
// ==/UserScript==

(function () {
    "use strict";
    var spam_msg = '';
    var spam_lock = 'False';
    var chat_opened = false;
    var spam_count = 0;
    var displayInput = true;
    var getSpamInput = '';
    var SpamInput = document.createElement("input");
    var ValidButton1 = document.createElement("button");
    var divClass = document.createElement('div');
    var ExplainText2 = document.createElement('p');
    var discordLink = document.createElement('a');
    var cheatKick = ''
    document.getElementById("craftnite-io_300x250").remove();
    document.getElementById("cross-promo").remove();
    var FlyEnabled = false
    var BedrockEnabled = false
    divClass.style.display = 'block';
    divClass.id = "MyDIV";
    document.body.appendChild(divClass);
    function changeColorAtHover(button, color, returncolor) {
        $(document).ready(function () {
            $(button).hover(function () {
                $(button).css('background', color);
            },
                function () {
                    $(button).css('background', returncolor);
                });
        });
    }
    function modifyHTML() {
        ValidButton1.innerHTML = "valid"
        ExplainText2.innerHTML = "To spam, you must activate the spam button and then hold the 'enter' key for as long as you want.<br /><br />This script was made by Raylazzz and was published by Raylazzz, so for those who would like to use it, please respect me in the game, at least in recognition of my work. 😂<br /><br /><br />new update :<br /><br>The bedrock-cheat, useful to go under the bedrock :<br />To use it, you must, first, activate the option 'En / Disable bedrock cheat' then, go to the level of the bedrock. Here you can press Shift to go down and then Space to go up. To stabilize yourself, you must press Shift and then Space once.<br /><br />Thank you for being so many to use my cheat and if you want new features, send me a message on my discord :<br /><br />"
        ExplainText2.style = "font-family: Madera; font-size: 13px; background-color: black; width: 300px; top: 0px; right: 15px; color: white; border-radius: 15px; border-color: black; padding: 15px; position: absolute; z-index: 100;"
        discordLink.href = "https://discord.com/channels/1020394306265153576/1020394306265153579";
        discordLink.style = "color: darkcyan; overflow-wrap: break-word; cursor: pointer; }";
        discordLink.innerHTML = "https://discord.com/channels/1020394306265153576/1020394306265153579";
        discordLink.target = "blank";
        SpamInput.className = 'Spam input';
        SpamInput.placeholder = "Spam message...";
        SpamInput.addEventListener('keydown', function (e) {
            if (e.key != "Backspace") e.preventDefault();
            if (e.key.length == 1) SpamInput.value += e.key;
        });
        ValidButton1.style = "color: white; top:15px;left:230px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        SpamInput.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;border-radius: 15px 15px 15px 15px;";
        ValidButton1.onclick = "myFunction()";
        ValidButton1.style.backgroundColor = "white";
        changeColorAtHover(ValidButton1, '#05d1ff', 'black');
        ValidButton1.style.backgroundColor = "black";
        document.getElementById('MyDIV').appendChild(ExplainText2);
        ExplainText2.appendChild(discordLink);
        ExplainText2.innerHTML += "<br /><br />Enjoy the cheat !!";
        document.getElementById('MyDIV').appendChild(SpamInput);
        document.getElementById('MyDIV').appendChild(ValidButton1);
        document.getElementById('MyDIV').removeChild(SpamInput);
        getSpamInput = SpamInput.value;
        spam_msg = getSpamInput;
        console.log(getSpamInput);
        displayInput = false;
        ValidButton1.innerHTML = "change spam message"
        ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        ValidButton1.style.backgroundColor = "black";
    }
    function HTMLButtonSpam() {
        ValidButton1.onclick = function () {
            if (displayInput == true) {
                document.getElementById('MyDIV').removeChild(SpamInput);
                getSpamInput = SpamInput.value;
                if (getSpamInput.slice(0, 1) != '/') {
                    spam_msg = getSpamInput;
                } else {
                    cheatKick = getSpamInput.slice(1, getSpamInput.length)
                    console.log(cheatKick);
                }
                displayInput = false;
                ValidButton1.innerHTML = "change spam message"
                ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
                ValidButton1.style.backgroundColor = "white";
            } else if (displayInput == false) {
                ValidButton1.style = "font-family: Madera; font-size: 13px; color: white; top:15px;left:240px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
                document.getElementById('MyDIV').appendChild(SpamInput);
                ValidButton1.innerHTML = "submit"
                document.getElementById('MyDIV').appendChild(ValidButton1);
                displayInput = true;
            }
        };
    }
    function keyboardManagement() {
        document.onkeydown = function (m) {
            if (m.key == "Enter") {
                if (chat_opened == false) {
                    chat_opened = true;
                } else if (chat_opened == true) {
                    chat_opened = false;
                }
                if (spam_lock == 'True') {
                    var elt = document.querySelector('input');
                    elt.value = '' + spam_count + ' ' + spam_msg;
                } else {
                    null;
                }
            }
            if (cheatKick == playerName) {
                alert(playerName + ', you were kicked of the game. Reason : Abusing cheat.');
                window.close();
            }
            if (chat_opened == true) {
                spam_count++
            }
            if (FlyEnabled == true) {
                G.CONFIG.a143 = 100
            } else if (FlyEnabled == false) {
                G.CONFIG.a143 = 0
            }
            if (BedrockEnabled == true) {
                if (m.key == " ") G.CONFIG.environmentOceanFloorHeight = 260;
                if (m.key == "Shift") {
                    G.CONFIG.environmentOceanFloorHeight = -10000;
                } else {
                    G.CONFIG.environmentOceanFloorHeight = 260;
                }
            } else if (BedrockEnabled == false) {
                G.CONFIG.environmentOceanFloorHeight = 260
            }
        }
    }
    function HTMLlabels() {
        var HTMLLabelsButton1 = document.createElement('button');
        var HTMLLabelsButton1Checked = false
        HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✖';
        HTMLLabelsButton1.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:75px; left:15px; position:absolute; z-index:99999; padding:15px; cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton1, '#05d1ff', 'black');
        HTMLLabelsButton1.onclick = function () {
            if (HTMLLabelsButton1Checked == true) {
                changeColorAtHover(HTMLLabelsButton1, '#05d1ff', "black");
                HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✖';
                G.CONFIG.a143 = 0
                FlyEnabled = false
                HTMLLabelsButton1Checked = false;
            } else if (HTMLLabelsButton1Checked == false) {
                changeColorAtHover(HTMLLabelsButton1, '#05d1ff', '#05d1ff');
                HTMLLabelsButton1.innerHTML = 'En/Disable Fly Mode ✔';
                G.CONFIG.a143 = 100
                FlyEnabled = true
                HTMLLabelsButton1Checked = true;
            }
        }

        var HTMLLabelsButton5 = document.createElement('button');
        var HTMLLabelsButton5Checked = false
        HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✖';
        HTMLLabelsButton5.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:195px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton5, '#05d1ff', 'black');
        HTMLLabelsButton5.onclick = function () {
            if (HTMLLabelsButton5Checked == true) {
                changeColorAtHover(HTMLLabelsButton5, '#05d1ff', "black");
                HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✖';
                G.CONFIG.environmentOceanFloorHeight = 260
                BedrockEnabled = false
                HTMLLabelsButton5Checked = false;
            } else if (HTMLLabelsButton5Checked == false) {
                changeColorAtHover(HTMLLabelsButton5, '#05d1ff', '#05d1ff');
                HTMLLabelsButton5.innerHTML = 'En/Disable bedrock cheat ✔';
                G.CONFIG.environmentOceanFloorHeight = 0
                BedrockEnabled = true
                HTMLLabelsButton5Checked = true;
            }
        }
        document.getElementById('MyDIV').appendChild(HTMLLabelsButton5);


        document.getElementById('MyDIV').appendChild(HTMLLabelsButton1);
        var HTMLLabelsButton2 = document.createElement('button');
        var HTMLLabelsButton2Checked = false
        HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✖';
        HTMLLabelsButton2.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:135px;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        changeColorAtHover(HTMLLabelsButton2, '#05d1ff', 'black');
        HTMLLabelsButton2.onclick = function () {
            spam_count = 0;
            if (HTMLLabelsButton2Checked == true) {
                changeColorAtHover(HTMLLabelsButton2, '#05d1ff', 'black');
                HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✖';
                HTMLLabelsButton2Checked = false;
            } else if (HTMLLabelsButton2Checked == false) {
                changeColorAtHover(HTMLLabelsButton2, '#05d1ff', '#05d1ff');
                HTMLLabelsButton2.innerHTML = 'En/Disable Spam Mode ✔';
                HTMLLabelsButton2Checked = true;
            }
            if (spam_lock == 'True') {
                spam_lock = 'False';
            } else if (spam_lock == 'False') {
                spam_lock = 'True';
            }
        }
        document.getElementById('MyDIV').appendChild(HTMLLabelsButton2);
    }
    function hideButtonsButton() {
        var HTMLLabelsButton3 = document.createElement('button');
        var HTMLLabelsButton3Checked = false
        HTMLLabelsButton3.innerHTML = '⬅';
        HTMLLabelsButton3.style = "font-family: Madera; font-size: 13px; background-color: black; color: white; top:320px;height: 100px ;left:15px;position:absolute;z-index:99999;padding:15px;cursor: pointer;border-radius: 15px 15px 15px 15px;";
        HTMLLabelsButton3.onclick = function () {
            if (HTMLLabelsButton3Checked == true) {
                divClass.style.display = 'block';
                changeColorAtHover(HTMLLabelsButton3, '#05d1ff', 'black');
                HTMLLabelsButton3.innerHTML = '⬅';
                HTMLLabelsButton3Checked = false
            } else if (HTMLLabelsButton3Checked == false) {
                divClass.style.display = 'none';
                changeColorAtHover(HTMLLabelsButton3, '#05d1ff', '#05d1ff');
                HTMLLabelsButton3.innerHTML = '➡';
                HTMLLabelsButton3Checked = true
            }
        }
        document.body.appendChild(HTMLLabelsButton3);

    }
    modifyHTML();
    HTMLlabels();
    HTMLButtonSpam();
    hideButtonsButton();
    keyboardManagement();
})();

J'ai ce code, comment faire pour que tous le texte du div "document.getElementById('MyDIV')" aient une autre couleur de sélection à la souris que cet éternel bleu ennuyeux?
 
ZZZ
Passionné
Messages
1 400
Fofocoins
7 662
Personnalisation du groupe
Personnalisation pseudo
Pour changer la couleur du texte du div `document.getElementById('MyDIV')`, vous pouvez ajouter la propriété `color` à son style CSS. Par exemple, pour mettre le texte en blanc, vous pouvez ajouter la ligne suivante :

```javascript
document.getElementById('MyDIV').style.color = 'white';
```

Placer cette ligne de code dans la fonction `modifyHTML()` permettra de changer la couleur du texte dès que le div est créé.
tu fonctionnes?
 

🚫 Alerte AdBlock !

Vous avez activé le mode Ninja, et il cache toutes les pubs ! 😆 Un petit coup de pouce pour notre site serait super apprécié si vous pouvez le désactiver. 🙏

🦸‍♂️ J'ai Désactivé AdBlock !