#MooTools Timer Example
Below is a code snippet that uses the Timer and TimerTask classes.
##Script
function print(id, value) {
document.getElementById(id).innerHTML = value;
}
#MooTools Timer Example
Below is a code snippet that uses the Timer and TimerTask classes.
##Script
function print(id, value) {
document.getElementById(id).innerHTML = value;
}
<?xml version="1.0" encoding="UTF-8"?> | |
<!-- Created by Isaac Holmlund (isaacch@gmail.com) --> | |
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> | |
<xs:element name="type" nillable="false"> | |
<xs:simpleType> | |
<xs:restriction base="xs:string"> | |
<xs:enumeration value="action"/> | |
<xs:enumeration value="action-attack"/> | |
<xs:enumeration value="action-duration"/> | |
<xs:enumeration value="action-reaction"/> |
var renderIntervalInMillis = 50; | |
var characterWidth = 80; | |
var i = 0; | |
var whitespace = (new Array(characterWidth)).join('\u205f'); | |
setInterval(function() { | |
var position = whitespace.length - (i++ % whitespace.length); | |
document.title = whitespace.substring(0, position) + '🐟' + whitespace.substring(position + 1); | |
}, renderIntervalInMillis); |
{ | |
"success": true, | |
"itemTemplates": [ | |
{ | |
"templateId": "BADGE_BATTLE_ATTACK_WON", | |
"badgeSettings": { | |
"badgeType": "BADGE_BATTLE_ATTACK_WON", | |
"badgeRank": 4, | |
"targets": [ | |
10, |
function urlObject(options) { | |
"use strict"; | |
/*global window, document*/ | |
var url_search_arr, | |
option_key, | |
i, | |
urlObj, | |
get_param, | |
key, |
/* | |
jQuery.reduce - a jQuery plugin for functional programming | |
@author John Hunter | |
created 2010-09-17 | |
use: $.reduce(arr, fnReduce, valueInitial); | |
fnReduce is called with arguments: [valueInitial, value, i, arr] | |
reduce will never be jQuery core - its not prototype :p (http://dev.jquery.com/ticket/1886) | |
*/ | |
(function ($) { |
function product() { | |
var args = Array.prototype.slice.call(arguments); // makes array from arguments | |
return args.reduce(function tl (accumulator, value) { | |
var tmp = []; | |
accumulator.forEach(function (a0) { | |
value.forEach(function (a1) { | |
tmp.push(a0.concat(a1)); | |
}); | |
}); | |
return tmp; |
// Turn on Developer Mode under User Settings > Appearance > Developer Mode (at the bottom) | |
// Then open the channel you wish to delete all of the messages (could be a DM) and click the three dots on the far right. | |
// Click "Copy ID" and paste that instead of LAST_MESSAGE_ID. | |
// Copy / paste the below script into the JavaScript console. | |
// If you're in a DM you will receive a 403 error for every message the other user sent (you don't have permission to delete their messages). | |
var before = 'LAST_MESSAGE_ID'; | |
clearMessages = function(){ | |
const authToken = document.body.appendChild(document.createElement`iframe`).contentWindow.localStorage.token.replace(/"/g, ""); | |
const channel = window.location.href.split('/').pop(); |