Not in other's post, but nvm.
Anywaaaay this ZQL stuff seems pretty cool, could you elaborate on how it works?
Tx, well you know every 'character' has it's own bytecode.
Color value's range from 0-255, so 256 different value's a color.
R-G-B, 3 colors, 256^3=16777216 different colors.
But because the bytecode only ranges from 1-255 (byte 0 is anoying cos it removes every byte in front of it..) I'll have to store 4 different value's instead of 3. (ZQL doesn't yet support opacity/transparency..).
It's difficult to explain.
The 1st token holds a combination of numbers for R-G-B to add a value to.
Very hard to explain. For instance:
local cdl={['n0']='a',['n1']='b',['n2']='c',['n3']='d',['n4']='e',['n5']='f',['n6']='g',['n7']='h',['n8']='i',['n9']='j',['n10']='k',['n11']='l',['n12']='m',['n13']='n',['n14']='o',['n15']='p',['n16']='q',['n17']='r',['n18']='s',['n19']='t',['n20']='u',['n21']='v',['n22']='w',['n23']='x',['n24']='y',['n25']='z',['n26']='A',['n27']='B',['n28']='C',['n29']='D',['n30']='E',['n31']='F',['n32']='G',['n33']='H',['n34']='I',['n35']='J',['n36']='K',['n37']='L',['n38']='M',['n39']='N',['n40']='O',['n41']='P',['n42']='Q',['n43']='R',['n44']='S',['n45']='T',['n46']='U',['n47']='V',['n48']='W',['n49']='X',['n50']='Y',['n51']='Z',['n52']='0',['n53']='1',['n54']='2',['n55']='3',['n56']='4',['n57']='5',['n58']='6',['n59']='7',['n60']='8',['n61']='9',['n62']='-',['n63']='/',['n64']=':',['n65']=';',['n66']='(',['n67']=')',['n68']='&',['n69']='@',['n70']='"',['n71']='.',['n72']=',',['n73']='?',['n74']='[',['n75']=']',['n76']='{',['n77']='}',['n78']='#',['n79']='%',['n80']='^',['n81']='*',['n82']='+',['n83']='=',['n84']='<',['n85']='>'}
The color: rgb(187,186,142)
Is 187 less than 86? Nope. R-Step0
Is 187 greater than 85? Yep. R-Step1
Is 187 greater than 170? Yep. R-Step2
Bottom-Value-R=2 (Greater than 85*2)
Is 186 less than 86? Yep. G-Step0.
Is 186 greater than 85? Yep. G-Step1.
Is 186 greater than 170? Yep. G-Step2.
Bottom-Value-G=2 (Greater than 85*2)
Is 142 less than 86? Nope. B-Step0.
Is 142 greater than 85? Yep. B-Step1.
Is 142 greater than 170? Nope. B-Step2.
Bottom-Value-B=1 (Greater than 85, but less than 85*2)
Bottom-Value-ID=221
Search for ID in list:
bvdl={['000']='a',['001']='b',['002']='c',['010']='d',['011']='e',['012']='f',['020']='g',['021']='h',['022']='i',['100']='j',['101']='k',['102']='l',['110']='m',['111']='n',['112']='o',['120']='p',['121']='q',['122']='r',['200']='s',['201']='t',['202']='u',['210']='v',['211']='w',['212']='x',['220']='y',['221']='z',['222']='A'}
Now we see the token/character for this bottom-value-combination is 'z'.
Now the bottom value's are:
For R: 171
For G: 171
For B: 86
Now we want to know the 'difference' between the R-G-B value's and their bottom-value's.
delta_R=187-171=16
delta_G=186-171=15
delta_B=142-86=56
Now let's see what is their token in list:
local cdl={['n0']='a',['n1']='b',['n2']='c',['n3']='d',['n4']='e',['n5']='f',['n6']='g',['n7']='h',['n8']='i',['n9']='j',['n10']='k',['n11']='l',['n12']='m',['n13']='n',['n14']='o',['n15']='p',['n16']='q',['n17']='r',['n18']='s',['n19']='t',['n20']='u',['n21']='v',['n22']='w',['n23']='x',['n24']='y',['n25']='z',['n26']='A',['n27']='B',['n28']='C',['n29']='D',['n30']='E',['n31']='F',['n32']='G',['n33']='H',['n34']='I',['n35']='J',['n36']='K',['n37']='L',['n38']='M',['n39']='N',['n40']='O',['n41']='P',['n42']='Q',['n43']='R',['n44']='S',['n45']='T',['n46']='U',['n47']='V',['n48']='W',['n49']='X',['n50']='Y',['n51']='Z',['n52']='0',['n53']='1',['n54']='2',['n55']='3',['n56']='4',['n57']='5',['n58']='6',['n59']='7',['n60']='8',['n61']='9',['n62']='-',['n63']='/',['n64']=':',['n65']=';',['n66']='(',['n67']=')',['n68']='&',['n69']='@',['n70']='"',['n71']='.',['n72']=',',['n73']='?',['n74']='[',['n75']=']',['n76']='{',['n77']='}',['n78']='#',['n79']='%',['n80']='^',['n81']='*',['n82']='+',['n83']='=',['n84']='<',['n85']='>'}
Now we see:
R='n16'='q'
G='n15'='p'
B='n56'='4'
The stored code for 'rgb(187,186,142)' is: zqp4