PtokaX forum

Archive => Archived 4.0 boards => Finished Lua 4 scripts => Topic started by: NeoUltimicia on 04 October, 2004, 23:36:33

Title: Not in order!!!
Post by: NeoUltimicia on 04 October, 2004, 23:36:33
I kept testing and trying to make the right click for RoboCop9.0-beta list in order. thou, it did not work at all.
Quote- RightClicker for RoboCopv9.0-Beta
--
-- Made by Optimus & TiMeTrAVelleR
-- USE SCRIPT AT YOUR OWN RISK, IT MAY NOT BE COMPATIBLE WITH ALL CLIENTS
--
-- Editable Settings --

-- 1=on / 0=off
SendTo = {
  • = 1,   -- Masters
  • [1] = 1,   -- Operators
    [2] = 1,   -- Vips
    [3] = 1,   -- Regs
    [4] = 1,   -- Moderator
    [5] = 1,   -- NetFounder
    [-1] = 1,  -- Users
    }

    sMenu = "RC"

    -- End Editable Settings --

    assert(dofile("tbl/scriptlevel.tbl"),"tbl/scriptlevel.tbl not found")
    assert(dofile("tbl/inbuildlevel.tbl"),"tbl/inbuildlevel.tbl not found")

    function customCMDs(user)
       --user:SendData("$UserCommand 1 3 zCUSTOM\\Test$<%[mynick]> +test||")   -- test
    end

    function NewUserConnected(user)
       if (SendTo[user.iProfile]==1) then
          user:SendData("$UserCommand 255 7 |")      
          user:SendData("$UserCommand 0 3 |")
          GetRightClick(user, ScriptLevel, ScriptCmds)
          GetRightClick(user, InbuildLevel, InbuildCmds)
          customCMDs(user)
          user:SendData(" Enhanced Right Click Support for [RoboCop] is available!")
       end
    end

    OpConnected=NewUserConnected

    function GetRightClick(user, table1, table2)
       for cmd,_ in table1 do
          if table1[cmd][user.iProfile] == 1 then
             for value,command in table2 do
                if cmd == value then
                   user:SendData(command)
                end
             end
          end
       end
    end

    ScriptCmds = {
    ["kick"]="$UserCommand 1 2 "..sMenu.."\\KICK/BAN\\
Kick User $<%[mynick]> !kick  %[nick] %[line:Reason]||",   -- kick
["ban"]="$UserCommand 1 2 "..sMenu.."\\KICK/BAN\\Ban User $<%[mynick]> !ban   %[nick] %[line:Reason]||",   -- ban
["nameban"]="$UserCommand 1 2 "..sMenu.."\\KICK/BAN\\Nameban User $<%[mynick]> !nameban  %[nick] %[line:Reason]||",   -- nameban
for example, for these three commands, I get like this in DC++:
RC > Kick User
RC > Nameban User
RC > Ban User

why they have changed their order!?? any idea!? is there a way to fix this?
Title: Oppss
Post by: NeoUltimicia on 04 October, 2004, 23:41:22
I hate this, lol.. I wanted to make a reply to a post.. and made a NEW thread.. sorry guys...

Original thread (http://board.univ-angers.fr/thread.php?threadid=2341&boardid=15&styleid=1&sid=cf72a0315d66702af6b85dbaefd4bfa1)