move color change to rows

This commit is contained in:
Aaron Riedel 2023-07-18 09:34:55 +02:00
parent ad3429cb94
commit f21a2aec99
Signed by: aaron
GPG key ID: 643004654D40D577

View file

@ -39,10 +39,6 @@ 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 (g>=255):
if(b>=255):
@ -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]