This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<script type="module"> | |
// WICG Shape Detection API | |
// - https://wicg.github.io/shape-detection-api/ | |
try { | |
const start = document.getElementById("start"); | |
const video = document.getElementById("video"); | |
const result = document.getElementById("result"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
console.log([...document.getElementById('combat-combatLog-section').children].map(child=>{const c=child.children[0].children[0].children[0],s=c.children[1].children,l=[...child.children[0].children[0].children].slice(3);return`{'${c.children[0].children[1].childNodes[0].textContent.trim().replace(/\S+/g,m=>m[0]+m.slice(1).toLowerCase())}',${s[0].children[1].textContent},${s[2].textContent},${s[4].textContent},${s[6].textContent},${s[8].textContent},{${l.map(r=>`{'${(s=>s[0].toUpperCase()+s.slice(1))(r.children[0].children[0].src.match(/\w+(?=\.png)/)[0])}',${r.children[1].innerText.includes('-')?r.children[1].innerText.split(' - ')[0]:r.children[1].innerText},${r.children[1].innerText.includes('-')?r.children[1].innerText.split(' - ')[1]:r.children[1].innerText},${r.children[2].innerText.slice(2)}}`).join(',')}}},`}).join('\n')) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PREC_EXPR = { | |
:closed => [ | |
[[/\G\(/, /\G\)/, -> (i) { -> (s) { i.(s) } }]] | |
] | |
} | |
PREC_TIMES = { | |
:left => [ | |
[[/\G\*/,], -> (l, r) { -> (s) { l.(s) * r.(s) } }], | |
[[/\G\//,], -> (l, r) { -> (s) { l.(s) / r.(s) } }], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name DHM Customizer | |
// @namespace https://diamondhunt.app/ | |
// @version 0.0.1 | |
// @description Customizable UI for Diamond Hunt Mobile | |
// @author somebody | |
// @match https://diamondhunt.app/ | |
// @grant GM_getValue | |
// @grant GM_setValue | |
// ==/UserScript== |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Script to get the loot table for an area, to be placed in https://diamondhuntmobile.fandom.com/wiki/Module:Area_DB | |
area='hauntedMansion'; // replace with the area you're looking for, capitalized the same way. | |
showExploringDropRates(area+'Loot');c=s=>s[0].toUpperCase()+s.slice(1).replace(/([a-z])([A-Z])/g,'$1 $2');setTimeout(_=>console.log('{'+[...$('#dialogue-confirm-text .table-stats')[0].children[0].children].slice(1).map(e=>'{\''+c(e.children[0].children[0].src.match(/\w+(?=\.png)/)[0])+'\','+((t=e.children[1].innerText).includes('-')?t.split(' - ')[0]:t).replace(/,/g,'')+','+(t.includes('-')?t.split(' - ')[1]:t).replace(/,/g,'')+','+e.children[2].innerText.slice(2).replace('*','')+','+(!!e.children[3])+','+e.children[2].innerText.includes('*')+'}').join(',').replace(/(,false)?,false}/g,'}')+'}'),1000) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* SnippetParser.re | |
* | |
* Module for parsing snippets??? | |
*/ | |
open CharCode; | |
module TokenType = { | |
let dollar = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"type":"methods", | |
"title":"Array Methods", | |
"object":"A", | |
"intro":[], | |
"methods":{ | |
"a(s/n)":{ | |
"description":"Returns the last index of `x`s/n`` in `A`, or `-1` if not found.", | |
"returns":"N", | |
"version":"1.4.5", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bin(): n leading 1s trailing 0s | |
1 1 0 | |
10 1 1 | |
11 1 0 | |
100 10 1 | |
101 1 10 | |
110 11 1 | |
111 1 0 | |
1000 11 1 | |
1001 10 10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(1, 1, 1, 1, 1) | |
(1, 1, 1, 1, 32) | |
(1, 1, 1, 1, 31) | |
(1, 1, 1, 1, 30) | |
(1, 1, 1, 1, 29) | |
(1, 1, 1, 1, 28) | |
(1, 1, 1, 1, 27) | |
(1, 1, 1, 1, 26) | |
(1, 1, 1, 1, 25) | |
(1, 1, 1, 1, 24) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(1, 1, 1, 1, 1) | |
(1, 1, 1, 1, 32) | |
(1, 1, 1, 1, 31) | |
(1, 1, 1, 1, 30) | |
(1, 1, 1, 1, 29) | |
(1, 1, 1, 1, 28) | |
(1, 1, 1, 1, 27) | |
(1, 1, 1, 1, 26) | |
(1, 1, 1, 1, 25) | |
(1, 1, 1, 1, 24) |
NewerOlder