CoiledSpring / Anti-Kick - Shoutbox Planet-Casio

// ==UserScript==
// @name        Anti-Kick - Shoutbox Planet-Casio
// @namespace   coiledscripts
// @include     http://www.planet-casio.com/Fr/*
// @version     1
// @grant       none
// ==/UserScript==

variations = ["tröll", "trołl", "trolł", "trołł", "tröłl", "trölł", "tröłł", "trôll", "trôłl", "trôlł", "trôłł", "trøll", "trøłl", "trølł", "trøłł", "ţroll", "ţrołl", "ţrolł", "ţrołł", "ţröll", "ţröłl", "ţrölł", "ţröłł", "ţrôll", "ţrôłl", "ţrôlł", "ţrôłł", "ţrøll", "ţrøłl", "ţrølł", "ţrøłł"];
remplacements = [["troll", variations[Math.floor(variations.length * Math.random())]]];

sb = $("#shoutbox");
sbForm = sb.children(".input-group");
sbMessage = sbForm.children('input[type="text"]');

function antiKick() {
  o_text = sbMessage.val(); n_text = o_text;
  for(i = 0; i < remplacements.length; i++) {
    n_text = n_text.replace(remplacements[i][0], remplacements[i][1]);
  }
  sbMessage.val(n_text);
}
sbForm.find(".btn-send").click(antiKick);
sbForm.submit(function(e) { antiKick(); return false; });
sbForm.find('input[type="text"]').keypress(function(e) { var code = (e.keyCode ? e.keyCode : e.which); if(code == 13) {antiKick(); return false;} });