Jump to content

Kaphotics

Helpful Member
  • Posts

    7023
  • Joined

  • Last visited

  • Days Won

    336

Posts posted by Kaphotics

  1. PID Frame Check for Emerald

    5j4hD.jpg

    local pid=0xPUT THE ENTIRE HEX PID HERE
    local mf,sf,pr=math.floor,string.format,print
    local ts,f,d,cp=0,0,0,0
    
    function rand(s)
    return (0x4e6d*(s%65536)+((0x41C6*(s%65536)+0x4e6d*mf(s/65536))%65536)*65536+0x6073)%(4294967296)
    end
    
    function main()
      while cp ~= pid do
    ts=rand(ts)+0
    cp=mf(rand(ts)/65536)*0x10000+mf(ts/65536)
    f=f+1
      end
    
      if d==0 then
    pr("PID: "..sf("%5XXXX", mf(pid/4096)))
    pr("RNG Frame: "..sf("%d", f))
    pr("Seconds: "..sf("%.2f", f/60))
    if f<10000 then pr("Seems like a soft reset!") end
    d=1 
      end
    end
    
    gui.register(main)

    checks the earliest frame that a PID can occur for emerald... just a small script to easily see if an upload is a plausible soft reset

    • Like 1
×
×
  • Create New...