next time use the {code} bracket so we can read without download. like so
Code:
elseif SubString(s2s,0,11)="-changename" then
set string s = GetPlayerName(Player(zzz))
set integer i2 = StringLength(s)
set integer i3= i2/4
call SetPlayerName(Player(zzz),"|cffff0080"+SubString(s,0,i3)+"|cffff00ff"+SubString(s,i3,i3+2)+"|cffff80c0"+SubString(s,i3+2,i3+4)+"|cffff80ff"+SubString(s,i3+4,
anyway. you don't create variables mid function, all locals are declared at the top of the function.
also you don't change the value using the type of variable.
change "set string s" to just "set s"