..but could you explain with comment in each event that what is that doing..
I'm sorry but I think that's a little bit excessive...
BtnRestart on clicked-Restart Layout
i think this is clear..also LocalStorage..
if missing -do someting
on get-do something
only the array can be a little confusing..if you do not visualize how it actually looks
so..in example you have 5 instance of same sprite..first instance always have IID=0;second=1
just like frames in animation..array same case..first cell have index=0;second=1 etc
so when you click on instance with IID=2..you save "clickCount"value in array on index 2
then you save Array as Json...