diff --git a/pingplace.py b/pingplace.py index cd38441..9641c7f 100644 --- a/pingplace.py +++ b/pingplace.py @@ -39,11 +39,7 @@ sock = ICMPv6Socket() # generate IP list ips=[] for w in range(width): - for h in range(hight): - xcoord=x+w - xcoord=f"{xcoord:#05x}".split('x')[-1] - ycoord=hex(y+h).split('x')[-1] - if (r>=255): + if (r>=255): if (g>=255): if(b>=255): r=0 @@ -55,6 +51,10 @@ for w in range(width): g=g+1 else: r=r+1 + for h in range(hight): + xcoord=x+w + xcoord=f"{xcoord:#05x}".split('x')[-1] + ycoord=hex(y+h).split('x')[-1] colorr=f"{r:#04x}".split('x')[-1] colorg=f"{g:#04x}".split('x')[-1] colorb=f"{b:#04x}".split('x')[-1]