is it possible to put table entry's into channel messages? i am not able to get it to print out but i can get data to go into a table
Code:
elseif (event == "CHAT_MSG_CHANNEL") then
local channel = tonumber(strsub(arg4,1,1));
ccvars.cnames[channel] = strsub(arg4,4);
CCAddMsgCustom(channel, "["..arg4.."]["..arg2.."]: "..arg1);
end
Code:
function CCAddMsgCustom(channel,msg)
tinsert(cccustomchannels[channel],1,msg);
--CopyTable(cccustomchannels[channel],1,msg)
SendChatMessage("{cccustomchannels[channel],1,msg}", CHANNEL, "Orcish", "guildtest");
sendChatMessage("{cccustomchannels[channel],1,msg}", CHANNEL, "Orcish", "/6");
--table.foreach({cccustomchannels[channel],1,msg}, print: testing);
if (ccvars.memorylimit>0 and getn(ccsye)>ccvars.memorylimit) then
tremove(cccustomchannels[channel], ccvars.memorylimit+1);
end
end
the last set of code is a test by me, tinsert puts the message into a table but i cannot get it in the same move to take what was in now in that table and put it in another channel. when i go sendChatMessage("{cccustomchannels[channel],1,msg}", CHANNEL, "Orcish", "/6"); it comes up with a nil value, when i go SendChatMessage("{cccustomchannels[channel],1,msg}", CHANNEL, "Orcish", "guildtest"); it doesnt come up with any error or ANYTHING at all. and yes i am in a channel and all appropriate channels have been registered.