0x28996f7d…515asent to0x00000000…5b01·#24,393,914·view on Etherscan
<!doctype html>
<html><head>
<meta name="title" content="PUSH4"/><meta charset="UTF-8"/><meta name="viewport" content="width=device-width,initial-scale=1"/>
<style>*{margin:0;padding:0;box-sizing:border-box}html,body{width:100%;height:100%;overflow:hidden;font-family:monospace}#container{width:100%;height:100%;display:flex;flex-direction:column;align-items:center}#artwork{width:100%;height:calc(100% - 30px);display:flex;align-items:flex-start;justify-content:center}#artwork img,#artwork iframe{height:100%;width:auto;max-width:100%;image-rendering:pixelated}#info{height:30px;display:flex;flex-direction:column;justify-content:flex-end;gap:5px;visibility:hidden;opacity:0;margin:0 auto}#info.loaded{visibility:visible;opacity:1}#info-text{display:flex;justify-content:space-between;padding:0 0 6px;font-size:11px;color:#666;letter-spacing:.3px}#progress-bar{height:2px;background:#222}#progress{height:100%;background:#555;width:0%}</style>
</head><body>
<div id="container"><div id="artwork"><div id="loading">Loading...</div></div><div id="info"><div id="info-text"><span><span id="title">--</span> by <span id="creator">--</span></span><span id="proxy">--</span></div><div id="progress-bar"><div id="progress"></div></div></div></div>
<script>
const R=[{{FILE_URIS}}],B={{BLOCK_INTERVAL}},C='{{CORE_ADDRESS}}',G='0x20C85580';
let rIdx=0,lB=0,lP=-1,pA=null,pC=0,rA=null;
function sE(m){document.getElementById('artwork').innerHTML='<div style="color:#ff5555;padding:20px;text-align:center">'+m+'</div>'}
async function f(m,p){const e=[];for(let i=0;i<R.length;i++){const x=(rIdx+i)%R.length,u=R[x];try{const r=await fetch(u,{method:'POST',headers:{'Content-Type':'application/json'},body:JSON.stringify({jsonrpc:'2.0',id:1,method:m,params:p})});if(!r.ok){e.push({r:u,e:`HTTP ${r.status}`});continue}const t=await r.text();let j;try{j=JSON.parse(t)}catch(pe){e.push({r:u,e:'Parse error'});continue}if(j.error){e.push({r:u,e:'RPC error'});continue}rIdx=x;return j.result}catch(ex){e.push({r:u,e:ex.message});continue}}sE('Connection Error');throw new Error('RPCs failed')}
async function gB(){return parseInt(await f('eth_blockNumber',[]),16)}
async function dP(){try{const r=await f('eth_call',[{to:C,data:'0xec556889'},'latest']);const a='0x'+r.slice(26,66);return a==='0x0000000000000000000000000000000000000000'?null:a}catch(e){return null}}
async function gPC(o){if(!o)return 0;try{return parseInt(await f('eth_call',[{to:o,data:'0x37c954d8'},'latest']),16)}catch(e){return 0}}
async function gCP(o){if(!o)return null;try{return'0x'+(await f('eth_call',[{to:o,data:'0x3f2d9d88'},'latest'])).slice(26,66)}catch(e){return null}}
async function gCI(o){if(!o)return 0;try{return parseInt(await f('eth_call',[{to:o,data:'0x81ef9a43'},'latest']),16)}catch(e){return 0}}
function dS(h){const d=h.slice(2),o=parseInt(d.slice(0,64),16)*2,l=parseInt(d.slice(o,o+64),16)*2;return d.slice(o+64,o+64+l).match(/.{2}/g).map(x=>String.fromCharCode(parseInt(x,16))).join('')}
async function gT(p){if(!p)return'--';try{return dS(await f('eth_call',[{to:p,data:'0x4a79d50c'},'latest']))}catch(e){return'--'}}
async function gCr(p){if(!p)return'--';try{const r=await f('eth_call',[{to:p,data:'0x02d05d3f'},'latest']),d=r.slice(2),so=parseInt(d.slice(0,64),16)*2,no=parseInt(d.slice(so,so+64),16)*2,ns=so+no,nl=parseInt(d.slice(ns,ns+64),16)*2;return d.slice(ns+64,ns+64+nl).match(/.{2}/g).map(x=>String.fromCharCode(parseInt(x,16))).join('')}catch(e){return'--'}}
async function dR(){try{return'0x'+(await f('eth_call',[{to:C,data:'0x8ada6b0f'},'latest'])).slice(26,66)}catch(e){return null}}
async function gS(){return dS(await f('eth_call',[{to:rA,data:'0xbfec768f',gas:G},'latest']))}
function sW(){const i=document.querySelector('#artwork img'),n=document.getElementById('info');if(i)n.style.width=i.clientWidth+'px'}
function rAw(s){const a=document.getElementById('artwork');a.innerHTML='<img src="'+s+'" alt="PUSH4">';a.querySelector('img').onload=sW}
function uP(e){const b=document.getElementById('progress'),c=(e/B)*100,n=Math.min(((e+1)/B)*100,100);b.style.transition='none';b.style.width=c+'%';requestAnimationFrame(()=>requestAnimationFrame(()=>{b.style.transition='width 12s linear';b.style.width=n+'%'}))}
async function poll(){try{const b=await gB();if(b!==lB){const pI=await gCI(pA);if(pI!==lP){const cp=await gCP(pA),[t,cr,sv]=await Promise.all([gT(cp),gCr(cp),gS()]);if(!t||t==='--'||!cr||cr==='--'||!sv)return;lB=b;lP=pI;uP(b%B);document.getElementById('title').textContent=t;document.getElementById('creator').textContent=cr;document.getElementById('proxy').textContent=(pI+1)+'/'+pC;rAw(sv)}else{lB=b;uP(b%B)}}}catch(e){}}
async function init(){[pA,rA]=await Promise.all([dP(),dR()]);pC=await gPC(pA);const[cp,pI]=await Promise.all([gCP(pA),gCI(pA)]);lP=pI;const[t,cr,sv]=await Promise.all([gT(cp),gCr(cp),gS()]);const b=await gB();lB=b;document.getElementById('title').textContent=t;document.getElementById('creator').textContent=cr;document.getElementById('proxy').textContent=(pI+1)+'/'+pC;rAw(sv);uP(b%B);document.getElementById('info').classList.add('loaded');window.addEventListener('resize',sW);setInterval(poll,3000)}
init().catch(e=>console.error('Init error:',e));
</script></body></html>