Soon we will have 2 major context “constants” that will change. blocks per cycle (4096 to 8192) and blocks per snapshot (256 to 512).
This will require payout mechanisms to retool how they determine the level of the roll_snapshot used for rights calculation. Here is my first stab at it, all my testing so far seems to indicate I’ve got it but would like some feedback
# assuming we already have the value (0 - 15) of roll_snapshot, an we need to find its level if cycle > (granadaStartCycle + 6): snapLevel = (4096*granadaStartCycle) + ((cycle-granadaStartCycle)*8192) + ((snapNum + 1) * 512) else: snapLevel = ((cycle - 5 - 2) * 4096) + ((snapNum + 1) * 256)