旧站的内容可能已过时。您可以前往“真魂”分站查看本页面,那里的内容将会定期同步。
RichardCrypt
来自个人维基
SoulLC old:
// num to symbols text.value.replace(/[0123]/g, d=>[..."✔🔘⚡🎵"][Number(d)])
// decrypt var str = text.value var symbols = [ ..."✔🔘⚡🎵" ] var table = [ ..."0123456789abcdefghijklmnopqrstuvwxyz", "高中楼", "科教楼", "初中楼", "体育馆", "AP楼", "操场", "食堂", "宿舍", ...new Array(4).fill(null), "课间", ...new Array(15).fill(null) ] var len = str.length var buf = [] var ans = [] for (let i = 0; i < len; ) { var digit = null symbols.some((symbol, val) => { if (str.substr(i, symbol.length) === symbol) { i += symbol.length buf.push(val) if (buf.length === 3) { var val = buf[0] << 4 | buf[1] | buf[2] << 2 ans.push(table[val]) buf.length = 0 } return true } }) || i++ } ans.join(" ")