This file contains hidden or 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
| let curr='£'; | |
| let recoup=(lost_money,target,isOdds,commission)=>{ | |
| let c=typeof(commission)!=='number'?1:1-commission; | |
| let f=target*c; | |
| let r=lost_money/f; | |
| let rd=(Math.ceil(r*100)*0.01).toFixed(2); | |
| return (isOdds!==true?`Stake ${curr}${rd} at odds ${target}`:`Bet ${curr}${target} at odds ${rd}`); | |
| } | |
| //recoup(10,4.33) //recoup £10 at 4.33 odds |
This file contains hidden or 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
| let choics=['A','B','C']; // Your options | |
| let optns=[]; | |
| let opts=''; | |
| for (let i=0, len=choics.length; i<len;++i){ | |
| let opi='opt'+i; | |
| let s=`<label style="display: inline-flex;"> | |
| <input type="checkbox"></input>${choics[i]}</label>`; | |
| optns.push(s); | |
| } |
This file contains hidden or 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
| function getMatchingNodesShadow_order(docm, slc, isNodeName, onlyShadowRoots){ | |
| function keepMatchesShadow(els,slcArr,isNodeName){ | |
| if(slcArr[0]===false){ | |
| return els; | |
| }else{ | |
| let out=[]; | |
| for(let i=0, len=els.length; i<len; i++){ | |
| let n=els[i]; | |
| for(let k=0, len_k=slcArr.length; k<len_k; k++){ |
This file contains hidden or 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
| function getMatchingNodesShadow_order(docm, slc, isNodeName, onlyShadowRoots){ | |
| function keepMatchesShadow(els,slcArr,isNodeName){ | |
| if(slcArr[0]===false){ | |
| return els; | |
| }else{ | |
| let out=[]; | |
| for(let i=0, len=els.length; i<len; i++){ | |
| let n=els[i]; | |
| for(let k=0, len_k=slcArr.length; k<len_k; k++){ |
This file contains hidden or 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
| function keepMatchesShadow(els,slcArr,isNodeName){ | |
| if(slcArr[0]===false){ | |
| return els; | |
| }else{ | |
| let out=[]; | |
| for(let i=0, len=els.length; i<len; i++){ | |
| let n=els[i]; | |
| for(let k=0, len_k=slcArr.length; k<len_k; k++){ | |
| let sk=slcArr[k]; | |
| if(isNodeName){ |
This file contains hidden or 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
| function setStyle(el,prop,val,pat){ | |
| pat=(typeof(pat)==='undefined')?new RegExp(`(?<=(^\\s*|;\\s*))${prop}\\s*\:\\s*[^;]*;?`):new RegExp(pat); | |
| let c=el.style.cssText; | |
| let cs=[...c]; | |
| let p=c.match(pat); | |
| let nv=`${prop}: ${val} !important;`; | |
| if(p===null){ | |
| let sc=(c.trim().endsWith(';'))?'':';'; | |
| el.style.cssText+=sc+nv; | |
| }else if(p[0]!==nv){ |
This file contains hidden or 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
| local s='common\\etc\\pesdb\\CompetitionKind.bin' -- The string we're looking for at address RDX (below) | |
| local s1=readString(RDX,s:len()) | |
| return(s==s1) |
This file contains hidden or 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
| function keepMatchesShadow(els,slcArr,isNodeName){ | |
| if(slcArr[0]===false){ | |
| return els; | |
| }else{ | |
| let out=[]; | |
| for(let i=0, len=els.length; i<len; i++){ | |
| let n=els[i]; | |
| for(let k=0, len_k=slcArr.length; k<len_k; k++){ | |
| let sk=slcArr[k]; | |
| if(isNodeName){ |
This file contains hidden or 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
| local addr=getAddress('...') -- breakpoint address | |
| local cntr=1 | |
| local startAddress=0x7FF4E5E60000 | |
| local endAddress=0x7FFD4B08FFFF | |
| local aob='41 72 73 65 6E 61 6C' -- 'Arsenal' | |
| function onBp() | |
| debug_getContext(true) | |
| local memscan = createMemScan() | |
| memscan.firstScan( |
This file contains hidden or 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
| local round = function(a, prec) | |
| return math.floor(a + 0.5*prec) | |
| end | |
| local bitOps = {} | |
| bitOps.getBits= function (num, asTable) | |
| local x = {} | |
| if num==0 then | |
| if asTable==true then | |
| return {0} | |
| else |
NewerOlder