add weird color pattern

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

View file

@ -24,13 +24,13 @@ def one_ping(socket, address):
print(err)
# settings
x=1
y=1
x=0
y=0
width=512
hight=512
r=0xff
g=0xff
b=0xff
r=0
g=0
b=0
prefix="2a01:4f8:c012:f8e6:1"
# open socket
@ -43,6 +43,18 @@ for w in range(width):
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):
r=0
g=0
b=0
else:
b=b+1
else:
g=g+1
else:
r=r+1
colorr=f"{r:#04x}".split('x')[-1]
colorg=f"{g:#04x}".split('x')[-1]
colorb=f"{b:#04x}".split('x')[-1]