I’m not sure if there’s a simple way to do this but the code below doesn’t work for sure. Any idea how to fix it?
let myInteger=5
keyboard('ctrl+i', () => {myInteger = Math.floor(Math.random()*12)})
I’m not sure if there’s a simple way to do this but the code below doesn’t work for sure. Any idea how to fix it?
let myInteger=5
keyboard('ctrl+i', () => {myInteger = Math.floor(Math.random()*12)})
The solution will be whenKey()
But not sure about the details yet. The code below works but pressing the key, the integer is changed temporarily only. It is not exactly what I want. I want permanent change.
let myint="1".whenKey("Control:i", x=>x.set(irand(16)))
$: s("bd:6").euclid(myint,16)