PtokaX forum

Archive => Archived 5.0 boards => Help with scripts => Topic started by: Jaakko on 28 February, 2005, 18:16:51

Title: Jumble 2 in lua5
Post by: Jaakko on 28 February, 2005, 18:16:51
Someone please help me out.
I have used plop's 425.lua to jumble2 but it still won't run.
All I get is Jumble.lua:282: unexpected symbol near `%
Title:
Post by: bastya_elvtars on 28 February, 2005, 19:50:04
Delete every % from a file that is not between quotation marks ("%S+" should be left as it is.) Use titmouse or editplus to highlight.
Title:
Post by: Jaakko on 28 February, 2005, 20:04:10
Getting better but now I get
Jumble.lua:347: attempt to index field `string' (a nil value)
Title:
Post by: Jaakko on 03 March, 2005, 20:59:33
Would someone please convert this to lua 5 for me.
I have tried everything but it still won't run.
Title:
Post by: PPK on 03 March, 2005, 22:10:08
Please, please ... i want it too :]
Title:
Post by: ??????Hawk?????? on 03 March, 2005, 22:54:37
heya peeps ..

I did wonder WHY??  when youve got all this  and More in XN 8.02  ..  

but anyway  here it is..................



Both the  CFG  and  the LUA file

Jumble.cfg  

-- JumbleFever
-- Author: RabidWombat
-- Converted to LUA 5 by ??????Hawk??????
--                  03/03/2005
-- This is the config file to set values.
-- Do so at your own risk.

sBotName = "JumbleFever";

sTranslator = "Your name here";
-- NOTE: this file is a lua file. JumbleFever calls dofile on it. So
-- you can do anything in here that you would want to occur in the
-- PtokaX Main event.

sJumbleWordsFile = "Jumble\\English.txt";
sJumbleScoresFile = "JumbleScores.txt";

sHintChar = "?"

iDisplayScores = 10; --  displays top 10 scores
-- iDisplayScores = nil; -- displays all scores

-- In seconds
iPauseTime = 10;
iHintTime = 60;
iGameEndTime = 120;
iBonusTimeLimit = 10;

-- FORMULA SYSTEM --
-- Scores and Hint are now formula strings that have variables:
-- iLength = length of phrase (minus spaces)
-- iBonusTime = bonus time remaining
-- additional math functions such as min, max, floor, etc can be used
-- If you're not a scripter, don't change this.
-- Cause I don't want to help 20 people with nil problems :-P

sScoreFormula = "6"; -- score equals 6
-- sScoreFormula = "$iLength"; -- score equals length of phrase
-- sScoreFormula = "2 * $iLength + 3" -- score equals length of phrase times 2 plus 3
-- sScoreFormula = "min($iLength - 5, 0) * 2 + 6"; -- score equals 6 plus 2 for every letter beyond 5
sBonusFormula = "$iBonusTime"; -- bonus score equals bonus time
sHintFormula = "math.floor(.4 * $iLength + .5)";

-- Command table.
-- Format: ["cmdname"] = { FunctionName, OperatorOnly, "Description"}

tCommands = {
[string.lower("a.start")] = { StartJumbleGame, 0, "Start the jumble game. Can be used with language selction (a.start language)"},
[string.lower("a.stop")] = { StopJumbleGame, 0, "Stop the jumble game."},
[string.lower("a.phrase")] = { DisplayJumblePhrase, 0, "Display the current jumble phrase."},
[string.lower("a.help")] = { DisplayJumbleHelp, 0, "Display this message."},
[string.lower("a.scores")] = { DisplayJumbleScores, 0, "Display current scores."},
[string.lower("a.myscore")] = { DisplayMyJumbleScore, 0, "Display your score."},
[string.lower("a.hint")] = { DisplayJumbleHint, 0, "Display the hint."},

[string.lower("a.join")] = { JoinJumble, 0, "Join the private jumble game."},
[string.lower("a.leave")] = { LeaveJumble, 0, "Leave the private jumble game."},

[string.lower("a.private")] = { SetPrivateJumbleGame, 1, "Set Jumble to be private."},
[string.lower("a.public")] = { SetPublicJumbleGame, 1, "Set Jumble to be public."},
}

-- This string table is dynamic. You define GLOBAL variables with $varname. To define "$"
-- user $$. All above values are considered globals. All others in this table have easy
-- names so I hope everyone understands without an explaination. Try to use common sense
-- when selecting global variables in a string. If you don't think it will be set at the
-- time the string is displayed, it probably isn't :-P

tStringTable = {
[1] = "\r\n$sBotName designed by: $sAuthor Email: $sEmail\r\n"..
"Play word jumble with your hub mates! Any text in the main chat is \r\n"..
"considered a guess for the jumble phrase. Here are the commands:\r\n",
[2] = "$sCmd\t- $sDesc\r\n",
[3] = "10 seconds left!!!",
[4] = "$sUserName recieves $iScore points and $iBonus time bonus. Rank $iRank/$iRankTotal (Score: $iUserScore)",
[5] = "$sUserName recieves $iScore points. Rank $iRank/$iRankTotal (Score: $iUserScore)",
[6] = "$sUserName has started a new $sBotName game!!!",
[7] = "Type \"$sJumbleHelp\" for help.",
[8] = "$sUserName has stopped the $sBotName game. :-(",
[9] = "The Jumble Phrase is: $sJumblePhrase", -- fix
[10] = "Rank: $iRank/$iRankTotal Score: $iUserScore",
[11] = "You don\'t have a score! Loser. :-)",
[12] = "$sUserName has joined the jumble game.",
[13] = "Hello $sUserName",
[14] = "$sUserName has left the jumble game.",
[15] = "The Jumble Phrase was: $sActualPhrase",
[16] = "Top $iDisplayScores $sBotName Players\r\n\r\n",
[17] = "All $sBotName Players\r\n\r\n",
[18] = "No Scores",
[19] = "$iPos) Name: $sUserName - Score: $iUserScore\r\n",
[20] = "Here\'s a hint: $sHint",
[21] = "The $sBotName has stopped automatically. :-("
};
Title:
Post by: ??????Hawk?????? on 03 March, 2005, 22:55:36
Jumble.lua_5.0.lua  
sAuthor = "RabidWombat";
sEmail = "cbarber@dwc.edu";
sConversion = " Converted to LUA 5 by ??????Hawk?????? 03/03/2005"
bGameRunning, bGamePaused = nil, nil;
sJumblePhrase, sActualPhrases, NoSpacePhrase = nil,nil,nil;
iLength, iBonusTime = 0, 0;
sScoreOutput, sHintOutput, sHelpOutput, sOpHelpOutput = nil, nil, nil, "";
iTimeCount, iGameNoReplyCount = 0, 0;
tScores, tScoresByName  = { n = 0 }, {};
tChannelUsers, iChannelCount = {}, nil;

-- PtokaX Events --

function Main()
dofile("jumble.cfg");

sScoreFormula = "return "..sScoreFormula;
sBonusFormula = "return "..sBonusFormula;
sHintFormula  = "return "..sHintFormula;

frmHub:RegBot(sBotName);

sHelpOutput = StrReplace(tStringTable[1]);

for cmd,tTemp in tCommands do
if(tTemp[1] == DisplayJumbleHelp) then
sJumbleHelp = cmd;
end

sCmd, sDesc = cmd, tTemp[3];

if(tTemp[2] == 0) then
sHelpOutput = sHelpOutput..StrReplace(tStringTable[2]);
else
sOpHelpOutput = sOpHelpOutput..StrReplace(tStringTable[2]);
end
end

OldSendToAll = SendToAll;
UserDisconnected = LeaveJumble;
OpDisconnected = LeaveJumble;

SetTimer(1000);

ReadScoresFromFile();
SetScores();
end

function OnTimer()
if(bGamePaused) then
iTimeCount = iTimeCount + 1;

if(iTimeCount >= iPauseTime) then
StartJumblePhrase();
end
elseif(bGameRunning) then
iTimeCount = iTimeCount + 1;

if(iTimeCount == iHintTime) then
SendToAll(sBotName, sHintOutput);
elseif (iTimeCount == iGameEndTime - 10) then
SendToAll(sBotName, StrReplace(tStringTable[3]));
elseif (iTimeCount == iGameEndTime) then
StopJumblePhrase();
if(iGameNoReplyCount >= 3) then
StopJumbleGame();
end
else

end
else

end
end



function ChatArrival(curUser, sData)
local s, e, sNewData, chat, cmd, args = string.find(sData, "(%b<>%s+((%S+)%s*([^%|]*)))%|$");
local s, e, sTo = string.find(sData, "^%$To: (%S+)");

if(cmd == nil or (sTo and sTo ~= sBotName)) then return 0; end

sUserName = curUser.sName;

if(sTo) then
curUser.SendData = curUser.SendPM;
end

cmd = string.lower(cmd);

if(tCommands[cmd] and (tCommands[cmd][2] == 0 or curUser.bOperator)) then
curUser:SendData(sData);
tCommands[cmd][1](curUser, args);
return 1;
else
if (not(iChannelCount) and string.sub(sData,1,1) == "<") then
iGameNoReplyCount = 0;
end

if(iChannelCount and string.find(sData, "$To: "..sBotName, 1, 1) == 1 and cmd == "!me") then
sNewData = "* "..sUserName..string.sub(chat, 4);
end

if(bGameRunning and bGamePaused == nil and string.find(string.upper(chat), sActualPhrase, 1, 1)) then
SendToAll(sNewData);

iBonusTime = math.max(iBonusTimeLimit - iTimeCount, 0);

iScore = assert(loadstring(StrReplace(sScoreFormula)))();
iBonus = assert(loadstring(StrReplace(sBonusFormula)))();

if(tScoresByName[sUserName]) then
tScoresByName[sUserName][2] = tScoresByName[sUserName][2] + iScore + iBonus;
else
tScoresByName[sUserName] = {sUserName, iScore + iBonus};
table.insert(tScores, tScoresByName[sUserName]);
end

iRank = SetScores(sUserName);
iRankTotal = table.getn(tScores);
iUserScore = tScoresByName[sUserName][2];

WriteScoresToFile();

StopJumblePhrase();

if(iBonusTime ~= 0) then
SendToAll(sBotName, StrReplace(tStringTable[4]));
else
SendToAll(sBotName, StrReplace(tStringTable[5]));
end

iGameNoReplyCount = 0;

return 1;
else
if(iChannelCount and string.find(sData, "^$To: "..sBotName, 1, 1) == 1) then
if(tChannelUsers[sUserName] == nil) then
JoinJumble(curUser);
else
SendToAll(sNewData);
iGameNoReplyCount = 0;
end

return 1;
end
end

end
end

-- Command Functions --

function StartJumbleGame(curUser, args)
if(bGameRunning) then return; end
if(args ~= "") then
HubGameActive = 2
local s, e, args = string.find(args, "([%w%s]+)$");
args = "Jumble\\"..args..".txt";
local f,e = io.open(args,"r")
if f then
sJumbleWordsFile = args;
f:close(f)
end
end
OldSendToAll(sBotName, StrReplace(tStringTable[6]));
StartJumblePhrase();
SendToAll(sBotName, StrReplace(tStringTable[7]));

iGameNoReplyCount = 0;
end

function StopJumbleGame(curUser)
if not(bGameRunning) then return; end

if not(bGamePaused) then
StopJumblePhrase();
end

if(curUser) then
OldSendToAll(sBotName, StrReplace(tStringTable[8]));
else
OldSendToAll(sBotName, StrReplace(tStringTable[21]));
-- TODO: fix numbers
end

bGameRunning, bGamePaused = nil, nil;
iBonusTime, iLength = 0, 0;
StopTimer();
end

function DisplayJumblePhrase(curUser)
if(bGameRunning and not bGamePaused) then
if(curUser == nil) then
SendToAll(sBotName, StrReplace(tStringTable[9]));
else
curUser:SendData(sBotName, StrReplace(tStringTable[9]));
end
end
end

function DisplayJumbleHelp(curUser)
if(curUser.bOperator) then
curUser:SendData(sBotName, sHelpOutput..sOpHelpOutput);
else
curUser:SendData(sBotName, sHelpOutput);
end
end

function DisplayJumbleScores(curUser)
curUser:SendData(sBotName, sScoresOutput);
end

function DisplayMyJumbleScore(curUser)
iRank = tScoresByName[curUser.sName][3];
iRankTotal = table.getn(tScores);
iUserScore = tScoresByName[sUserName][2];

if(tScoresByName[curUser.sName]) then
curUser:SendData(sBotName, StrReplace(tStringTable[10]));
else
curUser:SendData(sBotName, StrReplace(tStringTable[11]));
end
end

function DisplayJumbleHint(curUser)
if(iTimeCount >= iHintTime) then
curUser:SendData(sBotName, sHintOutput);
end
end

function JoinJumble(curUser)
if(iChannelCount and tChannelUsers[curUser.sName] == nil) then
SendToAll(sBotName, StrReplace(tStringTable[12]));

curUser:SendPM(sBotName, StrReplace(tStringTable[13]));
curUser.SendData = curUser.SendPM;

DisplayJumblePhrase(curUser);
DisplayJumbleHint(curUser);

tChannelUsers[curUser.sName] = 1;
iChannelCount = iChannelCount + 1;
end
end

function LeaveJumble(curUser)
if(iChannelCount and tChannelUsers[curUser.sName]) then
sUserName = curUser.sName;
SendToAll(sBotName, StrReplace(tStringTable[14]));

tChannelUsers[curUser.sName] = nil;
iChannelCount = iChannelCount - 1;

if(iChannelCount <= 0) then
iChannelCount = 0;
StopJumbleGame();
end
end
end

function SetPrivateJumbleGame(curUser)
if(iChannelCount == nil) then
SendToAll = SendToAllInChannel;
iChannelCount = 0;
end
end

function SetPublicJumbleGame(curUser)
if(iChannelCount) then
SendToAll = OldSendToAll;
tChannelUsers = {};
iChannelCount = nil;
end
end

-- Jumble Phrase Functions --

function JumbleString(str)
local tStr = { n = 0; };
local newString = "";

string.gsub(str, "(.)", function(c) table.insert(tStr, c); end);

math.randomseed(os.clock());

-- Fisher-Yates shuffle
for n = table.getn(tStr), 1, -1 do
local pos = math.random(n);
newString = tStr[pos].." "..newString;
tStr[pos] = tStr[n];
end

return newString;
end

function JumblePhrase(phr)
return string.sub(string.gsub(phr, "(%S+)", function (w) return JumbleString(w).."  "; end), 1, -2);
end

function StartJumblePhrase()
local hFile,Er = io.open(sJumbleWordsFile, "r");
if(hFile == nil) then
SendToAll(sBotName, "Error opening "..sJumbleWordsFile);
return;
end
local _, phr = nil, nil;
local iFileSize = hFile:seek("end")
math.randomseed(os.clock());
while(phr == nil) do
hFile:seek("set", math.random(iFileSize)-1);
  _, phr = hFile:read( "*l", "*l");
end
hFile:close();
sActualPhrase = string.upper(phr);
sNoSpacePhrase = string.gsub(sActualPhrase, "%s", "");
sJumblePhrase = JumblePhrase(sActualPhrase);
iLength = string.len(sNoSpacePhrase);

SetJumbleHint();

SendToAll(sBotName, StrReplace(tStringTable[9]));

iTimeCount = 0;
bGameRunning = 1;
bGamePaused = nil;
StopTimer(); StartTimer();
end

function StopJumblePhrase()
SendToAll(sBotName, StrReplace(tStringTable[15]));
sActualPhrase, sNoSpacePhrase, sJumblePhrase = nil, nil, nil;

iTimeCount = 0;
bGamePaused = 1;
iGameNoReplyCount = iGameNoReplyCount + 1;
end

-- String Functions --

function StrReplace(sString)
sString = string.gsub(sString, "%$(%w+)", function (w)
if(string.sub(w,1,1) == "$") then
return string.sub(w,2,-1);
else
return _G[w] or "nil";
end
end);

return sString;
end

-- Score Functions --

function SetScores(sName)
local iCount = table.getn(tScores);
iDisplayCount = iDisplayScores or iCount

if(iDisplayScores) then
sScoresOutput = StrReplace(tStringTable[16]);
else
sScoresOutput = StrReplace(tStringTable[17]);
end

if(iCount == 0) then
sScoresOutput = StrReplace(tStringTable[18]);
else
table.sort(tScores, function(a, b) return a[2] > b[2]; end);

for i = 1, iCount, 1 do
tScores[i][3] = i; -- set ranks for all users
end

for i = 1, math.min(iDisplayCount, iCount), 1 do
iPos = i;
sUserName = tScores[iPos][1];
iUserScore = tScores[iPos][2];
sScoresOutput = sScoresOutput..StrReplace(tStringTable[19]);
end
end

sUserName = sName;

if(sName) then
return tScoresByName[sName][3];
end
end

function ReadScoresFromFile()
dofile(sJumbleScoresFile);

for i = 1, table.getn(tScores), 1 do
tScoresByName[tScores[i][1]] = tScores[i];
end
end
function ToArrival(user, data)
ChatArrival(user, data)
end
function WriteScoresToFile()
local hFile,Er = io.open(sJumbleScoresFile, "w");
hFile:write("tScores = {\n");
for i = 1, table.getn(tScores), 1 do
hFile:write("["..i.."] = {"..string.format("%q", tScores[i][1])..","..tScores[i][2].."},\n");
end
hFile:write("n="..table.getn(tScores).."\n");
hFile:write("};");
hFile:close();
end

-- Hint Functions --

function SetJumbleHint()
local tRevealArray = { };

local iReveal = assert(loadstring(StrReplace(sHintFormula)))();

local iPos = nil;

while(iReveal > 0) do
repeat iPos = math.random(iLength); until tRevealArray[iPos] == nil

tRevealArray[iPos] = 1;
iReveal = iReveal - 1;
end

tRevealArray.iPos = 1;

sHint = string.gsub(sActualPhrase, "(%S)", function (c)
if (c == nil) then return ""; end

local out, tTemp = nil, tRevealArray;

if(tTemp[tTemp.iPos]) then
out = c;
else
out = sHintChar;
end

tTemp.iPos = tTemp.iPos + 1;

return out.." ";
end);
sHint = string.sub(sHint, 1, -2);

sHintOutput = StrReplace(tStringTable[20]);
end

-- Channel Functions --

function SendToAllInChannel(sSender, sRawOutput)
if(sSender) then
local _;

if(sRawOutput == nil) then
sRawOutput = sSender;
_, _, sSender = string.find(sRawOutput, "^%<(.-)%>");
else
sRawOutput = "<"..sSender.."> "..sRawOutput;
end

for nick, val in tChannelUsers do
if(nick ~= sSender) then
SendToNick(nick, "$To: "..nick.." From: "..sBotName.." $"..sRawOutput);
end
end
end
end




Have Fun Peeps


??????Hawk??????
Title:
Post by: Jaakko on 04 March, 2005, 15:30:24
Thank you. Thank you. Thank you.
I needed this script because I had this translated in finnish in my ptokax 0.3.3.0 15.25, and I don't want to do the translating all over again.
(I'm not even sure can if you use external .txt file for xn?)
Title:
Post by: PPK on 04 March, 2005, 18:40:04
QuoteOriginally posted by ??????Hawk??????
I did wonder WHY??  when youve got all this  and More in XN 8.02  ..
Because not need to install and is not compiled ... i always make few changes in scripts :P
Title:
Post by: Tw?sT?d-d?v on 13 March, 2005, 12:09:55
thx HAWK ...... Any way of making it so it starts when hub is started and making it so it doesnt stop automatically .....
THX


all i need now is a triv game in lua 5 ..  any1 doing this yet ??
Title:
Post by: Anna on 16 March, 2005, 20:25:26
yes, check this thread, in lua 5 section


http://board.univ-angers.fr/thread.php?threadid=3961&boardid=26&styleid=1&sid=dff3e2c8ddf19fd55e0fc942223f5926 (http://board.univ-angers.fr/thread.php?threadid=3961&boardid=26&styleid=1&sid=dff3e2c8ddf19fd55e0fc942223f5926)
Title:
Post by: exlepra on 16 March, 2005, 23:14:18
thx for the conversion.
How can I make the privatejumle mode to default?
cos now after every scriprestart I have to type a.private .
Title:
Post by: Tw?sT?d-d?v on 29 March, 2005, 23:13:17
hi ... was wandering what i would need to change in the above script to reset the scores
Title:
Post by: Syphrone-NL on 01 April, 2005, 21:13:09
Hello all can somebody add me custom commands to my right click??

I want the jumble in my right click

Can somebody add me Start Jumble, Stop Jumble, Jumble Help, Jumble Scores

This is my right click:

OpConnected=NewUserConnected

ScriptCmds = {
["kick"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Kick user$<%[mynick]> !kick %[nick] %[line:Reason]",
["ban"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Ban user$<%[mynick]> !ban %[nick] %[line:Reason]",
["nameban"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Nameban user$<%[mynick]> !nameban %[nick] %[line:Reason]",
["timeban"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Timeban User$<%[mynick]> !timeban %[nick] %[line:hr:mn] %[line:Reason]",
["kill"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Kill user [nameban+ipban]$<%[mynick]> !kill %[nick] %[line:Reason]",
["warn"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Warn user$<%[mynick]> !warn %[nick] %[line:Reason]",
["flood"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Flood user$<%[mynick]> !flood %[nick] %[line:Nr] %[line:Reason]",
["drop"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Drop user$<%[mynick]> !drop %[nick]",
["hconfig"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Show hub config$<%[mynick]> !hconfig",
["hstat"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Show hub statics$<%[mynick]> !hstat",
["info"]="$UserCommand 1 3 "..sMenu.."\\INFO\\Show user info$<%[mynick]> !info %[nick]",
["mass"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send mass message$<%[mynick]> !mass %[line:Message]",
["banner"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send hub banner message$<%[mynick]> !banner %[line:Text]",
["sendhubad"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send hub advertise add [main/pm]$<%[mynick]> !sendhubad %[line:main/pm]",
["talk"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Talk whitout nick$<%[mynick]> !talk %[line:Message]",
["online"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set online check [user/ip]$<%[mynick]> !online %[line:nick/ip]",
["offline"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set offline message to user$<%[mynick]> !offline %[line:nick] %[line:message]",
["watch"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Watch a user$<%[mynick]> !watch %[nick]",
["watchoff"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\set watcher off$<%[mynick]> !watchoff",
["getwatch"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Show all watchers$<%[mynick]> !getwatch",
["cmdspy"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set commandspy [on/off]$<%[mynick]> !cmdspy %[line:on/off]",
["topkickers"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show current topkickers$<%[mynick]> !topkickers",
["tophubbers"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show current tophubbers$<%[mynick]> !tophubbers",
["sminslots"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script minslots$<%[mynick]> !sminslots %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["smaxslots"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script maxslots$<%[mynick]> !smaxslots %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["smaxhubs"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script max hubs$<%[mynick]> !smaxhubs %[line:user/reg/vip/op/mod/master/founder] %[line:hubs]",
["sratio"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script slots/hubs ratio$<%[mynick]> !sratio %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["slimiter"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script bandwidth limiter$<%[mynick]> !slimiter %[line:user/reg/vip/op/mod/master/founder] %[line:limiter]",
["sminshare"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script minshare$<%[mynick]> !sminshare %[line:user/reg/vip/op/mod/master/founder] %[line:share] %[line:mb/gb]",
["smaxshare"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script maxshare$<%[mynick]> !smaxshare %[line:user/reg/vip/op/mod/master/founder] %[line:share] %[line:mb/gb]",
["hmaxusr"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set max users$<%[mynick]> !hmaxusr %[line:Number]",
["hdesc"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hub description$<%[mynick]> !hdesc %[line:Hub_Description]",
["chhubname"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hubname$<%[mynick]> !chhubname %[line:New Hubname]",
["chopchat"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set Op-Chat name$<%[mynick]> !chopchat",
["regserver"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set regserver address$<%[mynick]> !regserver %[line:New_Reg_Address]",
["autoredirect"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hub auto redirect users [on/off]$<%[mynick]> !autoredirect %[line:on/off]",
["autoregister"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set autoregister [on/off]$<%[mynick]> !autoregister %[line:on/off]",
["redirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Set hub redirect address$<%[mynick]> !redirect %[line:Host /Ip]",
["redirectfull"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Set hub redirect full [on/off]$<%[mynick]> !redirectfull %[line:on/off]",
["addredirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Add new address to redirect list$<%[mynick]> !addredirect %[line:Url/Ip]",
["delredirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Remove address from redirect list$<%[mynick]> !delredirect %[line:Url/Ip]",
["showredirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Show all listed redirect addresses$<%[mynick]> !showredirect",
["unbot"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Remove old botnames from userlist$<%[mynick]> !unbot %[nick]",
["hubprotect"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hub protection [on/off]$<%[mynick]> !hubprotect %[line:on/off]",
["getblocked"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Show current blocked users$<%[mynick]> !getblocked",
["massblocked"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send mass message to blocked users$<%[mynick]> !massblocked %[line:Message]",
["kickblocked"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Kick current blocked users$<%[mynick]> !kickblocked ",
["regreg"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as REG$<%[mynick]> !regreg %[nick] %[line:Password]",
["regvip"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as VIP$<%[mynick]> !regvip %[nick] %[line:Password]",
["regop"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as OP$<%[mynick]> !regop %[nick] %[line:Password]",
["regmod"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as MOD$<%[mynick]> !regmod %[nick] %[line:Password]",
["regmaster"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as MASTER$<%[mynick]> !regmaster %[nick] %[line:Password]",
["regfounder"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as FOUNDER$<%[mynick]> !regfounder %[nick] %[line:Password]",
["deluser"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Delete registerd user$<%[mynick]> !deluser %[nick]",
["upgrade"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Upgrade/Downgrade registerd users$<%[mynick]> !upgrade %[nick] %[line:reg/vip/op/mod/master/founder]",
["getpass"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Get password registerd user$<%[mynick]> !getpass %[nick]",
["resethstat"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Reset hub counters/statics$<%[mynick]> !resethstat",
["clear"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Clear logs/bans user$<%[mynick]> !clear %[nick]",
["showiplog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the iplog$<%[mynick]> !showiplog",
["showkicklog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the kicklog$<%[mynick]> !showkicklog",
["showbanlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the banlog$<%[mynick]> !showbanlog",
["showwarnlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the warnlog$<%[mynick]> !showwarnlog",
["delkicklog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Delete the kicklog$<%[mynick]> !delkicklog",
["delbanlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Delete the banlog$<%[mynick]> !delbanlog",
["delwarnlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Delete the warnlog$<%[mynick]> !delwarnlog",
["showlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Showlog user/ip$<%[mynick]> !showlog %[line:name/ip] ",
["follow"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set kick/ban/etc messages [on/off]$<%[mynick]> !follow %[line:On/Off] ",
["rules"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the hub rules$<%[mynick]> !rules",
["network"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the network info$<%[mynick]> !network",
["faq"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show faq about DC++$<%[mynick]> !faq",
["myip"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show your currently IP$<%[mynick]> !myip",
["myinfo"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show all your available info$<%[mynick]> !myinfo",
["version"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the script version$<%[mynick]> !version",
["regme"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Register me at this hub$<%[mynick]> !regme %[line:Password]",
["repass"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Change your own password$<%[mynick]> !repass %[line:New Pass]",
["showreg"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show all users by profile$<%[mynick]> !showreg %[line:reg/vip/op/mod/master/founder]",
["away"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Set my away message$<%[mynick]> !away %[line:Message]",
["back"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Restore my away message$<%[mynick]> !back",
["getaways"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show all current away messages$<%[mynick]> !getaways",
["report"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Report user to all OP's$<%[mynick]> !report %[nick] %[line:Message]",
["myhubtime"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show your total online time$<%[mynick]> !myhubtime",
["slots"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show users whit free slots$<%[mynick]> !slots",
["help"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show you this help$<%[mynick]> !help",
["inbuild"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the inbuild commands$<%[mynick]> !inbuild",
["showreglog"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Show the registerlog$<%[mynick]> !showreglog",
}
InbuildCmds = {
["gag"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Gag user$<%[mynick]> !gag %[nick]",
["ungag"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Ungag user$<%[mynick]> !ungag %[nick]",
["banip"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Banip user$<%[mynick]> !banip %[line:Ipnumber]",
["unban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Unban user$<%[mynick]> !unban %[nick] %[line:nick/ip]",
["nickban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Nickban user$<%[mynick]> !nickban %[nick] %[line:Reason]",
["getbanlist"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Getbanlist$<%[mynick]> !getbanlist",
["clrpermban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Clearpermban$<%[mynick]> !clrpermban",
["clrtempban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Cleartempban$<%[mynick]> !clrtempban",
["op"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Give user temperory op status$<%[mynick]> !op %[nick]",
["getinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Basic info user$<%[mynick]> !getinfo %[nick]",
["ipinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Show users with that ip$<%[mynick]> !getinfo %[line:Ipnumber]",
["iprangeinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Show users within that iprange$<%[mynick]> !iprangeinfo %[line:Ipnumber]",
["topic"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Change the hub topic$<%[mynick]> !topic %[line:Topic]",
["restart"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Restart hub$<%[mynick]> !restart",
["restartscripts"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Restart scripts$<%[mynick]> !restartscripts",
["gettempbanlist"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Gettempbanlist$<%[mynick]> !gettempbanlist",
["userinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Info user$<%[mynick]> !userinfo %[nick]",
["reloadtxt"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Reload the hub textfiles$<%[mynick]> !reloadtxt",
["tempunban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Unban tempbanned user$<%[mynick]> !tempunban %[nick]",
["tempban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Tempban user for x minutes$<%[mynick]> !tempban %[nick]",
}

customCMDs = function(user) --// You can put your custome commands here
--user:SendData("$UserCommand 1 3 zCUSTOM\\Test$<%[mynick]> !test||") -- Example line
end


Can you post then the whole script again
Already thx
Title:
Post by: Tw?sT?d-d?v on 01 April, 2005, 21:49:10
try this
OpConnected=NewUserConnected

ScriptCmds = {
["kick"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Kick user$<%[mynick]> !kick %[nick] %[line:Reason]",
["ban"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Ban user$<%[mynick]> !ban %[nick] %[line:Reason]",
["nameban"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Nameban user$<%[mynick]> !nameban %[nick] %[line:Reason]",
["timeban"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Timeban User$<%[mynick]> !timeban %[nick] %[line:hr:mn] %[line:Reason]",
["kill"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Kill user [nameban+ipban]$<%[mynick]> !kill %[nick] %[line:Reason]",
["warn"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Warn user$<%[mynick]> !warn %[nick] %[line:Reason]",
["flood"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Flood user$<%[mynick]> !flood %[nick] %[line:Nr] %[line:Reason]",
["drop"]="$UserCommand 1 3 "..sMenu.."\\KICK/BAN\\Drop user$<%[mynick]> !drop %[nick]",
["hconfig"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Show hub config$<%[mynick]> !hconfig",
["hstat"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Show hub statics$<%[mynick]> !hstat",
["info"]="$UserCommand 1 3 "..sMenu.."\\INFO\\Show user info$<%[mynick]> !info %[nick]",
["mass"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send mass message$<%[mynick]> !mass %[line:Message]",
["banner"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send hub banner message$<%[mynick]> !banner %[line:Text]",
["sendhubad"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send hub advertise add [main/pm]$<%[mynick]> !sendhubad %[line:main/pm]",
["talk"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Talk whitout nick$<%[mynick]> !talk %[line:Message]",
["online"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set online check [user/ip]$<%[mynick]> !online %[line:nick/ip]",
["offline"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set offline message to user$<%[mynick]> !offline %[line:nick] %[line:message]",
["watch"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Watch a user$<%[mynick]> !watch %[nick]",
["watchoff"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\set watcher off$<%[mynick]> !watchoff",
["getwatch"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Show all watchers$<%[mynick]> !getwatch",
["cmdspy"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set commandspy [on/off]$<%[mynick]> !cmdspy %[line:on/off]",
["topkickers"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show current topkickers$<%[mynick]> !topkickers",
["tophubbers"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show current tophubbers$<%[mynick]> !tophubbers",
["sminslots"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script minslots$<%[mynick]> !sminslots %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["smaxslots"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script maxslots$<%[mynick]> !smaxslots %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["smaxhubs"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script max hubs$<%[mynick]> !smaxhubs %[line:user/reg/vip/op/mod/master/founder] %[line:hubs]",
["sratio"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script slots/hubs ratio$<%[mynick]> !sratio %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["slimiter"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script bandwidth limiter$<%[mynick]> !slimiter %[line:user/reg/vip/op/mod/master/founder] %[line:limiter]",
["sminshare"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script minshare$<%[mynick]> !sminshare %[line:user/reg/vip/op/mod/master/founder] %[line:share] %[line:mb/gb]",
["smaxshare"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set script maxshare$<%[mynick]> !smaxshare %[line:user/reg/vip/op/mod/master/founder] %[line:share] %[line:mb/gb]",
["hmaxusr"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set max users$<%[mynick]> !hmaxusr %[line:Number]",
["hdesc"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hub description$<%[mynick]> !hdesc %[line:Hub_Description]",
["chhubname"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hubname$<%[mynick]> !chhubname %[line:New Hubname]",
["chopchat"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set Op-Chat name$<%[mynick]> !chopchat",
["regserver"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set regserver address$<%[mynick]> !regserver %[line:New_Reg_Address]",
["autoredirect"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hub auto redirect users [on/off]$<%[mynick]> !autoredirect %[line:on/off]",
["autoregister"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set autoregister [on/off]$<%[mynick]> !autoregister %[line:on/off]",
["redirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Set hub redirect address$<%[mynick]> !redirect %[line:Host /Ip]",
["redirectfull"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Set hub redirect full [on/off]$<%[mynick]> !redirectfull %[line:on/off]",
["addredirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Add new address to redirect list$<%[mynick]> !addredirect %[line:Url/Ip]",
["delredirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Remove address from redirect list$<%[mynick]> !delredirect %[line:Url/Ip]",
["showredirect"]="$UserCommand 1 3 "..sMenu.."\\REDIRECT\\Show all listed redirect addresses$<%[mynick]> !showredirect",
["unbot"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Remove old botnames from userlist$<%[mynick]> !unbot %[nick]",
["hubprotect"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Set hub protection [on/off]$<%[mynick]> !hubprotect %[line:on/off]",
["getblocked"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Show current blocked users$<%[mynick]> !getblocked",
["massblocked"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Send mass message to blocked users$<%[mynick]> !massblocked %[line:Message]",
["kickblocked"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Kick current blocked users$<%[mynick]> !kickblocked ",
["regreg"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as REG$<%[mynick]> !regreg %[nick] %[line:Password]",
["regvip"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as VIP$<%[mynick]> !regvip %[nick] %[line:Password]",
["regop"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as OP$<%[mynick]> !regop %[nick] %[line:Password]",
["regmod"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as MOD$<%[mynick]> !regmod %[nick] %[line:Password]",
["regmaster"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as MASTER$<%[mynick]> !regmaster %[nick] %[line:Password]",
["regfounder"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Register user as FOUNDER$<%[mynick]> !regfounder %[nick] %[line:Password]",
["deluser"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Delete registerd user$<%[mynick]> !deluser %[nick]",
["upgrade"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Upgrade/Downgrade registerd users$<%[mynick]> !upgrade %[nick] %[line:reg/vip/op/mod/master/founder]",
["getpass"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Get password registerd user$<%[mynick]> !getpass %[nick]",
["resethstat"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Reset hub counters/statics$<%[mynick]> !resethstat",
["clear"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Clear logs/bans user$<%[mynick]> !clear %[nick]",
["showiplog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the iplog$<%[mynick]> !showiplog",
["showkicklog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the kicklog$<%[mynick]> !showkicklog",
["showbanlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the banlog$<%[mynick]> !showbanlog",
["showwarnlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Show the warnlog$<%[mynick]> !showwarnlog",
["delkicklog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Delete the kicklog$<%[mynick]> !delkicklog",
["delbanlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Delete the banlog$<%[mynick]> !delbanlog",
["delwarnlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Delete the warnlog$<%[mynick]> !delwarnlog",
["showlog"]="$UserCommand 1 3 "..sMenu.."\\LOG\\Showlog user/ip$<%[mynick]> !showlog %[line:name/ip] ",
["follow"]="$UserCommand 1 3 "..sMenu.."\\OTHER\\Set kick/ban/etc messages [on/off]$<%[mynick]> !follow %[line:On/Off] ",
["rules"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the hub rules$<%[mynick]> !rules",
["network"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the network info$<%[mynick]> !network",
["faq"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show faq about DC++$<%[mynick]> !faq",
["myip"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show your currently IP$<%[mynick]> !myip",
["myinfo"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show all your available info$<%[mynick]> !myinfo",
["version"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the script version$<%[mynick]> !version",
["regme"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Register me at this hub$<%[mynick]> !regme %[line:Password]",
["repass"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Change your own password$<%[mynick]> !repass %[line:New Pass]",
["showreg"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show all users by profile$<%[mynick]> !showreg %[line:reg/vip/op/mod/master/founder]",
["away"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Set my away message$<%[mynick]> !away %[line:Message]",
["back"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Restore my away message$<%[mynick]> !back",
["getaways"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show all current away messages$<%[mynick]> !getaways",
["report"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Report user to all OP's$<%[mynick]> !report %[nick] %[line:Message]",
["myhubtime"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show your total online time$<%[mynick]> !myhubtime",
["slots"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show users whit free slots$<%[mynick]> !slots",
["help"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show you this help$<%[mynick]> !help",
["inbuild"]="$UserCommand 1 3 "..sMenu.."\\NORMAL\\Show the inbuild commands$<%[mynick]> !inbuild",
["showreglog"]="$UserCommand 1 3 "..sMenu.."\\REGISTER\\Show the registerlog$<%[mynick]> !showreglog",
}
InbuildCmds = {
["gag"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Gag user$<%[mynick]> !gag %[nick]",
["ungag"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Ungag user$<%[mynick]> !ungag %[nick]",
["banip"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Banip user$<%[mynick]> !banip %[line:Ipnumber]",
["unban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Unban user$<%[mynick]> !unban %[nick] %[line:nick/ip]",
["nickban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Nickban user$<%[mynick]> !nickban %[nick] %[line:Reason]",
["getbanlist"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Getbanlist$<%[mynick]> !getbanlist",
["clrpermban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Clearpermban$<%[mynick]> !clrpermban",
["clrtempban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Cleartempban$<%[mynick]> !clrtempban",
["op"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Give user temperory op status$<%[mynick]> !op %[nick]",
["getinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Basic info user$<%[mynick]> !getinfo %[nick]",
["ipinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Show users with that ip$<%[mynick]> !getinfo %[line:Ipnumber]",
["iprangeinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Show users within that iprange$<%[mynick]> !iprangeinfo %[line:Ipnumber]",
["topic"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Change the hub topic$<%[mynick]> !topic %[line:Topic]",
["restart"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Restart hub$<%[mynick]> !restart",
["restartscripts"]="$UserCommand 1 3 "..sMenu.."\\SETTING\\Restart scripts$<%[mynick]> !restartscripts",
["gettempbanlist"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Gettempbanlist$<%[mynick]> !gettempbanlist",
["userinfo"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Info user$<%[mynick]> !userinfo %[nick]",
["reloadtxt"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Reload the hub textfiles$<%[mynick]> !reloadtxt",
["tempunban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Unban tempbanned user$<%[mynick]> !tempunban %[nick]",
["tempban"]="$UserCommand 1 3 "..sMenu.."\\INBUILD\\Tempban user for x minutes$<%[mynick]> !tempban %[nick]",
}

customCMDs = function(user) --// You can put your custome commands here
user:SendData("$UserCommand 1 3 "..sMenu.."\\JUMBLE\\START ANAGRAMS$<%[mynick]> a.start|")
user:SendData("$UserCommand 1 3 "..sMenu.."\\JUMBLE\\STOP ANAGRAMS$<%[mynick]> a.stop|")
user:SendData("$UserCommand 1 3 "..sMenu.."\\JUMBLE\\DISPLAY PHRASE$<%[mynick]> a.phrase|")
user:SendData("$UserCommand 1 3 "..sMenu.."\\JUMBLE\\ANAGRAMS SCORES$<%[mynick]> a.scores|")
end
Title: right click (modified) part 1
Post by: ?Tr??T_???? on 18 July, 2005, 17:19:28
-- RightClicker for RoboCopv10.01
-- Made by Optimus & TiMeTrAVelleR
-- Optimized and fixed some stuff by [']['?N]Azim
-- Best is not to use it for normal users takes to much bandwidth

aMenu = "Quick Commands"
cMenu = "Hub Control"
eMenu = "Logs"
gMenu = "Misc"
sMenu = "']['h? ?impl? N?']['w?rK"
iMenu = "Hub Security"
kMenu = "Regs"
xMenu = "Games"
yMenu = "']['h? ?impl? N?']['w?rK"



SendTo = { --> 1=on/0=off
[on/off]$<%[mynick]> !cmdspy %[line:on/off]",
["sminslots"]="$UserCommand 1 3 "..cMenu.."\\Config\\Slots/Hubs\\Set script minslots$<%[mynick]> !sminslots %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["smaxslots"]="$UserCommand 1 3 "..cMenu.."\\Config\\Slots/Hubs\\Set script maxslots$<%[mynick]> !smaxslots %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["smaxhubs"]="$UserCommand 1 3 "..cMenu.."\\Config\\Slots/Hubs\\Set script max hubs$<%[mynick]> !smaxhubs %[line:user/reg/vip/op/mod/master/founder] %[line:hubs]",
["sratio"]="$UserCommand 1 3 "..cMenu.."\\Config\\Slots/Hubs\\Set script slots/hubs ratio$<%[mynick]> !sratio %[line:user/reg/vip/op/mod/master/founder] %[line:slots]",
["sminshare"]="$UserCommand 1 3 "..cMenu.."\\Config\\Sharing/Users\\Set script minshare$<%[mynick]> !sminshare %[line:user/reg/vip/op/mod/master/founder] %[line:share] %[line:mb/gb]",
["smaxshare"]="$UserCommand 1 3 "..cMenu.."\\Config\\Sharing/Users\\Set script maxshare$<%[mynick]> !smaxshare %[line:user/reg/vip/op/mod/master/founder] %[line:share] %[line:mb/gb]",
["hmaxusr"]="$UserCommand 1 3 "..cMenu.."\\Config\\Sharing/Users\\Set max users$<%[mynick]> !hmaxusr %[line:Number]",
["chhubname"]="$UserCommand 1 3 "..cMenu.."\\Config\\Other\\Set hubname$<%[mynick]> !chhubname %[line:New Hubname]",
["chopchat"]="$UserCommand 1 3 "..cMenu.."\\Config\\Other\\Set Op-Chat name$<%[mynick]> !chopchat",
["regserver"]="$UserCommand 1 3 "..cMenu.."\\Config\\Other\\Set regserver address$<%[mynick]> !regserver %[line:New_Reg_Address]",
["autoregister"]="$UserCommand 1 3 "..cMenu.."\\Config\\Other\\Set autoregister [on/off]$<%[mynick]> !autoregister %[line:on/off]",
["hubprotect"]="$UserCommand 1 3 "..cMenu.."\\Config\\Other\\Set hub protection [on/off]$<%[mynick]> !hubprotect %[line:on/off]",
["slimiter"]="$UserCommand 1 3 "..cMenu.."\\Config\\Other\\Set script bandwidth limiter$<%[mynick]> !slimiter %[line:user/reg/vip/op/mod/master/founder] %[line:limiter]",
["follow"]="$UserCommand 1 3 "..cMenu.."\\Config\\Other\\Set kick/ban/etc messages [on/off]$<%[mynick]> !follow %[line:On/Off] ",
["redirect"]="$UserCommand 1 3 "..cMenu.."\\Config\\Redirecting\\Set hub redirect address$<%[mynick]> !redirect %[line:Host /Ip]",
["redirectfull"]="$UserCommand 1 3 "..cMenu.."\\Config\\Redirecting\\Set hub redirect full [on/off]$<%[mynick]> !redirectfull %[line:on/off]",
["addredirect"]="$UserCommand 1 3 "..cMenu.."\\Config\\Redirecting\\Add new address to redirect list$<%[mynick]> !addredirect %[line:Url/Ip]",
["delredirect"]="$UserCommand 1 3 "..cMenu.."\\Config\\Redirecting\\Remove address from redirect list$<%[mynick]> !delredirect %[line:Url/Ip]",
["showredirect"]="$UserCommand 1 3 "..cMenu.."\\Config\\Redirecting\\Show all listed redirect addresses$<%[mynick]> !showredirect",
["autoredirect"]="$UserCommand 1 3 "..cMenu.."\\Config\\Redirecting\\Set hub auto redirect users [on/off]$<%[mynick]> !autoredirect %[line:on/off]",

--eMenu = "LOG MENU"
["showbanlog"]="$UserCommand 1 3 "..eMenu.."\\Bans\\Show the banlog$<%[mynick]> !showbanlog",
["delbanlog"]="$UserCommand 1 3 "..eMenu.."\\Bans\\Delete the banlog$<%[mynick]> !delbanlog",
["delkicklog"]="$UserCommand 1 3 "..eMenu.."\\Kicks\\Delete the kicklog$<%[mynick]> !delkicklog",
["showkicklog"]="$UserCommand 1 3 "..eMenu.."\\Kicks\\Show the kicklog$<%[mynick]> !showkicklog",
["delwarnlog"]="$UserCommand 1 3 "..eMenu.."\\Warns\\Delete the warnlog$<%[mynick]> !delwarnlog",
["showwarnlog"]="$UserCommand 1 3 "..eMenu.."\\Warns\\Show the warnlog$<%[mynick]> !showwarnlog",
["showlog"]="$UserCommand 1 3 "..eMenu.."\\Other\\Showlog user/ip$<%[mynick]> !showlog %[line:name/ip] ",
["clear"]="$UserCommand 1 3 "..eMenu.."\\Other\\Clear logs/bans user$<%[mynick]> !clear %[nick]",
["showiplog"]="$UserCommand 1 3 "..eMenu.."\\Other\\Show the iplog$<%[mynick]> !showiplog",

--gMenu = "MISC"
["slots"]="$UserCommand 1 3 "..gMenu.."\\Info\\Show users whit free slots$<%[mynick]> !slots",
["version"]="$UserCommand 1 3 "..gMenu.."\\Info\\Show the script version$<%[mynick]> !version",
["network"]="$UserCommand 1 3 "..gMenu.."\\Info\\Show the network info$<%[mynick]> !network",
["myip"]="$UserCommand 1 3 "..gMenu.."\\Info\\Show your currently IP$<%[mynick]> !myip",
["myinfo"]="$UserCommand 1 3 "..gMenu.."\\Info\\Show all your available info$<%[mynick]> !myinfo",
["getblocked"]="$UserCommand 1 3 "..gMenu.."\\Blocked\\Show current blocked users$<%[mynick]> !getblocked",
["massblocked"]="$UserCommand 1 3 "..gMenu.."\\Blocked\\Send mass message to blocked users$<%[mynick]> !massblocked %[line:Message]",
["kickblocked"]="$UserCommand 1 3 "..gMenu.."\\Blocked\\Kick current blocked users$<%[mynick]> !kickblocked ",
["myhubtime"]="$UserCommand 1 3 "..gMenu.."\\Stats\\Show your total online time$<%[mynick]> !myhubtime",
["topkickers"]="$UserCommand 1 3 "..gMenu.."\\Stats\\Show current topkickers$<%[mynick]> !topkickers",
["tophubbers"]="$UserCommand 1 3 "..gMenu.."\\Stats\\Show current tophubbers$<%[mynick]> !tophubbers",
["away"]="$UserCommand 1 3 "..gMenu.."\\Away\\Set my away message$<%[mynick]> !away %[line:Message]",
["back"]="$UserCommand 1 3 "..gMenu.."\\Away\\Restore my away message$<%[mynick]> !back",
["getaways"]="$UserCommand 1 3 "..gMenu.."\\Away\\Show all current away messages$<%[mynick]> !getaways",
["flood"]="$UserCommand 1 3 "..gMenu.."\\Other\\Flood user$<%[mynick]> !flood %[nick] %[line:Nr] %[line:Reason]",
["online"]="$UserCommand 1 3 "..gMenu.."\\Other\\Set online check [user/ip]$<%[mynick]> !online %[line:nick/ip]",
["offline"]="$UserCommand 1 3 "..gMenu.."\\Other\\Set offline message to user$<%[mynick]> !offline %[nick] %[line:Message]",
["faq"]="$UserCommand 1 3 "..gMenu.."\\Other\\Show faq about DC++$<%[mynick]> !faq",

--kMenu = "REG MENU"
["regreg"]="$UserCommand 1 3 "..kMenu.."\\Register\\Register user as REG$<%[mynick]> !regreg %[nick] %[line:Password]",
["regvip"]="$UserCommand 1 3 "..kMenu.."\\Register\\Register user as VIP$<%[mynick]> !regvip %[nick] %[line:Password]",
["regop"]="$UserCommand 1 3 "..kMenu.."\\Register\\Register user as OP$<%[mynick]> !regop %[nick] %[line:Password]",
["regmod"]="$UserCommand 1 3 "..kMenu.."\\Register\\Register user as MOD$<%[mynick]> !regmod %[nick] %[line:Password]",
["regmaster"]="$UserCommand 1 3 "..kMenu.."\\Register\\Register user as MASTER$<%[mynick]> !regmaster %[nick] %[line:Password]",
["regfounder"]="$UserCommand 1 3 "..kMenu.."\\Register\\Register user as FOUNDER$<%[mynick]> !regfounder %[nick] %[line:Password]",
["deluser"]="$UserCommand 1 3 "..kMenu.."\\Change Reg\\Delete registerd user$<%[mynick]> !deluser %[nick]",
["upgrade"]="$UserCommand 1 3 "..kMenu.."\\Change Reg\\Upgrade/Downgrade registerd users$<%[mynick]> !upgrade %[nick] %[line:reg/vip/op/mod/master/founder]",
["repass"]="$UserCommand 1 3 "..kMenu.."\\Change Reg\\Change your own password$<%[mynick]> !repass %[line:New Pass]",
["getpass"]="$UserCommand 1 3 "..kMenu.."\\Other\\Get password registerd user$<%[mynick]> !getpass %[nick]",
["showreglog"]="$UserCommand 1 3 "..kMenu.."\\Other\\Show the registerlog$<%[mynick]> !showreglog",
["regme"]="$UserCommand 1 3 "..kMenu.."\\Other\\Register me at this hub$<%[mynick]> !regme %[line:Password]",
["showreg"]="$UserCommand 1 3 "..kMenu.."\\Other\\Show all users by profile$<%[mynick]> !showreg %[line:reg/vip/op/mod/master/founder]",
["unbot"]="$UserCommand 1 3 "..kMenu.."\\Other\\Remove old botnames from userlist$<%[mynick]> !unbot %[nick]",
Title: part 2
Post by: ?Tr??T_???? on 18 July, 2005, 17:20:10
}
InbuildCmds = {
["banip"]="$UserCommand 1 3 "..aMenu.."\\Ban\\Banip user$<%[mynick]> !banip %[line:Ipnumber]",
["unban"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Unban user$<%[mynick]> !unban %[nick] %[line:nick/ip]",
["nickban"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Nickban user$<%[mynick]> !nickban %[nick] %[line:Reason]",
["getbanlist"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Getbanlist$<%[mynick]> !getbanlist",
["clrpermban"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Clearpermban$<%[mynick]> !clrpermban",
["clrtempban"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Cleartempban$<%[mynick]> !clrtempban",
["gettempbanlist"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Gettempbanlist$<%[mynick]> !gettempbanlist",
["tempunban"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Unban tempbanned user$<%[mynick]> !tempunban %[nick]",
["tempban"]="$UserCommand 1 3 "..iMenu.."\\Ban Controls\\Tempban user for x minutes$<%[mynick]> !tempban %[nick]",
["getinfo"]="$UserCommand 1 3 "..iMenu.."\\Info\\Basic info user$<%[mynick]> !getinfo %[nick]",
["ipinfo"]="$UserCommand 1 3 "..iMenu.."\\Info\\Show users with that ip$<%[mynick]> !getinfo %[line:Ipnumber]",
["userinfo"]="$UserCommand 1 3 "..iMenu.."\\Info\\Info user$<%[mynick]> !userinfo %[nick]",
["iprangeinfo"]="$UserCommand 1 3 "..iMenu.."\\Info\\Show users within that iprange$<%[mynick]> !iprangeinfo %[line:Ipnumber]",
["restart"]="$UserCommand 1 3 "..iMenu.."\\Hub Controls\\Restart hub$<%[mynick]> !restart",
["restartscripts"]="$UserCommand 1 3 "..iMenu.."\\Hub Controls\\Restart scripts$<%[mynick]> !restartscripts",
["reloadtxt"]="$UserCommand 1 3 "..iMenu.."\\Hub Controls\\Reload the hub textfiles$<%[mynick]> !reloadtxt",
["topic"]="$UserCommand 1 3 "..iMenu.."\\Other\\Change the hub topic$<%[mynick]> !topic %[line:Topic]",
["gag"]="$UserCommand 1 3 "..iMenu.."\\Other\\Gag user$<%[mynick]> !gag %[nick]",
["ungag"]="$UserCommand 1 3 "..iMenu.."\\Other\\Ungag user$<%[mynick]> !ungag %[nick]",
["op"]="$UserCommand 1 3 "..iMenu.."\\Other\\Give user temperory op status$<%[mynick]> !op %[nick]",
}

customCMDs = function(user) --// You can put your custome commands here
-- remove the (--) if using the jumble program
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Start Trivia$<%[mynick]> tbstart||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Stop Trivia$<%[mynick]> tbstop||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Join Trivia$<%[mynick]> tbjoin||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Hint$<%[mynick]> tbhintme||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Save Scores$<%[mynick]> tbhelp||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Load Scores$<%[mynick]> tbhelp||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Trivia Scores$<%[mynick]> tbscores||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Trivia\\Trivia Help$<%[mynick]> tbhelp||")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Jumble\\Start Jumble$<%[mynick]> a.start|")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Jumble\\Stop Jumble$<%[mynick]> a.stop|")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Jumble\\Display a Phrase$<%[mynick]> a.phrase|")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Jumble\\Join Jumble$<%[mynick]> a.join|")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Jumble\\Jumble Scores$<%[mynick]> a.scores|")
user:SendData("$UserCommand 1 3 "..xMenu.."\\Jumble\\Jumble Help$<%[mynick]> a.help|")
user:SendData("$UserCommand 1 4 zCUSTOMBadFile $$To: %[nick] From: %[mynick] $<%[mynick]> The follwing file is not allowed in here %[file]||")
end
Title: right click
Post by: ?Tr??T_???? on 18 July, 2005, 17:20:57
hope it helps
Title: hide bot
Post by: ?Tr??T_???? on 11 August, 2005, 11:16:56
can someone do a function in this jumble.lua to enable reg bot on hub or not... :rolleyes: