Jump to content

كيف اعرف كلمة الامر اللى اكتبها بالشات


Recommended Posts

السلام عليكم

اخواني انا الحين حملت مود وفتحت ملف

lua

المود مثلا عبارة عن اظهار الادمن الاون لاين

اريد اعرف ايش الكلمة اللى اكتبها بالشات عشان يظهر الادمن

يعني كيف اعرف الامر وين الاقي كلمتها

مثال #

addCommandHandler("admins",function(p) 
    local Admins,SuperModerators,Moderator = getOnlineAdmins() -- the function will return 3 tables 
    if #Admins ~= 0 then -- if the admins table not empty then 
        outputChatBox("Online Admins",p,255,0,0,true) 
        for k,v in ipairs ( Admins ) do -- loop the table 
            outputChatBox(""..getPlayerName(v),p,255,128,0,true) -- output the player name 
        end 
    end 
end ) 
function getOnlineAdmins() 
    local t1,t2,t3 = {},{},{} 
    for k,v in ipairs ( getElementsByType("player") ) do 
        local acc = getPlayerAccount(v);if not acc or isGuestAccount(acc) then return end;local accName = getAccountName(acc) 
        local isAdmin,isSMOD,isMod = isObjectInACLGroup("user."..accName,aclGetGroup("Admin")),isObjectInACLGroup("user."..accName,aclGetGroup("SuperModerator")),isObjectInACLGroup("user."..accName,aclGetGroup("Moderator")) 
        if isAdmin == true then 
            table.insert(t1,v) 
        elseif isSMOD == true then 
            table.insert(t2,v) 
        elseif isMod == true then 
            table.insert(t3,v) 
        end 
        return t1,t2,t3 
    end 
end 

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...