function FM_log(level, text) {
// caso não seja log total escolhe o que loga
var log = false;
switch (level) {
case "addtoprio()":log = true;
case "alternaTropas()":log = false;
case "sendtroops()":log = false;
defalt: log = false;
}
if ((logTotal == false) && (log == true))
GM_log(horaAtual() + " - "+level+", "+text);
else if (logTotal == true)
GM_log(horaAtual() + " - "+level+", "+text);
}
how to do that switch is a way it works?